@extends('layouts.master') @section('title') {{ translate('add check_out') }} @endsection @section('content')
{{ translate('add check_out') }}
{!! Form::open(array('url' => url('check_out/store'), 'method' => 'post', 'class' => 'form-horizontal', 'name' => 'form',"enctype"=>"multipart/form-data")) !!}
{!! Form::label('date',translate('date'),array('class'=>'')) !!} {!! Form::text('date',date("Y-m-d"), array('class' => 'form-control date-picker', 'placeholder'=>"",'required'=>'required')) !!}
{!! Form::label('borrower_id',translate('borrower'),array('class'=>'')) !!} {!! Form::select('borrower_id',$borrowers,null, array('class' => 'form-control select2', 'placeholder'=>"",'required'=>'required')) !!}
{!! Form::label('products',translate('product'),array('class'=>'')) !!} {!! Form::select('products',$products,null, array('class' => 'form-control select2', 'placeholder'=>translate('select').' '.translate('product'),'id'=>'products')) !!}

{{translate('order item')}}

{{translate('item')}} {{translate('qty')}} {{translate('unit_cost')}} {{translate('total')}}
{{translate('total')}}
{{translate('paid')}}
{{translate('payment method')}} {!! Form::select('payment_method_id',$payment_methods,null, array('class' => 'form-control', 'placeholder'=>"")) !!}
{!! Form::label('type',translate('type'),array('class'=>'')) !!} {!! Form::select('type',['cash'=>translate('cash'),'loan'=>translate('loan')],'cash', array('class' => 'form-control', 'id'=>"type",'required'=>'required')) !!}
{!! Form::label('loan_officer_id',translate('loan_officer')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('loan_officer_id',$users,null, array('class' => ' select2 form-control', 'placeholder'=>"Select",'id'=>'loan_officer_id')) !!}
{!! Form::label('loan_product_id',translate('loan').' '.translate('product')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('loan_product_id',$loan_products,$loan_product->id, array('class' => 'form-control select2','required'=>'required','id'=>'loanProduct')) !!}
{!! Form::label('principal',translate('principal').' '.translate('amount')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::text('principal',$loan_product->default_principal, array('class' => 'form-control touchspin', 'id'=>"principal",'required'=>'required')) !!}
{!! Form::label('loan_duration',translate('loan').' '.translate('duration')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::number('loan_duration',$loan_product->default_loan_duration, array('class' => 'form-control', 'placeholder'=>"5",'required'=>'required','id'=>'loan_duration')) !!}
{!! Form::select('loan_duration_type',array('day'=>translate('day').'(s)','week'=>translate('week').'(s)','month'=>translate('month').'(s)','year'=>translate('year').'(s)'),$loan_product->default_loan_duration_type, array('class' => 'form-control',"id"=>"loan_duration_type",'required'=>'required')) !!}
{!! Form::label('repayment_cycle',translate('repayment_cycle')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('repayment_cycle',array('daily'=>translate('daily'),'weekly'=>translate('weekly'),'monthly'=>translate('monthly'),'bi_monthly'=>translate('bi_monthly'),'quarterly'=>translate('quarterly'),'semi_annual'=>translate('semi_annually'),'annual'=>translate('annual')),$loan_product->repayment_cycle, array('class' => 'form-control',"id"=>"repayment_cycle",'required'=>'required')) !!}
{!! Form::label('release_date',translate('expected').' '.translate('disbursement').' '.translate('date')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::text('release_date',null, array('class' => 'form-control date-picker', 'placeholder'=>"yyyy-mm-dd",'required'=>'required','id'=>'release_date')) !!}
{!! Form::label('first_payment_date',translate('first').' '.translate('payment').' '.translate('date')." ",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::text('first_payment_date',null, array('class' => 'form-control date-picker', 'placeholder'=>"yyyy-mm-dd",''=>'','id'=>'first_payment_date')) !!}
{!! Form::label('interest_method',translate('interest').' '.translate('method')." *",array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('interest_method',array('flat_rate'=>translate('flat_rate'),'declining_balance_equal_installments'=>translate('declining_balance_equal_installments'),'declining_balance_equal_principal'=>translate('declining_balance_equal_principal'),'interest_only'=>translate('interest_only')),$loan_product->interest_method, array('class' => 'form-control','required'=>'required','id'=>'interest_method')) !!}
{!! Form::label('interest_rate',translate('loan').' '.translate('interest').' (%) *',array('class'=>'col-sm-3 control-label')) !!}
{!! Form::text('interest_rate',$loan_product->default_interest_rate, array('class' => 'form-control touchspin', 'id'=>"interest_rate",'required'=>'required')) !!}
{!! Form::select('interest_period',array('day'=>translate('per_day'),'week'=>translate('per_week'),'month'=>translate('per_month'),'year'=>translate('per_year')),$loan_product->interest_period, array('class' => 'form-control', "id"=>"interest_period",'required'=>'required')) !!}
{!! Form::label('override_interest',translate('override').' '.translate('interest'),array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('override_interest',array('0'=>translate('no'),'1'=>translate('yes')),0, array('class' => 'form-control','id'=>'override_interest')) !!}
{!! Form::label('override_interest_amount',translate('override').' '.translate('interest').' %',array('class'=>'col-sm-3 control-label')) !!}
{!! Form::text('override_interest_amount',0, array('class' => 'form-control touchspin','id'=>'override_interest_amount')) !!}
{!! Form::label('grace_on_interest_charged',translate('grace_on_interest'),array('class'=>'col-sm-3 control-label')) !!}
{!! Form::number('grace_on_interest_charged',$loan_product->grace_on_interest_charged, array('class' => 'form-control', 'placeholder'=>"2")) !!}
{!! Form::label('decimal_places',translate('decimal_place'),array('class'=>'col-sm-3 control-label')) !!}
{!! Form::select('decimal_places',array('round_off_to_two_decimal'=>translate('round_off_to_two_decimal'),'round_off_to_integer'=>translate('round_off_to_integer')),$loan_product->decimal_places, array('class' => 'form-control',"id"=>"",'required'=>'required')) !!}
{!! Form::label('description',translate('description'),array('class'=>'col-sm-3 control-label')) !!}
{!! Form::textarea('description',null, array('class' => 'form-control', 'rows'=>"3")) !!}
{!! Form::label('files',translate('loan').' '.translate('file').'('.translate('borrower_file_types').')',array('class'=>'col-sm-3 control-label')) !!}
{!! Form::file('files[]', array('class' => 'form-control file-styled', 'multiple'=>"multiple")) !!}
@foreach($loan_product->charges as $key) @if(!empty($key->charge)) @endif @endforeach
{{translate('name')}} {{translate('type')}} {{translate('amount')}} {{translate('collected on')}} {{translate('date')}}
{{ $key->charge->name }} @if($key->charge->charge_option=="fixed") {{translate('fixed')}} @endif @if($key->charge->charge_option=="principal_due") % {{translate('principal due')}} @endif @if($key->charge->charge_option=="principal_interest") % {{translate('principal')}} + {{translate('interest due')}} @endif @if($key->charge->charge_option=="interest_due") % {{translate('interest due')}} @endif @if($key->charge->charge_option=="total_due") % {{translate('total due')}} @endif @if($key->charge->charge_option=="original_principal") % {{translate('original principal')}} @endif @if($key->charge->override==1) @else {{$key->charge->amount}} @endif @if($key->charge->charge_type=='disbursement') {{translate('disbursement')}} @endif @if($key->charge->charge_type=='specified_due_date') {{translate('specified_due_date')}} @endif @if($key->charge->charge_type=='installment_fee') {{translate('installment_fee')}} @endif @if($key->charge->charge_type=='overdue_installment_fee') {{translate('overdue_installment_fee')}} @endif @if($key->charge->charge_type=='loan_rescheduling_fee') {{translate('loan_rescheduling_fee')}} @endif @if($key->charge->charge_type=='overdue_maturity') {{translate('overdue_maturity')}} @endif @if($key->charge->charge_type=='savings_activation') {{translate('savings_activation')}} @endif @if($key->charge->charge_type=='withdrawal_fee') {{translate('withdrawal_fee')}} @endif @if($key->charge->charge_type=='monthly_fee') {{translate('monthly_fee')}} @endif @if($key->charge->charge_type=='annual_fee') {{translate('annual_fee')}} @endif @if($key->charge->charge_type=='specified_due_date') @else @endif

{{translate('custom_field')}}

@foreach($custom_fields as $key)
{!! Form::label($key->id,$key->name,array('class'=>'')) !!}
@if($key->field_type=="number") @endif @if($key->field_type=="textfield") @endif @if($key->field_type=="date") @endif @if($key->field_type=="textarea") @endif @if($key->field_type=="decimal") @endif
@endforeach
{!! Form::close() !!}
@endsection @section('footer-scripts') @endsection