예제 #1
0
function paging($sql, $item_per_page, $page_per_block, $url, $page, $block)
{
    /*The Simple Advanced Paging by Bimosaurus..
    Please make it sure that this page is load the code like it
    ********************************************
    $item_per_page = 10;
    $page_per_block= 10;
    
    if (!isset($_GET[page]) ){
       $page  = 1;
       $block = 1;
    }else{
       $page  = ($_GET[page]);
       $block = ceil($page/$page_per_block);
    }
    
    $offset = ($page - 1) * $item_per_page ;
    ********************************************
    */
    $q = bukaquery($sql);
    $n = mysql_num_rows($q);
    $jumdata = $n;
    $jumhal = ceil($n / $item_per_page);
    $jumblock = ceil($jumhal / $page_per_block);
    /*Prevent from Paging Hacking*/
    if ($_GET[page] > $jumhal) {
        $page = $jumhal;
        $block = ceil($page / $page_per_block);
    } elseif ($_GET[page] < 1) {
        $page = 1;
        $block = 1;
    }
    /*end of prevention*/
    if ($jumhal > 1) {
        ?>
      <span style="float:left; margin-right:10px; font-size:13px; color:#333;">Halaman : </span>
      <?php 
        if ($block <= 1) {
            $prev = "no";
            $next = "yes";
        } elseif ($block >= $jumblock) {
            $prev = "yes";
            $next = "no";
        } else {
            $prev = "yes";
            $next = "yes";
        }
        if ($prev == "yes") {
            $prev_page = ($block - 1) * $page_per_block;
            $prev_block = $block - 1;
            ?>
         <span class="block_nav_page"><a href="<?php 
            echo $url;
            ?>
&page=1">&laquo;&laquo;First</a></span>
         <span class="block_nav_page" style="margin-right:8px;"><a href="<?php 
            echo $url;
            ?>
&page=<?php 
            echo $prev_page;
            ?>
">&laquo;Prev</a></span>
         <?php 
        } elseif ($prev == "no" && $jumblock > 1) {
            ?>
         <span class="block_nav_page" style="color:#ccc;">&laquo;&laquo;First</span>
         <span class="block_nav_page" style="margin-right:8px; color:#ccc;">&laquo;Prev</span>
         <?php 
        }
        $startblock = ($block - 1) * $page_per_block + 1;
        $endblock = $block * $page_per_block;
        while ($startblock <= $endblock && $startblock <= $jumhal) {
            if ($startblock == $page) {
                ?>
            <span class="item_paging_current"><?php 
                echo $startblock;
                ?>
</span>
            <?php 
            } else {
                ?>
            <span class="item_paging_active"><a href="<?php 
                echo $url;
                ?>
&page=<?php 
                echo $startblock;
                ?>
"><?php 
                echo $startblock;
                ?>
</a></span>
            <?php 
            }
            $startblock++;
        }
        if ($next == "yes") {
            $next_page = $block * $page_per_block + 1;
            $next_block = $block + 1;
            if ($next_page <= $jumhal) {
                ?>
            <span class="block_nav_page" style="margin-left:8px;"><a href="<?php 
                echo $url;
                ?>
&page=<?php 
                echo $next_page;
                ?>
">Next&raquo;</a></span>
            <span class="block_nav_page"><a href="<?php 
                echo $url;
                ?>
&page=<?php 
                echo $jumhal;
                ?>
">End &raquo; &raquo;</a></span>
            <?php 
            }
        } else {
            ?>
         <span class="block_nav_page" style="margin-left:8px; color:#ccc;">Next&raquo;</span>
         <span class="block_nav_page" style="color:#ccc;">End&raquo;&raquo;</span>
         <?php 
        }
    }
}
예제 #2
0
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['0']}</td>\n                                <td>" . formatDuit($baris[1]) . "</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data Status Keanggotaan Jamsostek masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" jamsostek ", " stts ='" . $stts . "' ", "?act=DetailJamsostek&action=TAMBAH&stts={$stts}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT stts,biaya from jamsostek ORDER BY stts ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo " Data : {$jumlah}";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
 }
 $hasil23 = bukaquery($_sql23);
 $baris23 = mysql_fetch_array($hasil23);
 $ttlinsentif = $baris23[0];
 $ttlttlinsentif = $ttlttlinsentif + $ttlinsentif;
 $jmltmb = $ttlinsentif + $jm + $jl;
 $ttljmltmb = $ttljmltmb + $jmltmb;
 $ttlgaji = $jmltmb + $lemburhb + $lemburhr + $gapok + $tnjjbtn + $tnjtnj + $tnjtnjbln + $ttlkasift + $tmbhjgmlm + $tmbahanjg + $tnjhadir;
 $ttlttlgaji = $ttlttlgaji + $ttlgaji;
 $_sql30 = "select master_tindakan.nama,sum(tindakan.jm)\n                                              from master_tindakan,tindakan\n                                              where tindakan.tnd=master_tindakan.id and\n                                              tindakan.id='{$baris['0']}'\n                                              and tgl like '%" . $tahun . "-" . $bulan . "%'\n                                              group by tindakan.tnd ";
 $hasil30 = bukaquery($_sql30);
 while ($baris30 = mysql_fetch_array($hasil30)) {
 }
 echo " \n                                  <td><font size='2' color='green'><i>" . formatDuit($ttlgaji) . "</i></font></td>\n                                  <td>";
 $_sql25 = "select potongan.jamsostek,\n                                                potongan.dansos,\n                                                potongan.simwajib,\n                                                potongan.angkop,\n                                                potongan.angla,\n                                                potongan.telpri,\n                                                potongan.pajak,\n                                                potongan.pribadi,\n                                                potongan.lain from potongan\n                                                where potongan.id='{$baris['0']}' and\n                                                potongan.tahun='{$tahun}' and potongan.bulan='{$bulanindex}' ";
 $hasil25 = bukaquery($_sql25);
 $baris25 = mysql_fetch_array($hasil25);
 $jamsostek = $baris25[0];
 $dansos = $baris25[1];
 $simwajib = $baris25[2];
 $angkop = $baris25[3];
 $angla = $baris25[4];
 $telpri = $baris25[5];
 $pajak = $baris25[6];
 $pribadi = $baris25[7];
 $lain = $baris25[8];
 if (empty($baris25[0])) {
     $jamsostek = 0;
 } else {
     $jamsostek = $baris25[0];
 }
예제 #4
0
    echo "</table>";
} else {
    echo "<b>Data Bidang masih kosong !</b>";
}
?>
   
    
    <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" bidang ", " nama ='" . $_GET['nama'] . "' ", "?act=ListBidang");
}
?>
    </div>
    <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT nama FROM bidang");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah} ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #5
