Skip to content

Commit

Permalink
* previous_outpoint_index changed to Integer (#31)
Browse files Browse the repository at this point in the history
* No ForeignKey needed
  • Loading branch information
lAmeR1 authored Aug 23, 2023
1 parent e54d2d1 commit 62889c3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions models/Transaction.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from sqlalchemy import Column, String, Integer, BigInteger, Boolean, ForeignKey, Index
from sqlalchemy.dialects.postgresql import ARRAY
from sqlalchemy import Column, String, Integer, BigInteger, Boolean, ARRAY, Index

from dbsession import Base

Expand All @@ -24,7 +23,7 @@ class Transaction(Base):
class TransactionOutput(Base):
__tablename__ = 'transactions_outputs'
id = Column(Integer, primary_key=True)
transaction_id = Column(String, ForeignKey('transactions.transaction_id'))
transaction_id = Column(String)
index = Column(Integer)
amount = Column(BigInteger)
script_public_key = Column(String)
Expand All @@ -45,7 +44,7 @@ class TransactionInput(Base):
index = Column(Integer)

previous_outpoint_hash = Column(String) # "ebf6da83db96d312a107a2ced19a01823894c9d7072ed0d696a9a152fd81485e"
previous_outpoint_index = Column(String) # "ebf6da83db96d312a107a2ced19a01823894c9d7072ed0d696a9a152fd81485e"
previous_outpoint_index = Column(Integer) # "ebf6da83db96d312a107a2ced19a01823894c9d7072ed0d696a9a152fd81485e"

signature_script = Column(String) # "41c903159094....281a1d26f70b0037d600554e01",
sig_op_count = Column(Integer)
Expand Down

0 comments on commit 62889c3

Please sign in to comment.