<div class="box box-success b-t-non" id='panel-add'>
	<h4 class="labelGreen">
		<i class="fa fa-plus-square m-r-15"></i> Form Tambah
	</h4>
	<hr class="m-t-0">
	<form method='post' action="<?php echo e(route('addDtPernikahan')); ?>" enctype='multipart/form-data'>
		<?php echo e(csrf_field()); ?>

		<div class="box-body">
			<div class='col-lg-12 col-md-12 col-sm-12 col-xs-12 p-0'>
				<div class='col-lg-6 col-md-6 col-sm-12 col-xs-12 p-b-5'>
					<div class="form-group" id='gr_reg'>
						<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>No Registrasi</label>
						<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
							<input type="text" name="no_registrasi" id='noRegistrasi' value="<?php echo e($kodeRegis); ?>" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12" readonly>
							<div class='iconStatus' id='icon_reg'></div>
						</div>
						<span class='col-lg-9 col-md-9 col-sm-12 col-xs-12 col-lg-offset-3 col-md-offset-3' id="cek_no_req"></span>
					</div>
				</div>
				<!-- <div class='clearfix p-b-5'></div> -->
				<div class='col-lg-6 col-md-6 col-sm-12 col-xs-12 p-b-5'>
					<div class="form-group m-b-0">
						<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Tgl Registrasi</label>
						<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12 input-group p-t-0 p-b-0 p-l-15 p-r-15">
							<div class="input-group-addon">
								<i class="fa fa-calendar"></i>
							</div>
							<input type="text" name='tgl_registrasi' autocomplete='off' placeholder='dd-mm-yyyy' class="form-control pull-right"  id='form_datetime_today_reg' data-date-format="dd-mm-yyyy" required='required'>
						</div>
					</div>
				</div>
			</div>
			<div class="clearfix"></div>
			<h4 class="labelGreen m-0 m-b-5"><i class="fa fa-puzzle-piece m-r-15"></i> 1. IDENTITAS PASANGAN</h4>
			<!-- <hr class="lineTopGreen"> -->
			<div class='col-lg-6 col-md-6 col-sm-12 col-xs-12 p-0'>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>NIK Calon Suami</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="nik_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Nama Calon Suami</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="nama_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Tempat Lahir</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="tmp_lahir_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group m-b-0">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Tanggal Lahir</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12 input-group p-t-0 p-b-0 p-l-15 p-r-15">
						<div class="input-group-addon">
							<i class="fa fa-calendar"></i>
						</div>
						<input type="text" name='tgl_lahir_suami' autocomplete='off' placeholder='dd-mm-yyyy' class="form-control pull-right"  id='form_datetime_today_husban' data-date-format="dd-mm-yyyy" required='required'>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Agama</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="agama_suami" id='agamaSuami' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Agama ::. </option>
							<option value='Aliran Kepercayaan'>Aliran Kepercayaan</option>
							<option value='Buddha'>Buddha</option>
							<option value='Hindu'>Hindu</option>
							<option value='Islam'>Islam</option>
							<option value='Konghucu'>Konghucu</option>
							<option value='Kristen Protestan'>Kristen Protestan</option>
							<option value='Katholik'>Katholik</option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Suku</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="suku_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pendidikan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="pendidikan_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pekerjaan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="pekerjaan_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Alamat</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="alamat_suami" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Provinsi</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="provinsi_suami_id" id='provinsiSuami' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Provinsi ::. </option>
							<?php foreach($provinsis as $provinsi): ?>
								<option value='<?php echo $provinsi->id_provinsi; ?>'><?php echo $provinsi->nama_provinsi; ?></option>
							<?php endforeach; ?>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Kabupaten</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="kabupaten_suami_id" id='kabupatenSuami' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Kabupaten ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Kecamatan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="kecamatan_suami_id" id='kecamatanSuami' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Kecamatan ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Desa</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="desa_suami_id" id='desaSuami' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Desa ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pernah Menikah Sebelumnya</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="radio" class="customCheck" id="nikahSuami1" value='1' name="pernah_menikah_suami">
						<label class="labelRadio" for="nikahSuami1">Ya</label>
						<input type="radio" class="customCheck" id="nikahSuami2" value='2' name="pernah_menikah_suami">
						<label class="labelRadio" for="nikahSuami2">Tidak</label>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12 col-lg-offset-3 col-md-offset-3">
						<div class="crop-edit">
							<center>
								<img id="preview-photo-suami" src="<?php echo url('dist/img/default_image.jpg'); ?>" class="img-polaroid" min-height="250" width="70%">
							</center>
						</div>
					</div>
					<div class='clearfix p-b-5'></div>
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Foto Suami</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="file" class="upload" onchange="loadFilePhotoSuami(event)" name="fotoSuami" accept="image/*" class="form-control customInput input-sm col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
			</div>
			<div class='col-lg-6 col-md-6 col-sm-12 col-xs-12 p-0'>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>NIK Calon Istri</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="nik" id='nikIstri' onkeyup="cekNIK()" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
						<div class='iconStatus' id='icon_nik'></div>
					</div>
					<span class='col-lg-9 col-md-9 col-sm-12 col-xs-12 col-lg-offset-3 col-md-offset-3' id="cek_no_induk"></span>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Nama Calon Istri</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="nama_bumil" id="namaBumil" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Tempat Lahir</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="tmp_lahir" id="tmpLahir" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group m-b-0">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Tanggal Lahir</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12 input-group p-t-0 p-b-0 p-l-15 p-r-15">
						<div class="input-group-addon">
							<i class="fa fa-calendar"></i>
						</div>
						<input type="text" name='tgl_lahir' autocomplete='off' placeholder='dd-mm-yyyy' class="form-control pull-right"  id='form_datetime_todayWife' data-date-format="dd-mm-yyyy" required='required'>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Agama</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="agama" id='agamaIstri' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Agama ::. </option>
							<option value='Aliran Kepercayaan'>Aliran Kepercayaan</option>
							<option value='Buddha'>Buddha</option>
							<option value='Hindu'>Hindu</option>
							<option value='Islam'>Islam</option>
							<option value='Konghucu'>Konghucu</option>
							<option value='Kristen Protestan'>Kristen Protestan</option>
							<option value='Katholik'>Katholik</option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Suku</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="suku_istri" id='sukuIstri' required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pendidikan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="pendidikan" id="pendidikanIstri" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pekerjaan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="pekerjaan" id="pekerjaanIstri" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Alamat</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="text" name="alamat_ktp" id="alamatIstri" required="required" autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Provinsi</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="provinsi_ktp_id" id='provinsiIstri' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Provinsi ::. </option>
							<?php foreach($provinsis as $provinsi): ?>
								<option value='<?php echo $provinsi->id_provinsi; ?>'><?php echo $provinsi->nama_provinsi; ?></option>
							<?php endforeach; ?>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Kabupaten</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="kabupaten_ktp_id" id='kabupatenIstri' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Kabupaten ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Kecamatan</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="kecamatan_ktp_id" id='kecamatanIstri' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Kecamatan ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pilih Desa</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<select name="desa_ktp_id" id='desaIstri' required="required" class="form-control input-sm customInput col-md-7 col-xs-12">
							<option value='' disabled selected> .:: Pilih Desa ::. </option>
						</select>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Pernah Menikah Sebelumnya</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="radio" class="customCheck" id="nikahIstri1" value='1' name="pernah_menikah_istri">
						<label class="labelRadio" for="nikahIstri1">Ya</label>
						<input type="radio" class="customCheck" id="nikahIstri2" value='2' name="pernah_menikah_istri">
						<label class="labelRadio" for="nikahIstri2">Tidak</label>
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
				<div class="form-group">
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12 col-lg-offset-3 col-md-offset-3">
						<div class="crop-edit imgIstri">
							<center>
								<img id="preview-photo-istri" src="<?php echo url('dist/img/default_image.jpg'); ?>" class="img-polaroid" min-height="250" width="70%">
							</center>
						</div>
					</div>
					<div class='clearfix p-b-5'></div>
					<label class="control-label col-lg-3 col-md-3 col-sm-12 col-xs-12" id='label-input'>Foto Istri</label>
					<div class="col-lg-9 col-md-9 col-sm-12 col-xs-12">
						<input type="file" id='valImgIstri' class="upload" onchange="loadFilePhoto(event)" name="foto" accept="image/*" class="form-control customInput input-sm col-md-7 col-xs-12">
					</div>
				</div>
				<div class='clearfix p-b-5'></div>
			</div>
			<div class="clearfix"></div>
			<h4 class="labelGreen m-0 m-b-5"><i class="fa fa-puzzle-piece m-r-15"></i> 2. DATA PERNIKAHAN</h4>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Persyaratan administrasi</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12">
					<input type="radio" class="customCheck" id="adminis1" value='1' name="syarat_administrasi" required="required"><label class="labelRadio" for="adminis1">Lengkap</label>
					<input type="radio" class="customCheck" id="adminis2" value='2' name="syarat_administrasi" required="required"><label class="labelRadio" for="adminis2">Tidak Lengkap</label>
				</div>
			</div>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Apakah sudah akad nikah di desa, sebelum ke KUA ?</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12">
					<input type="radio" class="customCheck" id="akadSebelum1" value='1' name="akad_sebelum_kua" required="required"><label class="labelRadio" for="akadSebelum1">Ya</label>
					<input type="radio" class="customCheck" id="akadSebelum2" value='2' name="akad_sebelum_kua" required="required"><label class="labelRadio" for="akadSebelum2">Tidak</label>
				</div>
				<div class='col-lg-12 p-0 m-0 m-b-5' id='tglAkadSebelum' style='display:none'>
					<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Tanggal</label>
					<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12 input-group p-t-0 p-b-0 p-l-15 p-r-15">
						<div class="input-group-addon">
							<i class="fa fa-calendar"></i>
						</div>
						<input type="text" name='tgl_akad' autocomplete='off' placeholder='dd-mm-yyyy' class="form-control pull-right"  id='form_datetime_today_akad' data-date-format="dd-mm-yyyy" required='required'>
					</div>
				</div>
			</div>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Apakah sudah menerima Vitamin pengantin dari puskesmas ?</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12">
					<input type="radio" class="customCheck" id="vitamin1" value='1' name="menerima_vitamin" required="required"><label class="labelRadio" for="vitamin1">Ya</label>
					<input type="radio" class="customCheck" id="vitamin2" value='2' name="menerima_vitamin" required="required"><label class="labelRadio" for="vitamin2">Tidak</label>
				</div>
			</div>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Mengikuti konseling/SUSCATIN ?</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12">
					<input type="radio" class="customCheck" id="konseling1" value='1' name="ikut_konseling" required="required"><label class="labelRadio" for="konseling1">Ya</label>
					<input type="radio" class="customCheck" id="konseling2" value='2' name="ikut_konseling" required="required"><label class="labelRadio" for="konseling2">Tidak</label>
				</div>
			</div>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0 p-b-5">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>Tanggal Pernikahan</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12 input-group p-t-0 p-b-0 p-l-15 p-r-15">
					<div class="input-group-addon">
						<i class="fa fa-calendar"></i>
					</div>
					<input type="text" name='tgl_pernikahan' autocomplete='off' placeholder='dd-mm-yyyy' class="form-control pull-right"  id='form_datetime_today_nikah' data-date-format="dd-mm-yyyy" required='required'>
				</div>
			</div>
			<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 form-group m-b-0">
				<label class="control-label col-lg-5 col-md-5 col-sm-12 col-xs-12" id='label-input'>No. Registrasi Pernikahan</label>
				<div class="col-lg-5 col-md-5 col-sm-12 col-xs-12">
					<input type="text" name="no_reg_pernikahan" required='required' autocomplete='off' class="form-control input-sm customInput col-md-7 col-xs-12">
				</div>
			</div>
			<div class='clearfix p-b-5'></div>
		</div>
		<div class="box-footer">
			<span id='tombol'>
				<button type="submit" class="btn btn-primary pull-right m-l-15">Simpan <span class="fa fa-save"></span></button>
			</span>
			<button type="button" class="btn btn-warning btn-cancel pull-right"><span class="fa fa-chevron-left"></span> Kembali</button>
		</div>
	</form>