0
<ul class="left_menu">
<?php 
$x = bukaquery("select * from kategori order by nm_kategori");
while ($row = mysql_fetch_row($x)) {
    $x2 = bukaquery("select * from subkategori where kd_kategori='{$row['0']}' order by nm_subktg");
    echo "<li class='even'><a href=?act=ListKategoriProduk&action=KATEGORI&kd_kategori={$row['0']}&nm_kategori={$row['1']}>{$row['1']} (" . mysql_num_rows($x2) . ")</a></li>";
}
?>

</ul>
<br/>
예제 #6
0
$baris = mysql_fetch_row($hasil);
$tahun = $baris[0];
$bln_leng = strlen($baris[1]);
$bulan = "0";
if ($bln_leng == 1) {
    $bulan = "0" . $baris[1];
} else {
    $bulan = $baris[1];
}
$id = $_GET['id'];
$_sql = "SELECT nik,nama FROM pegawai where id='{$id}'";
$hasil = bukaquery($_sql);
$baris = mysql_fetch_row($hasil);
$nik = $baris[0];
$nama = $baris[1];
$_sql = "select rawatjalan.tgl,\n                        rawatjalan.id,\n                        rawatjalan.tnd,\n                        master_tindakan.nama,\n                        rawatjalan.jm,\n                        rawatjalan.nm_pasien,\n                        rawatjalan.kamar,\n                        rawatjalan.diagnosa,\n                        rawatjalan.jmlh\n                        from rawatjalan inner join master_tindakan\n                        where rawatjalan.tnd=master_tindakan.id and rawatjalan.id='{$id}'\n\t\t\t    and tgl like '%" . $tahun . "-" . $bulan . "%' ORDER BY tgl ";
$hasil = bukaquery($_sql);
$jumlah = mysql_num_rows($hasil);
$ttljm = 0;
if (mysql_num_rows($hasil) != 0) {
    echo "<table width='100%' border='0' align='center' cellpadding='0' cellspacing='0' class='tbl_form'>\n                    <caption><h3 class=title><font color='999999'>Laporan Rawat Jalan Dokter " . $nik . " " . $nama . "<br>Tahun " . $tahun . " Bulan " . $bulan . "</font></h3><br>\n\t\t\t\t\t</caption>\n                    <tr class='head'>\n                        <td width='20%'><div align='center'><font size='2' face='Verdana'><strong>Jmlh.Tindakan</strong></font></div></td>\n                        <td width='50%'><div align='center'><font size='2' face='Verdana'><strong>Nama Tindakan</strong></font></div></td>\n                        <td width='30%'><div align='center'><font size='2' face='Verdana'><strong>JM Tindakan</strong></font></div></td>\n                    </tr>";
    while ($baris = mysql_fetch_array($hasil)) {
        $ttljm = $ttljm + $baris[4];
        echo "<tr class='isi'>\n                                <td>{$baris['8']}&nbsp;</td>\n                                <td>{$baris['3']}&nbsp;</td>\n                                <td>" . formatDuit($baris[4]) . "&nbsp;</td>\n                             </tr>";
    }
    echo "</table>";
    echo "<br><font color='999999' size='3'><b>Jumlah Total JM : " . formatDuit($ttljm) . "</b></font>";
}
?>
    </body>
</html>
예제 #7
0
			    <option id='TxtIsi17' value='FT>1'>FT>1</option>
                        </select>
                        <span id="MsgIsi17" style="color:#CC0000; font-size:10px;"></span>
                    </td>
                </tr>
		<tr class="head">
                    <td width="25%" >Kode Index</td><td width="">:</td>
                    <td width="75%">
                        <select name="indexins" class="text2" onkeydown="setDefault(this, document.getElementById('MsgIsi18'));" id="TxtIsi18">
                            <!--<option id='TxtIsi12' value='null'>- Ruang -</option>-->
                            <?php 
$_sql = "SELECT dep_id,persen FROM indexins  ORDER BY dep_id";
$hasil = bukaquery($_sql);
if ($action == "UBAH") {
    $_sql2 = "SELECT dep_id,persen FROM indexins where dep_id='{$indexins}' ORDER BY dep_id";
    $hasil2 = bukaquery($_sql2);
    while ($baris2 = mysql_fetch_array($hasil2)) {
        echo "<option id='TxtIsi18' value='{$baris2['0']}'>{$baris2['0']} {$baris2['1']}%</option>";
    }
}
while ($baris = mysql_fetch_array($hasil)) {
    echo "<option id='TxtIsi18' value='{$baris['0']}'>{$baris['0']} {$baris['1']}%</option>";
}
?>
                        </select>
                        <span id="MsgIsi18" style="color:#CC0000; font-size:10px;"></span>
                    </td>
                </tr>
				<tr class="head">
                    <td width="25%" >BPD</td><td width="">:</td>
                    <td width="75%">
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['1']}</td>\n                                <td>" . formatDuit($baris[2]) . "</td>\n                                <td>{$baris['3']}</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data master tindakan masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" master_tindakan ", " id ='" . $_GET['id'] . "' ", "?act=DetailTindakanRj&action=TAMBAH&nama={$nama}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT id,nama,jm from master_tindakan ORDER BY nama ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo " Data : {$jumlah} ";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
예제 #9
0
<?php

