@extends('layouts.app') @section('title', __('accounting-reports::lang.add_cheque_book')) @section('content')

@lang('accounting-reports::lang.add_cheque_book')

@if(session('error'))
{{ session('error') }}
@endif @if($errors->any())
@endif {!! Form::open(['url' => route('accounting-reports.cheque-books.store'), 'method' => 'post', 'id' => 'add_cheque_book_form']) !!}

@lang('accounting-reports::lang.cheque_book_details')

{!! Form::label('account_id', __('accounting-reports::lang.bank_account') . ':*') !!} {!! Form::select('account_id', $accounts, $selectedAccountId, [ 'class' => 'form-control select2', 'placeholder' => __('messages.please_select'), 'style' => 'width:100%', 'id' => 'account_id' ]) !!} @error('account_id') {{ $message }} @enderror @if(empty($accounts)) @lang('accounting-reports::lang.no_bank_accounts_found') @endif
{!! Form::label('book_name', __('accounting-reports::lang.book_name') . ':*') !!} {!! Form::text('book_name', old('book_name'), ['class' => 'form-control', 'placeholder' => __('accounting-reports::lang.book_name')]) !!}

@lang('accounting-reports::lang.example'): Book 1, Book A, etc.

{!! Form::label('book_number', __('accounting-reports::lang.book_number') . ':') !!} {!! Form::text('book_number', old('book_number'), ['class' => 'form-control', 'placeholder' => __('accounting-reports::lang.book_number')]) !!}

@lang('accounting-reports::lang.book_number_from_bank')

{!! Form::label('location_id', __('purchase.business_location') . ':') !!} {!! Form::select('location_id', $locations, old('location_id'), [ 'class' => 'form-control select2', 'placeholder' => __('messages.please_select'), 'style' => 'width:100%' ]) !!}
{!! Form::label('start_cheque_no', __('accounting-reports::lang.start_cheque_no') . ':*') !!} {!! Form::text('start_cheque_no', old('start_cheque_no'), [ 'class' => 'form-control', 'placeholder' => __('accounting-reports::lang.example') . ': 0001', 'id' => 'start_cheque_no' ]) !!}

@lang('accounting-reports::lang.starting_cheque_number')

{!! Form::label('end_cheque_no', __('accounting-reports::lang.end_cheque_no') . ':*') !!} {!! Form::text('end_cheque_no', old('end_cheque_no'), [ 'class' => 'form-control', 'placeholder' => __('accounting-reports::lang.example') . ': 0030', 'id' => 'end_cheque_no' ]) !!}

@lang('accounting-reports::lang.ending_cheque_number')

{!! Form::label('issue_date', __('accounting-reports::lang.issue_date') . ':') !!}
{!! Form::text('issue_date', old('issue_date', @format_date('now')), ['class' => 'form-control date-picker', 'readonly']) !!}
{!! Form::label('expiry_date', __('accounting-reports::lang.expiry_date') . ':') !!}
{!! Form::text('expiry_date', old('expiry_date'), ['class' => 'form-control date-picker', 'readonly']) !!}
{!! Form::label('notes', __('accounting-reports::lang.description') . ':') !!} {!! Form::textarea('notes', old('notes'), ['class' => 'form-control', 'rows' => '3', 'placeholder' => __('accounting-reports::lang.description')]) !!}
{!! Form::close() !!}
@endsection @section('javascript') @endsection