<?php
$user = auth()->user();
?>
<div class="content">
	<div class="widget">
		<div class="widget-header">
			<h3><?php echo e(__('mylanguage.jamath_member_new')); ?></h3>
		</div>
		<div class="widget-content">
			<ul class="nav nav-tabs nav-tabs-custom-colored" role="tablist">
				<li class="active"><a href="#colored21" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-user"></i> <?php echo e(__('mylanguage.jamath_member')); ?></a></li>
				<li><a href="#colored22" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-cog"></i> <?php echo e(__('mylanguage.address')); ?></a></li>
				<li><a href="#colored23" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-cog"></i> <?php echo e(__('mylanguage.family_members')); ?></a></li>
				<li><a href="#colored24" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-cog"></i> <?php echo e(__('mylanguage.document')); ?></a></li>
				<li><a href="#colored25" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-cog"></i> <?php echo e(__('mylanguage.subscription')); ?></a></li>
				<li><a href="#colored26" role="tab" data-toggle="tab" class="loanApp"><i class="fa fa-cog"></i> <?php echo e(__('mylanguage.trans_rpt')); ?></a></li>
			</ul>
<form id="frmmain" name="frmmain" data-parsley-validate novalidate>
<input type="hidden" name="_token" id="_token" value="<?php echo e(csrf_token()); ?>">
<input type="hidden" name="Username" id="Username" value="<?php echo e($user->usr_id); ?>">
<input type="hidden" name="cst_id" id="cst_id" value="<?php echo e(isset($data) ? $data['cst_id'] : '0'); ?>">
				<div class="tab-content">
					<div id="colored21" class="tab-pane fade in active">
						<!-- HORIZONTAL FORM -->
						<div class="widget">
							<div class="widget-header">
							<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.main')); ?> <?php echo e(__('mylanguage.member_profile')); ?></h3></div>
							<div class="widget-content">
<div class="alert  alert-info " >
    <ul><li class="fa fa-cog  fa-1x fa-fw"></li><?php echo e(__('grade.enter_details')); ?>...</ul>
</div>						
<div class="alert alert-success print-success-msg" style="display:none">
    <ul></ul>
</div>	
<div class="alert alert-danger print-error-msg" style="display:none">
    <ul></ul>
