<?php
if($this->session->userdata('is_logged_in')===FALSE){
            redirect('login');
}
?>
<div class="centering" style="width:500px;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().'c_template_pen_tun/cetak_penetapan_majelis_hakim_tun';?>">
                    <table id='tableDetilPerkara' style="font-size:14px;">
                        <col width="35%">
                        <col width="65%">
                        <tbody>
                        <tr>
                            <td class="header" colspan="2"><?php //echo strtoupper($judul."<br/>Perkara ".$jnsperkara); ?> Cetak Penetapan Hakim/Majelis Majelis</td>
                        </tr>
                        <tr>
                            <td id="first-child">Nomor Perkara <?php //print_r($enc1); ?></td>
                            <td>
                                <?php print_r($perkara['0']['nomor_perkara']); ?>
                                <input type="hidden" name='enc' value='<?php echo $enc;?>'>
                            </td>
                        </tr>
                        <tr>
                            <?php
                            if (intval($perkara['0']['alur_perkara_id'])>100){
                                echo "<td id='first-child'>Tanggal Pelimpahan</td>";
                            }else{
                                echo "<td id='first-child'>Tanggal Pendaftaran</td>";
                            }
                            ?>
                            <td>
                            <?php echo $this->tanggalhelper->convertDayDate($tanggal_pelimpahan->tanggal_pendaftaran); ?>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2" class="divider">Info Penetapan Majelis Hakim</td>
                        </tr>
                        <tr>
                            <td id="first-child">Tanggal Penetapan Majelis Hakim</td>
                            <td>
                            <?php
                                if (count($data_majelis_detail)<>0){                            
                                    foreach ($data_majelis_detail as $row=>$val){
                                        if ($val['aktif']=='Y'){
                                            echo $this->tanggalhelper->convertDayDate($val['tanggal_penetapan']);                                   
                                            break;
                                        }
                                    }
                                }else{
                                    echo $this->tanggalhelper->convertDayDate($data_majelis_detail['0']['tanggal_penetapan']);
                                }
                            ?>
                            </td>
                        </tr>
                        <tr>                        
                            <td id="first-child">Hakim/Majelis Hakim</td>
                            <td>
                                <?php echo $data_majelis['0']['majelis_hakim_text']; ?>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2" class="divider" >Cetak</td>
                        </tr>
                        <tr>
                            <td class="templatepopleftcol">Ditetapkan Oleh <font color=red>*</font></td>
                            <td style="">
                                <span class="custom-dropdown custom-dropdown--emerald">
                                    <select style='width:303px;'  name="ditetapkanoleh" id="ditetapkanoleh" class="custom-dropdown__select custom-dropdown__select--white">
                                        <option value='1'><?php echo $this->templatehelper->ucname("Ketua ".$penandatangan->row(0)->NamaPN." :: ".$penandatangan->row(0)->KetuaPNNama);?></option>
                                        <option value='2'><?php echo $this->templatehelper->ucname("Wakil Ketua ".$penandatangan->row(0)->NamaPN." :: ".$penandatangan->row(0)->WakilKetuaPNNama);?></option>
                                    </select>
                                </span>
                            </td> 
                        </tr>
                        <tr>
                            <td colspan="2" class="buttongroup">
                            <input type="button" id="kembali" value="Kembali" class="btn">
                            <input type="submit" id="simpan" value="Cetak" class="btn">
                            </td>
                        </tr>
                        </tbody>
                    </table>
                </form>
            </div>
        </div>
    </div>
</div>

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