Add a consumption helper and fold the golden fee into the amount
This commit is contained in:
1 parent
55ec92d3cf
commit
0eda493ac7
1 file changed
+10
@@ -99,6 +99,16 @@ def lots_of(market_id):
|
|||||||
conn.close()
|
conn.close()
|
||||||
|
|
||||||
|
|
||||||
|
def consumptions(tx_id):
|
||||||
|
conn = database.connect()
|
||||||
|
try:
|
||||||
|
return [dict(row) for row in conn.execute(
|
||||||
|
"SELECT * FROM lot_consumptions WHERE tx_id = ? ORDER BY id", (tx_id,)
|
||||||
|
).fetchall()]
|
||||||
|
finally:
|
||||||
|
conn.close()
|
||||||
|
|
||||||
|
|
||||||
class TaxTestCase(unittest.TestCase):
|
class TaxTestCase(unittest.TestCase):
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
self._directory = tempfile.TemporaryDirectory()
|
self._directory = tempfile.TemporaryDirectory()
|
||||||
|
|||||||
Reference in new issue
Block a user