@@ -17,7 +17,7 @@ discard block |
||
17 | 17 | </style> |
18 | 18 | |
19 | 19 | <?php |
20 | -global $char128asc,$char128charWidth; |
|
20 | +global $char128asc, $char128charWidth; |
|
21 | 21 | $char128asc = ' !"#$%&\'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~'; |
22 | 22 | $char128wid = [ |
23 | 23 | '212222', '222122', '222221', '121223', '121322', '131222', '122213', '122312', '132212', '221213', // 0-9 |
@@ -30,24 +30,24 @@ discard block |
||
30 | 30 | '112412', '122114', '122411', '142112', '142211', '241211', '221114', '413111', '241112', '134111', // 70-79 |
31 | 31 | '111242', '121142', '121241', '114212', '124112', '124211', '411212', '421112', '421211', '212141', // 80-89 |
32 | 32 | '214121', '412121', '111143', '111341', '131141', '114113', '114311', '411113', '411311', '113141', // 90-99 |
33 | - '114131', '311141', '411131', '211412', '211214', '211232', '23311120', ]; // 100-106 |
|
33 | + '114131', '311141', '411131', '211412', '211214', '211232', '23311120', ]; // 100-106 |
|
34 | 34 | |
35 | 35 | ////Define Function |
36 | 36 | function bar128($text) |
37 | 37 | { // Part 1, make list of widths |
38 | - global $char128asc,$char128wid; |
|
39 | - $w = $char128wid[$sum = 104]; // START symbol |
|
38 | + global $char128asc, $char128wid; |
|
39 | + $w = $char128wid[$sum = 104]; // START symbol |
|
40 | 40 | $onChar = 1; |
41 | - for ($x = 0; $x < strlen($text); $x++) { // GO THRU TEXT GET LETTERS |
|
42 | - if (!(($pos = strpos($char128asc, $text[$x])) === false)) { // SKIP NOT FOUND CHARS |
|
41 | + for ($x = 0; $x<strlen($text); $x++) { // GO THRU TEXT GET LETTERS |
|
42 | + if (!(($pos = strpos($char128asc, $text[$x]))===false)) { // SKIP NOT FOUND CHARS |
|
43 | 43 | $w .= $char128wid[$pos]; |
44 | 44 | $sum += $onChar++ * $pos; |
45 | 45 | } |
46 | 46 | } |
47 | - $w .= $char128wid[$sum % 103].$char128wid[106]; //Check Code, then END |
|
47 | + $w .= $char128wid[$sum % 103].$char128wid[106]; //Check Code, then END |
|
48 | 48 | //Part 2, Write rows |
49 | 49 | $html = '<table cellpadding=0 cellspacing=0><tr>'; |
50 | - for ($x = 0; $x < strlen($w); $x += 2) { // code 128 widths: black border, then white space |
|
50 | + for ($x = 0; $x<strlen($w); $x += 2) { // code 128 widths: black border, then white space |
|
51 | 51 | $html .= "<td><div class=\"b128\" style=\"border-left-width:{$w[$x]};width:{$w[$x + 1]}\"></div>"; |
52 | 52 | } |
53 | 53 |
@@ -110,10 +110,10 @@ discard block |
||
110 | 110 | <select name="itipe_barang" class="form-control" onChange="document.myform.submit();"> |
111 | 111 | <?php |
112 | 112 | $query = mysql_query('SELECT * FROM tipe_barang ORDER BY id_tipe_barang'); |
113 | - if ($query && mysql_num_rows($query) > 0) { |
|
113 | + if ($query && mysql_num_rows($query)>0) { |
|
114 | 114 | while ($row = mysql_fetch_object($query)) { |
115 | 115 | echo '<option value="'.$row->id_tipe_barang.'"'; |
116 | - if ($row->id_tipe_barang == $tipe_barang) { |
|
116 | + if ($row->id_tipe_barang==$tipe_barang) { |
|
117 | 117 | echo ' selected'; |
118 | 118 | } |
119 | 119 | echo '>'.$row->tipe_barang.'</option>'; |
@@ -127,10 +127,10 @@ discard block |
||
127 | 127 | <select name="ioutlet" class="form-control" onChange="document.myform.submit();"> |
128 | 128 | <?php |
129 | 129 | $query = mysql_query('SELECT * FROM outlet ORDER BY id_outlet'); |
130 | - if ($query && mysql_num_rows($query) > 0) { |
|
130 | + if ($query && mysql_num_rows($query)>0) { |
|
131 | 131 | while ($row = mysql_fetch_object($query)) { |
132 | 132 | echo '<option value="'.$row->id_outlet.'"'; |
133 | - if ($row->id_outlet == $outlet) { |
|
133 | + if ($row->id_outlet==$outlet) { |
|
134 | 134 | echo ' selected'; |
135 | 135 | } |
136 | 136 | echo '>'.$row->outlet.'</option>'; |
@@ -234,7 +234,7 @@ discard block |
||
234 | 234 | |
235 | 235 | $sisa_stok = $r['stok'] - $reserve; |
236 | 236 | |
237 | - if ($sisa_stok == '0') { |
|
237 | + if ($sisa_stok=='0') { |
|
238 | 238 | echo ''; |
239 | 239 | } else { |
240 | 240 | echo'<tr>'; |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | header('Content-Type: application/download'); |
119 | 119 | header('Content-Type: application/vnd.ms-excel'); |
120 | 120 | |
121 | -if ($tipe == 'R') { |
|
121 | +if ($tipe=='R') { |
|
122 | 122 | header("Content-Disposition: attachment;filename=rekap_revenue_$nprd.xls "); |
123 | 123 | } else { |
124 | 124 | header("Content-Disposition: attachment;filename=detail_rekap_$nprd.xls "); |
@@ -187,7 +187,7 @@ discard block |
||
187 | 187 | |
188 | 188 | ?> |
189 | 189 | |
190 | - <?php if ($tipe == 'R') { |
|
190 | + <?php if ($tipe=='R') { |
|
191 | 191 | ?> |
192 | 192 | |
193 | 193 | |
@@ -344,7 +344,7 @@ discard block |
||
344 | 344 | |
345 | 345 | |
346 | 346 | <?php |
347 | - for ($j = 1; $j <= $hjml; $j++) { |
|
347 | + for ($j = 1; $j<=$hjml; $j++) { |
|
348 | 348 | echo '<th>KUNJ</th>'; |
349 | 349 | echo '<th>REV</th>'; |
350 | 350 | } ?> |
@@ -533,7 +533,7 @@ discard block |
||
533 | 533 | |
534 | 534 | $month = date('m', strtotime($iprd)) * 1; |
535 | 535 | |
536 | - if ($month == '1') { |
|
536 | + if ($month=='1') { |
|
537 | 537 | $imonth = 12; |
538 | 538 | } else { |
539 | 539 | $imonth = $month - 1; |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | |
121 | 121 | $jenis_transaksi = $_GET['jenis_transaksi']; |
122 | 122 | |
123 | -if ($tipe == 'R') { |
|
123 | +if ($tipe=='R') { |
|
124 | 124 | $kertas = 'portrait'; |
125 | 125 | } else { |
126 | 126 | $kertas = 'landscape'; |
@@ -286,7 +286,7 @@ discard block |
||
286 | 286 | |
287 | 287 | ?> |
288 | 288 | |
289 | - <?php if ($tipe == 'R') { |
|
289 | + <?php if ($tipe=='R') { |
|
290 | 290 | ?> |
291 | 291 | |
292 | 292 | |
@@ -425,7 +425,7 @@ discard block |
||
425 | 425 | |
426 | 426 | |
427 | 427 | <?php |
428 | - for ($j = 1; $j <= $hjml; $j++) { |
|
428 | + for ($j = 1; $j<=$hjml; $j++) { |
|
429 | 429 | echo '<th>KUNJ</th>'; |
430 | 430 | echo '<th>REV</th>'; |
431 | 431 | } ?> |
@@ -614,7 +614,7 @@ discard block |
||
614 | 614 | |
615 | 615 | $month = date('m', strtotime($iprd)) * 1; |
616 | 616 | |
617 | - if ($month == '1') { |
|
617 | + if ($month=='1') { |
|
618 | 618 | $imonth = 12; |
619 | 619 | } else { |
620 | 620 | $imonth = $month - 1; |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | $id = $r['id_modul']; |
13 | 13 | $fa_icon = $r['fa_icon']; |
14 | 14 | |
15 | -if ($r[orientation] == 'P') { |
|
15 | +if ($r[orientation]=='P') { |
|
16 | 16 | $orientation = 'portrait'; |
17 | 17 | } else { |
18 | 18 | $orientation = 'landscape'; |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | |
140 | 140 | <!--<body onload="cetakspk()">--> |
141 | 141 | |
142 | -<?php if ($_GET['printto'] == '2') { |
|
142 | +<?php if ($_GET['printto']=='2') { |
|
143 | 143 | ?> |
144 | 144 | <body onload="icetak()"> |
145 | 145 | <?php |
@@ -79,7 +79,7 @@ |
||
79 | 79 | |
80 | 80 | if ($id) { |
81 | 81 | $query = mysql_query('SELECT * FROM general_setting WHERE id_general_setting = "'.$id.'"'); |
82 | - if ($query && mysql_num_rows($query) == 1) { |
|
82 | + if ($query && mysql_num_rows($query)==1) { |
|
83 | 83 | $data = mysql_fetch_object($query); |
84 | 84 | } else { |
85 | 85 | die('Data general_setting tidak ditemukan'); |
@@ -17,7 +17,7 @@ |
||
17 | 17 | $datetime = date('Y-m-d G:i:s', $hour); |
18 | 18 | $userid = $_SESSION['userid']; |
19 | 19 | |
20 | - if ($module == 'general_setting' and $act == 'input') { |
|
20 | + if ($module=='general_setting' and $act=='input') { |
|
21 | 21 | $id_module = $_POST['id_module']; |
22 | 22 | |
23 | 23 | $lokasi_file = $_FILES['fupload']['tmp_name']; |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | |
45 | 45 | if ($id) { |
46 | 46 | $query = mysql_query('SELECT * FROM poli WHERE id_poli = "'.$id.'"'); |
47 | - if ($query && mysql_num_rows($query) == 1) { |
|
47 | + if ($query && mysql_num_rows($query)==1) { |
|
48 | 48 | $data = mysql_fetch_object($query); |
49 | 49 | } else { |
50 | 50 | die('Data modul tidak ditemukan'); |
@@ -81,7 +81,7 @@ discard block |
||
81 | 81 | <?php if ($id) { |
82 | 82 | ?> |
83 | 83 | |
84 | - <?php if (@$data->aktif == 'Y') { |
|
84 | + <?php if (@$data->aktif=='Y') { |
|
85 | 85 | ?> |
86 | 86 | |
87 | 87 | <div class="form-group"> |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | $userid = $_SESSION['userid']; |
17 | 17 | |
18 | 18 | // Hapus modul |
19 | - if ($module == 'poli' and $act == 'hapus') { |
|
19 | + if ($module=='poli' and $act=='hapus') { |
|
20 | 20 | $id = $_GET['id']; |
21 | 21 | $id_module = $_GET['id_module']; |
22 | 22 | |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | } |
34 | 34 | |
35 | 35 | // Input group |
36 | - elseif ($module == 'poli' and $act == 'input') { |
|
36 | + elseif ($module=='poli' and $act=='input') { |
|
37 | 37 | $id_module = $_POST['id_module']; |
38 | 38 | |
39 | 39 | if ($_POST['ID']) { |