<div class="centering" style="width:600px;margin-top: 1%;z-index:-100">
	<div id='majelis_hakim' style="border: 1px solid #ffffff;">
    	<div class="detil" style="padding: 2px;background-color: white;">
            	<div style="font-size:14px;">
            	<form id="frm_majelis" class="removeformbottomspace" method="post" action="<?php echo base_url().'detil_pk/simpan_penetapan_majelis_pemeriksa';?>">
              	<table id='tableDetilPerkara' style="font-size:14px;">
		<col width="45%">
		<col width="55%">
		<tbody>
			<tr>
				<td style="padding:4px;background:white;font-size:16px;color:#111;" align="center" colspan="2"><strong>Penetapan <?php echo $alur_perkara_id<100?'Majelis':''; ?> Hakim Pemeriksa PK</strong></td>
			</tr>
			<tr>
				<td id="first-child">Tanggal Penetapan <?php echo $alur_perkara_id>100?'Majelis':''; ?> Hakim <font color="red">*</font></td>
				<td><input id="tgl_penetapan" name="tgl_penetapan" value="<?php echo $tanggal_penetapan; ?>"  class="datepicker" maxlength="10" placeholder="tgl/bln/tahun"></td>
				<input type="hidden" name="perkara_id" id="perkara_id" value="<?php echo $perkara_id;?>">
				<input type="hidden" name="alur_perkara_id" id="alur_perkara_id" value="<?php echo $alur_perkara_id;?>">
			</tr>			
			<tr class="majelis">
				<td id="first-child">Hakim <?php echo $alur_perkara_id>100?'Ketua':''; ?> <font color="red">*</font></td>
				<td><?php echo form_dropdown('hakim1', $hakim_pn, $hakim1, ' class="form-control" id="hakim1"'); ?></td>
			</tr>
			<?php if($alur_perkara_id>100){ ?>
			<tr class="majelis">
				<td id="first-child">Hakim Anggota 1 <font color="red">*</font></td>
				<td><?php echo form_dropdown('hakim2', $hakim_pn, $hakim2, ' class="form-control" id="hakim2"'); ?></td>
			</tr>
			<tr class="majelis">
				<td id="first-child">Hakim Anggota 2 <font color="red">*</font></td>
				<td><?php echo form_dropdown('hakim3', $hakim_pn, $hakim3, ' class="form-control" id="hakim3"'); ?></td>
			</tr>
			<?php } ?>
			<tr>
				<td colspan="2" class="buttongroup">
					<input type="button" id='close_form_add_majelis' value="Kembali" class="btn">
					<input type="submit" id="simpan" value="Simpan" class="btn">
					<input type="hidden" id="tanggal_sekarang" value="<?php echo $tanggal_sekarang;?>">
					<input type="hidden" id="refresh" class='detil_perkara_refresh' value="0">
				</td>
			</tr>
		</tbody>
	</table>
              	</form>
            	</div>
        	</div>
    	</div>
</div>

<script type="text/javascript">
 $('#close_form_add_majelis').closingFormWin();
$('.datepicker').ValidateDateInput();

$('#frm_majelis').SubmitHandling({
	refresh:'1',
     	setRefresh:1,
     	divRef:'#konten',
     	clicked:1,
     	btnClicked:'.close_form',
     	whenStatus:1
 });

$('#tgl_penetapan').datepicker({
	inline: true,
     	showOtherMonths: true,
     	dateFormat: 'dd/mm/yy',
     	dayNamesMin: ['Ming', 'Sen', 'Sel', 'Rab', 'Kam', 'Jum', 'Sab'],
     	beforeShowDay:$.datepicker.noWeekends,
     	onSelect: function(dateText, inst) {
              		var error = 0;
               
               	var tmp = $(this).val().split("/");
                    	var tmp2 = $('#tanggal_sekarang').val().split("/");
                    	if((new Date(tmp[2]+"-"+tmp[1]+"-"+tmp[0]+"T00:00:00").getTime() > new Date(tmp2[2]+"-"+tmp2[1]+"-"+tmp2[0]+"T00:00:00").getTime())){
                         		message = 'Tidak Dapat Memilih Melebihi Hari ini. Sekarang Tanggal '+$('#tanggal_sekarang').val();
                         		error = 1
                   	}

                    	if(error==1){
                         		message_error_show(message);
                         		$(this).css("background-color", "red");
                   	}else{
                         		$(this).css("background-color", "#dedbdb");
                   	}
                   	error = 0;
     	}
});
</script>