File tree Expand file tree Collapse file tree 7 files changed +22
-11
lines changed Expand file tree Collapse file tree 7 files changed +22
-11
lines changed Original file line number Diff line number Diff line change 3131 exit ();
3232}
3333
34- $ sql = 'SELECT l.id, p.price AS price
34+ $ sql = 'SELECT l.id, l.kilo, p.price AS price
3535 FROM laundry AS l
3636 JOIN transactions AS t ON l.transaction_id = t.id
3737 JOIN prices AS p ON l.type = p.id
4343
4444$ total_price = 0 ;
4545foreach ($ results as $ row ) {
46- $ total_price += $ row ['price ' ];
46+ $ total_price += $ row ['price ' ] * $ row [ ' kilo ' ] ;
4747}
4848
4949echo $ total_price ;
Original file line number Diff line number Diff line change 1414$ lastname = $ fullname [1 ];
1515?>
1616 <tr>
17- <td># <?php echo $ row ['id ' ]; ?> </td>
17+ <td><?php echo $ row ['id ' ]; ?> </td>
1818 <td><img class="rounded-circle me-2" width="30" height="30" src="assets/img/profile.png"><?php echo $ row ['fullname ' ]; ?> </td>
1919 <td><?php echo $ row ['address ' ]; ?> </td>
2020 <td><?php echo $ row ['contact ' ]; ?> </td>
Original file line number Diff line number Diff line change 2828 }
2929
3030 echo '<tr> ' ;
31- echo '<td># ' . $ row ['id ' ] . '</td> ' ;
31+ echo '<td> ' . $ row ['id ' ] . '</td> ' ;
3232 echo '<td><img class="rounded-circle me-2" width="30" height="30" src="assets/img/profile.png"> ' . $ row ['fullname ' ] . '</td> ' ;
3333 echo '<td><img class="rounded-circle me-2" width="30" height="30" src="assets/img/profile.png"> ' . $ row ['username ' ] . '</td> ' ;
3434 echo '<td> ' . $ row ['kilo ' ] . '</td> ' ;
Original file line number Diff line number Diff line change 1313
1414 ?>
1515 <tr>
16- <td># <?php echo $ row ['id ' ]; ?> </td>
16+ <td><?php echo $ row ['id ' ]; ?> </td>
1717 <td><img class="rounded-circle me-2" width="30" height="30" src="assets/img/profile.png"><?php echo $ row ['username ' ]; ?> </td>
1818 <td><?php echo $ row ['created_at ' ]; ?> </td>
1919 <td class="text-center">
Original file line number Diff line number Diff line change 1111
1212?>
1313 <tr>
14- <td># <?php echo $ row ['id ' ]; ?> </td>
14+ <td><?php echo $ row ['id ' ]; ?> </td>
1515 <td><?php echo $ row ['name ' ]; ?> </td>
1616 <td><?php echo $ row ['unit ' ]; ?> </td>
1717 <td><?php echo $ row ['stock ' ]; ?> </td>
Original file line number Diff line number Diff line change 107107 <script src="assets/js/vfs_fonts.js"></script>
108108 <script src="assets/js/buttons.html5.min.js"></script>
109109 <script src="assets/js/buttons.print.min.js"></script>
110- <script src="assets/js/listTable.js"></script>
111110 <script src="assets/js/theme.js"></script>
112111 <script src="assets/js/sweetalert.min.js"></script>
113112 <script>
119118 } else if (type == 'error') {
120119 swal("Error!", message, "error");
121120 }
122-
121+ $(document).ready(function() {
122+ $('#dataTable').DataTable( {
123+ dom: 'Blfrtip',
124+ aaSorting: [[0, 'desc']],
125+ buttons: [
126+ { extend: 'excel', className: 'btn btn-primary' },
127+ { extend: 'pdf', className: 'btn btn-primary' },
128+ { extend: 'print', className: 'btn btn-primary' }
129+ ]
130+ } );
131+
132+
133+ } );
123134 </script>
124135</body>
125136
Original file line number Diff line number Diff line change 7474 ?>
7575 <div class="d-flex justify-content-between align-items-center mb-5">
7676 <div>
77- <h2 class="mb-0 ">Queue <span class="text-primary font-weight-bold">#<?php echo $ queue_number ; ?> </span></h2>
78- <h4 class="mb-0">Type - <span class="text-primary font-weight-bold"><?php echo $ row ['name ' ]; ?> </span></h4 >
79- <h4 class="mb-0">Load - <span class="text-primary font-weight-bold"><?php echo $ row ['kilo ' ]; ?> kg</span></h4 >
77+ <h2 class="mb-2 ">Queue <span class="text-primary font-weight-bold">#<?php echo $ queue_number ; ?> </span></h2>
78+ <h5 class="mb-0 ms-5 font-monospace ">Type - <span class="text-primary font-weight-bold"><?php echo $ row ['name ' ]; ?> </span></h5 >
79+ <h5 class="mb-0 ms-5 font-monospace ">Load - <span class="text-primary font-weight-bold"><?php echo $ row ['kilo ' ]; ?> kg</span></h5 >
8080 </div>
8181 </div>
8282 <div class="progress d-flex justify-content-between d-flex justify-content-between mx-0 mt-0 mb-5">
You can’t perform that action at this time.
0 commit comments