

		 {!! Form::open(array('url'=>'rdsinisters', 'class'=>'form-horizontal','files' => true , 'parsley-validate'=>'','novalidate'=>' ')) !!}

	@if(Session::has('messagetext'))
	  
		   {!! Session::get('messagetext') !!}
	   
	@endif
	<ul class="parsley-error-list">
		@foreach($errors->all() as $error)
			<li>{{ $error }}</li>
		@endforeach
	</ul>		


<div class="col-md-12">
						<fieldset><legend> Gestion des sinistres RD</legend>
				{!! Form::hidden('id', $row['id']) !!}					
									  <div class="form-group row  " >
										<label for="Compte" class=" control-label col-md-4 text-left"> Compte <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <select name='account_id' rows='5' id='account_id' class='select2 '   ></select> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Cie" class=" control-label col-md-4 text-left"> Cie <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='cie' id='cie' value='{{ $row['cie'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Coass" class=" control-label col-md-4 text-left"> Coass <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='coass' id='coass' value='{{ $row['coass'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Id Cabinet" class=" control-label col-md-4 text-left"> Id Cabinet <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='id_cbt' id='id_cbt' value='{{ $row['id_cbt'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Id Cie" class=" control-label col-md-4 text-left"> Id Cie <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='id_cie' id='id_cie' value='{{ $row['id_cie'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Police" class=" control-label col-md-4 text-left"> Police <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='police' id='police' value='{{ $row['police'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Assuré" class=" control-label col-md-4 text-left"> Assuré <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='insured' id='insured' value='{{ $row['insured'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date sinistre" class=" control-label col-md-4 text-left"> Date sinistre <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='sinister_date' id='sinister_date' value='{{ $row['sinister_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date déclaration" class=" control-label col-md-4 text-left"> Date déclaration <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='declaration_date' id='declaration_date' value='{{ $row['declaration_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Nature sinistre" class=" control-label col-md-4 text-left"> Nature sinistre <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='sinister_nature' id='sinister_nature' value='{{ $row['sinister_nature'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Expert" class=" control-label col-md-4 text-left"> Expert <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='expert' id='expert' value='{{ $row['expert'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date devis" class=" control-label col-md-4 text-left"> Date devis <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='quote_date' id='quote_date' value='{{ $row['quote_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Montant devis" class=" control-label col-md-4 text-left"> Montant devis <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='quote_amout' id='quote_amout' value='{{ $row['quote_amout'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date rapport" class=" control-label col-md-4 text-left"> Date rapport <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='report_date' id='report_date' value='{{ $row['report_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Montant rapport" class=" control-label col-md-4 text-left"> Montant rapport <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='report_amount' id='report_amount' value='{{ $row['report_amount'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date quittance" class=" control-label col-md-4 text-left"> Date quittance <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='receipt_date' id='receipt_date' value='{{ $row['receipt_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Montant Reg Client" class=" control-label col-md-4 text-left"> Montant Reg Client <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='pay_cust_amount' id='pay_cust_amount' value='{{ $row['pay_cust_amount'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date Reg Client" class=" control-label col-md-4 text-left"> Date Reg Client <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='pay_cust_date' id='pay_cust_date' value='{{ $row['pay_cust_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Réf Chq Cabinet" class=" control-label col-md-4 text-left"> Réf Chq Cabinet <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='pay_id_cbt' id='pay_id_cbt' value='{{ $row['pay_id_cbt'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Date Reg Cie" class=" control-label col-md-4 text-left"> Date Reg Cie <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='pay_cie_date' id='pay_cie_date' value='{{ $row['pay_cie_date'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Réf Chq Cie" class=" control-label col-md-4 text-left"> Réf Chq Cie <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='pay_id_cie' id='pay_id_cie' value='{{ $row['pay_id_cie'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Observations" class=" control-label col-md-4 text-left"> Observations <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='observations' id='observations' value='{{ $row['observations'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> 					
									  <div class="form-group row  " >
										<label for="Sort du sinitre" class=" control-label col-md-4 text-left"> Sort du sinitre <span class="asterix"> * </span></label>
										<div class="col-md-6">
										  <input  type='text' name='fate_sinister' id='fate_sinister' value='{{ $row['fate_sinister'] }}' 
						     class='form-control form-control-sm ' /> 
										 </div> 
										 <div class="col-md-2">
										 	
										 </div>
									  </div> </fieldset>
			</div>
			
			

			<div style="clear:both"></div>	
				
					
				  <div class="form-group">
					<label class="col-sm-4 text-right">&nbsp;</label>
					<div class="col-sm-8">	
					<button type="submit" name="apply" class="btn btn-default btn-sm" ><i class="fa  fa-check-circle"></i> {{ Lang::get('core.sb_apply') }}</button>
					<button type="submit" name="submit" class="btn btn-default btn-sm" ><i class="fa  fa-save "></i> {{ Lang::get('core.sb_save') }}</button>
				  </div>	  
			
		</div> 
		 <input type="hidden" name="action_task" value="public" />
		 {!! Form::close() !!}
		 
   <script type="text/javascript">
	$(document).ready(function() { 
		
		
		$("#account_id").jCombo("{!! url('rdsinisters/comboselect?filter=sc_accounts:id:name') !!}",
		{  selected_value : '{{ $row["account_id"] }}' });
		 

		$('.removeCurrentFiles').on('click',function(){
			var removeUrl = $(this).attr('href');
			$.get(removeUrl,function(response){});
			$(this).parent('div').empty();	
			return false;
		});		
		
	});
	</script>		 
