/
cetak_semua_karyawan_bln.php
117 lines (110 loc) · 3.7 KB
/
cetak_semua_karyawan_bln.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
<?php
// config
include './config/config.php';
if ($ses_login === TRUE) {
$id = $_POST['pemegang_id'];
$bulan = $_POST['bulan'];
$tahun = $_POST['tahun'];
$data_cetak = db_cetak_self($id, $bulan, $tahun);
$site_title = "Laporan Perorangan";
include './view/header_cetak.php';
?>
<div class="row">
<br/>
<div class="col-lg-3"></div>
<div class="col-lg-6" style="text-align: center">
<b>
Rekapitulasi Pemeliharan Kendaraan Dinas Bermotor Roda Dua<br/>
BPS Kota Tasikmalaya Tahun Anggaran <?php echo date("Y"); ?>
</b>
</div>
<div class="col-lg-3"></div>
</div>
<div class="row">
<br/>
<div class="col-lg-2"></div>
<div class="col-lg-8">
<table class="identitas">
<tr>
<td>Bulan </td>
<td> : </td>
<td><?php echo $bulan . " / " . $tahun; ?></td>
</tr>
<tr>
<td>Nama Pemegang </td>
<td> : </td>
<td><?php
$identitas = db_pemegang_get_row_by_id($id);
echo $identitas['nama'];
?></td>
</tr>
<tr>
<td>No. Polisi </td>
<td> : </td>
<td><?php echo db_kendaraan_get_nopol_by_pemegang_id($id); ?></td>
</tr>
</table>
<br/>
<table class="table table-bordered">
<thead>
<tr>
<th>No</th>
<th>Tanggal</th>
<th>Jenis Pembelian</th>
<th>Banyaknya (Liter)</th>
<th>Total Harga</th>
<th>Keterangan</th>
</tr>
</thead>
<tbody>
<?php
$no = 0;
$liter = 0;
$total = 0;
while ($data = mysql_fetch_array($data_cetak)) {
++$no;
?>
<tr>
<td><?php
$liter += $data['jumlah'];
$total += $data['biaya'];
echo $no;
?></td>
<td><?php echo $data['tanggal']; ?></td>
<td><?php echo $data['jenis']; ?></td>
<td><?php echo $data['jumlah']; ?></td>
<td><?php echo $data['biaya']; ?></td>
<td><?php echo $data['keterangan']; ?></td>
</tr>
<?php } ?>
</tbody>
<tfoot>
<td>
<th>Jumlah</th>
<th></th>
<th><?php echo $liter; ?></th>
<th>Rp. <?php echo number_format($total); ?></th>
<th></th>
</td>
</tfoot>
</table>
<br>
<div class="pull-right" style="text-align: right">
<p>Tasikmalaya, <span id="footer-date"></span></p>
<p>Kasubbag Tata Usaha</p>
<br/>
<br/>
<br/>
<br/>
<p>Dede Iskandar Nuroni, SE</p>
<p>NIP. 19650211 198503 1001</p>
</div>
</div>
<div class="col-lg-2"></div>
</div>
<?php
include './view/footer.php';
} else {
redirect($site_url, 'login.php');
}
?>