include_once "conf/command.php";
include_once "conf/conf.php";
if (isset($_GET['act']) && $_GET['act'] == "login") {
    $sql = "SELECT nip,usere,passwordte,type FROM user WHERE usere='" . $_POST['usere'] . "' AND passwordte='" . $_POST['passwordte'] . "'";
    $hasil = bukaquery($sql);
    $baris = mysql_fetch_row($hasil);
    $nip = $baris[0];
    $usere = $baris[1];
    $passwordte = $baris[2];
    $type = $baris[3];
    $hasil = bukaquery($sql);
    $baris = mysql_fetch_row($hasil);
    if (JumlahBaris($hasil) == 0) {
        header("Location:index.php");
    } else {
        session_start();
        HapusAll(" sesion ");
        InsertData(" sesion ", "'{$nip}'");
        /*$ses_admin = $hasil[0];
        		session_register("ses_admin");
        		$url = "index.php?act=HomeAdmin&type=$type";*/
        if ($type == 'ADMIN') {
            $ses_admin = $hasil[0];
            session_register("ses_admin");
            $url = "index.php?act=HomeAdmin&nip={$nip}";
        } elseif ($type == 'PEGAWAI') {
            $ses_pegawai = $hasil[0];
            session_register("ses_pegawai");
            $url = "index.php?act=HomeAdmin&nip={$nip}";
예제 #10
0
$jumlah = mysql_num_rows($hasil);
if (mysql_num_rows($hasil) != 0) {
    echo "<table width='600px' border='0' align='center' cellpadding='0' cellspacing='0' class='tbl_form'>\r\n                    <tr class='head'>\r\n                        <td width='70px'><div align='center'><font size='2' face='Verdana'><strong>Proses</strong></font></div></td>\r\n                        <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>NIK</strong></font></div></td>\r\n                        <td width='250px'><div align='center'><font size='2' face='Verdana'><strong>Nama</strong></font></div></td>\r\n                        <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Anggota Koperasi</strong></font></div></td>\r\n                        <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Anggota Jamsostek</strong></font></div></td>\r\n                    </tr>";
    while ($baris = mysql_fetch_array($hasil)) {
        echo "<tr class='isi'>\r\n                                <td>\r\n                                    <center>\r\n                                        <a href=?act=InputKeanggotaan&action=UBAH&id={$baris['0']}>[Update]</a>\r\n                                    </center>\r\n                               </td>\r\n                                <td>{$baris['1']}</td>\r\n                                <td>{$baris['2']}</td>\r\n                                <td>{$baris['3']}</td>\r\n                                <td>{$baris['4']}</td>\r\n                             </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data keanggotaan masih kosong !</b>";
}
?>
    </div>
	</form>
    <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("select pegawai.id,pegawai.nik,pegawai.nama,\r\n                keanggotaan.koperasi, keanggotaan.jamsostek\r\n                from keanggotaan right OUTER JOIN pegawai\r\n                on keanggotaan.id=pegawai.id\r\n\t\t\t\twhere pegawai.nik like '%" . $keyword . "%' or \r\n\t\t\t\tpegawai.nama like '%" . $keyword . "%' or\r\n\t\t\t\tkeanggotaan.koperasi like '%" . $keyword . "%' or\r\n\t\t\t\tkeanggotaan.jamsostek like '%" . $keyword . "%'\r\n\t\t\t\torder by pegawai.id ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah} <a target=_blank href=/penggajian/pages/keanggotaan/LaporanKeanggotaan.php?&keyword={$keyword}>| Laporan |</a> ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #11
0
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['2']}</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data Jaga Malam masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" jgmlm ", " id ='" . $_GET['id'] . "' and tgl ='" . $_GET['tgl'] . "'", "?act=InputJagaMalam&action=TAMBAH&id={$id}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT tgl,id,jml\n                        from jgmlm  where id='{$id}'\n\t\t\t     and tgl like '%" . $tahun . "-" . $bulan . "%' ORDER BY tgl ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah} <a target=_blank href=http://" . host() . "/penggajian/pages/presensi/laporanpresensidetail.php?&id={$id}>| Laporan |</a>";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
예제 #12
0
    }
    echo "</table>";
} else {
    echo "<b>Data Jabatan Fungsional masih kosong !</b>";
}
?>
    
    <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" fungsional ", " kode ='" . $_GET['kode'] . "' ", "?act=ListFungsional");
}
?>
    </div>
    <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT kode,nama FROM fungsional");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "<br/>Jumlah Record : {$jumlah} ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #13
0
    }
    echo "</table>";
} else {
    echo "<b>Data Index Pegawai masih kosong !</b>";
}
$BtnPrint = $_POST['BtnPrint'];
if (isset($BtnPrint)) {
    echo "<html><head><title></title><meta http-equiv='refresh' content='2;pages/pegawai/LaporanIndex.php?&keyword={$keyword}'></head><body></body></html>";
}
?>
    </div>
            </form>
       <?php 
if (mysql_num_rows($hasil) != 0) {
    $say = " pegawai.pendidikan=pendidikan.tingkat\r\n                and pegawai.stts_kerja =stts_kerja.stts\r\n                and pegawai.jnj_jabatan=jnj_jabatan.kode ";
    $hasil1 = bukaquery("select pegawai.id,\r\n                pegawai.nik,\r\n                pegawai.nama,\r\n                pegawai.jbtn,\r\n                pegawai.pendidikan,\r\n                pegawai.mulai_kerja,\r\n                CONCAT(FLOOR(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'),DATE_FORMAT(mulai_kerja, '%Y%m'))/12), ' Tahun ',MOD(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'), DATE_FORMAT(mulai_kerja, '%Y%m')),12), ' Bulan ') as lama,\r\n                pendidikan.indek as index_pendidikan,\r\n                (To_days('{$tahun}-{$bulan}-{$hari}')-to_days(mulai_kerja))/365 as masker,\r\n                stts_kerja.indek as index_status,\r\n                pegawai.indek as index_struktural,\r\n                pegawai.pengurang,\r\n                pegawai.mulai_kontrak,\r\n                CONCAT(FLOOR(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'),DATE_FORMAT(mulai_kontrak, '%Y%m'))/12), ' Tahun ',MOD(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'), DATE_FORMAT(mulai_kontrak, '%Y%m')),12), ' Bulan ') as lamakontrak,\r\n                (To_days('{$tahun}-{$bulan}-{$hari}')-to_days(mulai_kontrak))/365 as maskon\r\n                from pegawai inner join pendidikan\r\n                inner join stts_kerja\r\n                inner join jnj_jabatan\r\n                where " . $say . " and pegawai.nik like '%" . $keyword . "%' or\r\n                " . $say . " and pegawai.nama like '%" . $keyword . "%' or\r\n                " . $say . " and pegawai.jbtn like '%" . $keyword . "%' or\r\n                " . $say . " and pegawai.pendidikan like '%" . $keyword . "%' or\r\n                " . $say . " and pegawai.mulai_kontrak like '%" . $keyword . "%' or\r\n                " . $say . " and pegawai.mulai_kerja like '%" . $keyword . "%'\r\n                order by pegawai.id ASC");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah} <a target=_blank href=/penggajian/pages/pegawai/LaporanIndex.php?&keyword={$keyword}>| Laporan |</a> ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #14
