diff --git a/flask_paycomuz/__init__.py b/flask_paycomuz/__init__.py index bc70433..b26aa05 100644 --- a/flask_paycomuz/__init__.py +++ b/flask_paycomuz/__init__.py @@ -22,7 +22,7 @@ class Payme_Transaction(db.Model): amount = db.Column(db.Integer, nullable=True) state = db.Column(db.Integer, default=1) created_at = db.Column(db.BigInteger, nullable=False) - reason = db.Column(db.String, nullable=True) + reason = db.Column(db.Integer, nullable=True) account = db.relationship('Payme_Account', backref='payme_transaction') def result(self): diff --git a/flask_paycomuz/views.py b/flask_paycomuz/views.py index 1f94edc..67d5081 100644 --- a/flask_paycomuz/views.py +++ b/flask_paycomuz/views.py @@ -100,7 +100,7 @@ def CancelTransaction(self,data): if tr.state == 1: tr.state = -1 tr.time = int(time.time() * 1000) - tr.reason = data['params']['reason'] + tr.reason = int(data['params']['reason']) self.db.session.add(tr) self.db.session.commit() return { diff --git a/setup.py b/setup.py index 86d133e..4fef3a8 100644 --- a/setup.py +++ b/setup.py @@ -182,7 +182,7 @@ class Payme_Account(db.Model): setup( name='Flask-PaycomUz', - version='1.2.4', + version='1.2.5', url='https://github.com/Odya-LLC/flask_paycomuz', license='MIT', author='odya',