Untitled

mail@pastecode.io avatar
unknown
plain_text
a year ago
2.6 kB
6
Indexable
Never
    __tablename__ = 'checkbook_transaction'

    id = db.Column(db.String(1024), primary_key=True)
    trace_number = db.Column(db.Integer, Sequence('trace_number_seq'))
    debit_user_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_user.id'), nullable=False)
    credit_user_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_user.id'), nullable=True)
    originator_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_user.id'), nullable=True)
    debit_account_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_bank_account.id'), nullable=False)
    credit_account_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_bank_account.id'), nullable=True)
    debit_processor_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_processor.id'), nullable=True)
    credit_processor_id = db.Column(
        db.String(1024), db.ForeignKey('checkbook_processor.id'), nullable=True)
    bill_id = db.Column(db.String(1024), db.ForeignKey('checkbook_billing.id'), nullable=True)
    bill_amount = db.Column(Numeric(19, 2), nullable=True)
    amount = db.Column(Numeric(19, 2), nullable=False)
    aggregated_amount = db.Column(Numeric(19, 2), nullable=True)
    status = db.Column(ENUM('READY', 'DEBIT_CREATED', 'COMPLETED',
                            'CREDIT_FAILED', 'CANCELED', 'REFUNDED',
                            'DEBIT_FAILED', name='txn_status'), nullable=False)
    description = db.Column(db.String(1024), nullable=True)
    return_code = db.Column(db.String(256), nullable=True)
    conditional_return_code = db.Column(db.String(256), nullable=True)
    debit_created_ts = db.Column(TIMESTAMP, nullable=True)
    credit_created_ts = db.Column(TIMESTAMP, nullable=True)
    comment = db.Column(HSTORE, default={}, nullable=False)
    failed_ts = db.Column(TIMESTAMP, nullable=True)
    ip_address = db.Column(INET, nullable=True)
    on_hold = db.Column(db.Boolean(), server_default="f", nullable=False)
    instant = db.Column(db.Boolean(), server_default="f", nullable=False)
    effective_date_debit = db.Column(Date, nullable=True)
    effective_date_credit = db.Column(Date, nullable=True)
    rtp_processing = db.Column(db.Boolean(), server_default="f", nullable=False)
    created_ts = db.Column(
        TIMESTAMP, server_default=text('CURRENT_TIMESTAMP'), nullable=False)
    updated_ts = db.Column(
        TIMESTAMP, default=db.func.now(), nullable=False)
    reconciled_ts = db.Column(TIMESTAMP, nullable=True)
    uuid = db.Column(db.String(1024), nullable=True)