python - django如何创建两个用户表?
大家讲道理
大家讲道理 2017-04-18 09:46:45
0
1
319

想知道django如何能有两个用户表。
教师表和学生表,都要实现登录。
如果可以,登录的时候应该怎么写,一定要重写auth?

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(1)
伊谢尔伦

There is no need to use two tables. Add a field to the user table to identify whether the user is a teacher or a student.
When logging in, just check this field.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template