TaleLin / lin-cms-flask

🎀A simple and practical CMS implememted by Flask
http://doc.cms.talelin.com/
Other
832 stars 216 forks source link

登录的时候,再做一下逻辑判断,需要在哪个位置写业务 #174

Closed sunchangpu closed 3 years ago

sunchangpu commented 3 years ago

我想在登录的时候,再做一下逻辑判断(比如用户会员是否已经到期,expire_time这个字段已经放进去了),应该在哪里写业务逻辑的 ?

这句话是做用户名,密码是否正确判断的的么?user = manager.user_model.verify(form.username.data, form.password.data)

image

sunchangpu commented 3 years ago

image

sunchangpu commented 3 years ago

image 就是想找到这个判断密码错误的位置,去加个是否过期的判断

sunlin92 commented 3 years ago

图片

sunchangpu commented 3 years ago

3q ,搞定