@extends('layouts.app')

@section('title')
    Add New Transfer
@stop

@section('breadcrumb')
    <ol class="breadcrumb pull-right">
        <li><a href="{{ route('home') }}"><i class="fa fa-dashboard"></i> Home</a></li>
        <li><a href="{{ route('transfer.all') }}">Transfers</a></li>
        <li class="active">Add New Transfer</li>
    </ol>
@stop

@section('css')

    <style type="text/css">
      .spanha{
        color: red;
      }

      .divider:after,
.divider:before {
  content: "";
  flex: 1;
  height: 1px;
  background: #eee;
}
    </style>

@stop

@section('content')

    <div class="container-fluid">
        <div class="row">

            <form method='post' autocomplete="off" action="{{ route('transfer.insert') }}" enctype="multipart/form-data">
                {{ csrf_field() }}
                <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box">
                        <h3 class="box-title m-b-0"><i class="icon-layers fa-fw"></i> Add New Transfer</h3>
                        <p class="text-muted m-b-30 font-13"> <span class="spanha">Note:</span> All * fields are mandatory </p>
                       


                     


                    </div>
                </div>

                {{-- Unit Information --}}
                <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box">
                        <h3 class="box-title m-b-0"><i class="icon-layers fa fa-building"></i> Unit Information</h3>

                        <hr>
                        <div class="clearfix"></div>
                      
                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label style="padding-top: 8px;" class="control-label col-md-4">Unit No<span
                                        style="color:red">*</span></label>
                                <div class="col-md-8">
                                    <select class="form-control  " id="property-no" name="property_id"
                                        onchange="updateSchedule()">
                                        <option value="" selected="">None</option>
                                        @foreach ($properties as $p)
                                            <option value="{{ $p->id }}">
                                                
                                                            @if ($p->unitNumber->registration)
                                                                {{ $p->unitNumber->registration->registrationNo->number }}
                                                            @endif
                                                            - {{ $p->unitNumber->unit_number }}
                                                        
                                                    
                                            </option>
                                        @endforeach
                                    </select>
                                    @if ($errors->has('property_id'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('property_id') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>


                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Owner Name</label>
                                <div class="col-md-8">

                                    <input type="text" readonly="" class="form-control" id="owner-name"
                                        name="owner_name" value="{{ old('owner_name') }}" placeholder="Owner Name">
                                    @if ($errors->has('owner-name'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('owner-name') }}</strong>
                                        </span>
                                    @endif

                                </div>
                            </div>
                        </div>

                        <br>

                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Old Ref #</label>
                                <div class="col-md-8">

                                    <input type="text" readonly="" class="form-control" id="old_client_id"
                                        name="old_client_id" value="{{ old('old_client_id') }}"
                                        placeholder="old_ref_no">
                                    @if ($errors->has('old_client_id'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('old_client_id') }}</strong>
                                        </span>
                                    @endif

                                </div>
                            </div>
                        </div>
                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Transfer Type</label>
                                <div class="col-md-8">

                                    <input type="text" readonly="" class="form-control" id="transfer_type"
                                         value="{{ old('transfer_type') }}"
                                        placeholder="transfer_type">
                                    @if ($errors->has('transfer_type'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('transfer_type') }}</strong>
                                        </span>
                                    @endif

                                </div>
                            </div>
                        </div>

                      
                        <br>

                      
                        <div class="clearfix"></div>


                    </div>
                     
                </div>
                {{-- End Unit Information --}}


                {{-- Customer Information --}}
                <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box">
                        <h3 class="box-title m-b-0"><i class="icon-layers fa fa-users"></i> Customer Information</h3>

                        <hr>
                        <div class="clearfix"></div>
                           {{-- Customer Information --}}

 



                                <!-- Nav tabs -->
                                <ul class="nav customtab nav-tabs" role="tablist"
                                    style="    background: #87c490;color: white;">
                                    <li style="    border: 1px solid #29b329;" role="presentation" class=""><a
                                            href="#home1" aria-controls="home" role="tab" data-toggle="tab"
                                            aria-expanded="true" style="font-weight: 700;"><span
                                                class="visible-xs"><i class="ti-home"></i></span><span
                                                class="hidden-xs"> New Customer</span></a></li>
                                    <li style="border: 1px solid #29b329;" role="presentation" class="active"><a
                                            href="#profile1" aria-controls="profile" role="tab"
                                            data-toggle="tab" aria-expanded="false" style="font-weight: 700;"><span
                                                class="visible-xs"><i class="ti-user"></i></span> <span
                                                class="hidden-xs">Existing Customer</span></a></li>

                                </ul>
                                <!-- Tab panes -->
                                <div class="tab-content">
                                    <div role="tabpanel" class="tab-pane fade active in" id="profile1">
                                        <div class="col-md-6">
                                            <div class="form-group">
                                                <label class="control-label col-md-4" style="margin-left: -24px;">Name of Applicant</label>
                                                <div class="col-md-4" style="width: 405px;">
                                                    <select class="form-control  " name="customer_id"
                                                        autofocus="off" style="width: 100%!important;">
                                                        <option value="" selected="" disabled="">None
                                                        </option>
                                                        @foreach ($customers as $c)
                                                            @if (isset($customer))
                                                                @if ($customer->id == $c->id)
                                                                    <option value="{{ $c->id }}"
                                                                        selected="">{{ $c->name }}
                                                                    </option>
                                                                @endif
                                                            @else
                                                                @if (old('customer_id') == $c->id)
                                                                    <option value="{{ $c->id }}"
                                                                        selected="">{{ $c->name }}
                                                                    </option>
                                                                @else
                                                                    <option value="{{ $c->id }}">
                                                                        {{ $c->name }}</option>
                                                                @endif
                                                            @endif
                                                        @endforeach
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="clearfix"></div>
                                        {{-- <button type="button" style="float: left!important;"
                                            class="btn btn-primary add_field_button1">Add Nominee</button> --}}
                                        <div class="input_fields_wrap2">
                                            <div class="clearfix"></div>
                                            <div>
                                            </div>


                                        </div>
                                    </div>




                                    <div role="tabpanel" class="tab-pane fade  " id="home1">

                                        <div class="form-body">
                                            <div class="row">
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Name of Applicant
                                                            <span style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="name" value="{{ old('name') }}"
                                                                placeholder="Enter Name">
                                                            @if ($errors->has('name'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('name') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">S/O D/O W/O <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="father_name"
                                                                value="{{ old('father_name') }}" placeholder="">
                                                            <input type="radio" name="father_type"
                                                                value="1">S/O
                                                            <input type="radio" name="father_type"
                                                                value="2">D/O
                                                            <input type="radio" name="father_type"
                                                                value="3"> W/O
                                                            @if ($errors->has('father_name'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('father_name') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">CNIC <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                value="{{ old('cnic') }}" name="cnic"
                                                                id="cnic"
                                                                data-inputmask="'mask': '9999999999999'"
                                                                placeholder="XXXXXXXXXXXXX">
                                                            <input type="radio" name="cnic_flag"
                                                                value="1"> Locally
                                                            <input type="radio" name="cnic_flag"
                                                                value="2"> Internationally
                                                            @if ($errors->has('cnic'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('cnic') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Passport No.</label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                value="{{ old('passport_no') }}"
                                                                name="passport_no" id="passport_no"
                                                                placeholder="XXXXXXXXX">
                                                            @if ($errors->has('passport_no'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('passport_no') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Date of Birth <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="date" class="form-control"
                                                                value="{{ old('dob') }}" name="dob"
                                                                max="{{ date('Y-m-d') }}" id="dob"
                                                                placeholder="XX-XX-XXXX">
                                                            @if ($errors->has('dob'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('dob') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Enter Occupation </label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                value="{{ old('occupation') }}" name="occupation"
                                                                id="occupation" placeholder="Occupation">
                                                            @if ($errors->has('occupation'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('occupation') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>



                                                <div class="clearfix"></div>
                                                <div class="col-md-6" style="margin-top: 20px;">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Mailing Address <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <textarea class="form-control" name="mailing_address" id="mailing_address" style="width: 362px; height: 45px;" placeholder="Enter Mailing Address">{{ old('mailing_address') }}</textarea>
                                                            @if ($errors->has('mailing_address'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('mailing_address') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4" style="margin-top: 20px;">Permanent Address
                                                            <span style="color: red">*</span></label> &nbsp;
                                                        &nbsp;&nbsp; same as Mailing Address <input type="checkbox"
                                                            id="same_address" name="same_address">
                                                        <div class="col-md-8">
                                                            <textarea class="form-control" name="permanent_address" id="permanent_address" style="width: 362px; height: 45px;" placeholder="">{{ old('permanent_address') }}</textarea>
                                                            @if ($errors->has('permanent_address'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('permanent_address') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Email</label>
                                                        <div class="col-md-8">
                                                            <input type="email" class="form-control"
                                                                name="email" value="{{ old('email') }}"
                                                                id="exampleInputEmail1" placeholder="Enter email">

                                                            @if ($errors->has('address'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('address') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Password</label>
                                                        <div class="col-md-8">
                                                            <input type="password" class="form-control"
                                                                name="password" value="{{ old('password') }}"
                                                                id="exampleInputEmail1"
                                                                placeholder="Enter Password">

                                                            @if ($errors->has('password'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('password') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>


                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Mobile Number <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                type='number' name="mobile_number"
                                                                value="{{ old('mobile_number') }}"
                                                                placeholder="Enter Mobile Number">
                                                            <label style="text-align: right">Note (use comma for
                                                                multiple numbers)</label>
                                                            @if ($errors->has('mobile_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('mobile_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>


                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Phone Number</label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                type='number' name="phone_number"
                                                                value="{{ old('phone_number') }}"
                                                                placeholder="Enter Phone Number">
                                                            @if ($errors->has('phone_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('phone_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>


                                                <div class="clearfix"></div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Residential
                                                            Number</label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                name="res_number" value="{{ old('res_number') }}"
                                                                placeholder="Enter Res. Number">
                                                            @if ($errors->has('res_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('res_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                               <!--  -->
                                               <div class="form-group" style="height: 0px;">
                                                    <label for="exampleInputEmail1"
                                                        class="col-sm-2 control-label" style="margin-left: 15px; ">Picture <span
                                                            style="color: red">*</span></label>
                                                    <div class="col-sm-20">
                                                        <div class="input-group" style="width: 365px; margin-left: -12px;">
                                                            <div class="input-group-addon"><i
                                                                    class="icon-picture"></i></div>
                                                            <input type="file" class="form-control"
                                                                name="file">
                                                            @if ($errors->has('file'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('file') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                               <!--  -->
                                                <div class="clearfix"></div>
                                                

                                                <div class="form-group">
                                                    <label for="exampleInputEmail1"
                                                        class="col-sm-2 control-label" style="width: 150px; margin-left: 15px;">Documents (CNIC, Passport
                                                        etc) <span style="color: red">*</span></label>
                                                    <div class="col-md-4" style="margin-left: 43px;">
                                                        <div class="input-group" style="width: 365px;">
                                                            <div class="input-group-addon"><i
                                                                    class="icon-picture"></i></div>
                                                            <input multiple="" type="file"
                                                                class="form-control" name="photos[]">
                                                            @if ($errors->has('document'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('document') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>
                                                <hr>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Nominee Name <span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="nominee_name"
                                                                value="{{ old('nominee_name') }}"
                                                                id="exampleInputuname" placeholder="Enter Name">
                                                            @if ($errors->has('nominee_name'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_name') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">S/O, D/O, W/O.<span
                                                                style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="nominee_so_do_wo"
                                                                value="{{ old('nominee_so_do_wo') }}"
                                                                id="exampleInputuname"
                                                                placeholder="Enter Father Name">
                                                            <input type="radio" name="nominee_father_type"
                                                                value="1">S/O
                                                            <input type="radio" name="nominee_father_type"
                                                                value="2">D/O
                                                            <input type="radio" name="nominee_father_type"
                                                                value="3"> W/O
                                                            @if ($errors->has('nominee_so_do_wo'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_so_do_wo') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">CNIC</label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                value="{{ old('nominee_cnic') }}"
                                                                name="nominee_cnic" id="nominee_cnic"
                                                                data-inputmask="'mask': '9999999999999'"
                                                                placeholder="XXXXXXXXXXXXX">
                                                            <input type="radio" name="nominee_cnic_flag"
                                                                value="1"> Locally
                                                            <input type="radio" name="nominee_cnic_flag"
                                                                value="2"> Internationally
                                                            @if ($errors->has('nominee_cnic'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_cnic') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Passport No.</label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                value="{{ old('nominee_passport_no') }}"
                                                                name="nominee_passport_no"
                                                                id="nominee_passport_no" placeholder="XXXXXXXXX">
                                                            @if ($errors->has('nominee_passport_no'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_passport_no') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Relation With
                                                            Applicant <span style="color: red">*</span></label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="nominee_relation"
                                                                value="{{ old('nominee_relation') }}"
                                                                placeholder="Enter Relation">
                                                            @if ($errors->has('nominee_relation'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_relation') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Email</label>
                                                        <div class="col-md-8">
                                                            <input type="text" class="form-control"
                                                                name="nominee_email"
                                                                value="{{ old('nominee_email') }}"
                                                                placeholder="Enter Email">
                                                            @if ($errors->has('nominee_email'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_email') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>

                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Mobile Number
                                                        </label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                name="nominee_mobile_number"
                                                                value="{{ old('nominee_mobile_number') }}"
                                                                placeholder="Enter Mobile Number">
                                                            @if ($errors->has('nominee_mobile_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_mobile_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>


                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Res. Number </label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                name="nominee_res_number"
                                                                value="{{ old('nominee_res_number') }}"
                                                                placeholder="Enter Res Number">
                                                            @if ($errors->has('nominee_res_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_res_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="clearfix"></div>
                                                <div class="col-md-6">
                                                    <div class="form-group">
                                                        <label class="control-label col-md-4">Phone Number </label>
                                                        <div class="col-md-8">

                                                            <input type="text" class="form-control"
                                                                name="nominee_phone_number"
                                                                value="{{ old('nominee_phone_number') }}"
                                                                placeholder="Enter Phone Number">
                                                            @if ($errors->has('nominee_phone_number'))
                                                                <span class="help-block">
                                                                    <strong>{{ $errors->first('nominee_phone_number') }}</strong>
                                                                </span>
                                                            @endif
                                                        </div>
                                                    </div>
                                                </div>

                                                <div class="clearfix"></div>


                                            </div>

                                            <div class="clearfix"></div>
                                        </div>
                                    </div>
                                </div>

                         

                        {{-- End Customer Information --}}
                    </div>
                </div>
                {{-- End Customer Information --}}


                {{-- Check List --}}
                {{-- <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box">
                        <h3 class="box-title m-b-0"><i class="icon-layers fa fa-file-text"></i> Required Documents </h3>

                        <hr>
                        <div class="clearfix"></div>
                <section class="vh-100"  >
                    <div class="container py-5 h-100">
                      <div class="row d-flex justify-content-center align-items-center h-100">
                        <div class="col col-lg-8 col-xl-6">
                          <div class="card rounded-3">
                            <div class="card-body p-4">
                  
                              <p class="mb-2"><span class="h2 me-2">Documents</span> <span
                                  class="badge bg-danger">checklist</span></p>
                             
                              <ul class="list-group rounded-0">
                                <li class="list-group-item border-0 d-flex align-items-center ps-0">
                                  <input class="form-check-input me-3" type="checkbox" value="" aria-label="..." checked />
                                  <s>Task list and assignments</s>
                                  
                                </li>
                                <li class="list-group-item border-0 d-flex align-items-center ps-0">
                                  <input class="form-check-input me-3" type="checkbox" value="" aria-label="..." />
                                  Set due date and assignments
                                </li>
                                <li class="list-group-item border-0 d-flex align-items-center ps-0">
                                  <input class="form-check-input me-3" type="checkbox" value="" aria-label="..." />
                                  Remove duplicate tasks and stories
                                </li>
                                <li class="list-group-item border-0 d-flex align-items-center ps-0">
                                  <input class="form-check-input me-3" type="checkbox" value="" aria-label="..." />
                                  Update the userflow and stories
                                </li>
                                <li class="list-group-item border-0 d-flex align-items-center ps-0">
                                  <input class="form-check-input me-3" type="checkbox" value="" aria-label="..." />
                                  Adjust the components
                                </li>
                              </ul>
                  
                             
                  
                            </div>
                          </div>
                        </div>
                      </div>
                    </div>
                  </section>
                    </div>
                </div> --}}
                {{-- End Check List --}}


                {{-- Transfer Information --}}
                <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box-2">
                        <h3 class="box-title m-b-0"  ><i class="icon-layers fa fa-exchange"></i> Transfer Information</h3>

                        <hr>
                        <div class="clearfix"></div>
                          {{-- Transfer Charges  --}}
                          <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Transfer Charges <span
                                        style="color: red">*</span></label>
                                <div class="col-md-8">

                                    <input type="text" class="form-control" id="transfer_charges"
                                        name="transfer_charges" value="{{ old('transfer_charges') }}"
                                        placeholder="Enter Transfer Charges">
                                    @if ($errors->has('transfer_charges'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('transfer_charges') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>



                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Transfer Date <span
                                        style="color:red">*</span></label>
                                <div class="col-md-8">

                                    <input type="date" class="form-control" name="transfer_date"
                                        value="{{ old('transfer_date') }}" id="exampleInputEmail1"
                                        placeholder="Transfer Date">
                                    @if ($errors->has('transfer_date'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('transfer_date') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>

                        <br>

                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Cost Of unit</label>
                                <div class="col-md-8">

                                    <input type="text" readonly="" id='cost-amount' class="form-control"
                                        name="cost" value="{{ old('cost') }}" placeholder="Cost Amount">
                                    @if ($errors->has('cost'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('cost') }}</strong>
                                        </span>
                                    @endif
                                    <div style="color:black;" class="help-block" id='cost-amount-label'></div>
                                </div>
                            </div>
                        </div>


                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Transfer Note</label>
                                <div class="col-md-8">

                                    <textarea class="form-control" name="transfer_note" placeholder="Add Transfer Note..."value="{{ old('transfer_note') }}"></textarea>
                                    @if ($errors->has('transfer_note'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('transfer_note') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>




                        <br>

                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Received Amount</label>
                                <div class="col-md-8">

                                    <input type="text" class="form-control" readonly=""
                                        id="received-amount" name="received_amount"
                                        value="{{ old('received_amount') }}">
                                    @if ($errors->has('received_amount'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('received_amount') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>

                        <div class="col-md-6" style="margin-bottom: 10px;">
                            <div class="form-group">
                                <label class="control-label col-md-4">Pending Due</label>
                                <div class="col-md-8">

                                    <input type="text" class="form-control" disabled="" id="pending_due"
                                        name="pending_due" value="{{ old('pending_due') }}">
                                    @if ($errors->has('pending_due'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('pending_due') }}</strong>
                                        </span>
                                    @endif
                                </div>
                            </div>
                        </div>

                        {{-- End Transfer Charges  --}}
                        <div class="form-group m-b-0 pull-right">
                            <div class="col-sm-offset-3 col-sm-9">
                                <button type="submit" class="btn btn-info  waves-effect waves-light ">Save</button>
                            </div>
                        </div>
                    </div>
                </div>
                 {{-- End Transfer Information --}}

                <!--receipt module -->
                {{-- <div class="col-lg-12 col-sm-12 col-xs-12">
                    <div class="white-box">
                        <h3 class="box-title">Receipt Info</h3>
                        <hr>
                        <div id="receipt_div" style="margin-bottom: 40px;">

                            <div class="col-md-6" style="margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Payment Head <span
                                          style="color: red">*</span></label>
                                    <div class="col-md-8">
                                        <select class="form-control chosen-select" name="payment_head">
                                            @if (old('payment_head') == \App\Receipt::transfer_fee)
                                                <option value="{{ \App\Receipt::transfer_fee }}" selected="">Transfer
                                                    Fee</option>
                                            @else
                                                <option value="{{ \App\Receipt::transfer_fee }}">Transfer Fee</option>
                                            @endif
                                        </select>
                                        @if ($errors->has('payment_head'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('payment_head') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6" style="margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Payment Mode <span
                                            style="color: red">*</span></label>
                                    <div class="col-md-8">
                                        <select class="form-control chosen-select" name='payment_mode'
                                            onchange="changeFunc(this.value)">
                                            @if (old('payment_mode') == \App\Receipt::cash)
                                                <option value="{{ \App\Receipt::cash }}" selected="">Cash</option>
                                                <option value="{{ \App\Receipt::bank }}">Bank Transfer</option>
                                                <option value="{{ \App\Receipt::cheque }}">Cheque</option>
                                                <option value="{{ \App\Receipt::adjustment }}">Adjustment</option>
                                            @elseif(old('payment_mode') == \App\Receipt::bank)
                                                <option value="{{ \App\Receipt::cash }}">Cash</option>
                                                <option value="{{ \App\Receipt::bank }}" selected="">Bank Transfer
                                                </option>
                                                <option value="{{ \App\Receipt::cheque }}">Cheque</option>
                                                <option value="{{ \App\Receipt::adjustment }}">Adjustment</option>
                                            @elseif(old('payment_mode') == \App\Receipt::cheque)
                                                <option value="{{ \App\Receipt::cash }}">Cash</option>
                                                <option value="{{ \App\Receipt::bank }}">Bank Transfer</option>
                                                <option value="{{ \App\Receipt::cheque }}" selected="">Cheque</option>
                                                <option value="{{ \App\Receipt::adjustment }}">Adjustment</option>
                                            @elseif(old('payment_mode') == \App\Receipt::cheque)
                                                <option value="{{ \App\Receipt::cash }}">Cash</option>
                                                <option value="{{ \App\Receipt::bank }}">Bank Transfer</option>
                                                <option value="{{ \App\Receipt::cheque }}" selected="">Cheque</option>
                                                <option selected="" value="{{ \App\Receipt::adjustment }}">Adjustment
                                                </option>
                                            @else
                                                <option selected='' value="{{ \App\Receipt::cash }}" selected="">
                                                    Cash</option>
                                                <option value="{{ \App\Receipt::bank }}">Bank Transfer</option>
                                                <option value="{{ \App\Receipt::cheque }}">Cheque</option>
                                                <option value="{{ \App\Receipt::adjustment }}">Adjustment</option>
                                            @endif
                                        </select>
                                        @if ($errors->has('payment_mode'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('payment_mode') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6" id='bank' style="display: none;margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Depositor Bank Name</label>
                                    <div class="col-md-8">
                                        <select name="bank_name" class="form-control chosen-select">
                                            <option value="" selected="">None</option>
                                            @foreach ($banks as $bank)
                                                @if (old('bank_name') == $bank->id)
                                                    <option selected="" value="{{ $bank->id }}">
                                                        {{ $bank->name }}</option>
                                                @else
                                                    <option value="{{ $bank->id }}">{{ $bank->name }}</option>
                                                @endif
                                            @endforeach
                                        </select>
                                        @if ($errors->has('bank_name'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('bank_name') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>
                            <div id='adjustment' style="display: none;">
                                <div class="col-md-6" style="margin-bottom: 10px;">
                                    <div class="form-group">
                                        <label class="control-label col-md-4">Adjustment Type <span
                                                style="color: red">*</span></label>
                                        <div class="col-md-8">
                                            <select class="form-control chosen-select" name='adjustment_type'>
                                                @if (old('adjustment_type') == \App\ProjectAccount::property)
                                                    <option value="{{ \App\ProjectAccount::property }}" selected="">
                                                        Property</option>
                                                    <option value="{{ \App\ProjectAccount::vehicle }}">Vehicle</option>
                                                    <option value="{{ \App\ProjectAccount::others }}">Others</option>
                                                @elseif(old('adjustment_type') == \App\ProjectAccount::vehicle)
                                                    <option value="{{ \App\ProjectAccount::property }}">Property</option>
                                                    <option value="{{ \App\ProjectAccount::vehicle }}" selected="">
                                                        Vehicle</option>
                                                    <option value="{{ \App\ProjectAccount::others }}">Others</option>
                                                @elseif(old('adjustment_type') == \App\ProjectAccount::others)
                                                    <option value="{{ \App\ProjectAccount::property }}">Property</option>
                                                    <option value="{{ \App\ProjectAccount::vehicle }}">Vehicle</option>
                                                    <option value="{{ \App\ProjectAccount::others }}" selected="">
                                                        Others</option>
                                                @else
                                                    <option selected='' value="{{ \App\ProjectAccount::property }}"
                                                        selected="">Property</option>
                                                    <option value="{{ \App\ProjectAccount::vehicle }}">Vehicle</option>
                                                    <option value="{{ \App\ProjectAccount::others }}">Others</option>
                                                @endif
                                            </select>
                                            @if ($errors->has('adjustment_type'))
                                                <span class="help-block">
                                                    <strong>{{ $errors->first('adjustment_type') }}</strong>
                                                </span>
                                            @endif
                                        </div>
                                    </div>
                                </div>
                                <div class="col-md-6" style="margin-bottom: 10px;">
                                    <div class="form-group">
                                        <label class="control-label col-md-4">Adjustment Detail <span
                                                style="color: red">*</span></label>
                                        <div class="col-md-8">
                                            <textarea name="adjustment_detail" class="form-control"></textarea>

                                            @if ($errors->has('adjustment_detail'))
                                                <span class="help-block">
                                                    <strong>{{ $errors->first('adjustment_detail') }}</strong>
                                                </span>
                                            @endif
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6" id='company-bank' style="display: none;margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Company Account</label>
                                    <div class="col-md-8">
                                        <select name="company_account" class="form-control chosen-select">
                                            <option value="" selected="">None</option>
                                            @foreach ($cBanks as $bank)
                                                @if (old('bank_name') == $bank->id)
                                                    <option selected="" value="{{ $bank->id }}">
                                                        {{ $bank->name }} - {{ $bank->account_number }}</option>
                                                @else
                                                    <option value="{{ $bank->id }}">{{ $bank->name }} -
                                                        {{ $bank->account_number }}</option>
                                                @endif
                                            @endforeach
                                        </select>
                                        @if ($errors->has('company_account'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('company_account') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>
                            <div class="col-md-6" id='cheque' style="display: none;margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Cheque Number</label>
                                    <div class="col-md-8">
                                        <input type="text" name='cheque_number' value="{{ old('cheque_number') }}"
                                            class="form-control" id="exampleInputEmail1"
                                            placeholder="Enter Check Number">
                                        @if ($errors->has('cheque_number'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('cheque_number') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>
                            <div class="clearfix"></div>
                            <div class="col-md-6" style="margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Amount <span style="color: red">*</span></label>
                                    <div class="col-md-8">
                                        <input type="text" name="amount" value="{{ old('amount') }}"
                                            class="form-control" id="receipt_amount" placeholder="Enter Amount">
                                        @if ($errors->has('amount'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('amount') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>

                            <div class="col-md-6" style="margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Receipt Date <span
                                            style="color: red">*</span></label>
                                    <div class="col-md-8">
                                        <input type="date" class="form-control" name='receipt_date'
                                            value="{{ old('receipt_date') }}" id="receipt_date"
                                            placeholder="Enter Registration Date">
                                        @if ($errors->has('receipt_date'))
                                            <span class="help-block">
                                                <strong>{{ $errors->first('receipt_date') }}</strong>
                                            </span>
                                        @endif
                                    </div>
                                </div>
                            </div>

                            <br>
                            <div class="clearfix"></div>

                           
                            <div class="col-md-6" style="margin-bottom: 10px;">
                                <div class="form-group">
                                    <label class="control-label col-md-4">Receipt Number<span style="color: red">*</span></label>
                                <div class="col-md-8">
                                    @if(old('receipt_no'))
                                    <input type="text" class="form-control" name='receipt_no' value="{{old('receipt_no')}}" id="exampleInputEmail1" placeholder="Enter Receipt Number">
                                    @else
                                    <input type="text" class="form-control" name='receipt_no' value="{{$receipt_no}}" id="exampleInputEmail1" placeholder="Enter Receipt Number">
                                    @endif
                                    <!--<input type="text" class="form-control" name='receipt_no' value="{{old('receipt_no')}}" id="exampleInputEmail1" placeholder="Enter Receipt Number">-->
                                    @if ($errors->has('receipt_no'))
                                        <span class="help-block">
                                            <strong>{{ $errors->first('receipt_no') }}</strong>
                                        </span>
                                    @endif
                                </div>
                                </div>
                          </div>

                        </div>--}}

                        <!-- <hr> -->

                        {{-- <br>
                      

                    </div>
                </div>  --}}
              
               
            </form>
        </div>
    </div>


@stop

@section('js')

    <script src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/3/jquery.inputmask.bundle.js"></script>

    <script>
        $(":input").inputmask();
        $(document).ready(function() {
    $('.js-example-basic-single').select2();
});

        function updateSchedule() {
            $('.preloader').fadeIn();
            var id = $('#property-no').val();

            var data = {
                'id': id
            };

            $.get('/transfer/updateInfo', data, function(data) {

                if (data) {
                    $('#cost-amount').val(new Intl.NumberFormat().format(data['info'].net_pay));
                    $('#owner-name').val(data['info'].customer.name);
                    $('#old_client_id').val(data['info'].membership_no);
                    $('#received-amount').val(new Intl.NumberFormat().format(data['received']));

                    $('#transfer_type').val();
                    $('#pending_due').val(new Intl.NumberFormat().format(data['due']));

                    // if (data['due'] > 0) {
                    //     toastr.error('Pending Due Amount.');
                    // }
                    $('#transfer_type').empty();
                   if(data['transfer_type'] ==  {{\App\TransferProperty::normal_transfer}})
                   {
                 $('#transfer_type').val('Normal Transfer');
                   }
                   else  if(data['transfer_type'] ==  {{\App\TransferProperty::gift_transfer}})
                   {
                    $('#transfer_type').val('Gift Transfer');
                   }

                   else  if(data['transfer_type'] ==  {{\App\TransferProperty::family_transfer}})
                   {
                    $('#transfer_type').val('Family Transfer');
                   }
                   else  if(data['transfer_type'] ==   {{\App\TransferProperty::death_transfer}})
                   {
                    $('#transfer_type').val('Death Transfer');
                   }


                    
                     
                    
                    
                    
                }

            });
            $('.preloader').fadeOut();
        }

        $('#country_id').change(function() {
            $('.preloader').fadeIn();
            var data = {
                'country_id': $(this).val()
            };

            $.get('/getCitiesByCountry', data, function(data) {
                var model = $('#city_id');
                model.empty();

                model.append("<option value='' disabled selected>" + '' + "</option>");


                $.each(data, function(index, element) {
                    model.append("<option value='" + element.id + "'>" + element.name +
                    "</option>");
                });
            });
            $('.preloader').fadeOut();
        });
    </script>


@stop
