<script src="<?php echo base_url();?>resources/js/jquery.ui.timepicker.js"></script>
<div class="centering" style="width:612px;margin-top: 1%;z-index:-100">
    <div id='frm_court_calendar' style="border: 1px solid #ffffff;">
        <div class="detil" style="padding: 2px;background-color: white;">
            <div style="font-size:14px;">
                <?php if($act==='tambah'){ ?>               
                <form id="frm_input_cc" style="background:white;margin:0;" method="post" action="<?php echo base_url().'manage_court_calendar/validateInput';?>">
                <?php }elseif($act==='edit'){ ?>
                <form id="frm_input_cc" class="removeformbottomspace" method="post" action="<?php echo base_url().'manage_court_calendar/validateEdit';?>">
                <?php } ?>
                    <table id='tableDetilPerkara' style="font-size:14px; width:100%" border="0">
                        <col width="280px">
                        <col>
                        <tbody>
                            <tr><td align="center" style="padding:4px;background:white;font-size:16px;color:#111;" colspan="2">TAMBAH/EDIT RENCANA PERSIDANGAN<br></td></tr>
                            <tr><td class="divider" colspan="2">Data Perkara</td></tr>                                                       
                            <tr>
                                <td >Nomor Perkara</td>
                                <td style="font-weight: bold;"><span><?php print $nomor_perkara;?></span></td>
                            </tr>                    
                            <tr>
                                <td >Jenis Perkara</td>
                                <td style="font-weight: bold;"><span><?php print $jenis_perkara;?></span></td>
                            </tr>
                            <tr>
                                <td >Tanggal Pendaftaran</td>
                                <td style="font-weight: bold;"><span><?php print $tgl_pendaftaran;?></span></td>
                            </tr>
                            <tr><td class="divider" colspan="2">Rencana Jadwal Persidangan</td></tr> 
                             <tr>
                                <td>Tanggal Persidangan<font color="red">*</font></td>
                                <td style="padding:0px;padding-left:5px;">
                                    <input id="tgl_sidang" name="tgl_sidang" value="<?php echo $rencana_tanggal; ?>" class="datepicker" maxlength="10" placeholder="tgl/bln/tahun">
                                </td>
                            </tr>
                            <tr>
                                <td>Jam Pelaksanaan<span style="color:red">*</span></td>
                                <td>
                                    <input id="jamSidang" name="jamSidang" value="<?php echo substr($jam_sidang,0,5); ?>" class="timepicker" maxlength="4" placeholder="HH:mm">&nbsp;s.d&nbsp;<b>selesai</b>
                                </td>
                            </tr>                   
                            <tr>
                                <td valign="top" style="vertical-align:top;">Jadwal/Agenda Sidang<font color="red">*</font></td>
                                <td><textarea class="standard-input" id="agenda_sidang" name="agenda_sidang"  style="height: 50px;resize: none;width:300px"><?php echo $rencana_agenda; ?></textarea><td>
                            </tr>

                            <tr>
                                <td >Keterangan</td>
                                <td>
                                    <textarea class="standard-input" id='keterangan' name='keterangan' value="<?php echo $keterangan; ?>"  style="height: 50px;resize: none;width:300px"><?php echo $keterangan; ?></textarea>
                                </td>
                            </tr>
                            <tr>
                                <td colspan="2" class="buttongroup">
                                    <input type="button" id='close_frm_cc' value="Kembali" class="btn">
                                    <?php
                                        if(!empty($enc_cc)){
                                            echo '<input type="button" id="hapus" value="Hapus" style="text-decoration:none" class="btn btn-danger">';
                                         }
                                    ?>                                   
                                    <input type="submit" id="simpan" value="Simpan" class="btn">
                                </td>
                            </tr>
                            <input type="hidden" id="nomor_perkara" name="nomor_perkara" value="<?php echo $nomor_perkara;?>" >
                            <input type="hidden" id="curr_date" value="<?php  echo $current_date;?>">
                            <input type="hidden" id="refresh" class='detil_perkara_refresh' value="0">
                            <input type="hidden" name='enc' value='<?php  echo $enc;?>'>
                            <?php 
                                if($act=='edit'){
                            ?>
                            <input type="hidden" name='enc_cc' value='<?php  echo $enc_cc;?>'>
                            <?php        
                                }
                            ?>
                            
                        </tbody>
                    </table>
                </form>
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">    
    $('#jamSidang').timepicker({});
    $('#close_frm_cc').closingFormWin();
    $('#frm_input_cc').SubmitHandling({
        refresh:'1',
        setRefresh:1,
        divRef:'#konten',
        clicked:1,
        btnClicked:'#close_frm_cc',
        whenStatus:1
    });   
    $('#hapus').ButtonClickHandling({
        refresh:'1',
        setRefresh:1,
        divRef:'#konten',
        clicked:1,
        btnClicked:'#close_frm_cc',
        whenStatus:1,
        actions:'<?php echo base_url()?>manage_court_calendar/hapus_cc/',
        formName:'#frm_input_cc',
        actionName:'Hapus Data'
    });
       
    $('#tgl_sidang').datepicker({
                inline: true,
                showOtherMonths: true,
                dateFormat: 'dd/mm/yy',
                dayNamesMin: ['Ming', 'Sen', 'Sel', 'Rab', 'Kam', 'Jum', 'Sab']
    });

    $('.datepicker').ValidateDateInput();

   
</script>
