From 69efec1888955aacd8fe2e2b0dd10a2176706db5 Mon Sep 17 00:00:00 2001 From: Brett Smith Date: Fri, 28 Sep 2018 08:34:47 -0400 Subject: [PATCH] nbpy2017: Rename _RATE constants to _RBI. This is a nonfunctional change that's just meant to better document what these values actually represent. --- import2ledger/importers/nbpy2017.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/import2ledger/importers/nbpy2017.py b/import2ledger/importers/nbpy2017.py index c0109ca..71686f4 100644 --- a/import2ledger/importers/nbpy2017.py +++ b/import2ledger/importers/nbpy2017.py @@ -10,10 +10,10 @@ STATUS_PAID = 'Payment' STATUS_REFUNDED = 'Refund' class Invoice2017: - STANDARD_TICKET_RATE = decimal.Decimal('42.50') - DISCOUNT_TICKET_RATE = STANDARD_TICKET_RATE / 2 - STANDARD_SHIRT_RATE = decimal.Decimal('25.50') - DISCOUNT_SHIRT_RATE = STANDARD_SHIRT_RATE + STANDARD_TICKET_RBI = decimal.Decimal('42.50') + DISCOUNT_TICKET_RBI = STANDARD_TICKET_RBI / 2 + STANDARD_SHIRT_RBI = decimal.Decimal('25.50') + DISCOUNT_SHIRT_RBI = STANDARD_SHIRT_RBI CURRENCY = 'USD' @classmethod @@ -78,9 +78,9 @@ class Invoice2017: def _read_invoice_items(self, table, first_row_text, rows_text): self.amount = decimal.Decimal(0) self.tickets_sold = decimal.Decimal(0) - self.ticket_rate = self.STANDARD_TICKET_RATE + self.ticket_rate = self.STANDARD_TICKET_RBI self.shirts_sold = decimal.Decimal(0) - self.shirt_rate = self.STANDARD_SHIRT_RATE + self.shirt_rate = self.STANDARD_SHIRT_RBI for description, qty, unit_price, total in rows_text: if qty is None: continue @@ -92,7 +92,7 @@ class Invoice2017: elif description.startswith('T-Shirt - '): self.shirts_sold += int(qty) elif description.startswith('Early Bird ('): - self.ticket_rate = self.DISCOUNT_TICKET_RATE + self.ticket_rate = self.DISCOUNT_TICKET_RBI def _read_invoice_activity(self, table, first_row_text, rows_text): self.actions = [{