repr role as self.name

This commit is contained in:
deflax 2024-04-05 15:57:34 +03:00
parent 8ee8025046
commit 876d6c1069

View file

@ -51,7 +51,8 @@ class Role(db.Model):
db.session.commit() db.session.commit()
def __repr__(self): def __repr__(self):
return '<Role %r>' % self.name #return '<Role %r>' % self.name
return self.name
class User(db.Model, UserMixin): class User(db.Model, UserMixin):
__tablename__ = 'users' __tablename__ = 'users'