0
    $hasilobat = bukaquery($_sqlobat);
    while ($obat = mysql_fetch_array($hasilobat)) {
        echo "{$obat['0']}, ";
    }
    echo "<br/><br/>Hasil pemeriksaan penunjang :<br/>";
    $_sqljalandr = "select hasil from rawat_jl_dr  where  rawat_jl_dr.no_rawat='{$norw}' group by hasil";
    $hasiljalandr = bukaquery($_sqljalandr);
    $no = 1;
    while ($pemeriksaan = mysql_fetch_array($hasiljalandr)) {
        if (!empty($pemeriksaan[0])) {
            echo "{$no}. {$pemeriksaan['0']}<br/> ";
            $no++;
        }
    }
    $_sqlinapdr = "select hasil from rawat_inap_dr  where  rawat_inap_dr.no_rawat='{$norw}' group by hasil ";
    $hasilinapdr = bukaquery($_sqlinapdr);
    while ($pemeriksaan = mysql_fetch_array($hasilinapdr)) {
        if (!empty($pemeriksaan[0])) {
            echo "{$no}. {$pemeriksaan['0']}<br/> ";
            $no++;
        }
    }
    echo "<br/>\n                Mohon Penatalaksanaan selanjutnya.<br/>\n                Demikian rujukan ini, mohon balasan rujukan (Dx dan Tx). Atas kerjasamanya kami ucapkan terima kasih.<br/><br/>\n                Wonogiri, " . substr($tanggal, 8, 2) . "-" . substr($tanggal, 5, 2) . "-" . substr($tanggal, 0, 4) . "<br/>\n                Salan dan Hormat Kami, <br/><br/><br/><br/>\n                <u>( {$dokter} )</u>\n                </font>\n                \n                </td>\n                  </tr>\n                </table>";
} else {
    echo "<font color='999999' size='2'  face='Tahoma'><b>Data  Billing masih kosong !</b>";
}
?>
  

    </body>
</html>
    <body>

    <?php 
reportsqlinjection();
$tanggal1 = $_GET['tanggal1'];
$tanggal2 = $_GET['tanggal2'];
$_sql = "select left(tgl_registrasi,7) from reg_periksa where tgl_registrasi between '{$tanggal1}' and '{$tanggal2}' group by left(tgl_registrasi,7)  order by tgl_registrasi";
$hasil = bukaquery($_sql);
if (mysql_num_rows($hasil) != 0) {
    echo "<table width='100%'  border='1' align='left' cellpadding='0' cellspacing='0' class='tbl_form'>\r\n                 <caption><br/><center><font color='000000' size='4' face='Arial'>Laporan Kunjuangan Bulanan<br> Periode {$tanggal1} s.d. {$tanggal2} </font></center><br/></caption>\r\n                 <tr class=isi15>\r\n                    <td width='5%' align=center>No</td>\r\n                    <td width='20%' align=center>Bulan</td>\r\n                    <td width='15%' align=center>Tahun</td>\r\n                    <td width='25%' align=center>Poli</td>\r\n                    <td width='10%' align=center>Pasien Lama</td>\r\n                    <td width='10%' align=center>Pasien Baru</td>\r\n                    <td width='15%' align=center>Jumlah Pasien</td>\r\n                 </tr>";
    $i = 1;
    $lama = 0;
    $baru = 0;
    $total = 0;
    while ($baris = mysql_fetch_array($hasil)) {
        $hasil2 = bukaquery("select kd_poli, nm_poli from poliklinik");
        while ($baris2 = mysql_fetch_array($hasil2)) {
            $lama = $lama + getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}' and stts_daftar='Lama'");
            $baru = $baru + getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}' and stts_daftar='Baru'");
            $total = $total + getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}'");
            echo "<tr class='isi15'>\r\n\t\t\t\t\t\t\t\t   <td>{$i} &nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . konversiBulan(substr($baris[0], 5, 2)) . "&nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . substr($baris[0], 0, 4) . " &nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . $baris2[1] . " &nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}' and stts_daftar='Lama'") . " &nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}' and stts_daftar='Baru'") . " &nbsp;</td>\r\n\t\t\t\t\t\t\t\t   <td>" . getOne("select count(no_rawat) from reg_periksa where tgl_registrasi like '%{$baris['0']}%' and kd_poli='{$baris2['0']}'") . " &nbsp;</td>\r\n\t\t\t\t\t\t      </tr>";
            $i++;
        }
    }
    echo "\r\n                   <tr class=isi15>\r\n                     <td>&nbsp;</td>\r\n                     <td>Total</td>\r\n                     <td>&nbsp;</td>\r\n                     <td>&nbsp;</td>\r\n                     <td>{$lama} &nbsp;</td>\r\n                     <td>{$baru} &nbsp;</td>\r\n                     <td>{$total} &nbsp;</td>\r\n                   </tr>    \r\n                 </table>";
} else {
    echo "<b>Data masih kosong !</b>";
}
?>

    </body>