</div>
								<div class="row">
									<div class="col-md-6 form-horizontal">	
										<div class="form-group">
											<label for="cst_gender" class="col-sm-4 control-label"><?php echo e(__('mylanguage.date_of_join')); ?></label>
											<div class="col-sm-8">
												<input type="date" class="form-control" id="cst_doj" name="cst_doj" placeholder="<?php echo e(__('mylanguage.date_of_join')); ?>" value="<?php echo date("Y-m-d"); ?>" onkeyup="loadgradeslno(cst_doj.value,grd_id.value)" onchange="loadgradeslno(cst_doj.value,grd_id.value)">
											</div>
										</div>		
										<div class="form-group">
											<label for="cst_name" class="col-sm-4 control-label"><?php echo e(__('mylanguage.name')); ?></label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="cst_name" name="cst_name" placeholder="<?php echo e(__('mylanguage.full')); ?> <?php echo e(__('mylanguage.name')); ?>" >
											</div>
										</div>
										<div class="form-group">
											<label for="cst_dob" class="col-sm-4 control-label"><?php echo e(__('mylanguage.dob')); ?></label>
											<div class="col-sm-8">
												<input type="date" class="form-control" id="cst_dob" name="cst_dob" placeholder="DOB." onkeyup="ageCount(this.value,'lacc_age')" onchange="ageCount(this.value,'lacc_age')" max="<?php echo date("Y-m-d"); ?>" >
												<span id="ageerror"></span>
											</div>
										</div>
									</div>
									<div class="col-md-6 form-horizontal">
										<div class="form-group">
											<label for="grd_id" class="col-sm-4 control-label"><?php echo e(__('mylanguage.select_grade')); ?></label>
											<div class="col-sm-8">
												<select id="grd_id" name="grd_id" class="form-control" onchange="loadgradeslno(cst_doj.value,grd_id.value)">
													<option value=""><?php echo e(__('mylanguage.select_grade')); ?></option>
												</select>
											</div>
										</div>							
										<div class="form-group">
											<label for="cst_code" class="col-sm-4 control-label"><?php echo e(__('mylanguage.member_id')); ?></label>
											<div class="col-sm-8">
												<input type="hidden" class="form-control" id="cst_grd_code" name="cst_grd_code" value="0">
												<input type="text" class="form-control" id="cst_code" name="cst_code" placeholder="<?php echo e(__('mylanguage.member_id')); ?>" readonly >
											</div>
										</div>
										<div class="form-group">
											<label for="lacc_age" class="col-sm-4 control-label"><?php echo e(__('mylanguage.age')); ?>.</label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="lacc_age" name="lacc_age" placeholder="<?php echo e(__('mylanguage.age')); ?>" readonly >
											</div>
										</div>
										
									</div>
								</div>
							</div>
						</div>
						<div class="widget">
							<div class="widget-header">
							<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.personal_det')); ?></h3></div>
							<div class="widget-content">
								<div class="row">
									<div class="col-md-6 form-horizontal">
										<div class="form-group">
											<label for="cst_maritalstatus" class="col-sm-4 control-label"><?php echo e(__('mylanguage.marital_status')); ?></label>
											<div class="col-sm-8">
												<select id="cst_maritalstatus" name="cst_maritalstatus" class="form-control">
													<option value="">- <?php echo e(__('mylanguage.marital_status')); ?> - </option>
													<option value="Single"><?php echo e(__('mylanguage.single')); ?></option>
													<option value="Married"><?php echo e(__('mylanguage.married')); ?></option>
													<option value="Divorced"><?php echo e(__('mylanguage.divorced')); ?></option>
													<option value="Widowed"><?php echo e(__('mylanguage.widowed')); ?></option>
												</select>
											</div>
										</div>
										<div class="form-group">
											<label for="cst_qualification" class="col-sm-4 control-label"><?php echo e(__('mylanguage.qualification')); ?></label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="cst_qualification" name="cst_qualification" placeholder="<?php echo e(__('mylanguage.qualification')); ?>" >
											</div>
										</div>
										<div class="form-group">
											<label for="cst_bloodgroup" class="col-sm-4 control-label"><?php echo e(__('mylanguage.blood_group')); ?></label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="cst_bloodgroup" name="cst_bloodgroup" placeholder="<?php echo e(__('mylanguage.blood_group')); ?>" >
											</div>
										</div>
									</div>
									<div class="col-md-6 form-horizontal">										
										<div class="form-group">
											<label for="cst_gender" class="col-sm-4 control-label"><?php echo e(__('mylanguage.gender')); ?></label>
											<div class="col-sm-8">
												<select id="cst_gender" name="cst_gender" class="form-control">
													<option value="">- <?php echo e(__('mylanguage.gender')); ?> -</option>
													<option value="Male"><?php echo e(__('mylanguage.male')); ?></option>
													<option value="Female"><?php echo e(__('mylanguage.female')); ?></option>
												</select>
											</div>
										</div>
										<div class="form-group">
											<label for="cst_occupation" class="col-sm-4 control-label"><?php echo e(__('mylanguage.occupation')); ?></label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="cst_occupation" name="cst_occupation" placeholder="<?php echo e(__('mylanguage.occupation')); ?>" >
											</div>
										</div>
										<div class="form-group">
											<label for="cst_income" class="col-sm-4 control-label"><?php echo e(__('mylanguage.income')); ?></label>
											<div class="col-sm-8">
												<input type="text" class="form-control" id="cst_income" name="cst_income" placeholder="<?php echo e(__('mylanguage.income')); ?>" >
											</div>
										</div>										
									</div>
								</div>
							</div>
						</div>
						<div class="widget">
							<div class="widget-header">
							<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.note')); ?></h3></div>
							<div class="widget-content">
								<div class="row">
									<div class="col-md-12 form-horizontal">
										<div class="form-group">
											<div class="col-sm-12">
