@extends('layouts.master')
@section('page_title')
    @if(isset($page_title))
        {{ $page_title }}
    @endif
@endsection
@section('content')
  <div class="">
    <div class="page-title">
      <div class="title_left" style="width:800px !important;">
        <ol class="breadcrumb">
          <li><a href="{!! url('dashboard') !!}">Dashboard</a></li>
          <li class="active">Create Service</li>
        </ol>
      </div>
    </div>
    <div class="clearfix"></div>
      <div class="row">
        <div class="col-md-12 col-sm-12 col-xs-12">
          <div class="x_panel">
              <div class="x_title">
                @include('commons.notifications')
                <div class="clearfix"></div>
              </div>
                {{-- start of content --}}
                <div class="x_content">
                  <br>
                      {!! Form::model($client, [
                          'method' => 'PATCH',
                          'url' => ['ussdclients', $client],
                          'class' => 'form-horizontal form-label-left'
                      ]) !!}
                      <div class="form-group">
                        <label class="control-label col-md-3 col-sm-3 col-xs-12" for="amountPaid">Amount Paid</label>
                        <div class="col-md-6 col-sm-6 col-xs-12 {{ $errors->has('amount_paid') ? 'has-error' : ''}}">
                          {!! Form::number('amount_paid', old('amount_paid'), ['class' => 'form-control col-md-7 col-xs-12', 'placeholder'=>'Enter amount total amount paid' , 'id' => 'amountPaid']) !!}
                          {!! $errors->first('amount_paid', '<p class="help-block">:message</p>') !!}
                          <p class="help-block" style="color: red;">-- no commas --</p>
                        </div>
                      </div>
                      <div class="form-group">
                        <label class="control-label col-md-3 col-sm-3 col-xs-12" for="paymentType">Payment Type</label>
                        <div class="col-md-6 col-sm-6 col-xs-12 {{ $errors->has('payment_type') ? 'has-error' : ''}}">
                          {!! Form::text('payment_type', old('payment_type'), ['class' => 'form-control col-md-7 col-xs-12', 'placeholder'=>'Enter payment type e.g. initial deposit' , 'id' => 'paymentType']) !!}
                          {!! $errors->first('payment_type', '<p class="help-block">:message</p>') !!}
                        </div>
                      </div>
                      
                      <div class="form-group">
                        <label class="control-label col-md-3 col-sm-3 col-xs-12" for="remarks">Remarks</label>
                        <div class="col-md-6 col-sm-6 col-xs-12 {{ $errors->has('remarks') ? 'has-error' : ''}}">
                          {!! Form::text('remarks', old('remarks'), ['class' => 'form-control col-md-7 col-xs-12', 'placeholder'=>'Enter remarks' , 'id' => 'remarks']) !!}
                          {!! $errors->first('remarks', '<p class="help-block">:message</p>') !!}
                        </div>
                      </div>
                      
                      
                      <div class="ln_solid"></div>
                      <div class="form-group">
                        <div class="col-md-6 col-sm-6 col-xs-12 col-md-offset-3">
                          <button type="submit" class="btn btn-success"><i class="fa fa-save"></i> Submit</button>
                        </div>
                      </div>
                  {!! Form::close() !!}
                </div>
                {{-- end of x_content --}}
              </div>
              {{-- end of x_panel --}}
            </div>
          </div>
          
        </div>

@endsection

@section('javascript')
<script type="text/javascript">
  $(function(){
    $('select').select2();

  });
</script>
@endsection