예제 #16
0
     $bariscek = mysql_fetch_array($hasilcek);
     $idcek = $bariscek["id"];
     if (empty($idcek)) {
         if (empty($urlnya)) {
             echo "<font size='9'>Pilih shift dulu !!!!!!!</font>";
         } else {
             Tambah("temporary_presensi", "'{$idpeg}','{$shift}',NOW(),NULL,\n                                if(TIME_TO_SEC(now())-TIME_TO_SEC({$jam})>600,'Terlambat','Tepat Waktu'),\n                                if(TIME_TO_SEC(now())-TIME_TO_SEC({$jam})>600,SEC_TO_TIME(TIME_TO_SEC(now())-TIME_TO_SEC({$jam})),''),'','{$urlnya}'", " Presensi Masuk jam {$jam_masuk}");
             echo "<html><head><title></title><meta http-equiv='refresh' content='5;URL=?page=Input'></head><body></body></html>";
         }
     } elseif (!empty($idcek)) {
         if (empty($urlnya)) {
             echo "<font size='9'>Pilih shift dulu !!!!!!!</font>";
         } else {
             Ubah2(" temporary_presensi ", " jam_pulang=NOW(),\n                                    durasi=(SEC_TO_TIME(unix_timestamp(now()) - unix_timestamp(jam_datang))) where id='{$idpeg}'  ");
             $_sqlcek = "select id, shift, jam_datang, jam_pulang, status, keterlambatan, durasi, photo from temporary_presensi where id='{$idpeg}'";
             $hasilcek = bukaquery($_sqlcek);
             $bariscek = mysql_fetch_array($hasilcek);
             $idcek = $bariscek["id"];
             $shift = $bariscek["shift"];
             $jam_datang = $bariscek["jam_datang"];
             $jam_pulang = $bariscek["jam_pulang"];
             $status = $bariscek["status"];
             $keterlambatan = $bariscek["keterlambatan"];
             $durasi = $bariscek["durasi"];
             Tambah("rekap_presensi", "'{$idcek}','{$shift}','{$jam_datang}','{$jam_pulang}','{$status}','{$keterlambatan}','{$durasi}','','{$urlnya}'", " Presensi Pulang jam {$jam_pulang}");
             hapusinput(" delete from temporary_presensi where id ='{$idcek}' ");
             echo "<html><head><title></title><meta http-equiv='refresh' content='5;URL=?page=Input'></head><body></body></html>";
         }
     }
 } elseif (empty($idpeg) || empty($shift)) {
     echo "<b>ID Pegawai atau Jam Masuk ada yang salah, Silahkan pilih berdasarkan shift departemen anda</b>";
예제 #17
0
    }
    echo "</table>";
} else {
    echo "<b>Data Status WP masih kosong !</b>";
}
?>
    
    <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" stts_wp ", " stts ='" . $_GET['stts'] . "' ", "?act=ListSttswp");
}
?>
    </div>
    <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT stts,ktg FROM stts_wp ORDER BY stts ASC");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "<br/>Data : {$jumlah} ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['1']}</td>\n                                <td>" . formatDuit($baris[2]) . "</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data Master Tunjangan Harian !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" master_tunjangan_harian ", " id ='" . $id . "' ", "?act=DetailTunjanganHarian&action=TAMBAH&nama=" . $nama);
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT nama,tnj from master_tunjangan_harian ORDER BY nama ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo " Data : {$jumlah} ";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
예제 #19
0
        if ($angla != 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>Angsuran Lain</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($angla) . "</td>\n\t\t\t\t       </TR>";
        }
        if ($telpri != 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>Telepon Pribadi</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($telpri) . "</td>\n\t\t\t\t       </TR>";
        }
        if ($pajak != 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>Pajak</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($pajak) . "</td>\n\t\t\t\t       </TR>";
        }
        if ($pribadi != 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>Pribadi</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($pribadi) . "</td>\n\t\t\t\t       </TR>";
        }
        if ($lain - $alpha > 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>{$ktg}</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($lain - $alpha) . "</td>\n\t\t\t\t       </TR>";
        }
        if ($alpha != 0) {
            echo "\n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>Kurang Jaga</TD><td width='3px'>:</td><td width='140px'>" . formatDuit($alpha) . "</td>\n\t\t\t\t       </TR>";
        }
        echo "<TR class='isi6'>\n                                            <TD width='130px'>&nbsp;&nbsp;&nbsp;<i>Jumlah Potongan </i></TD>\n\t\t\t\t\t    <td width='3px'>:</td>\n\t\t\t\t\t    <td width='140px' align=right><i>" . formatDuit($jamsostek + $dansos + $simwajib + $angkop + $angla + $telpri + $pajak + $pribadi + $lain) . "</i></td>\n\t\t\t\t\t </TR> \n                                         \n\t\t\t\t       <TR class='isi6'>\n                                         <TD width='130px'>&nbsp;&nbsp;&nbsp;<i>TOTAL JM DITERIMA</i></TD>\n\t\t\t\t\t <td width='3px'>:</td>\n\t\t\t\t\t <td width='140px' align=right><font size='2px' face='Arial' color='777777'><i>" . formatDuit($ttlditerima) . "</i></font></td>\n\t\t\t\t      </TR>\n                                      <TR class='isi6'>\n                                         <TD width='130px' colspan='3'>&nbsp;&nbsp;&nbsp;<i>" . Terbilang($ttlditerima) . "</i></td>\n\t\t\t\t      </TR>\n\t\t\t\t      <TR class='isi6'>\n                                         <TD width='130px'></TD><td></td><td><center>Yogyakarta, " . date('d-m-Y') . "</center> </td>\n\t\t\t\t      </TR>\n\t\t\t\t      <TR class='isi6'>\n                                         <TD width='130px'><center>Penerima</center></TD>\n\t\t\t\t\t <td width='3px'>&nbsp;</td>\n\t\t\t\t\t <td width='140px'><center>Pengelola</center></td>\n\t\t\t\t      </TR>\n\t\t\t\t      <TR class='isi6'>\n                                         <TD width='130px'>&nbsp;</TD>\n\t\t\t\t\t <td width='3px'>&nbsp;</td>\n\t\t\t\t\t <td width='140px'>&nbsp;</td>\n\t\t\t\t      </TR>\n\t\t\t\t      <TR class='isi6'>\n                                         <TD width='130px'>&nbsp;</TD>\n\t\t\t\t\t <td width='3px'>&nbsp;</td>\n\t\t\t\t\t <td width='140px'>&nbsp;</td>\n\t\t\t\t      </TR>\n\t\t\t\t      <TR class='isi6'>\n                                         <TD width='130px'><center>( {$baris['2']} )</center></TD>\n\t\t\t\t\t <td width='3px'>&nbsp;</td>\n\t\t\t\t\t <td width='140px'><center>( dr Lily T S Siagian )</center></td>\n\t\t\t\t      </TR>\n\t\t\t\t      </table>\n\t\t\t\t      <center><font size='1px' face='Arial' color='777777'><i><b>..Terima kasih atas kerjasamanya <br>dalam memberikan pelayanan yang berkualitas..</b></i></font></center>\n\n                                        <center><font face='Arial' size='3' color='777777'>Rincian Tindakan</font></center>";
        $_sql30 = "select tindakan.tgl,tindakan.nm_pasien,tindakan.kamar,master_tindakan.nama\n                                              from master_tindakan,tindakan\n                                              where tindakan.tnd=master_tindakan.id and\n                                              tindakan.id='{$baris['0']}'\n                                              and tgl like '%" . $tahun . "-" . $bulan . "%' ";
        echo "<table width='270px' border='0' align='center' cellpadding='0' cellspacing='0' class='tbl_form'>\n                                               <tr class='isi6'>\n                                                   <td width='50px'><div align='center'><font size='1' face='Arial'>Tgl</font></div></td>\n                                                   <td width='50px'><div align='center'><font size='1' face='Arial'>Nm.Pasien</font></div></td>\n                                                   <td width='50px'><div align='center'><font size='1' face='Arial'>Kamar</font></div></td>\n                                                   <td width='50px'><div align='center'><font size='1' face='Arial'>Tindakan</font></div></td>\n                                                 </tr>";
        $hasil30 = bukaquery($_sql30);
        while ($baris30 = mysql_fetch_array($hasil30)) {
            echo "<TR class='isi6'>\n                                                   <td>" . date("Y-m-d", $baris30[0]) . "</td>\n                                                    <td>{$baris30['1']}</td>\n                                                    <td>{$baris30['2']}</td>\n                                                    <td>{$baris30['3']}</td>\n                                                 </tr>";
        }
        echo " \n                                      </table>\n                                      \n                                     </td>\n                                     </tr>\n                                     </table>";
    }
}
?>
    </body>
</html>
예제 #20
0
                            <?php 
        echo "</center>\n                                </td>\n                                <td>" . formatDuit($baris[3]) . "</td>\n                                <td>{$baris['4']}</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data jasa lain masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" jasa_lain ", " id ='" . $_GET['id'] . "' and thn ='" . $_GET['thn'] . "'\n                       and bln ='" . $_GET['bln'] . "' and bsr_jasa ='" . $_GET['bsr_jasa'] . "'", "?act=InputJasaLain&action=TAMBAH&id={$id}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT thn, bln, id, bsr_jasa, ktg\n                        from jasa_lain  where id='{$id}'\n\t\t\tand thn='" . $tahun . "' and bln='" . $bulan . "' ORDER BY bsr_jasa ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah} ";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
