diff --git a/accountant/api/models/operations.py b/accountant/api/models/operations.py index 718099d..b26eaee 100644 --- a/accountant/api/models/operations.py +++ b/accountant/api/models/operations.py @@ -42,13 +42,13 @@ class Operation(db.Model): ) scheduled_operation = db.relationship( - "ScheduledOperation", backref=db.backref('entry', lazy="dynamic") + "ScheduledOperation", backref=db.backref('operations', lazy="dynamic") ) account_id = db.Column(db.Integer, db.ForeignKey('account.id'), index=True) account = db.relationship( - 'Account', backref=db.backref('operation', lazy="dynamic") + 'Account', backref=db.backref('operations', lazy="dynamic") ) category = db.Column(db.String(100), nullable=True, index=True)