biweeklybudget.models.transaction module¶
-
class
biweeklybudget.models.transaction.
Transaction
(**kwargs)[source]¶ Bases:
sqlalchemy.ext.declarative.api.Base
,biweeklybudget.models.base.ModelAsDict
-
_sa_class_manager
= {'account': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cf6b0>, 'account_id': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfef0>, 'actual_amount': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfbf0>, 'budget': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cf8f0>, 'budget_id': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707eb0b0>, 'budgeted_amount': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfcb0>, 'date': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfb30>, 'description': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfd70>, 'id': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfa70>, 'notes': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cfe30>, 'scheduled_trans': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cf830>, 'scheduled_trans_id': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cffb0>, 'transfer': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707cf9b0>, 'transfer_id': <sqlalchemy.orm.attributes.InstrumentedAttribute object at 0x7f8f707eb170>}¶
-
account_id
¶ ID of the account this transaction is against
-
actual_amount
¶ Actual amount of the transaction
-
budget_id
¶ ID of the Budget this transaction is against
-
budgeted_amount
¶ Budgeted amount of the transaction
-
date
¶ date of the transaction
-
description
¶ description
-
id
¶ Primary Key
-
notes
¶ free-form notes
-
scheduled_trans
¶ Relationship - the
ScheduledTransaction
this Transaction was created from; set when a scheduled transaction is converted to a real one
-
scheduled_trans_id
¶ ID of the ScheduledTransaction this Transaction was created from; set when a scheduled transaction is converted to a real one
-
transfer
¶ Relationship - the
Transaction
that makes up the other half/side of a transfer, if this transaction was for a transfer.
-
transfer_id
¶ If the transaction is one half of a transfer, the Transaction ID of the other half/side of the transfer.
-
static
unreconciled
(db)[source]¶ Return a query to match all unreconciled Transactions.
Parameters: db (sqlalchemy.orm.session.Session) – active database session to use for queries Returns: query to match all unreconciled Transactions Return type: sqlalchemy.orm.query.Query
-