getYearCycleDates(); $counts = []; if($locations) { $location_ids_csv = implode(", ", array_column($locations, "id")); $sql = "SELECT `location_id`, COUNT(`id`) AS `test_count`, SUM(IF(`retest` = 1, 1, 0)) AS `retest_count` FROM `test` WHERE `location_id` IN ($location_ids_csv) AND `dts_start` BETWEEN '$date_start' AND '$date_end' GROUP BY `location_id`"; $result = DB::query($sql); while($row = DB::fetchAssoc($result)) { $counts[$row["location_id"]] = $row; } } ?>
isArchived()) $class = "text-muted"; $test_count = $counts[$location->id]["test_count"] ?? 0; $retest_count = $counts[$location->id]["retest_count"] ?? 0; ?>
ID Name / Address Legal Entity Internal ID Tests Retests
id?> name)?> closed) { ?> Closed isArchived()) { ?>
getDisplayAddress(["address_1", "address_2", "city", "postal_code"]))?>
legal_entity_name)?> internal_id)?> Edit
No locations to display.