</div>
<script type="text/javascript">
	var onLoad = (function() {
		$('#panel-add').animateCss('bounceInUp');
	})();

	$('.btn-cancel').click(function(e){
    	e.preventDefault();
    	$('#panel-add').animateCss('bounceOutDown');
    	$('.other-page').fadeOut(function(){
    		$('.other-page').empty();
            $('.main-layer').fadeIn();
        });
    });

    $('#form_datetime_today_reg').datetimepicker({
        weekStart: 2,
        todayBtn:  1,
        autoclose: 1,
        todayHighlight: 1,
        startView: 2,
        minView: 2,
        forceParse: 0,
    });

    $('#form_datetime_today_husban').datetimepicker({
        weekStart: 2,
        todayBtn:  1,
        autoclose: 1,
        todayHighlight: 1,
        startView: 2,
        minView: 2,
        forceParse: 0,
    });

    $('#agamaSuami').chosen();
    $('#provinsiSuami').chosen();
    $('#kabupatenSuami').chosen();
    $('#kecamatanSuami').chosen();
    $('#desaSuami').chosen();

    $('#provinsiSuami').change(function(){
    	var id= $('#provinsiSuami').val();
    	$.post("<?php echo route('getKabupaten'); ?>", {id :id }).done(function(data){
    		var listKab = '<option value="" disabled selected> .:: Pilih Kabupaten ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listKab += '<option value="'+v.id_kabupaten+'">'+v.nama_kabupaten+'</option>';
    			});
    		}
    		$('#kabupatenSuami').html(listKab);
    		$('#kabupatenSuami').trigger('chosen:updated');
    	});
    });
    $('#kabupatenSuami').change(function(){
    	var id= $('#kabupatenSuami').val();
    	$.post("<?php echo route('getKecamatan'); ?>", {id :id }).done(function(data){
    		var listKec = '<option value="" disabled selected> .:: Pilih Kecamatan ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listKec += '<option value="'+v.id_kecamatan+'">'+v.nama_kecamatan+'</option>';
    			});
    		}
    		$('#kecamatanSuami').html(listKec);
    		$('#kecamatanSuami').trigger('chosen:updated');
    	});
    });
    $('#kecamatanSuami').change(function(){
    	var id= $('#kecamatanSuami').val();
    	$.post("<?php echo route('getDesa'); ?>", {id :id }).done(function(data){
    		var listDes = '<option value="" disabled selected> .:: Pilih Desa ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listDes += '<option value="'+v.id_desa+'">'+v.nama_desa+'</option>';
    			});
    		}
    		$('#desaSuami').html(listDes);
    		$('#desaSuami').trigger('chosen:updated');
    	});
    });
    
    function loadFilePhotoSuami(event) {
        var image = URL.createObjectURL(event.target.files[0]);
        $('#preview-photo-suami').fadeOut(function(){
        	$(this).attr('src', image).fadeIn().css({
        		'-webkit-animation' : 'showSlowlyElement 700ms',
        		'animation'         : 'showSlowlyElement 700ms'
        	});
        });
    };

    $('#form_datetime_todayWife').datetimepicker({
        weekStart: 2,
        todayBtn:  1,
        autoclose: 1,
        todayHighlight: 1,
        startView: 2,
        minView: 2,
        forceParse: 0,
    });

    $('#agamaIstri').chosen();
    $('#provinsiIstri').chosen();
    $('#kabupatenIstri').chosen();
    $('#kecamatanIstri').chosen();
    $('#desaIstri').chosen();

    $('#provinsiIstri').change(function(){
    	var id= $('#provinsiIstri').val();
    	$.post("<?php echo route('getKabupaten'); ?>", {id :id }).done(function(data){
    		var listKab = '<option value="" disabled selected> .:: Pilih Kabupaten ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listKab += '<option value="'+v.id_kabupaten+'">'+v.nama_kabupaten+'</option>';
    			});
    		}
    		$('#kabupatenIstri').html(listKab);
    		$('#kabupatenIstri').trigger('chosen:updated');
    	});
    });
    $('#kabupatenIstri').change(function(){
    	var id= $('#kabupatenIstri').val();
    	$.post("<?php echo route('getKecamatan'); ?>", {id :id }).done(function(data){
    		var listKec = '<option value="" disabled selected> .:: Pilih Kecamatan ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listKec += '<option value="'+v.id_kecamatan+'">'+v.nama_kecamatan+'</option>';
    			});
    		}
    		$('#kecamatanIstri').html(listKec);
    		$('#kecamatanIstri').trigger('chosen:updated');
    	});
    });
    $('#kecamatanIstri').change(function(){
    	var id= $('#kecamatanIstri').val();
    	$.post("<?php echo route('getDesa'); ?>", {id :id }).done(function(data){
    		var listDes = '<option value="" disabled selected> .:: Pilih Desa ::. </option>';
    		if(data.length > 0){
    			$.each(data, function(k,v){
    				listDes += '<option value="'+v.id_desa+'">'+v.nama_desa+'</option>';
    			});
    		}
    		$('#desaIstri').html(listDes);
    		$('#desaIstri').trigger('chosen:updated');
    	});
    });

    function loadFilePhoto(event) {
        var image = URL.createObjectURL(event.target.files[0]);
        $('#preview-photo-istri').fadeOut(function(){
        	$(this).attr('src', image).fadeIn().css({
        		'-webkit-animation' : 'showSlowlyElement 700ms',
        		'animation'         : 'showSlowlyElement 700ms'
        	});
        });
    };
    
    function cekNIK() {
		var nik = $('#nikIstri').val();
		$.post("<?php echo route('cekNikIstri'); ?>", {nik:nik }).done(function(data){
			if(data.bumil.length == 0){
				$('#namaBumil').val("");$('#namaBumil').attr('readonly',false);
				$('#tmpLahir').val("");$('#tmpLahir').attr('readonly',false);
				$('#form_datetime_todayWife').val("");$('#form_datetime_todayWife').attr('disabled',false);
				$('#agamaIstri').html("<option value='' disabled selected> .:: Pilih Agama ::. </option><option value='Aliran Kepercayaan'>Aliran Kepercayaan</option><option value='Buddha'>Buddha</option><option value='Hindu'>Hindu</option><option value='Islam'>Islam</option><option value='Konghucu'>Konghucu</option><option value='Kristen Protestan'>Kristen Protestan</option><option value='Katholik'>Katholik</option>");
				$('#agamaIstri').attr('disabled',false);
				$('#agamaIstri').trigger('chosen:updated');
				$('#sukuIstri').val("");$('#sukuIstri').attr('readonly',false);
				$('#pendidikanIstri').val("");$('#pendidikanIstri').attr('readonly',false);
				$('#pekerjaanIstri').val("");$('#pekerjaanIstri').attr('readonly',false);
				$('#alamatIstri').val("");$('#alamatIstri').attr('readonly',false);
				var prov = "<option value='' disabled selected> .:: Pilih Provinsi ::. </option>";
				$.each(data.provinsis, function(k,p){
					prov += '<option value="'+p.id_provinsi+'">'+p.nama_provinsi+'</option>';
				});
				$('#provinsiIstri').html(prov);$('#provinsiIstri').attr('disabled',false);
				$('#provinsiIstri').trigger('chosen:updated');
				$('#kabupatenIstri').html("<option value='' disabled selected> .:: Pilih Kabupaten ::. </option>");$('#kabupatenIstri').attr('disabled',false);
				$('#kabupatenIstri').trigger('chosen:updated');
				$('#kecamatanIstri').html("<option value='' disabled selected> .:: Pilih Kecamatan ::. </option>");$('#kecamatanIstri').attr('disabled',false);
				$('#kecamatanIstri').trigger('chosen:updated');
				$('#desaIstri').html("<option value='' disabled selected> .:: Pilih Desa ::. </option>");$('#desaIstri').attr('disabled',false);
				$('#desaIstri').trigger('chosen:updated');
				var gmbIstri = "<center><img id='preview-photo-istri' src='<?php echo url('dist/img/default_image.jpg'); ?>' class='img-polaroid' min-height='250' width='70%'></center>";
				$('.imgIstri').html(gmbIstri);
				$('#valImgIstri').val("");
			}else{
				$.each(data.bumil, function(k,v){
					$('#namaBumil').val(v.nama_bumil);$('#namaBumil').attr('readonly',false);
					$('#tmpLahir').val(v.tmp_lahir);$('#tmpLahir').attr('readonly',false);
					var tglAwal = v.tgl_lahir.split("-");
					var tglEnd = tglAwal[2]+"-"+tglAwal[1]+"-"+tglAwal[0];
					$('#form_datetime_todayWife').val(tglEnd);$('#form_datetime_todayWife').attr('disabled',false);
					var choseAgama = "<option value='"+v.agama+"'>"+v.agama+"</option>";
					$('#agamaIstri').html("<option value='"+v.agama+"'>"+v.agama+"</option>");$('#agamaIstri').attr('disabled',false);
					$('#agamaIstri').trigger('chosen:updated');
					$('#sukuIstri').val(v.suku);$('#sukuIstri').attr('readonly',false);
					$('#pendidikanIstri').val(v.pendidikan);$('#pendidikanIstri').attr('readonly',false);
					$('#pekerjaanIstri').val(v.pekerjaan);$('#pekerjaanIstri').attr('readonly',false);
					$('#alamatIstri').val(v.alamat_ktp);$('#alamatIstri').attr('readonly',false);

					var prov = "<option value='' disabled selected> .:: Pilih Provinsi ::. </option>";
					$.each(data.provinsis, function(k,p){
						if (p.id_provinsi == v.provinsi_ktp_id) {
							prov += '<option value="'+p.id_provinsi+'" selected>'+p.nama_provinsi+'</option>';
						}else{
							prov += '<option value="'+p.id_provinsi+'">'+p.nama_provinsi+'</option>';
						}
					});
					var kab = "<option value='' disabled selected> .:: Pilih Kabupaten ::. </option>";
					$.each(data.kabupatens, function(k,p){
						if (p.id_kabupaten == v.kabupaten_ktp_id) {
							kab += '<option value="'+p.id_kabupaten+'" selected>'+p.nama_kabupaten+'</option>';
						}else{
							kab += '<option value="'+p.id_kabupaten+'">'+p.nama_kabupaten+'</option>';
						}
					});
					var kec = "<option value='' disabled selected> .:: Pilih Kecamatan ::. </option>";
					$.each(data.kecamatans, function(k,p){
						if (p.id_kecamatan == v.kecamatan_ktp_id) {
							kec += '<option value="'+p.id_kecamatan+'" selected>'+p.nama_kecamatan+'</option>';
						}else{
							kec += '<option value="'+p.id_kecamatan+'">'+p.nama_kecamatan+'</option>';
						}
					});
					var des = "<option value='' disabled selected> .:: Pilih Desa ::. </option>";
					$.each(data.desas, function(k,p){
						if (p.id_desa == v.desa_ktp_id) {
							des += '<option value="'+p.id_desa+'" selected>'+p.nama_desa+'</option>';
						}else{
							des += '<option value="'+p.id_desa+'">'+p.nama_desa+'</option>';
						}
					});

					$('#provinsiIstri').html(prov);
					$('#provinsiIstri').trigger('chosen:updated');
					$('#kabupatenIstri').html(kab);
					$('#kabupatenIstri').trigger('chosen:updated');
					$('#kecamatanIstri').html(kec);
					$('#kecamatanIstri').trigger('chosen:updated');
					$('#desaIstri').html(des);
					$('#desaIstri').trigger('chosen:updated');
					var gmbIstri = "<center><img id='preview-photo-istri' src='<?php echo url('dist/img/istri/"+v.foto+"'); ?>' class='img-polaroid' min-height='250' width='70%'></center>";
					$('.imgIstri').html(gmbIstri);
    			});
			}
		});
	}
