16 lines
492 B
Python
16 lines
492 B
Python
from odoo import models, fields, api
|
|
|
|
class SchoolUser(models.Model):
|
|
_name = 'school.user'
|
|
_description = 'School User'
|
|
|
|
name = fields.Char(string="Name", required=True)
|
|
login = fields.Char(string="Login", required=True)
|
|
password = fields.Char(string="Password", required=True)
|
|
role = fields.Selection([
|
|
('admin', 'Admin'),
|
|
('teacher', 'Teacher'),
|
|
('parent', 'Parent'),
|
|
('student', 'Student'),
|
|
], required=True, default='student')
|