@@ -47,27 +47,27 @@ discard block |
||
47 | 47 | //---------------------------------------------------------------------- |
48 | 48 | public static function isdigitat($str, $pos) |
49 | 49 | { |
50 | - if ($pos >= strlen($str)) { |
|
50 | + if ($pos>=strlen($str)) { |
|
51 | 51 | return false; |
52 | 52 | } |
53 | 53 | |
54 | - return (ord($str[$pos]) >= ord('0')) && (ord($str[$pos]) <= ord('9')); |
|
54 | + return (ord($str[$pos])>=ord('0')) && (ord($str[$pos])<=ord('9')); |
|
55 | 55 | } |
56 | 56 | |
57 | 57 | //---------------------------------------------------------------------- |
58 | 58 | public static function isalnumat($str, $pos) |
59 | 59 | { |
60 | - if ($pos >= strlen($str)) { |
|
60 | + if ($pos>=strlen($str)) { |
|
61 | 61 | return false; |
62 | 62 | } |
63 | 63 | |
64 | - return QRinput::lookAnTable(ord($str[$pos])) >= 0; |
|
64 | + return QRinput::lookAnTable(ord($str[$pos]))>=0; |
|
65 | 65 | } |
66 | 66 | |
67 | 67 | //---------------------------------------------------------------------- |
68 | 68 | public function identifyMode($pos) |
69 | 69 | { |
70 | - if ($pos >= strlen($this->dataStr)) { |
|
70 | + if ($pos>=strlen($this->dataStr)) { |
|
71 | 71 | return QR_MODE_NUL; |
72 | 72 | } |
73 | 73 | |
@@ -77,11 +77,11 @@ discard block |
||
77 | 77 | return QR_MODE_NUM; |
78 | 78 | } elseif (self::isalnumat($this->dataStr, $pos)) { |
79 | 79 | return QR_MODE_AN; |
80 | - } elseif ($this->modeHint == QR_MODE_KANJI) { |
|
81 | - if ($pos + 1 < strlen($this->dataStr)) { |
|
80 | + } elseif ($this->modeHint==QR_MODE_KANJI) { |
|
81 | + if ($pos + 1<strlen($this->dataStr)) { |
|
82 | 82 | $d = $this->dataStr[$pos + 1]; |
83 | 83 | $word = (ord($c) << 8) | ord($d); |
84 | - if (($word >= 0x8140 && $word <= 0x9ffc) || ($word >= 0xe040 && $word <= 0xebbf)) { |
|
84 | + if (($word>=0x8140 && $word<=0x9ffc) || ($word>=0xe040 && $word<=0xebbf)) { |
|
85 | 85 | return QR_MODE_KANJI; |
86 | 86 | } |
87 | 87 | } |
@@ -103,25 +103,25 @@ discard block |
||
103 | 103 | $run = $p; |
104 | 104 | $mode = $this->identifyMode($p); |
105 | 105 | |
106 | - if ($mode == QR_MODE_8) { |
|
106 | + if ($mode==QR_MODE_8) { |
|
107 | 107 | $dif = QRinput::estimateBitsModeNum($run) + 4 + $ln |
108 | 108 | + QRinput::estimateBitsMode8(1) // + 4 + l8 |
109 | 109 | - QRinput::estimateBitsMode8($run + 1); // - 4 - l8 |
110 | - if ($dif > 0) { |
|
110 | + if ($dif>0) { |
|
111 | 111 | return $this->eat8(); |
112 | 112 | } |
113 | 113 | } |
114 | - if ($mode == QR_MODE_AN) { |
|
114 | + if ($mode==QR_MODE_AN) { |
|
115 | 115 | $dif = QRinput::estimateBitsModeNum($run) + 4 + $ln |
116 | 116 | + QRinput::estimateBitsModeAn(1) // + 4 + la |
117 | 117 | - QRinput::estimateBitsModeAn($run + 1); // - 4 - la |
118 | - if ($dif > 0) { |
|
118 | + if ($dif>0) { |
|
119 | 119 | return $this->eatAn(); |
120 | 120 | } |
121 | 121 | } |
122 | 122 | |
123 | 123 | $ret = $this->input->append(QR_MODE_NUM, $run, str_split($this->dataStr)); |
124 | - if ($ret < 0) { |
|
124 | + if ($ret<0) { |
|
125 | 125 | return -1; |
126 | 126 | } |
127 | 127 | |
@@ -147,7 +147,7 @@ discard block |
||
147 | 147 | + QRinput::estimateBitsModeNum($q - $p) + 4 + $ln |
148 | 148 | - QRinput::estimateBitsModeAn($q); // - 4 - la |
149 | 149 | |
150 | - if ($dif < 0) { |
|
150 | + if ($dif<0) { |
|
151 | 151 | break; |
152 | 152 | } else { |
153 | 153 | $p = $q; |
@@ -163,13 +163,13 @@ discard block |
||
163 | 163 | $dif = QRinput::estimateBitsModeAn($run) + 4 + $la |
164 | 164 | + QRinput::estimateBitsMode8(1) // + 4 + l8 |
165 | 165 | - QRinput::estimateBitsMode8($run + 1); // - 4 - l8 |
166 | - if ($dif > 0) { |
|
166 | + if ($dif>0) { |
|
167 | 167 | return $this->eat8(); |
168 | 168 | } |
169 | 169 | } |
170 | 170 | |
171 | 171 | $ret = $this->input->append(QR_MODE_AN, $run, str_split($this->dataStr)); |
172 | - if ($ret < 0) { |
|
172 | + if ($ret<0) { |
|
173 | 173 | return -1; |
174 | 174 | } |
175 | 175 | |
@@ -181,12 +181,12 @@ discard block |
||
181 | 181 | { |
182 | 182 | $p = 0; |
183 | 183 | |
184 | - while ($this->identifyMode($p) == QR_MODE_KANJI) { |
|
184 | + while ($this->identifyMode($p)==QR_MODE_KANJI) { |
|
185 | 185 | $p += 2; |
186 | 186 | } |
187 | 187 | |
188 | 188 | $ret = $this->input->append(QR_MODE_KANJI, $p, str_split($this->dataStr)); |
189 | - if ($ret < 0) { |
|
189 | + if ($ret<0) { |
|
190 | 190 | return -1; |
191 | 191 | } |
192 | 192 | |
@@ -202,12 +202,12 @@ discard block |
||
202 | 202 | $p = 1; |
203 | 203 | $dataStrLen = strlen($this->dataStr); |
204 | 204 | |
205 | - while ($p < $dataStrLen) { |
|
205 | + while ($p<$dataStrLen) { |
|
206 | 206 | $mode = $this->identifyMode($p); |
207 | - if ($mode == QR_MODE_KANJI) { |
|
207 | + if ($mode==QR_MODE_KANJI) { |
|
208 | 208 | break; |
209 | 209 | } |
210 | - if ($mode == QR_MODE_NUM) { |
|
210 | + if ($mode==QR_MODE_NUM) { |
|
211 | 211 | $q = $p; |
212 | 212 | while (self::isdigitat($this->dataStr, $q)) { |
213 | 213 | $q++; |
@@ -215,12 +215,12 @@ discard block |
||
215 | 215 | $dif = QRinput::estimateBitsMode8($p) // + 4 + l8 |
216 | 216 | + QRinput::estimateBitsModeNum($q - $p) + 4 + $ln |
217 | 217 | - QRinput::estimateBitsMode8($q); // - 4 - l8 |
218 | - if ($dif < 0) { |
|
218 | + if ($dif<0) { |
|
219 | 219 | break; |
220 | 220 | } else { |
221 | 221 | $p = $q; |
222 | 222 | } |
223 | - } elseif ($mode == QR_MODE_AN) { |
|
223 | + } elseif ($mode==QR_MODE_AN) { |
|
224 | 224 | $q = $p; |
225 | 225 | while (self::isalnumat($this->dataStr, $q)) { |
226 | 226 | $q++; |
@@ -228,7 +228,7 @@ discard block |
||
228 | 228 | $dif = QRinput::estimateBitsMode8($p) // + 4 + l8 |
229 | 229 | + QRinput::estimateBitsModeAn($q - $p) + 4 + $la |
230 | 230 | - QRinput::estimateBitsMode8($q); // - 4 - l8 |
231 | - if ($dif < 0) { |
|
231 | + if ($dif<0) { |
|
232 | 232 | break; |
233 | 233 | } else { |
234 | 234 | $p = $q; |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | $run = $p; |
242 | 242 | $ret = $this->input->append(QR_MODE_8, $run, str_split($this->dataStr)); |
243 | 243 | |
244 | - if ($ret < 0) { |
|
244 | + if ($ret<0) { |
|
245 | 245 | return -1; |
246 | 246 | } |
247 | 247 | |
@@ -251,8 +251,8 @@ discard block |
||
251 | 251 | //---------------------------------------------------------------------- |
252 | 252 | public function splitString() |
253 | 253 | { |
254 | - while (strlen($this->dataStr) > 0) { |
|
255 | - if ($this->dataStr == '') { |
|
254 | + while (strlen($this->dataStr)>0) { |
|
255 | + if ($this->dataStr=='') { |
|
256 | 256 | return 0; |
257 | 257 | } |
258 | 258 | |
@@ -262,7 +262,7 @@ discard block |
||
262 | 262 | case QR_MODE_NUM: $length = $this->eatNum(); break; |
263 | 263 | case QR_MODE_AN: $length = $this->eatAn(); break; |
264 | 264 | case QR_MODE_KANJI: |
265 | - if ($mode == QR_MODE_KANJI) { |
|
265 | + if ($mode==QR_MODE_KANJI) { |
|
266 | 266 | $length = $this->eatKanji(); |
267 | 267 | } else { |
268 | 268 | $length = $this->eat8(); |
@@ -272,10 +272,10 @@ discard block |
||
272 | 272 | |
273 | 273 | } |
274 | 274 | |
275 | - if ($length == 0) { |
|
275 | + if ($length==0) { |
|
276 | 276 | return 0; |
277 | 277 | } |
278 | - if ($length < 0) { |
|
278 | + if ($length<0) { |
|
279 | 279 | return -1; |
280 | 280 | } |
281 | 281 | |
@@ -289,12 +289,12 @@ discard block |
||
289 | 289 | $stringLen = strlen($this->dataStr); |
290 | 290 | $p = 0; |
291 | 291 | |
292 | - while ($p < $stringLen) { |
|
292 | + while ($p<$stringLen) { |
|
293 | 293 | $mode = self::identifyMode(substr($this->dataStr, $p), $this->modeHint); |
294 | - if ($mode == QR_MODE_KANJI) { |
|
294 | + if ($mode==QR_MODE_KANJI) { |
|
295 | 295 | $p += 2; |
296 | 296 | } else { |
297 | - if (ord($this->dataStr[$p]) >= ord('a') && ord($this->dataStr[$p]) <= ord('z')) { |
|
297 | + if (ord($this->dataStr[$p])>=ord('a') && ord($this->dataStr[$p])<=ord('z')) { |
|
298 | 298 | $this->dataStr[$p] = chr(ord($this->dataStr[$p]) - 32); |
299 | 299 | } |
300 | 300 | $p++; |
@@ -307,7 +307,7 @@ discard block |
||
307 | 307 | //---------------------------------------------------------------------- |
308 | 308 | public static function splitStringToQRinput($string, QRinput $input, $modeHint, $casesensitive = true) |
309 | 309 | { |
310 | - if (is_null($string) || $string == '\0' || $string == '') { |
|
310 | + if (is_null($string) || $string=='\0' || $string=='') { |
|
311 | 311 | throw new Exception('empty string!!!'); |
312 | 312 | } |
313 | 313 |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | { |
30 | 30 | $len = count($frame); |
31 | 31 | foreach ($frame as &$frameLine) { |
32 | - for ($i = 0; $i < $len; $i++) { |
|
32 | + for ($i = 0; $i<$len; $i++) { |
|
33 | 33 | $frameLine[$i] = (ord($frameLine[$i]) & 1) ? '1' : '0'; |
34 | 34 | } |
35 | 35 | } |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | |
49 | 49 | $eccLevel = 'L'; |
50 | 50 | |
51 | - if (count($mode) > 1) { |
|
51 | + if (count($mode)>1) { |
|
52 | 52 | $eccLevel = $mode[1]; |
53 | 53 | } |
54 | 54 | |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | foreach ($qrTab as $line) { |
63 | 63 | $arrAdd = []; |
64 | 64 | foreach (str_split($line) as $char) { |
65 | - $arrAdd[] = ($char == '1') ? 1 : 0; |
|
65 | + $arrAdd[] = ($char=='1') ? 1 : 0; |
|
66 | 66 | } |
67 | 67 | $barcode_array['bcode'][] = $arrAdd; |
68 | 68 | } |
@@ -82,7 +82,7 @@ discard block |
||
82 | 82 | self::markTime('before_build_cache'); |
83 | 83 | |
84 | 84 | $mask = new QRmask(); |
85 | - for ($a = 1; $a <= QRSPEC_VERSION_MAX; $a++) { |
|
85 | + for ($a = 1; $a<=QRSPEC_VERSION_MAX; $a++) { |
|
86 | 86 | $frame = QRspec::newFrame($a); |
87 | 87 | if (QR_IMAGE) { |
88 | 88 | $fileName = QR_CACHE_DIR.'frame_'.$a.'.png'; |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | |
92 | 92 | $width = count($frame); |
93 | 93 | $bitMask = array_fill(0, $width, array_fill(0, $width, 0)); |
94 | - for ($maskNo = 0; $maskNo < 8; $maskNo++) { |
|
94 | + for ($maskNo = 0; $maskNo<8; $maskNo++) { |
|
95 | 95 | $mask->makeMaskNo($maskNo, $width, $frame, $bitMask, true); |
96 | 96 | } |
97 | 97 | } |
@@ -102,9 +102,9 @@ discard block |
||
102 | 102 | //---------------------------------------------------------------------- |
103 | 103 | public static function log($outfile, $err) |
104 | 104 | { |
105 | - if (QR_LOG_DIR !== false) { |
|
106 | - if ($err != '') { |
|
107 | - if ($outfile !== false) { |
|
105 | + if (QR_LOG_DIR!==false) { |
|
106 | + if ($err!='') { |
|
107 | + if ($outfile!==false) { |
|
108 | 108 | file_put_contents(QR_LOG_DIR.basename($outfile).'-errors.txt', date('Y-m-d H:i:s').': '.$err, FILE_APPEND); |
109 | 109 | } else { |
110 | 110 | file_put_contents(QR_LOG_DIR.'errors.txt', date('Y-m-d H:i:s').': '.$err, FILE_APPEND); |
@@ -117,8 +117,8 @@ discard block |
||
117 | 117 | public static function dumpMask($frame) |
118 | 118 | { |
119 | 119 | $width = count($frame); |
120 | - for ($y = 0; $y < $width; $y++) { |
|
121 | - for ($x = 0; $x < $width; $x++) { |
|
120 | + for ($y = 0; $y<$width; $y++) { |
|
121 | + for ($x = 0; $x<$width; $x++) { |
|
122 | 122 | echo ord($frame[$y][$x]).','; |
123 | 123 | } |
124 | 124 | } |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | public static function markTime($markerId) |
129 | 129 | { |
130 | 130 | list($usec, $sec) = explode(' ', microtime()); |
131 | - $time = ((float) $usec + (float) $sec); |
|
131 | + $time = ((float)$usec + (float)$sec); |
|
132 | 132 | |
133 | 133 | if (!isset($GLOBALS['qr_time_bench'])) { |
134 | 134 | $GLOBALS['qr_time_bench'] = []; |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | <tbody>'; |
152 | 152 | |
153 | 153 | foreach ($GLOBALS['qr_time_bench'] as $markerId=>$thisTime) { |
154 | - if ($p > 0) { |
|
154 | + if ($p>0) { |
|
155 | 155 | echo '<tr><th style="text-align:right">till '.$markerId.': </th><td>'.number_format($thisTime - $lastTime, 6).'s</td></tr>'; |
156 | 156 | } else { |
157 | 157 | $startTime = $thisTime; |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | |
177 | 177 | return true; |
178 | 178 | } catch (Exception $e) { |
179 | - echo 'Exception reçue : ', $e->getMessage(), "\n"; |
|
179 | + echo 'Exception reçue : ', $e->getMessage(), "\n"; |
|
180 | 180 | } |
181 | 181 | } |
182 | 182 | } |
@@ -33,5 +33,5 @@ |
||
33 | 33 | // |
34 | 34 | //?> |
35 | 35 | <?php |
36 | - echo" <link href='css/i_style.css' type='text/css' rel='stylesheet'>"; |
|
37 | - ?> |
|
38 | 36 | \ No newline at end of file |
37 | + echo" <link href='css/i_style.css' type='text/css' rel='stylesheet'>"; |
|
38 | + ?> |
|
39 | 39 | \ No newline at end of file |
@@ -35,12 +35,12 @@ |
||
35 | 35 | ////Define Function |
36 | 36 | function bar128($text) |
37 | 37 | { // Part 1, make list of widths |
38 | - global $char128asc,$char128wid; |
|
38 | + global $char128asc,$char128wid; |
|
39 | 39 | $w = $char128wid[$sum = 104]; // START symbol |
40 | 40 | $onChar = 1; |
41 | 41 | for ($x = 0; $x < strlen($text); $x++) { // GO THRU TEXT GET LETTERS |
42 | 42 | if (!(($pos = strpos($char128asc, $text[$x])) === false)) { // SKIP NOT FOUND CHARS |
43 | - $w .= $char128wid[$pos]; |
|
43 | + $w .= $char128wid[$pos]; |
|
44 | 44 | $sum += $onChar++ * $pos; |
45 | 45 | } |
46 | 46 | } |
@@ -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 |
@@ -109,16 +109,16 @@ discard block |
||
109 | 109 | <p class="pull-right"> |
110 | 110 | <select name="itipe_barang" class="form-control" onChange="document.myform.submit();"> |
111 | 111 | <?php |
112 | - $query = mysql_query('SELECT * FROM tipe_barang ORDER BY id_tipe_barang'); |
|
113 | - if ($query && mysql_num_rows($query) > 0) { |
|
114 | - while ($row = mysql_fetch_object($query)) { |
|
115 | - echo '<option value="'.$row->id_tipe_barang.'"'; |
|
116 | - if ($row->id_tipe_barang == $tipe_barang) { |
|
117 | - echo ' selected'; |
|
118 | - } |
|
119 | - echo '>'.$row->tipe_barang.'</option>'; |
|
120 | - } |
|
121 | - } |
|
112 | + $query = mysql_query('SELECT * FROM tipe_barang ORDER BY id_tipe_barang'); |
|
113 | + if ($query && mysql_num_rows($query) > 0) { |
|
114 | + while ($row = mysql_fetch_object($query)) { |
|
115 | + echo '<option value="'.$row->id_tipe_barang.'"'; |
|
116 | + if ($row->id_tipe_barang == $tipe_barang) { |
|
117 | + echo ' selected'; |
|
118 | + } |
|
119 | + echo '>'.$row->tipe_barang.'</option>'; |
|
120 | + } |
|
121 | + } |
|
122 | 122 | ?> |
123 | 123 | </select> |
124 | 124 | </p> |
@@ -126,16 +126,16 @@ discard block |
||
126 | 126 | <p class="pull-right"> |
127 | 127 | <select name="ioutlet" class="form-control" onChange="document.myform.submit();"> |
128 | 128 | <?php |
129 | - $query = mysql_query('SELECT * FROM outlet ORDER BY id_outlet'); |
|
130 | - if ($query && mysql_num_rows($query) > 0) { |
|
131 | - while ($row = mysql_fetch_object($query)) { |
|
132 | - echo '<option value="'.$row->id_outlet.'"'; |
|
133 | - if ($row->id_outlet == $outlet) { |
|
134 | - echo ' selected'; |
|
135 | - } |
|
136 | - echo '>'.$row->outlet.'</option>'; |
|
137 | - } |
|
138 | - } |
|
129 | + $query = mysql_query('SELECT * FROM outlet ORDER BY id_outlet'); |
|
130 | + if ($query && mysql_num_rows($query) > 0) { |
|
131 | + while ($row = mysql_fetch_object($query)) { |
|
132 | + echo '<option value="'.$row->id_outlet.'"'; |
|
133 | + if ($row->id_outlet == $outlet) { |
|
134 | + echo ' selected'; |
|
135 | + } |
|
136 | + echo '>'.$row->outlet.'</option>'; |
|
137 | + } |
|
138 | + } |
|
139 | 139 | ?> |
140 | 140 | </select> |
141 | 141 | </p> |
@@ -175,7 +175,7 @@ discard block |
||
175 | 175 | |
176 | 176 | <?php |
177 | 177 | |
178 | - $SQL = "SELECT b.jenis_barang |
|
178 | + $SQL = "SELECT b.jenis_barang |
|
179 | 179 | ,c.unit_barang |
180 | 180 | ,a.kode as kode_barang |
181 | 181 | ,a.id_barang |
@@ -208,15 +208,15 @@ discard block |
||
208 | 208 | ,d.harga_jual |
209 | 209 | ORDER BY a.id_jenis_barang,a.kode"; |
210 | 210 | |
211 | - $tampil = mysql_query($SQL); |
|
211 | + $tampil = mysql_query($SQL); |
|
212 | 212 | |
213 | - $no = 1; |
|
213 | + $no = 1; |
|
214 | 214 | |
215 | - while ($r = mysql_fetch_array($tampil)) { |
|
216 | - $id_barang = $r['id_barang']; |
|
217 | - $kode_barang = $r['kode_barang']; |
|
215 | + while ($r = mysql_fetch_array($tampil)) { |
|
216 | + $id_barang = $r['id_barang']; |
|
217 | + $kode_barang = $r['kode_barang']; |
|
218 | 218 | |
219 | - $dsql = mysql_query("SELECT sum(qty) as reserve |
|
219 | + $dsql = mysql_query("SELECT sum(qty) as reserve |
|
220 | 220 | FROM stok_reserved |
221 | 221 | WHERE id_barang_promosi = '$id_barang' |
222 | 222 | AND id_outlet = '$outlet' |
@@ -224,35 +224,35 @@ discard block |
||
224 | 224 | and prd = '$prd' |
225 | 225 | "); |
226 | 226 | |
227 | - $d = mysql_fetch_array($dsql); |
|
227 | + $d = mysql_fetch_array($dsql); |
|
228 | 228 | |
229 | - if ($d['reserve']) { |
|
230 | - $reserve = $d['reserve']; |
|
231 | - } else { |
|
232 | - $reserve = 0; |
|
233 | - } |
|
229 | + if ($d['reserve']) { |
|
230 | + $reserve = $d['reserve']; |
|
231 | + } else { |
|
232 | + $reserve = 0; |
|
233 | + } |
|
234 | 234 | |
235 | - $sisa_stok = $r['stok'] - $reserve; |
|
235 | + $sisa_stok = $r['stok'] - $reserve; |
|
236 | 236 | |
237 | - if ($sisa_stok == '0') { |
|
238 | - echo ''; |
|
239 | - } else { |
|
240 | - echo'<tr>'; |
|
241 | - echo" <td style='text-align:center;'>"; |
|
242 | - echo"<a href='../../modul/mod_$module/aksi_$module.php?module=$module&act=add&barcode=$kode_barang&prd=$prd¬rans=$notrans&kode=$kode&tanggal=$tanggal&customer=$customer&outlet=$outlet&id_outlet=$id_outlet&id_module=$id_module&look=1' title=''><span class='icon'><i class='fa fa-check'></i></span></a>"; |
|
237 | + if ($sisa_stok == '0') { |
|
238 | + echo ''; |
|
239 | + } else { |
|
240 | + echo'<tr>'; |
|
241 | + echo" <td style='text-align:center;'>"; |
|
242 | + echo"<a href='../../modul/mod_$module/aksi_$module.php?module=$module&act=add&barcode=$kode_barang&prd=$prd¬rans=$notrans&kode=$kode&tanggal=$tanggal&customer=$customer&outlet=$outlet&id_outlet=$id_outlet&id_module=$id_module&look=1' title=''><span class='icon'><i class='fa fa-check'></i></span></a>"; |
|
243 | 243 | |
244 | - echo'</td>'; |
|
245 | - echo'<td>'.$r['jenis_barang'].'</td>'; |
|
246 | - echo'<td>'.$r['kode_barang'].'</td>'; |
|
247 | - echo'<td>'.$r['barang'].'</td>'; |
|
248 | - echo'<td>'.$r['unit_barang'].'</td>'; |
|
249 | - echo"<td style='text-align:right;'>".number_format($r['harga_jual'], 0, '.', ',').'</td>'; |
|
244 | + echo'</td>'; |
|
245 | + echo'<td>'.$r['jenis_barang'].'</td>'; |
|
246 | + echo'<td>'.$r['kode_barang'].'</td>'; |
|
247 | + echo'<td>'.$r['barang'].'</td>'; |
|
248 | + echo'<td>'.$r['unit_barang'].'</td>'; |
|
249 | + echo"<td style='text-align:right;'>".number_format($r['harga_jual'], 0, '.', ',').'</td>'; |
|
250 | 250 | |
251 | - echo'</tr>'; |
|
252 | - } |
|
251 | + echo'</tr>'; |
|
252 | + } |
|
253 | 253 | |
254 | - $no++; |
|
255 | - } |
|
254 | + $no++; |
|
255 | + } |
|
256 | 256 | ?> |
257 | 257 | </tbody> |
258 | 258 | </table> |
@@ -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>'; |
@@ -146,49 +146,49 @@ discard block |
||
146 | 146 | |
147 | 147 | <?php |
148 | 148 | |
149 | - $gtampil = mysql_query("SELECT * FROM informasi_perusahaan where id_informasi_perusahaan = '1'"); |
|
149 | + $gtampil = mysql_query("SELECT * FROM informasi_perusahaan where id_informasi_perusahaan = '1'"); |
|
150 | 150 | |
151 | - $g = mysql_fetch_array($gtampil); |
|
151 | + $g = mysql_fetch_array($gtampil); |
|
152 | 152 | |
153 | - if ($g['pict']) { |
|
154 | - $pict = $g['pict']; |
|
155 | - } else { |
|
156 | - $pict = ''; |
|
157 | - } |
|
153 | + if ($g['pict']) { |
|
154 | + $pict = $g['pict']; |
|
155 | + } else { |
|
156 | + $pict = ''; |
|
157 | + } |
|
158 | 158 | |
159 | - $company = ucwords($g['company']); |
|
159 | + $company = ucwords($g['company']); |
|
160 | 160 | |
161 | - $jsql = mysql_query("SELECT * FROM jenis_transaksi |
|
161 | + $jsql = mysql_query("SELECT * FROM jenis_transaksi |
|
162 | 162 | WHERE id_jenis_transaksi = '$jenis_transaksi' |
163 | 163 | |
164 | 164 | "); |
165 | 165 | |
166 | - $j = mysql_fetch_array($jsql); |
|
166 | + $j = mysql_fetch_array($jsql); |
|
167 | 167 | |
168 | - $jenis_transaksi = $j['jenis_transaksi']; |
|
168 | + $jenis_transaksi = $j['jenis_transaksi']; |
|
169 | 169 | |
170 | - $sql = mysql_query("SELECT a.*,b.shift FROM kasir a LEFT JOIN shift b |
|
170 | + $sql = mysql_query("SELECT a.*,b.shift FROM kasir a LEFT JOIN shift b |
|
171 | 171 | ON a.id_shift = b.id_shift |
172 | 172 | WHERE a.id_kasir = '$k_ID' |
173 | 173 | |
174 | 174 | "); |
175 | 175 | |
176 | - $r = mysql_fetch_array($sql); |
|
176 | + $r = mysql_fetch_array($sql); |
|
177 | 177 | |
178 | - $penjualan_barang = $r['id_kasir']; |
|
178 | + $penjualan_barang = $r['id_kasir']; |
|
179 | 179 | |
180 | - $shift = $r['shift']; |
|
180 | + $shift = $r['shift']; |
|
181 | 181 | |
182 | - $petugas = $r['petugas']; |
|
182 | + $petugas = $r['petugas']; |
|
183 | 183 | |
184 | - $status = $r['status']; |
|
184 | + $status = $r['status']; |
|
185 | 185 | |
186 | - $tanggal = date('d/m/Y', strtotime($r['tanggal'])); |
|
186 | + $tanggal = date('d/m/Y', strtotime($r['tanggal'])); |
|
187 | 187 | |
188 | - ?> |
|
188 | + ?> |
|
189 | 189 | |
190 | 190 | <?php if ($tipe == 'R') { |
191 | - ?> |
|
191 | + ?> |
|
192 | 192 | |
193 | 193 | |
194 | 194 | <table width="100%"> |
@@ -214,14 +214,14 @@ discard block |
||
214 | 214 | <?php |
215 | 215 | $htampil = mysql_query("SELECT * FROM jenis_transaksi where aktif = 'Y' ORDER BY id_jenis_transaksi"); |
216 | 216 | |
217 | - $hjml = mysql_num_rows($htampil); |
|
217 | + $hjml = mysql_num_rows($htampil); |
|
218 | 218 | |
219 | - while ($h = mysql_fetch_array($htampil)) { |
|
220 | - echo '<tr>'; |
|
221 | - echo '<td>'.$h['jenis_transaksi'].'</td>'; |
|
219 | + while ($h = mysql_fetch_array($htampil)) { |
|
220 | + echo '<tr>'; |
|
221 | + echo '<td>'.$h['jenis_transaksi'].'</td>'; |
|
222 | 222 | |
223 | - //transaksi umum tunai |
|
224 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
223 | + //transaksi umum tunai |
|
224 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
225 | 225 | , IFNULL(SUM(c.jumlah),0) as rp |
226 | 226 | FROM kasir b LEFT JOIN kasir_detail c |
227 | 227 | ON b.id_kasir = c.id_kasir |
@@ -230,13 +230,13 @@ discard block |
||
230 | 230 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
231 | 231 | AND b.status != '4'"); |
232 | 232 | |
233 | - $d = mysql_fetch_array($dtampil); |
|
233 | + $d = mysql_fetch_array($dtampil); |
|
234 | 234 | |
235 | - echo '<th>'.$d['jml'].'</th>'; |
|
236 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
235 | + echo '<th>'.$d['jml'].'</th>'; |
|
236 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
237 | 237 | |
238 | - echo '</tr>'; |
|
239 | - } ?> |
|
238 | + echo '</tr>'; |
|
239 | + } ?> |
|
240 | 240 | |
241 | 241 | |
242 | 242 | <tr> |
@@ -250,10 +250,10 @@ discard block |
||
250 | 250 | WHERE b.tanggal like '$prd%' |
251 | 251 | AND b.status != '4'"); |
252 | 252 | |
253 | - $d = mysql_fetch_array($dtampil); |
|
253 | + $d = mysql_fetch_array($dtampil); |
|
254 | 254 | |
255 | - echo '<th>'.$d['jml'].'</th>'; |
|
256 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; ?> |
|
255 | + echo '<th>'.$d['jml'].'</th>'; |
|
256 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; ?> |
|
257 | 257 | |
258 | 258 | </tr> |
259 | 259 | |
@@ -291,8 +291,8 @@ discard block |
||
291 | 291 | |
292 | 292 | |
293 | 293 | <?php |
294 | - } else { |
|
295 | - ?> |
|
294 | + } else { |
|
295 | + ?> |
|
296 | 296 | |
297 | 297 | <table width="100%"> |
298 | 298 | <tr> |
@@ -323,11 +323,11 @@ discard block |
||
323 | 323 | |
324 | 324 | $htampil = mysql_query("SELECT * FROM penjamin where aktif = 'Y' ORDER BY id_penjamin"); |
325 | 325 | |
326 | - $hjml = mysql_num_rows($htampil); |
|
326 | + $hjml = mysql_num_rows($htampil); |
|
327 | 327 | |
328 | - while ($h = mysql_fetch_array($htampil)) { |
|
329 | - echo "<th colspan='2' rowspan='2'>".$h['penjamin'].'</th>'; |
|
330 | - } ?> |
|
328 | + while ($h = mysql_fetch_array($htampil)) { |
|
329 | + echo "<th colspan='2' rowspan='2'>".$h['penjamin'].'</th>'; |
|
330 | + } ?> |
|
331 | 331 | |
332 | 332 | <th colspan ="4" >UMUM</th> |
333 | 333 | <th colspan ="2" rowspan='2'>TOTAL</th> |
@@ -367,15 +367,15 @@ discard block |
||
367 | 367 | |
368 | 368 | $htampil = mysql_query("SELECT * FROM jenis_transaksi where aktif = 'Y' ORDER BY id_jenis_transaksi"); |
369 | 369 | |
370 | - $hjml = mysql_num_rows($htampil); |
|
370 | + $hjml = mysql_num_rows($htampil); |
|
371 | 371 | |
372 | - while ($h = mysql_fetch_array($htampil)) { |
|
373 | - echo'<tr>'; |
|
372 | + while ($h = mysql_fetch_array($htampil)) { |
|
373 | + echo'<tr>'; |
|
374 | 374 | |
375 | - echo'<td>'.$h['jenis_transaksi'].'</td>'; |
|
375 | + echo'<td>'.$h['jenis_transaksi'].'</td>'; |
|
376 | 376 | |
377 | - //transaksi asuransi |
|
378 | - $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
377 | + //transaksi asuransi |
|
378 | + $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
379 | 379 | , COUNT(c.jumlah) as jml |
380 | 380 | , IFNULL(SUM(c.jumlah),0) as rp |
381 | 381 | FROM penjamin a LEFT JOIN kasir b |
@@ -391,12 +391,12 @@ discard block |
||
391 | 391 | GROUP BY a.id_penjamin |
392 | 392 | ORDER BY a.id_penjamin"); |
393 | 393 | |
394 | - while ($d1 = mysql_fetch_array($dtampil1)) { |
|
395 | - echo "<td style='text-align:center;'>".$d1['jml'].'</td>'; |
|
396 | - echo "<td style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</td>'; |
|
397 | - } |
|
394 | + while ($d1 = mysql_fetch_array($dtampil1)) { |
|
395 | + echo "<td style='text-align:center;'>".$d1['jml'].'</td>'; |
|
396 | + echo "<td style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</td>'; |
|
397 | + } |
|
398 | 398 | |
399 | - $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
399 | + $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
400 | 400 | , IFNULL(SUM(c.jumlah),0) as rp |
401 | 401 | FROM kasir b LEFT JOIN kasir_detail c |
402 | 402 | ON b.id_kasir = c.id_kasir |
@@ -406,12 +406,12 @@ discard block |
||
406 | 406 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
407 | 407 | AND b.status != '4'"); |
408 | 408 | |
409 | - $d2 = mysql_fetch_array($dtampil2); |
|
409 | + $d2 = mysql_fetch_array($dtampil2); |
|
410 | 410 | |
411 | - echo "<td style='text-align:center;'>".$d2['jml'].'</td>'; |
|
412 | - echo "<td style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</td>'; |
|
411 | + echo "<td style='text-align:center;'>".$d2['jml'].'</td>'; |
|
412 | + echo "<td style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</td>'; |
|
413 | 413 | |
414 | - $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
414 | + $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
415 | 415 | , IFNULL(SUM(c.jumlah),0) as rp |
416 | 416 | FROM kasir b LEFT JOIN kasir_detail c |
417 | 417 | ON b.id_kasir = c.id_kasir |
@@ -421,12 +421,12 @@ discard block |
||
421 | 421 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
422 | 422 | AND b.status != '4'"); |
423 | 423 | |
424 | - $d3 = mysql_fetch_array($dtampil3); |
|
424 | + $d3 = mysql_fetch_array($dtampil3); |
|
425 | 425 | |
426 | - echo "<td style='text-align:center;'>".$d3['jml'].'</td>'; |
|
427 | - echo "<td style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</td>'; |
|
426 | + echo "<td style='text-align:center;'>".$d3['jml'].'</td>'; |
|
427 | + echo "<td style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</td>'; |
|
428 | 428 | |
429 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
429 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
430 | 430 | , IFNULL(SUM(c.jumlah),0) as rp |
431 | 431 | FROM kasir b LEFT JOIN kasir_detail c |
432 | 432 | ON b.id_kasir = c.id_kasir |
@@ -435,13 +435,13 @@ discard block |
||
435 | 435 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
436 | 436 | AND b.status != '4'"); |
437 | 437 | |
438 | - $d = mysql_fetch_array($dtampil); |
|
438 | + $d = mysql_fetch_array($dtampil); |
|
439 | 439 | |
440 | - echo "<td style='text-align:center;'>".$d['jml'].'</td>'; |
|
441 | - echo "<td style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</td>'; |
|
440 | + echo "<td style='text-align:center;'>".$d['jml'].'</td>'; |
|
441 | + echo "<td style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</td>'; |
|
442 | 442 | |
443 | - echo'</tr>'; |
|
444 | - } ?> |
|
443 | + echo'</tr>'; |
|
444 | + } ?> |
|
445 | 445 | |
446 | 446 | </tbody> |
447 | 447 | |
@@ -449,12 +449,12 @@ discard block |
||
449 | 449 | |
450 | 450 | <?php |
451 | 451 | |
452 | - echo'<tr>'; |
|
452 | + echo'<tr>'; |
|
453 | 453 | |
454 | - echo'<th>TOTAL</th>'; |
|
454 | + echo'<th>TOTAL</th>'; |
|
455 | 455 | |
456 | - //transaksi asuransi |
|
457 | - $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
456 | + //transaksi asuransi |
|
457 | + $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
458 | 458 | , COUNT(c.jumlah) as jml |
459 | 459 | , IFNULL(SUM(c.jumlah),0) as rp |
460 | 460 | FROM penjamin a LEFT JOIN kasir b |
@@ -469,12 +469,12 @@ discard block |
||
469 | 469 | GROUP BY a.id_penjamin |
470 | 470 | ORDER BY a.id_penjamin"); |
471 | 471 | |
472 | - while ($d1 = mysql_fetch_array($dtampil1)) { |
|
473 | - echo '<th>'.$d1['jml'].'</th>'; |
|
474 | - echo "<th style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</th>'; |
|
475 | - } |
|
472 | + while ($d1 = mysql_fetch_array($dtampil1)) { |
|
473 | + echo '<th>'.$d1['jml'].'</th>'; |
|
474 | + echo "<th style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</th>'; |
|
475 | + } |
|
476 | 476 | |
477 | - $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
477 | + $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
478 | 478 | , IFNULL(SUM(c.jumlah),0) as rp |
479 | 479 | FROM kasir b LEFT JOIN kasir_detail c |
480 | 480 | ON b.id_kasir = c.id_kasir |
@@ -483,12 +483,12 @@ discard block |
||
483 | 483 | WHERE b.tanggal LIKE '$prd%' |
484 | 484 | AND b.status != '4'"); |
485 | 485 | |
486 | - $d2 = mysql_fetch_array($dtampil2); |
|
486 | + $d2 = mysql_fetch_array($dtampil2); |
|
487 | 487 | |
488 | - echo '<th>'.$d2['jml'].'</th>'; |
|
489 | - echo "<th style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</th>'; |
|
488 | + echo '<th>'.$d2['jml'].'</th>'; |
|
489 | + echo "<th style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</th>'; |
|
490 | 490 | |
491 | - $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
491 | + $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
492 | 492 | , IFNULL(SUM(c.jumlah),0) as rp |
493 | 493 | FROM kasir b LEFT JOIN kasir_detail c |
494 | 494 | ON b.id_kasir = c.id_kasir |
@@ -497,12 +497,12 @@ discard block |
||
497 | 497 | WHERE b.tanggal LIKE '$prd%' |
498 | 498 | AND b.status != '4'"); |
499 | 499 | |
500 | - $d3 = mysql_fetch_array($dtampil3); |
|
500 | + $d3 = mysql_fetch_array($dtampil3); |
|
501 | 501 | |
502 | - echo '<th>'.$d3['jml'].'</th>'; |
|
503 | - echo "<th style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</th>'; |
|
502 | + echo '<th>'.$d3['jml'].'</th>'; |
|
503 | + echo "<th style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</th>'; |
|
504 | 504 | |
505 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
505 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
506 | 506 | , IFNULL(SUM(c.jumlah),0) as rp |
507 | 507 | FROM kasir b LEFT JOIN kasir_detail c |
508 | 508 | ON b.id_kasir = c.id_kasir |
@@ -510,12 +510,12 @@ discard block |
||
510 | 510 | WHERE b.tanggal like '$prd%' |
511 | 511 | AND b.status != '4'"); |
512 | 512 | |
513 | - $d = mysql_fetch_array($dtampil); |
|
513 | + $d = mysql_fetch_array($dtampil); |
|
514 | 514 | |
515 | - echo '<th>'.$d['jml'].'</th>'; |
|
516 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
515 | + echo '<th>'.$d['jml'].'</th>'; |
|
516 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
517 | 517 | |
518 | - echo'</tr>'; ?> |
|
518 | + echo'</tr>'; ?> |
|
519 | 519 | |
520 | 520 | |
521 | 521 | |
@@ -529,17 +529,17 @@ discard block |
||
529 | 529 | |
530 | 530 | $lastday = date('t', strtotime($iprd)); |
531 | 531 | |
532 | - $year = date('Y', strtotime($iprd)); |
|
532 | + $year = date('Y', strtotime($iprd)); |
|
533 | 533 | |
534 | - $month = date('m', strtotime($iprd)) * 1; |
|
534 | + $month = date('m', strtotime($iprd)) * 1; |
|
535 | 535 | |
536 | - if ($month == '1') { |
|
537 | - $imonth = 12; |
|
538 | - } else { |
|
539 | - $imonth = $month - 1; |
|
540 | - } |
|
536 | + if ($month == '1') { |
|
537 | + $imonth = 12; |
|
538 | + } else { |
|
539 | + $imonth = $month - 1; |
|
540 | + } |
|
541 | 541 | |
542 | - $nprd = $lastday.' '.getBulan1($imonth).' '.$year; ?> |
|
542 | + $nprd = $lastday.' '.getBulan1($imonth).' '.$year; ?> |
|
543 | 543 | |
544 | 544 | <table width="100%"> |
545 | 545 | <tr> |
@@ -570,7 +570,7 @@ discard block |
||
570 | 570 | |
571 | 571 | |
572 | 572 | <?php |
573 | - } ?> |
|
573 | + } ?> |
|
574 | 574 | |
575 | 575 | |
576 | 576 |
@@ -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; |
@@ -244,50 +244,50 @@ discard block |
||
244 | 244 | |
245 | 245 | <?php |
246 | 246 | |
247 | - $gtampil = mysql_query("SELECT * FROM informasi_perusahaan where id_informasi_perusahaan = '1'"); |
|
247 | + $gtampil = mysql_query("SELECT * FROM informasi_perusahaan where id_informasi_perusahaan = '1'"); |
|
248 | 248 | |
249 | - $g = mysql_fetch_array($gtampil); |
|
249 | + $g = mysql_fetch_array($gtampil); |
|
250 | 250 | |
251 | - if ($g['pict']) { |
|
252 | - $pict = $g['pict']; |
|
253 | - } else { |
|
254 | - $pict = ''; |
|
255 | - } |
|
251 | + if ($g['pict']) { |
|
252 | + $pict = $g['pict']; |
|
253 | + } else { |
|
254 | + $pict = ''; |
|
255 | + } |
|
256 | 256 | |
257 | - $company = ucwords($g['company']); |
|
257 | + $company = ucwords($g['company']); |
|
258 | 258 | |
259 | - $jsql = mysql_query("SELECT * FROM jenis_transaksi |
|
259 | + $jsql = mysql_query("SELECT * FROM jenis_transaksi |
|
260 | 260 | WHERE id_jenis_transaksi = '$jenis_transaksi' |
261 | 261 | |
262 | 262 | |
263 | 263 | "); |
264 | 264 | |
265 | - $j = mysql_fetch_array($jsql); |
|
265 | + $j = mysql_fetch_array($jsql); |
|
266 | 266 | |
267 | - $jenis_transaksi = $j['jenis_transaksi']; |
|
267 | + $jenis_transaksi = $j['jenis_transaksi']; |
|
268 | 268 | |
269 | - $sql = mysql_query("SELECT a.*,b.shift FROM kasir a LEFT JOIN shift b |
|
269 | + $sql = mysql_query("SELECT a.*,b.shift FROM kasir a LEFT JOIN shift b |
|
270 | 270 | ON a.id_shift = b.id_shift |
271 | 271 | WHERE a.id_kasir = '$k_ID' |
272 | 272 | |
273 | 273 | "); |
274 | 274 | |
275 | - $r = mysql_fetch_array($sql); |
|
275 | + $r = mysql_fetch_array($sql); |
|
276 | 276 | |
277 | - $penjualan_barang = $r['id_kasir']; |
|
277 | + $penjualan_barang = $r['id_kasir']; |
|
278 | 278 | |
279 | - $shift = $r['shift']; |
|
279 | + $shift = $r['shift']; |
|
280 | 280 | |
281 | - $petugas = $r['petugas']; |
|
281 | + $petugas = $r['petugas']; |
|
282 | 282 | |
283 | - $status = $r['status']; |
|
283 | + $status = $r['status']; |
|
284 | 284 | |
285 | - $tanggal = date('d/m/Y', strtotime($r['tanggal'])); |
|
285 | + $tanggal = date('d/m/Y', strtotime($r['tanggal'])); |
|
286 | 286 | |
287 | - ?> |
|
287 | + ?> |
|
288 | 288 | |
289 | 289 | <?php if ($tipe == 'R') { |
290 | - ?> |
|
290 | + ?> |
|
291 | 291 | |
292 | 292 | |
293 | 293 | <table width="100%"> |
@@ -314,14 +314,14 @@ discard block |
||
314 | 314 | <?php |
315 | 315 | $htampil = mysql_query("SELECT * FROM jenis_transaksi where aktif = 'Y' AND id_jenis_transaksi != '6' ORDER BY id_jenis_transaksi"); |
316 | 316 | |
317 | - $hjml = mysql_num_rows($htampil); |
|
317 | + $hjml = mysql_num_rows($htampil); |
|
318 | 318 | |
319 | - while ($h = mysql_fetch_array($htampil)) { |
|
320 | - echo '<tr>'; |
|
321 | - echo '<td>'.$h['jenis_transaksi'].'</td>'; |
|
319 | + while ($h = mysql_fetch_array($htampil)) { |
|
320 | + echo '<tr>'; |
|
321 | + echo '<td>'.$h['jenis_transaksi'].'</td>'; |
|
322 | 322 | |
323 | - //transaksi umum tunai |
|
324 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
323 | + //transaksi umum tunai |
|
324 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
325 | 325 | , IFNULL(SUM(c.jumlah),0) as rp |
326 | 326 | FROM kasir b LEFT JOIN kasir_detail c |
327 | 327 | ON b.id_kasir = c.id_kasir |
@@ -330,13 +330,13 @@ discard block |
||
330 | 330 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
331 | 331 | AND b.status != '4'"); |
332 | 332 | |
333 | - $d = mysql_fetch_array($dtampil); |
|
333 | + $d = mysql_fetch_array($dtampil); |
|
334 | 334 | |
335 | - echo '<th>'.$d['jml'].'</th>'; |
|
336 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
335 | + echo '<th>'.$d['jml'].'</th>'; |
|
336 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
337 | 337 | |
338 | - echo '</tr>'; |
|
339 | - } ?> |
|
338 | + echo '</tr>'; |
|
339 | + } ?> |
|
340 | 340 | |
341 | 341 | </tbody> |
342 | 342 | |
@@ -351,10 +351,10 @@ discard block |
||
351 | 351 | WHERE b.tanggal like '$prd%' |
352 | 352 | AND b.status != '4'"); |
353 | 353 | |
354 | - $d = mysql_fetch_array($dtampil); |
|
354 | + $d = mysql_fetch_array($dtampil); |
|
355 | 355 | |
356 | - echo '<th>'.$d['jml'].'</th>'; |
|
357 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; ?> |
|
356 | + echo '<th>'.$d['jml'].'</th>'; |
|
357 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; ?> |
|
358 | 358 | |
359 | 359 | </tr> |
360 | 360 | |
@@ -382,8 +382,8 @@ discard block |
||
382 | 382 | |
383 | 383 | |
384 | 384 | <?php |
385 | - } else { |
|
386 | - ?> |
|
385 | + } else { |
|
386 | + ?> |
|
387 | 387 | |
388 | 388 | <table width="100%"> |
389 | 389 | <tr> |
@@ -404,11 +404,11 @@ discard block |
||
404 | 404 | |
405 | 405 | $htampil = mysql_query("SELECT * FROM penjamin where aktif = 'Y' ORDER BY id_penjamin"); |
406 | 406 | |
407 | - $hjml = mysql_num_rows($htampil); |
|
407 | + $hjml = mysql_num_rows($htampil); |
|
408 | 408 | |
409 | - while ($h = mysql_fetch_array($htampil)) { |
|
410 | - echo "<th colspan='2' rowspan='2'>".$h['penjamin'].'</th>'; |
|
411 | - } ?> |
|
409 | + while ($h = mysql_fetch_array($htampil)) { |
|
410 | + echo "<th colspan='2' rowspan='2'>".$h['penjamin'].'</th>'; |
|
411 | + } ?> |
|
412 | 412 | |
413 | 413 | <th colspan ="4" >UMUM</th> |
414 | 414 | <th colspan ="2" rowspan='2'>TOTAL</th> |
@@ -425,10 +425,10 @@ discard block |
||
425 | 425 | |
426 | 426 | |
427 | 427 | <?php |
428 | - for ($j = 1; $j <= $hjml; $j++) { |
|
429 | - echo '<th>KUNJ</th>'; |
|
430 | - echo '<th>REV</th>'; |
|
431 | - } ?> |
|
428 | + for ($j = 1; $j <= $hjml; $j++) { |
|
429 | + echo '<th>KUNJ</th>'; |
|
430 | + echo '<th>REV</th>'; |
|
431 | + } ?> |
|
432 | 432 | |
433 | 433 | |
434 | 434 | <th>KUNJ</th> |
@@ -448,15 +448,15 @@ discard block |
||
448 | 448 | |
449 | 449 | $htampil = mysql_query("SELECT * FROM jenis_transaksi where aktif = 'Y' ORDER BY id_jenis_transaksi"); |
450 | 450 | |
451 | - $hjml = mysql_num_rows($htampil); |
|
451 | + $hjml = mysql_num_rows($htampil); |
|
452 | 452 | |
453 | - while ($h = mysql_fetch_array($htampil)) { |
|
454 | - echo'<tr>'; |
|
453 | + while ($h = mysql_fetch_array($htampil)) { |
|
454 | + echo'<tr>'; |
|
455 | 455 | |
456 | - echo'<td>'.$h['jenis_transaksi'].'</td>'; |
|
456 | + echo'<td>'.$h['jenis_transaksi'].'</td>'; |
|
457 | 457 | |
458 | - //transaksi asuransi |
|
459 | - $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
458 | + //transaksi asuransi |
|
459 | + $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
460 | 460 | , COUNT(c.jumlah) as jml |
461 | 461 | , IFNULL(SUM(c.jumlah),0) as rp |
462 | 462 | FROM penjamin a LEFT JOIN kasir b |
@@ -472,12 +472,12 @@ discard block |
||
472 | 472 | GROUP BY a.id_penjamin |
473 | 473 | ORDER BY a.id_penjamin"); |
474 | 474 | |
475 | - while ($d1 = mysql_fetch_array($dtampil1)) { |
|
476 | - echo "<td style='text-align:center;'>".$d1['jml'].'</td>'; |
|
477 | - echo "<td style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</td>'; |
|
478 | - } |
|
475 | + while ($d1 = mysql_fetch_array($dtampil1)) { |
|
476 | + echo "<td style='text-align:center;'>".$d1['jml'].'</td>'; |
|
477 | + echo "<td style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</td>'; |
|
478 | + } |
|
479 | 479 | |
480 | - $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
480 | + $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
481 | 481 | , IFNULL(SUM(c.jumlah),0) as rp |
482 | 482 | FROM kasir b LEFT JOIN kasir_detail c |
483 | 483 | ON b.id_kasir = c.id_kasir |
@@ -487,12 +487,12 @@ discard block |
||
487 | 487 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
488 | 488 | AND b.status != '4'"); |
489 | 489 | |
490 | - $d2 = mysql_fetch_array($dtampil2); |
|
490 | + $d2 = mysql_fetch_array($dtampil2); |
|
491 | 491 | |
492 | - echo "<td style='text-align:center;'>".$d2['jml'].'</td>'; |
|
493 | - echo "<td style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</td>'; |
|
492 | + echo "<td style='text-align:center;'>".$d2['jml'].'</td>'; |
|
493 | + echo "<td style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</td>'; |
|
494 | 494 | |
495 | - $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
495 | + $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
496 | 496 | , IFNULL(SUM(c.jumlah),0) as rp |
497 | 497 | FROM kasir b LEFT JOIN kasir_detail c |
498 | 498 | ON b.id_kasir = c.id_kasir |
@@ -502,12 +502,12 @@ discard block |
||
502 | 502 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
503 | 503 | AND b.status != '4'"); |
504 | 504 | |
505 | - $d3 = mysql_fetch_array($dtampil3); |
|
505 | + $d3 = mysql_fetch_array($dtampil3); |
|
506 | 506 | |
507 | - echo "<td style='text-align:center;'>".$d3['jml'].'</td>'; |
|
508 | - echo "<td style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</td>'; |
|
507 | + echo "<td style='text-align:center;'>".$d3['jml'].'</td>'; |
|
508 | + echo "<td style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</td>'; |
|
509 | 509 | |
510 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
510 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
511 | 511 | , IFNULL(SUM(c.jumlah),0) as rp |
512 | 512 | FROM kasir b LEFT JOIN kasir_detail c |
513 | 513 | ON b.id_kasir = c.id_kasir |
@@ -516,13 +516,13 @@ discard block |
||
516 | 516 | AND c.id_jenis_transaksi = '".$h['id_jenis_transaksi']."' |
517 | 517 | AND b.status != '4'"); |
518 | 518 | |
519 | - $d = mysql_fetch_array($dtampil); |
|
519 | + $d = mysql_fetch_array($dtampil); |
|
520 | 520 | |
521 | - echo "<td style='text-align:center;'>".$d['jml'].'</td>'; |
|
522 | - echo "<td style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</td>'; |
|
521 | + echo "<td style='text-align:center;'>".$d['jml'].'</td>'; |
|
522 | + echo "<td style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</td>'; |
|
523 | 523 | |
524 | - echo'</tr>'; |
|
525 | - } ?> |
|
524 | + echo'</tr>'; |
|
525 | + } ?> |
|
526 | 526 | |
527 | 527 | </tbody> |
528 | 528 | |
@@ -530,12 +530,12 @@ discard block |
||
530 | 530 | |
531 | 531 | <?php |
532 | 532 | |
533 | - echo'<tr>'; |
|
533 | + echo'<tr>'; |
|
534 | 534 | |
535 | - echo'<th>TOTAL</th>'; |
|
535 | + echo'<th>TOTAL</th>'; |
|
536 | 536 | |
537 | - //transaksi asuransi |
|
538 | - $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
537 | + //transaksi asuransi |
|
538 | + $dtampil1 = mysql_query("SELECT a.id_penjamin |
|
539 | 539 | , COUNT(c.jumlah) as jml |
540 | 540 | , IFNULL(SUM(c.jumlah),0) as rp |
541 | 541 | FROM penjamin a LEFT JOIN kasir b |
@@ -550,12 +550,12 @@ discard block |
||
550 | 550 | GROUP BY a.id_penjamin |
551 | 551 | ORDER BY a.id_penjamin"); |
552 | 552 | |
553 | - while ($d1 = mysql_fetch_array($dtampil1)) { |
|
554 | - echo '<th>'.$d1['jml'].'</th>'; |
|
555 | - echo "<th style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</th>'; |
|
556 | - } |
|
553 | + while ($d1 = mysql_fetch_array($dtampil1)) { |
|
554 | + echo '<th>'.$d1['jml'].'</th>'; |
|
555 | + echo "<th style='text-align:right;'>".number_format($d1['rp'], 0, '.', ',').'</th>'; |
|
556 | + } |
|
557 | 557 | |
558 | - $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
558 | + $dtampil2 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
559 | 559 | , IFNULL(SUM(c.jumlah),0) as rp |
560 | 560 | FROM kasir b LEFT JOIN kasir_detail c |
561 | 561 | ON b.id_kasir = c.id_kasir |
@@ -564,12 +564,12 @@ discard block |
||
564 | 564 | WHERE b.tanggal LIKE '$prd%' |
565 | 565 | AND b.status != '4'"); |
566 | 566 | |
567 | - $d2 = mysql_fetch_array($dtampil2); |
|
567 | + $d2 = mysql_fetch_array($dtampil2); |
|
568 | 568 | |
569 | - echo '<th>'.$d2['jml'].'</th>'; |
|
570 | - echo "<th style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</th>'; |
|
569 | + echo '<th>'.$d2['jml'].'</th>'; |
|
570 | + echo "<th style='text-align:right;'>".number_format($d2['rp'], 0, '.', ',').'</th>'; |
|
571 | 571 | |
572 | - $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
572 | + $dtampil3 = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
573 | 573 | , IFNULL(SUM(c.jumlah),0) as rp |
574 | 574 | FROM kasir b LEFT JOIN kasir_detail c |
575 | 575 | ON b.id_kasir = c.id_kasir |
@@ -578,12 +578,12 @@ discard block |
||
578 | 578 | WHERE b.tanggal LIKE '$prd%' |
579 | 579 | AND b.status != '4'"); |
580 | 580 | |
581 | - $d3 = mysql_fetch_array($dtampil3); |
|
581 | + $d3 = mysql_fetch_array($dtampil3); |
|
582 | 582 | |
583 | - echo '<th>'.$d3['jml'].'</th>'; |
|
584 | - echo "<th style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</th>'; |
|
583 | + echo '<th>'.$d3['jml'].'</th>'; |
|
584 | + echo "<th style='text-align:right;'>".number_format($d3['rp'], 0, '.', ',').'</th>'; |
|
585 | 585 | |
586 | - $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
586 | + $dtampil = mysql_query("SELECT COUNT(c.jumlah) as jml |
|
587 | 587 | , IFNULL(SUM(c.jumlah),0) as rp |
588 | 588 | FROM kasir b LEFT JOIN kasir_detail c |
589 | 589 | ON b.id_kasir = c.id_kasir |
@@ -591,12 +591,12 @@ discard block |
||
591 | 591 | WHERE b.tanggal like '$prd%' |
592 | 592 | AND b.status != '4'"); |
593 | 593 | |
594 | - $d = mysql_fetch_array($dtampil); |
|
594 | + $d = mysql_fetch_array($dtampil); |
|
595 | 595 | |
596 | - echo '<th>'.$d['jml'].'</th>'; |
|
597 | - echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
596 | + echo '<th>'.$d['jml'].'</th>'; |
|
597 | + echo "<th style='text-align:right;'>".number_format($d['rp'], 0, '.', ',').'</th>'; |
|
598 | 598 | |
599 | - echo'</tr>'; ?> |
|
599 | + echo'</tr>'; ?> |
|
600 | 600 | |
601 | 601 | |
602 | 602 | |
@@ -610,17 +610,17 @@ discard block |
||
610 | 610 | |
611 | 611 | $lastday = date('t', strtotime($iprd)); |
612 | 612 | |
613 | - $year = date('Y', strtotime($iprd)); |
|
613 | + $year = date('Y', strtotime($iprd)); |
|
614 | 614 | |
615 | - $month = date('m', strtotime($iprd)) * 1; |
|
615 | + $month = date('m', strtotime($iprd)) * 1; |
|
616 | 616 | |
617 | - if ($month == '1') { |
|
618 | - $imonth = 12; |
|
619 | - } else { |
|
620 | - $imonth = $month - 1; |
|
621 | - } |
|
617 | + if ($month == '1') { |
|
618 | + $imonth = 12; |
|
619 | + } else { |
|
620 | + $imonth = $month - 1; |
|
621 | + } |
|
622 | 622 | |
623 | - $nprd = $lastday.' '.getBulan1($imonth).' '.$year; ?> |
|
623 | + $nprd = $lastday.' '.getBulan1($imonth).' '.$year; ?> |
|
624 | 624 | |
625 | 625 | <table width="100%"> |
626 | 626 | |
@@ -643,7 +643,7 @@ discard block |
||
643 | 643 | |
644 | 644 | |
645 | 645 | <?php |
646 | - } ?> |
|
646 | + } ?> |
|
647 | 647 | |
648 | 648 | </body> |
649 | 649 |
@@ -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; |
@@ -166,7 +166,7 @@ discard block |
||
166 | 166 | |
167 | 167 | <?php |
168 | 168 | $gtampil = mysql_query("SELECT * FROM informasi_perusahaan where id_informasi_perusahaan = '1'"); |
169 | - $g = mysql_fetch_array($gtampil); |
|
169 | + $g = mysql_fetch_array($gtampil); |
|
170 | 170 | |
171 | 171 | if ($g['pict']) { |
172 | 172 | $pict = $g['pict']; |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | |
211 | 211 | <?php |
212 | 212 | |
213 | - $tampil = mysql_query("SELECT b.obat |
|
213 | + $tampil = mysql_query("SELECT b.obat |
|
214 | 214 | , c.satuan |
215 | 215 | , sum(a.qty) as jumlah |
216 | 216 | FROM kunjungan_berobat h inner join kunjungan_berobat_detail a |
@@ -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 |
@@ -371,11 +371,11 @@ |
||
371 | 371 | <!-- /editor --> |
372 | 372 | |
373 | 373 | <?php |
374 | - if (empty($pict)) { |
|
375 | - $ipict = 'logo.png'; |
|
376 | - } else { |
|
377 | - $ipict = $pict; |
|
378 | - } ?> |
|
374 | + if (empty($pict)) { |
|
375 | + $ipict = 'logo.png'; |
|
376 | + } else { |
|
377 | + $ipict = $pict; |
|
378 | + } ?> |
|
379 | 379 | |
380 | 380 | <script> |
381 | 381 | var btnCust = '<button type="button" class="btn btn-default" title="Add picture tags" ' + |
@@ -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'); |