Просмотр исходного кода

Update CSV exports to be aware of custom labels for regions, brand and area managers

Alan Lam 1 год назад
Родитель
Сommit
e142f004a2

+ 7 - 1
template_processing/age_verification/project_csv.php

@@ -9,11 +9,17 @@
 
 $config = $template->getConfiguration();
 
+$customer = $template->getCustomer();
+
+$brand_label = $customer->getBrandLabel(1);
+$region_label = $customer->getRegionLabel(1);
+$area_manager_label = $customer->getAreaManagerLabel(1);
+
 $field_names = [
 	"Project ID", "Project Name",
 	"Template Name",
 	"Test ID", "Test Status", "Test Void", "Gaming Void", "Alcohol Void", "Test Result",
-	"Location Name", "Legal Entity", "Address", "Email", "Phone", "Brand", "Region", "Internal ID", "Area Manager",
+	"Location Name", "Legal Entity", "Address", "Email", "Phone", $brand_label, $region_label, "Internal ID", $area_manager_label,
 	"Tester Age", "Tester Gender", "Travel Costs",
 
 	"Date", "Start Time", "End Time", "Duration",

+ 7 - 1
template_processing/age_verification/project_customer_csv.php

@@ -10,9 +10,15 @@
 
 $config = $template->getConfiguration();
 
+$customer = $template->getCustomer();
+
+$brand_label = $customer->getBrandLabel(1);
+$region_label = $customer->getRegionLabel(1);
+$area_manager_label = $customer->getAreaManagerLabel(1);
+
 $field_names = [
 	"Test Result", "Test Void",
-	"Location Name", "Address", "Brand", "Region", "Internal ID", "Area Manager",
+	"Location Name", "Address", $brand_label, $region_label, "Internal ID", $area_manager_label,
 
 	"Date",
 	"All-Time Test Count", "Current Year Period Test Count"