shiftSaleReport2.php 739 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. require "connectionDb.php";
  3. $date = $_GET['selectDateToFind'];
  4. $date = str_replace('-', '_', $date);
  5. $shiftnum = 2;
  6. $shiftTankReport2 = $db->query("SELECT * FROM shift_sale_vw WHERE date='$date'");
  7. print_r("<tr>
  8. <th>Pump Number</th>
  9. <th>Fuel Grade</th>
  10. <th>Unit Price</th>
  11. <th>Volume</th>
  12. <th>Amount</th>
  13. </tr>");
  14. while ($row = $shiftTankReport2->fetchArray()) {
  15. if ($row['number']==$shiftnum) {
  16. print_r(
  17. "<tr>"
  18. ."<td>".$row['fp_id']."</td>"
  19. ."<td>".$row['grade_name']."</td>"
  20. ."<td>".decimalAndNumberFormat1($row['price'])."</td>"
  21. ."<td>".decimalAndNumberFormat1($row['volume'])."</td>"
  22. ."<td>".decimalAndNumberFormat1($row['amount'])."</td>"
  23. ."</tr>"
  24. );
  25. }
  26. }
  27. ?>