From 0a149eaa0f1e8f353c07071d5225ca5e737f247c Mon Sep 17 00:00:00 2001 From: zzlgreat Date: Sun, 23 Nov 2025 23:17:12 +0800 Subject: [PATCH] update pay function --- app.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app.py b/app.py index eae07914..edf95661 100755 --- a/app.py +++ b/app.py @@ -4633,7 +4633,7 @@ class PredictionTransaction(db.Model): topic_id = db.Column(db.Integer, db.ForeignKey('prediction_topic.id'), nullable=False) # 交易信息 - transaction_type = db.Column(db.String(10), nullable=False) # buy/sell + trade_type = db.Column(db.String(10), nullable=False) # buy/sell direction = db.Column(db.String(3), nullable=False) # yes/no shares = db.Column(db.Integer, nullable=False) # 份额数量 price = db.Column(db.Float, nullable=False) # 成交价格 @@ -4650,7 +4650,7 @@ class PredictionTransaction(db.Model): user = db.relationship('User', backref='prediction_transactions') def __repr__(self): - return f'' + return f'' class CreditTransaction(db.Model): @@ -13987,7 +13987,7 @@ def buy_prediction_shares(): transaction = PredictionTransaction( user_id=current_user.id, topic_id=topic_id, - transaction_type='buy', + trade_type='buy', direction=direction, shares=shares, price=avg_price,