예제 #21
0
        $hasil = bukaquery($_sql);
        $baris = mysql_fetch_row($hasil);
        $id = $baris[0];
        $nik = $baris[1];
        $nama = $baris[2];
        $indek = $baris[3];
        $pengurang = $baris[4];
    }
}
echo "<input type=hidden name=id value={$id}><input type=hidden name=action value={$action}>";
$_sqlnext = "SELECT id FROM pegawai WHERE id>'{$id}' order by id asc limit 1";
$hasilnext = bukaquery($_sqlnext);
$barisnext = mysql_fetch_row($hasilnext);
$next = $barisnext[0];
$_sqlprev = "SELECT id FROM pegawai WHERE id<'{$id}' order by id desc limit 1";
$hasilprev = bukaquery($_sqlprev);
$barisprev = mysql_fetch_row($hasilprev);
$prev = $barisprev[0];
echo "<div align='center' class='link'>\r\n                          <a href=?act=EditIndexPegawai&action=UBAH&id={$prev}><<--</a>\r\n                          <a href=?act=ListIndexPegawai>| Index Pegawai |</a>\r\n                          <a href=?act=EditIndexPegawai&action=UBAH&id={$next}>-->></a>\r\n                          </div>";
?>
            <table width="100%" align="center">
                <tr class="head">
                    <td width="45%" >NIK</td><td width="">:</td>
                    <td width="55%"><?php 
echo $nik;
?>
</td>
                </tr>
                <tr class="head">
                    <td width="45%" >Nama</td><td width="">:</td>
                    <td width="55%"><?php 