<textarea class="form-control" id="cst_note" name="cst_note" placeholder="<?php echo e(__('mylanguage.note')); ?>"></textarea>
											</div>
										</div>
									</div>
								</div>
							</div>
						</div>
						<!-- END HORIZONTAL FORM -->
					</div>
					<div id="colored22" class="tab-pane fade">
						<!-- HORIZONTAL FORM -->
						<div class="row">
							<div class="col-md-6">
								<div class="widget">
									<div class="widget-header">
									<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.Residence_Address')); ?>:</h3></div>
									<div class="widget-content">
										<div class="row">
											<div class="col-md-12 form-horizontal">
												<div class="form-group">
													<label for="lacc_resaddr_addr" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Address')); ?></label>
													<div class="col-sm-8">
														<textarea class="form-control" id="lacc_resaddr_addr" name="lacc_resaddr_addr" placeholder="<?php echo e(__('mylanguage.Address')); ?>"></textarea>
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_city" class="col-sm-4 control-label"><?php echo e(__('mylanguage.City')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_city" name="lacc_resaddr_city" placeholder="<?php echo e(__('mylanguage.City')); ?>">
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_pin" class="col-sm-4 control-label"><?php echo e(__('mylanguage.PIN_Code')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_pin" name="lacc_resaddr_pin" placeholder="<?php echo e(__('mylanguage.PIN_Code')); ?>">
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_landmark" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Landmark')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_landmark" name="lacc_resaddr_landmark" placeholder="<?php echo e(__('mylanguage.Landmark')); ?>">
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_mob" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Mobno')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_mob" name="lacc_resaddr_mob" placeholder="<?php echo e(__('mylanguage.Mobno')); ?>">
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_tel" class="col-sm-4 control-label"><?php echo e(__('mylanguage.TelNo')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_tel" name="lacc_resaddr_tel" placeholder="<?php echo e(__('mylanguage.TelNo')); ?>">
													</div>
												</div>
												<div class="form-group">
													<label for="lacc_resaddr_email" class="col-sm-4 control-label"><?php echo e(__('mylanguage.EmailID')); ?></label>
													<div class="col-sm-8">
														<input type="text" class="form-control" id="lacc_resaddr_email" name="lacc_resaddr_email" placeholder="<?php echo e(__('mylanguage.EmailID')); ?>">
													</div>
												</div>
											</div>
										</div>
									</div>
								</div>
							</div>
							
							<div class="col-md-6">
								<!-- REGISTRATION FORM WITH ICONS -->								
								<div class="widget">
									<div class="widget-header">
									<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.PermanentAddress')); ?></h3></div>
									<div class="widget-content">
										<div class="row">
		<div class="col-md-12 form-horizontal">
			<div class="form-group">
				<label for="lacc_permaddr_addr" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Address')); ?></label>
				<div class="col-sm-8">
					<textarea class="form-control" id="lacc_permaddr_addr" name="lacc_permaddr_addr" placeholder="<?php echo e(__('mylanguage.Address')); ?>"></textarea>
				</div>
			</div>
	 
			<div class="form-group">
				<label for="lacc_permaddr_city" class="col-sm-4 control-label"><?php echo e(__('mylanguage.City')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_city" name="lacc_permaddr_city" placeholder="<?php echo e(__('mylanguage.City')); ?>">
				</div>
			</div>
			<div class="form-group">
				<label for="lacc_permaddr_pin" class="col-sm-4 control-label"><?php echo e(__('mylanguage.PIN_Code')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_pin" name="lacc_permaddr_pin" placeholder="<?php echo e(__('mylanguage.PIN_Code')); ?>">
				</div>
			</div>
			<div class="form-group">
				<label for="lacc_permaddr_landmark" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Landmark')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_landmark" name="lacc_permaddr_landmark" placeholder="<?php echo e(__('mylanguage.Landmark')); ?>">
				</div>
			</div>
			<div class="form-group">
				<label for="lacc_permaddr_mob" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Mobno')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_mob" name="lacc_permaddr_mob" placeholder="<?php echo e(__('mylanguage.Mobno')); ?>">
				</div>
			</div>
			<div class="form-group">
				<label for="lacc_permaddr_tel" class="col-sm-4 control-label"><?php echo e(__('mylanguage.TelNo')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_tel" name="lacc_permaddr_tel" placeholder="<?php echo e(__('mylanguage.TelNo')); ?>">
				</div>
			</div>
			<div class="form-group">
				<label for="lacc_permaddr_email" class="col-sm-4 control-label"><?php echo e(__('mylanguage.EmailID')); ?></label>
				<div class="col-sm-8">
					<input type="text" class="form-control" id="lacc_permaddr_email" name="lacc_permaddr_email" placeholder="<?php echo e(__('mylanguage.EmailID')); ?>">
				</div>
			</div>
		</div>
										</div>
									</div>
								</div>
								<!-- END REGISTRATION FORM WITH ICONS -->
							</div>							
						</div>
						<!-- END HORIZONTAL FORM -->
					</div>
					<div id="colored23" class="tab-pane fade">
						<!-- HORIZONTAL FORM -->
						<div class="row">
							<div class="col-md-12">
								<!-- REGISTRATION FORM WITH ICONS -->
<div class="widget">
	<div class="widget-header">
	<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.Family_Members_entry')); ?></h3></div>
	<div class="widget-content">
		<div class="row">
			<div class="col-md-6 form-horizontal">
				<div class="form-group">
					<label for="cst_family_relationship" class="col-sm-4 control-label"><?php echo e(__('mylanguage.relationship')); ?></label>
					<div class="col-sm-8">
						<select id="cst_family_relationship" name="cst_family_relationship" class="form-control">
							<option value="">- <?php echo e(__('mylanguage.select')); ?> -</option>
							<option value="Husband"><?php echo e(__('mylanguage.Husband')); ?></option>
							<option value="Wife"><?php echo e(__('mylanguage.Wife')); ?></option>
							<option value="Father"><?php echo e(__('mylanguage.Father')); ?></option>
							<option value="Mother"><?php echo e(__('mylanguage.Mother')); ?></option>
							<option value="Son"><?php echo e(__('mylanguage.Son')); ?></option>
							<option value="Daughter"><?php echo e(__('mylanguage.Daughter')); ?></option>
						</select>
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_name" class="col-sm-4 control-label"><?php echo e(__('mylanguage.name')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="cst_family_name" name="cst_family_name" placeholder="<?php echo e(__('mylanguage.name')); ?>" >
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_gender" class="col-sm-4 control-label"><?php echo e(__('mylanguage.gender')); ?></label>
					<div class="col-sm-8">
						<select id="cst_family_gender" name="cst_family_gender" class="form-control">
								<option value="">- <?php echo e(__('mylanguage.gender')); ?> -</option>
								<option value="Male"><?php echo e(__('mylanguage.male')); ?></option>
								<option value="Female"><?php echo e(__('mylanguage.female')); ?></option>
						</select>
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_maritalstatus" class="col-sm-4 control-label"><?php echo e(__('mylanguage.marital_status')); ?></label>
					<div class="col-sm-8">
						<select id="cst_family_maritalstatus" name="cst_family_maritalstatus" class="form-control">
							<option value="">- <?php echo e(__('mylanguage.marital_status')); ?> -</option>
							<option value="Single"><?php echo e(__('mylanguage.single')); ?></option>
							<option value="Married"><?php echo e(__('mylanguage.single')); ?></option>
							<option value="Divorced"><?php echo e(__('mylanguage.divorced')); ?></option>
							<option value="Widowed"><?php echo e(__('mylanguage.widowed')); ?></option>
						</select>
					</div>
				</div>				
				<div class="form-group">
					<label for="cst_family_qualification" class="col-sm-4 control-label"><?php echo e(__('mylanguage.qualification')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="cst_family_qualification" name="cst_family_qualification" placeholder="<?php echo e(__('mylanguage.qualification')); ?>" >
					</div>
				</div>
			</div>
			<div class="col-md-6 form-horizontal">
				<div class="form-group">
					<label for="cst_family_dob" class="col-sm-4 control-label"><?php echo e(__('mylanguage.dob')); ?>.</label>
					<div class="col-sm-8">
						<input type="date" class="form-control" id="cst_family_dob" name="cst_family_dob" placeholder="DOB." onkeyup="ageCount(this.value,'cst_family_age')" onchange="ageCount(this.value,'cst_family_age')" >
						<span id="ageerror"></span>
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_age" class="col-sm-4 control-label"><?php echo e(__('mylanguage.age')); ?>.</label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="cst_family_age" name="cst_family_age" placeholder="<?php echo e(__('mylanguage.age')); ?>" readonly >
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_bloodgroup" class="col-sm-4 control-label"><?php echo e(__('mylanguage.blood_group')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="cst_family_bloodgroup" name="cst_family_bloodgroup" placeholder="<?php echo e(__('mylanguage.blood_group')); ?>" >
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_mobileno" class="col-sm-4 control-label"><?php echo e(__('mylanguage.Mobno')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="cst_family_mobileno" name="cst_family_mobileno" placeholder="<?php echo e(__('mylanguage.Mobno')); ?>" >
					</div>
				</div>
				<div class="form-group">
					<label for="cst_family_note" class="col-sm-4 control-label"><?php echo e(__('mylanguage.note')); ?></label>
					<div class="col-sm-8"><input type="text" class="form-control" id="cst_family_note" name="cst_family_note" placeholder="<?php echo e(__('mylanguage.note')); ?>" >
					</div>
				</div>
			</div>
		</div>
	</div>
	<div class="widget-footer">
	<center><button type="submit" id="btnfamilymember" name="btnfamilymember" class="btn btn-default">Add</button></center>
	</div>
</div>
								<!-- END REGISTRATION FORM WITH ICONS -->
							</div>
							
							<div class="col-md-12">
								<!-- REGISTRATION FORM WITH ICONS -->
								
								<div class="widget">
									<div class="widget-header">
									<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.family_members_list')); ?>:</h3></div>
									<div class="widget-content">
										<div class="row">
											<div class="col-md-12 form-horizontal">
<table  class="table table-striped table-bordered" id="tabloan">
	<thead>
	<tr>
		<th><?php echo e(__('mylanguage.slno')); ?></th>
		<th><?php echo e(__('mylanguage.relationship')); ?></th>							
		<th><?php echo e(__('mylanguage.name')); ?></th>							
		<th><?php echo e(__('mylanguage.gender')); ?></th>							
		<th><?php echo e(__('mylanguage.dob')); ?></th>							
		<th><?php echo e(__('mylanguage.more_detail')); ?></th>							
		<th><?php echo e(__('mylanguage.action')); ?></th>
	</tr>
	</thead>
	<tbody>
			<tr>
				<td></td>
				<td></td>
				<td></td>
				<td></td>    
				<td></td>  
				<td></td>  
				<td></td> 
			</tr>
	</tbody>
</table>									
											</div>
										</div>
									</div>
								</div>
								<!-- END REGISTRATION FORM WITH ICONS -->
							</div>
							
						</div>
						<!-- END HORIZONTAL FORM -->
					</div>
					<div id="colored24" class="tab-pane fade">
						<!-- HORIZONTAL FORM -->
						
						<div class="row">

							<div class="col-md-12">
								<!-- REGISTRATION FORM WITH ICONS -->
<div class="widget">
	<div class="widget-header">
	<h3><i class="fa fa-edit"></i> <?php echo e(__('mylanguage.upload_documents')); ?></h3></div>
	<div class="widget-content">
		<div class="row">
			<div class="col-md-6 form-horizontal">
				<div class="form-group">
					<label for="doc_doctype" class="col-sm-4 control-label"><?php echo e(__('mylanguage.document_type')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="doc_doctype" name="doc_doctype" placeholder="<?php echo e(__('mylanguage.document_type')); ?>" >
					</div>
				</div>
				<div class="form-group">
					<label for="doc_docfile" class="col-sm-4 control-label"><?php echo e(__('mylanguage.document_file')); ?></label>
					<div class="col-sm-8">
						<input type="file" class="form-control" id="doc_docfile" name="doc_docfile"  >
					</div>
				</div>
			</div>
			<div class="col-md-6 form-horizontal">
				<div class="form-group">
					<label for="doc_docno" class="col-sm-4 control-label"><?php echo e(__('mylanguage.idnocode')); ?></label>
					<div class="col-sm-8">
						<input type="text" class="form-control" id="doc_docno" name="doc_docno" placeholder="<?php echo e(__('mylanguage.idnocode')); ?>" >
					</div>
				</div>
			</div>
						
			<div class="col-md-6 form-horizontal">
				<div class="form-group">
					<label for="doc_detail" class="col-sm-4 control-label"><?php echo e(__('mylanguage.document_note')); ?></label>
					<div class="col-sm-8"><input type="text" class="form-control" id="doc_detail" name="doc_detail" placeholder="<?php echo e(__('mylanguage.document_note')); ?>" ></div>
				</div>
			</div>
		</div>
	</div>
	<div class="widget-footer">
	<center><button type="submit" id="btndocument" name="btndocument" class="btn btn-default">Add</button></center>
	</div>
</div>
								<!-- END REGISTRATION FORM WITH ICONS -->
							</div>
							
							<div class="col-md-12">
								<!-- REGISTRATION FORM WITH ICONS -->
								
								<div class="widget">
									<div class="widget-header">
									<h3><i class="fa fa-edit"></i> View Uploaded Documents:</h3></div>
									<div class="widget-content">
										<div class="row">
											<div class="col-md-12 form-horizontal">
<table  class="table table-striped table-bordered" id="tabloan">
	<thead>
	<tr>
		<th><?php echo e(__('mylanguage.slno')); ?></th>
		<th><?php echo e(__('mylanguage.document_type')); ?></th>							
		<th><?php echo e(__('mylanguage.idnocode')); ?></th>						
		<th><?php echo e(__('mylanguage.document_file')); ?></th>	
		<th><?php echo e(__('mylanguage.more_detail')); ?></th>								
		<th><?php echo e(__('mylanguage.action')); ?></th>
	</tr>
	</thead>
	<tbody>
			<tr>
				<td></td>
				<td></td>
				<td></td>
				<td></td>    
				<td></td>  
				<td></td>  
			</tr>
	</tbody>
</table>									
											</div>
										</div>
									</div>
								</div>
								<!-- END REGISTRATION FORM WITH ICONS -->
							</div>
							
						</div>
						<!-- END HORIZONTAL FORM -->
					</div>
					
					<div id="colored25" class="tab-pane fade">
						<!-- HORIZONTAL FORM -->
						<div class="row">							
							<div class="col-md-12">
								<!-- Invoice amount - Paid Amount - Balance Amount STARTS HERE-->
								<div class="widget" id="tabipb"></div>
								<!-- Invoice amount - Paid Amount - Balance Amount ENDS HERE-->
							</div>
						</div>
						<!-- END HORIZONTAL FORM -->
					</div>								
				
					<div id="colored26" class="tab-pane fade">
						<!-- HORIZONTAL FORM -->
						<div class="row">
							<div class="col-md-12" id="tabrpt"></div>
						<!-- END HORIZONTAL FORM -->
					</div>								
				
				</div>
				<!-- HORIZONTAL FORM -->
				<div class="widget">
					<div class="widget-header"><center>
						<?php if(isset($data[0]->cst_id)): ?>
						<button type="submit" id="btnsubmitall" name="btnsubmitall" class="btn btn-default loanapplicant_submit">Update</button>
						<?php else: ?>
						<button type="submit" id="btnsubmitall" name="btnsubmitall" class="btn btn-default loanapplicant_submit">Submit</button>
						<?php endif; ?>
						</center></div>
					
					
				</div>
			</form>
			<!-- END HORIZONTAL FORM -->
		</div>
	</div>
</div>
<script src="js/jquery.validate.min.js"></script>
<style>
	.error
	{
	color:red;
	}
</style>
<script>
	i = 0;
	$(document).ready(function()
	  {
			$("#btnfamilymember").click(function(){
				alert("All Fields are Mandatory");
					/*
			//$(".alert-info").find("ul").html('<li class="fa fa-cog fa-spin fa-1x fa-fw"></li>Inserting record...');
			var _token = $("input[name='_token']").val();
			var cst_family_relationship =  $('#cst_family_relationship').val();
			var cst_family_name  =  $('#cst_family_name').val();
			var cst_family_gender =  $('#cst_family_gender').val();
			var cst_family_maritalstatus =  $('#cst_family_maritalstatus').val();
			var cst_family_qualification =  $('#cst_family_qualification').val();
			var cst_family_dob =  $('#cst_family_dob').val();
			var cst_family_age  = $('#cst_family_age').val();
			var cst_family_bloodgroup =  $('#cst_family_bloodgroup').val();
			var cst_family_mobileno =  $('#cst_family_mobileno').val();
			var cst_family_note =  $('#cst_family_note').val();
			document.getElementById("errfyear").innerHTML = "";
			document.getElementById("errfstartyear").innerHTML = "";
			document.getElementById("errfendyear").innerHTML = "";
			
   if(fyear == "")
   {
		document.getElementById("errfyear").innerHTML = "Title should not be empty...";
		$(".alert-info").find("ul").html('<li class="fa fa-cog fa-1x fa-fw"></li>Kindly check the error...');
   }
   else  if(fstartyear == "")
   {
		document.getElementById("errfstartyear").innerHTML = "Fiscal Year Starts From should not be empty...";
		$(".alert-info").find("ul").html('<li class="fa fa-cog fa-1x fa-fw"></li>Kindly check the error...');
   }
   else  if(fendyear == "")
   {
		document.getElementById("errfendyear").innerHTML = "Fiscal Year Ends At should not be empty...";
		$(".alert-info").find("ul").html('<li class="fa fa-cog fa-1x fa-fw"></li>Kindly check the error...');
   }
   else
			
   {						   
		if(i == 0)
		{
			i++;
			$.ajax({
				url: "/addfamilymembers",
				type:'POST',
				data: {_token:_token, cst_family_relationship: cst_family_relationship, cst_family_name: cst_family_name, cst_family_gender: cst_family_gender, cst_family_maritalstatus:cst_family_maritalstatus, cst_family_qualification:cst_family_qualification, cst_family_dob:cst_family_dob, cst_family_age:cst_family_age, cst_family_bloodgroup:cst_family_bloodgroup, cst_family_mobileno:cst_family_mobileno, cst_family_note:cst_family_note},
				success: function(data) {
					//alert(data);
					if(data.status == 1)
					{
						printSuccessMsg(data.message);
						$('#sideMenu').load('fiscalyear');
					}
					else
					{
						printErrorMsg(data.message)
					}
				}
			});
		}
							   
   }			*/
					return false;
				});
				$("#btndocument").click(function(){
					alert("All Fields are Mandatory");
					return false;
				});
				$("#btnsubmitall").click(function(){
					i = 0;
//#########################btnsubmitall starts################################
$(".alert-info").find("ul").html('<li class="fa fa-cog fa-spin fa-1x fa-fw"></li>Inserting record...');
	var _token = $("input[name='_token']").val();
	var Username = $('#Username').val();
	var cst_id = $('#cst_id').val();
	var cst_doj = $('#cst_doj').val();
	var cst_name = $('#cst_name').val();
	var cst_dob = $('#cst_dob').val();
	var grd_id = $('#grd_id').val();
	var cst_code = $('#cst_code').val();
	var cst_grd_code = $('#cst_grd_code').val();
	var lacc_age = $('#lacc_age').val();
	var cst_maritalstatus = $('#cst_maritalstatus').val();
	var cst_qualification = $('#cst_qualification').val();
	var cst_bloodgroup = $('#cst_bloodgroup').val();
	var cst_gender = $('#cst_gender').val();
	var cst_occupation = $('#cst_occupation').val();
	var cst_income = $('#cst_income').val();
	var cst_note = $('#cst_note').val();
	var lacc_resaddr_addr = $('#lacc_resaddr_addr').val();
	var lacc_resaddr_city = $('#lacc_resaddr_city').val();
	var lacc_resaddr_pin = $('#lacc_resaddr_pin').val();
	var lacc_resaddr_landmark = $('#lacc_resaddr_landmark').val();
	var lacc_resaddr_mob = $('#lacc_resaddr_mob').val();
	var lacc_resaddr_tel = $('#lacc_resaddr_tel').val();
	var lacc_resaddr_email = $('#lacc_resaddr_email').val();
	var lacc_permaddr_addr = $('#lacc_permaddr_addr').val();
	var lacc_permaddr_city = $('#lacc_permaddr_city').val();
	var lacc_permaddr_pin = $('#lacc_permaddr_pin').val();
	var lacc_permaddr_landmark = $('#lacc_permaddr_landmark').val();
	var lacc_permaddr_mob = $('#lacc_permaddr_mob').val();
	var lacc_permaddr_tel = $('#lacc_permaddr_tel').val();
	var lacc_permaddr_email = $('#lacc_permaddr_email').val();
/*
	document.getElementById("errtaxtype").innerHTML = "";
	document.getElementById("errtaxpercentage").innerHTML = "";
	if(taxtype == "")
	{
		document.getElementById("errtaxtype").innerHTML = "Tax Type should not be empty...";
		$(".alert-info").find("ul").html('<li class="fa fa-cog fa-1x fa-fw"></li>Kindly check the error...');
	}
	else if(taxpercentage == "")
	{
		document.getElementById("errtaxpercentage").innerHTML = "Tax Percentage should not be empty...";
		$(".alert-info").find("ul").html('<li class="fa fa-cog fa-1x fa-fw"></li>Kindly check the error...');
	}
	else
*/
	{						   
		if(i == 0)
		{
		i++;
		$.ajax({
		url: "/ApplicantionInsert",
		type:'POST',
		data: {Username:Username, cst_id: cst_id,cst_doj:cst_doj,cst_name:cst_name,cst_dob:cst_dob,grd_id:grd_id,cst_code:cst_code,cst_grd_code:cst_grd_code,lacc_age:lacc_age,cst_maritalstatus:cst_maritalstatus,cst_qualification:cst_qualification,cst_bloodgroup:cst_bloodgroup,cst_gender:cst_gender,cst_occupation:cst_occupation,cst_income:cst_income,cst_note:cst_note, lacc_resaddr_addr:lacc_resaddr_addr,lacc_resaddr_city:lacc_resaddr_city, lacc_resaddr_pin:lacc_resaddr_pin, lacc_resaddr_landmark:lacc_resaddr_landmark, lacc_resaddr_mob:lacc_resaddr_mob,lacc_resaddr_tel:lacc_resaddr_tel,  lacc_resaddr_email:lacc_resaddr_email, lacc_permaddr_addr:lacc_permaddr_addr, lacc_permaddr_city:lacc_permaddr_city,lacc_permaddr_pin:lacc_permaddr_pin, lacc_permaddr_landmark:lacc_permaddr_landmark, lacc_permaddr_mob:lacc_permaddr_mob,lacc_permaddr_tel:lacc_permaddr_tel, lacc_permaddr_email:lacc_permaddr_email},
			success: function(data) {
				alert("Record Inserted successfully...");
				$('#sideMenu').load('viewJamathApplicant');
				/*
				if(data == '{"status":"Success","entry_type":"Insert"}')
				{
				printSuccessMsg(data.status);
				$('#sideMenu').load('viewJamathApplicant');
				}
				else
				{
				printErrorMsg(data.status)
				}
				*/
			}
		});	
		}
	}
//############################btnsubmitall ends#############################
					return false;
				});
	});

	function printErrorMsg (msg) {				
		$(".alert-info").css('display','none');
		$(".print-success-msg").css('display','none');
		$(".print-error-msg").find("ul").html('');
		$(".print-error-msg").css('display','block');
		$(".print-error-msg").find("ul").append('<li class="fa fa-times-circle fa-1x fa-fw"></li>'+msg);
	}
			
	function printSuccessMsg (msg) {
		$(".alert-info").css('display','none');
		$(".print-error-msg").css('display','none');
		$(".print-success-msg").find("ul").html('');
		$(".print-success-msg").css('display','block');
		$(".print-success-msg").find("ul").append('<li class="fa fa-check  fa-1x fa-fw"></li>'+msg);
	}
	
	function ageCount(dt,agectrl)
	{
		lacc_dob=dt;
		ageCounts(lacc_dob,agectrl);
	}
	function ageCounts(lacc_dob,agectrl)
	{
		$('#ageerror').html("");
		dob = new Date(lacc_dob);
		var today = new Date();
		var age = Math.floor((today-dob) / (365.25 * 24 * 60 * 60 * 1000));
		if(age<0)
		{
			$('#ageerror').html("<span style='color:red'>Sorry! Age Below Then 0</span>");
		}
		else
		{
			$('#ageerror').html("");
			$('#'+agectrl).val(age);
		}		
	}
	//load Full fund types 	edit_grd_id edit_grd_id
	$(document).ready(function(){
		var edit_grd_id = $('#edit_grd_id').val();
		$.ajax({
		type: "GET",
		url:"/loadgradelist",
		dataType: "json",
		success: function (data) {
		$.each(data,function(i,obj)
		{
			if(edit_grd_id ==0)
			{
				var div_data="<option value="+obj.grd_id+">"+obj.grd_grade+" (" + obj.grd_prefix + ")</option>";	
			}
			else 
			{
				if(edit_grd_id == obj.grd_id)
				{
					var div_data="<option value="+obj.grd_id+" selected>"+obj.grd_grade+" (" + obj.grd_prefix + ")</option>";	
				}
				else{
					var div_data="<option value="+obj.grd_id+">"+obj.grd_grade+" (" + obj.grd_prefix + ")</option>";		
				}
			}
			$(div_data).appendTo('#grd_id');
		});  
		}
		});
	});
	//###Coding to Load Grade Serial Number starts here
	function loadgradeslno(doj,gradeid)
	{
		//loadgradeslno(cst_doj.value,grd_id.value)
		if(gradeid=="")
		{
		}
		else
		{
			var Username = $('#Username').val();
			$.ajax({
					url:'Loadgradeserialnumber',
					type:'GET',
					data:'&doj='+doj+'&gradeid='+gradeid+'&Username='+Username,
					success:function(data)
					{
						$('#cst_code').val(data['reclist'][0].gradeprefix+data['reclist'][0].custcode);
						$('#cst_grd_code').val(data['reclist'][0].custcode);				
						$('#tabipb').html(data['transrecord']);
						$('#tabrpt').html(data['rpt_transrecord']);
					}
				});
		}
	}
	//###Coding to Load Grade Serial Number ends here
</script>																						