Skip to content

Commit 31000f3

Browse files
authored
Merge pull request #226 from QuanMPhm/221/cluster_name
Added `Cluster Name` column to storage invoice
2 parents fcd7dd1 + 934b06a commit 31000f3

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/coldfront_plugin_cloud/management/commands/calculate_storage_gb_hours.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ class InvoiceRow:
4141
Project_Name: str = ""
4242
Project_ID: str = ""
4343
PI: str = ""
44+
Cluster_Name: str = ""
4445
Invoice_Email: str = ""
4546
Invoice_Address: str = ""
4647
Institution: str = ""
@@ -211,6 +212,7 @@ def process_invoice_row(allocation, attrs, su_name, rate):
211212
attributes.ALLOCATION_PROJECT_ID
212213
),
213214
PI=allocation.project.pi.email,
215+
Cluster_Name=allocation.resources.first().resource_type.name.lower(),
214216
Institution_Specific_Code=allocation.get_attribute(
215217
attributes.ALLOCATION_INSTITUTION_SPECIFIC_CODE
216218
)

0 commit comments

Comments
 (0)