shiftTankReport1.php 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. <?php
  2. require "connectionDb.php";
  3. $date = $_GET['selectDateToFind'];
  4. $date = str_replace('-', '_', $date);
  5. $shiftnum = 1;
  6. $shiftTankReport1 = $db->query("SELECT * FROM shift_tank_vw WHERE date='$date'");
  7. print_r("<tr>
  8. <th>Tank Number</th>
  9. <th>Product Text</th>
  10. <th>Open Volume</th>
  11. <th>Close Volume</th>
  12. <th>Open Water Volume</th>
  13. <th>Close Water Volume</th>
  14. <th>Open Level</th>
  15. <th>Close Level</th>
  16. </tr>");
  17. while ($row = $shiftTankReport1->fetchArray()) {
  18. if ($row['number']==$shiftnum) {
  19. print_r(
  20. "<tr>"
  21. ."<td>".$row['tank_id']."</td>"
  22. ."<td>".$row['product_text']."</td>"
  23. ."<td>".decimalAndNumberFormat1($row['open_vol'])."</td>"
  24. ."<td>".decimalAndNumberFormat1($row['close_vol'])."</td>"
  25. ."<td>".decimalAndNumberFormat1($row['open_water_vol'])."</td>"
  26. ."<td>".decimalAndNumberFormat1($row['close_water_vol'])."</td>"
  27. ."<td>".decimalAndNumberFormat2($row['open_level'])."</td>"
  28. ."<td>".decimalAndNumberFormat2($row['close_level'])."</td>"
  29. ."</tr>"
  30. );
  31. }
  32. }
  33. ?>