예제 #22
0
         if ($masker >= 1 && $masker < 3) {
             $gapokgp = $barisgp[1];
         } else {
             if ($masker >= 3) {
                 $gapokgp = $barisgp[2];
             }
         }
     }
     $gapok = $gapokgp;
     if ($masker < 1) {
         $gapok = $masker * $gapokgp;
     }
 } else {
     if ($status == "PT") {
         $_sqlgp = "SELECT `gapok1`, `gapok2`, `gapok3`\n                                from pendidikan  where tingkat like '%" . substr($pendidikan, 0, 7) . "%' order by gapok1 desc limit 1 ";
         $hasilgp = bukaquery($_sqlgp);
         $barisgp = mysql_fetch_row($hasilgp);
         $gapokgp = 0;
         if ($masker < 1) {
             $gapokgp = $barisgp[0];
         } else {
             if ($masker >= 1 && $masker < 3) {
                 $gapokgp = $barisgp[1];
             } else {
                 if ($masker >= 3) {
                     $gapokgp = $barisgp[2];
                 }
             }
         }
         $gapok = $nmasuk / $wajibmasuk * $gapokgp;
         if ($masker < 1) {
예제 #23
0
    <body>

    <?php 
reportsqlinjection();
$noretur = str_replace("_", " ", $_GET['noretur']);
$petugas = str_replace("_", " ", $_GET['petugas']);
$tanggal = $_GET['tanggal'];
$nm_member = str_replace("_", " ", $_GET['nm_member']);
$catatan = str_replace("_", " ", $_GET['catatan']);
$_sql = "select  nama_brng,h_retur, jml_retur, subtotal from  tampreturjual ";
$hasil = bukaquery($_sql);
$_sqlins = "SELECT nama_instansi, alamat_instansi, kabupaten, propinsi from setting";
$hasilins = bukaquery($_sqlins);
$barisins = mysql_fetch_array($hasilins);
$_sqlset = "SELECT * from setnota";
$hasilset = bukaquery($_sqlset);
$barisset = mysql_fetch_array($hasilset);
if (mysql_num_rows($hasil) != 0) {
    echo "<table width='{$barisset['0']}'  border='0' align='left' cellpadding='0' cellspacing='0' class='tbl_form'>\r\n                 <tr class='isi14'>\r\n                       <td width=50% colspan=4 align=left>\r\n                           <font color='000000' size='4' face='Tahoma'>&nbsp;</font><br/>\r\n                           <font color='000000' size='2' face='Tahoma'>\r\n                               &nbsp;<br/>\r\n                           </font>\r\n                       </td>\r\n                 </tr>\r\n                 <tr class='isi14'>\r\n                    <td colspan='5' align='center'>\r\n                       <font color='000000' size='3' face='Tahoma'>TANDA TERIMA RETUR</font>\r\n                    </td>\r\n                 </tr> \r\n                 <tr class='isi14'>\r\n                    <td colspan='3' align='center'>\r\n                       <font color='000000' size='2' face='Tahoma'>&nbsp;</font>\r\n                    </td>\r\n                 </tr> \r\n                 <tr>\r\n                 <td colspan='6'>\r\n                 <table width=100%>\r\n                 <tr class='isi14'>\r\n                    <td width='20%'>\r\n                       <font color='000000' size='2' face='Tahoma'>No.Retur</font>\r\n                    </td>\r\n                    <td width='40%'>: {$noretur}</td>\r\n                    <td width='40%' colspan=2>{$barisins['2']}, " . substr($tanggal, 8, 2) . "-" . substr($tanggal, 5, 2) . "-" . substr($tanggal, 0, 4) . "</td>\r\n                 </tr> \r\n                 <tr class='isi14'>\r\n                    <td width='20%'>\r\n                       <font color='000000' size='2' face='Tahoma'>Sales</font>\r\n                    </td>\r\n                    <td width='40%'>: {$petugas}</td>\r\n                    <td width='40%' colspan=2>{$nm_member}</td>\r\n                 </tr> \r\n                 </table>\r\n                 </td>\r\n                 </tr>\r\n                 <tr class='isi13'>\r\n                     <td colspan=4>&nbsp;</td>\r\n                 </tr>\r\n                 <tr class='isi14'>\r\n                      <td colspan=4 height='310px' valign=top>\r\n                            <table width=100% cellpadding='0' cellspacing='0'>\r\n                               <tr class=isi15>\r\n                                   <td width='5%' align=center>No</td>\r\n                                   <td width='60%' align=center>Barang</td>\r\n                                   <td width='10%' align=center>Harga</td>\r\n                                   <td width='5%' align=center>Jml</td>\r\n                                   <td width='10%' align=center>Total</td>\r\n                               </tr>";
    $ttlpesan = 0;
    $i = 1;
    while ($barispesan = mysql_fetch_array($hasil)) {
        $ttlpesan = $ttlpesan + $barispesan[3];
        echo "\r\n                                            <tr class='isi15'>\r\n                                                <td>{$i}</td>\r\n                                                <td>{$barispesan['0']}</td>\r\n                                                <td align=right>" . formatDuit2($barispesan[1]) . "</td>\r\n                                                <td align=right>" . formatDuit2($barispesan[2]) . "</td>\r\n                                                <td align=right>" . formatDuit2($barispesan[3]) . "</td>\r\n                                           </tr>";
        $i++;
    }
    echo " <tr class='isi14'>\r\n                                      <td colspan=4 align=right><b>Total Retur</b></td>\r\n                                      <td align='right'><b>" . formatDuit2($ttlpesan) . "</b></td>\r\n                                    </tr> \r\n                          </table>\r\n                          <br/>\r\n                      </td>\r\n                    </tr>\r\n                    <tr class='isi14'>\r\n                      <td colspan=1 width='30%'>\r\n                        <table width='100%' cellpadding='0' cellspacing='0'>\r\n                           <tr class='isi15'>\r\n                              <td width='33%'>Sales&nbsp;&nbsp;&nbsp;</td><td width='33%'>Checking</td><td width='33%'>Gudang</td>\r\n                           </tr>\r\n                           <tr class='isi15'>\r\n                              <td height='40px'>&nbsp;</td><td>&nbsp;</td><td>&nbsp;</td>\r\n                           </tr>\r\n                        </table>\r\n                      </td>\r\n                      <td colspan=3 width='70%'>\r\n                        <table width=100% cellpadding='0' cellspacing='0'>\r\n                           <tr class='isi14'>\r\n                              <td width='80%'>Catatan</td><td align=center>Penerima</td>\r\n                           </tr>\r\n                           <tr class='isi14' valign=bottom>\r\n                              <td height='40px'>{$catatan}</td><td align=center>( {$petugas} )</td>\r\n                           </tr>\r\n                        </table>\r\n                      </td>\r\n                    </tr>\r\n                 </table>";
} else {
    echo "<b>Data pesan masih kosong !</b>";
}
?>
예제 #24
0
}
$keyword = $_GET['keyword'];
$say = " pegawai.pendidikan=pendidikan.tingkat\n                and pegawai.stts_kerja =stts_kerja.stts\n                and pegawai.jnj_jabatan=jnj_jabatan.kode ";
$_sql = "select pegawai.id,\n                pegawai.nik,\n                pegawai.nama,\n                pegawai.jbtn,\n                pegawai.pendidikan,\n                pegawai.mulai_kerja,\n                CONCAT(FLOOR(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'),DATE_FORMAT(mulai_kerja, '%Y%m'))/12), ' Tahun ',MOD(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'), DATE_FORMAT(mulai_kerja, '%Y%m')),12), ' Bulan ') as lama,\n                pendidikan.indek as index_pendidikan,\n                (To_days('{$tahun}-{$bulan}-{$hari}')-to_days(mulai_kerja))/365 as masker,\n                stts_kerja.indek as index_status,\n                pegawai.indek as index_struktural,\n                pegawai.pengurang,\n                pegawai.mulai_kontrak,\n                CONCAT(FLOOR(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'),DATE_FORMAT(mulai_kontrak, '%Y%m'))/12), ' Tahun ',MOD(PERIOD_DIFF(DATE_FORMAT('{$tahun}-{$bulan}-{$hari}', '%Y%m'), DATE_FORMAT(mulai_kontrak, '%Y%m')),12), ' Bulan ') as lamakontrak,\n                (To_days('{$tahun}-{$bulan}-{$hari}')-to_days(mulai_kontrak))/365 as maskon,\n                cuti_diambil\n                from pegawai inner join pendidikan\n                inner join stts_kerja\n                inner join jnj_jabatan\n                where " . $say . " and pegawai.nik like '%" . $keyword . "%' or\n                " . $say . " and pegawai.nama like '%" . $keyword . "%' or\n                " . $say . " and pegawai.jbtn like '%" . $keyword . "%' or\n                " . $say . " and pegawai.pendidikan like '%" . $keyword . "%' or\n                " . $say . " and pegawai.mulai_kerja like '%" . $keyword . "%'\n                order by pegawai.id ASC ";
$hasil = bukaquery($_sql);
$jumlah = mysql_num_rows($hasil);
if (mysql_num_rows($hasil) != 0) {
    echo "<table width='100%' border='0' align='center' cellpadding='0' cellspacing='0' class='tbl_form'>\n                    <caption><h1 class=title>DAFTAR INDEX PEGAWAI/KARYAWAN RSKIA SADEWA YOGYAKARTA</h1><br></caption>\n                    <tr class='head'>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>NIK</strong></font></div></td>\n                                 <td width='180px'><div align='center'><font size='2' face='Verdana'><strong>Nama</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Jabatan</strong></font></div></td>\n                                 <td width='150px'><div align='center'><font size='2' face='Verdana'><strong>Pendidikan</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Mulai Kerja</strong></font></div></td>\n                                 <td width='150px'><div align='center'><font size='2' face='Verdana'><strong>Lama Kerja</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Index Pendidikan</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Index Masa Kerja</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Index Status</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Index Struktural</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Pengurang</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Total Index</strong></font></div></td>\n                                 <td width='80px'><div align='center'><font size='2' face='Verdana'><strong>Mulai Kontrak</strong></font></div></td>\n                                 <td width='150px'><div align='center'><font size='2' face='Verdana'><strong>Lama Kontrak</strong></font></div></td>\n                                 <td width='150px'><div align='center'><font size='2' face='Verdana'><strong>Gaji Pokok</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Hak Cuti</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Cuti Diambil</strong></font></div></td>\n                                 <td width='100px'><div align='center'><font size='2' face='Verdana'><strong>Sisa Cuti</strong></font></div></td>\n                   </tr>";
    while ($baris = mysql_fetch_array($hasil)) {
        $_sql4 = "SELECT `gapok1`, `gapok2`, `gapok3`\n                            from pendidikan  where tingkat='{$baris['4']}' ";
        $hasil4 = bukaquery($_sql4);
        $baris4 = mysql_fetch_row($hasil4);
        $gapok = 0;
        $hakcuti = 0;
        $_sql6 = "SELECT count(id)\n                            from ketidakhadiran  where id='{$baris['0']}'\n                            and tgl like '%" . $tahun . "%' and jns='C' group by id";
        $hasil6 = bukaquery($_sql6);
        $baris6 = mysql_fetch_row($hasil6);
        $ttlc = $baris6[0] + $baris[15];
        if (empty($baris6[0])) {
            $ttlc = 0;
        }
        $masa_kerja = 0;
        if ($baris[8] < 1) {
            $masa_kerja = 0;
        } else {
            if ($baris[8] >= 1 && $baris[8] < 2) {
                $masa_kerja = 2;
            } else {
                if ($baris[8] >= 2 && $baris[8] < 3) {
                    $masa_kerja = 4;
                } else {
예제 #25
0
if ($_GET['action'] == "HAPUS") {
    Hapus(" pegawai ", " id ='" . $_GET['id'] . "' ", "?act=ListCariPegawai");
}
$BtnPrint = $_POST['BtnPrint'];
if (isset($BtnPrint)) {
    echo "<html><head><title></title><meta http-equiv='refresh' content='2;pages/pegawai/LaporanPegawai.php?&keyword={$keyword}'></head><body></body></html>";
}
?>
    </div>

    </form>

     
       <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("select id,nik,nama,jk,jbtn,jnj_jabatan,departemen,bidang,stts_wp,stts_kerja,\r\n                 npwp, pendidikan, gapok,tmp_lahir,tgl_lahir,alamat,kota,mulai_kerja,ms_kerja,\r\n                 indexins,bpd,rekening,stts_aktif,wajibmasuk,mulai_kontrak from pegawai\r\n                 where\r\n                 nik like '%" . $keyword . "%' or\r\n                 nama like '%" . $keyword . "%' or\r\n                 jk like '%" . $keyword . "%' or\r\n                 jbtn like '%" . $keyword . "%' or\r\n                 jnj_jabatan like '%" . $keyword . "%' or\r\n                 departemen like '%" . $keyword . "%' or\r\n                 bidang like '%" . $keyword . "%' or\r\n                 stts_wp like '%" . $keyword . "%' or\r\n                 stts_kerja like '%" . $keyword . "%' or\r\n                 npwp like '%" . $keyword . "%' or\r\n                 pendidikan like '%" . $keyword . "%' or\r\n                 gapok like '%" . $keyword . "%' or\r\n                 tmp_lahir like '%" . $keyword . "%' or\r\n                 tgl_lahir like '%" . $keyword . "%' or\r\n                 alamat like '%" . $keyword . "%' or\r\n                 kota like '%" . $keyword . "%' or\r\n                 mulai_kerja like '%" . $keyword . "%' or\r\n                 ms_kerja like '%" . $keyword . "%' or\r\n                 indexins like '%" . $keyword . "%' or\r\n                 bpd like '%" . $keyword . "%' or\r\n                 rekening like '%" . $keyword . "%' or\r\n                 stts_aktif like '%" . $keyword . "%'\r\n                 order by id ASC");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo " Data : {$jumlah}<a target=_blank href=/penggajian/pages/pegawai/LaporanPegawai.php?&keyword={$keyword}>| Laporan |</a> ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #26
0
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['2']}</td>\n                                <td>{$baris['3']}</td>\n                                <td>{$baris['4']}</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data ketidakhadiran masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" ketidakhadiran", " id ='" . $_GET['id'] . "' and tgl ='" . $_GET['tgl'] . "' and jns ='" . $_GET['jns'] . "'", "?act=InputTidakHadir&action=TAMBAH&id={$id}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT tgl,id,jns,ktg,jml\n                        from ketidakhadiran where id='{$id}'\n\t\t\t     and tgl like '%" . $tahun . "-" . $bulan . "%' ORDER BY tgl ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah}, A : " . $ttla . " , S : " . $ttls . ", C : " . $ttlc . ", I : " . $ttli . " ";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>
예제 #27
0
function autonomer($table, $strawal, $pnj)
{
    $hasil = bukaquery($table);
    $s = mysql_num_rows($hasil) + 1;
    $j = strlen($s);
    $s1 = "";
    for ($i = 1; $i <= $pnj - $j; $i++) {
        $s1 = $s1 + "0";
    }
    return $strawal . "" . $s1 . "" . $s;
}
예제 #28
0
function getOne($sql)
{
    $hasil = bukaquery($sql);
    list($result) = mysql_fetch_array($hasil);
    return $result;
}
        $hasil2 = bukaquery($_sql2);
        while ($baris2 = mysql_fetch_array($hasil2)) {
            echo "<table width='300px'><tr class='isi3'><td width='200px'>{$baris2['0']}</td><td>: {$baris2['1']}</td></tr></table>";
        }
        echo "&nbsp;</a>\r\n\t\t\t\t</td>\r\n                                <td><a href=?act=InputTindakanDokter&action=TAMBAH&id={$baris['0']}>" . formatDuit($baris[5]) . "</a></td>\r\n                             </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data keanggotaan masih kosong !</b>";
}
?>
    </div>
	</form>
    <?php 
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT pegawai.id,pegawai.nik,pegawai.nama,\r\n\t\t        pegawai.departemen,sum(tindakan.jmlh),sum(tindakan.jm)\r\n                FROM tindakan right OUTER JOIN pegawai\r\n\t\t\t\tON tindakan.id=pegawai.id and tgl like '%" . $tahun . "-" . $bulan . "%'\r\n\t\t\t\twhere pegawai.nik like '%" . $keyword . "%' or \r\n\t\t\t\tpegawai.nama like '%" . $keyword . "%' or\r\n\t\t\t\tpegawai.departemen like '%" . $keyword . "%' \r\n\t\t\t\tgroup by pegawai.id order by pegawai.id ASC");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah}, Ttl.JM : " . formatDuit($ttljm) . "  <a target=_blank href=/penggajian/pages/tindakan/laporantindakandokter.php?&keyword={$keyword}>| Laporan |</a> ";
}
?>
    </div>
</div>

</div>
</div>
</div>
</div>
</div>
</div>
예제 #30
0
                            <?php 
        echo "</center>\n                                </td>\n                                <td>{$baris['0']}</td>\n                                <td>{$baris['2']}</td>\n                                <td>{$baris['3']} Jam</td>\n                           </tr>";
    }
    echo "</table>";
} else {
    echo "<b>Data lembur masih kosong !</b>";
}
?>
        </div>
        </form>
        <?php 
if ($_GET['action'] == "HAPUS") {
    Hapus(" presensi", " id ='" . $_GET['id'] . "' and tgl ='" . $_GET['tgl'] . "'", "?act=DetailPresensi&action=TAMBAH&id={$id}");
}
if (mysql_num_rows($hasil) != 0) {
    $hasil1 = bukaquery("SELECT tgl,id,jns,lembur\n                        from presensi where id='{$id}'\n\t\t\t     and tgl like '%" . $tahun . "-" . $bulan . "%' ORDER BY tgl ASC ");
    $jumlah1 = mysql_num_rows($hasil1);
    $i = $jumlah1 / 19;
    $i = ceil($i);
    echo "Data : {$jumlah}, Ttl.Lembur HB : " . $ttllembur . " , Ttl.Lembur HR : " . $ttlhr . " <a target=_blank href=/penggajian/pages/presensi/LaporanPresensiDetail.php?&id={$id}>| Laporan |</a> ";
}
?>
    </div>

</div>

</div>
</div>
</div>
</div>
</div>