62 |
('quantity',_('Units'), '%s', 0), |
('quantity',_('Units'), '%s', 0), |
63 |
('description',_('Description'), '%s', 0), |
('description',_('Description'), '%s', 0), |
64 |
('each',_('Price/Unit'), dollarFormat, 1), |
('each',_('Price/Unit'), dollarFormat, 1), |
65 |
('extended',_('Extended'), dollarFormat, 1) ) |
('extended',_('Extended'), dollarFormat, 1), |
66 |
|
('taxable',_('T'), '%s', 1) ) |
67 |
|
|
68 |
self.totalFieldMapping = {} |
self.totalFieldMapping = {} |
69 |
|
|
113 |
# TODO |
# TODO |
114 |
for field, foo, format, bar in self.receiptColumns: |
for field, foo, format, bar in self.receiptColumns: |
115 |
try: |
try: |
116 |
self.output.write(format % event.__dict__[field]+' ') |
if field == 'taxable': |
117 |
|
if event['taxable']: |
118 |
|
self.output.write('* ') |
119 |
|
else: |
120 |
|
self.output.write(' ') |
121 |
|
else: |
122 |
|
self.output.write(format % event.__dict__[field]+' ') |
123 |
except KeyError: |
except KeyError: |
124 |
pass |
pass |
125 |
self.output.write("\n") |
self.output.write("\n") |