From db048fd00b24a90b5dfabc43859769fa9f74b7a6 Mon Sep 17 00:00:00 2001 From: Kristi Nikolla Date: Wed, 1 May 2024 10:47:27 -0400 Subject: [PATCH] Return PI email in storage invoices This switches the PI field in invoices to use email instead. --- .../management/commands/calculate_storage_gb_hours.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/coldfront_plugin_cloud/management/commands/calculate_storage_gb_hours.py b/src/coldfront_plugin_cloud/management/commands/calculate_storage_gb_hours.py index dc3edfb..b1bad40 100644 --- a/src/coldfront_plugin_cloud/management/commands/calculate_storage_gb_hours.py +++ b/src/coldfront_plugin_cloud/management/commands/calculate_storage_gb_hours.py @@ -154,7 +154,7 @@ def process_invoice_row(allocation, attrs, su_name, rate): InvoiceMonth=options['invoice_month'], Project_Name=allocation.get_attribute(attributes.ALLOCATION_PROJECT_NAME), Project_ID=allocation.get_attribute(attributes.ALLOCATION_PROJECT_ID), - PI=allocation.project.pi, + PI=allocation.project.pi.email, Institution_Specific_Code=allocation.get_attribute( attributes.ALLOCATION_INSTITUTION_SPECIFIC_CODE ) or "N/A",