/*
	function cekReg() {
		var noReg = $('#noRegistrasi').val();
		$.post("<?php echo route('cekNoRegistrasi'); ?>", {noReg:noReg }).done(function(data){
			if(data.length == 0){
				$('#gr_reg').attr('class','form-group');
				var icon = "<i class='fa fa-check-circle'></i>";
				$('#icon_reg').attr('style','color:green');
				var status = "";
				var button = '<button type="submit" class="btn btn-primary pull-right m-l-15">Simpan <span class="fa fa-save"></span></button>';
			}else{
				$('#gr_reg').attr('class','form-group has-error');
				var icon = "<i class='fa fa-warning'></i>";
				$('#icon_reg').attr('style','color:red');
				var status = "<p class='messageError'><i>No Registrasi Sudah Digunakan</i></p>";
				var button = '<button type="submit" class="btn btn-primary pull-right m-l-15" disabled>Simpan <span class="fa fa-save"></span></button>';
			}
			if (noReg != '') {
				$('#cek_no_req').html(status);
				$('#icon_reg').html(icon);
				$('#tombol').html(button);
			}else{
				$('#cek_no_req').html("");
				$('#icon_reg').html("");
				$('#tombol').html('<button type="submit" class="btn btn-primary pull-right m-l-15" disabled>Simpan <span class="fa fa-save"></span></button>');
			};
		});
	}
*/

    $('#akadSebelum1 ').click(function(){
		$('#tglAkadSebelum').show();
		$('#form_datetime_today_akad').attr('required',true);
	});
	$('#akadSebelum2').click(function(){
		$('#tglAkadSebelum').hide();
		$('#form_datetime_today_akad').attr('required',false);
	});

    $('#form_datetime_today_akad').datetimepicker({
        weekStart: 2,
        todayBtn:  1,
        autoclose: 1,
        todayHighlight: 1,
        startView: 2,
        minView: 2,
        forceParse: 0,
    });

    $('#form_datetime_today_nikah').datetimepicker({
        weekStart: 2,
        todayBtn:  1,
        autoclose: 1,
        todayHighlight: 1,
        startView: 2,
        minView: 2,
        forceParse: 0,
    });
</script>