feature/4-patient-doctor-management #24

Merged
luis_portillo merged 11 commits from feature/4-patient-doctor-management into dev 2025-07-14 04:53:51 +00:00
2 changed files with 17 additions and 0 deletions
Showing only changes of commit 40deb136d5 - Show all commits

View File

@ -1 +1,2 @@
# -*- coding: utf-8 -*-
from . import partner

View File

@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
from odoo import models, fields, api
class ResPartner(models.Model):
_inherit = 'res.partner'
is_patient = fields.Boolean(string="Es Paciente")
patient_identifier = fields.Char(string="Identificador de Paciente", copy=False)
is_doctor = fields.Boolean(string="Es Médico")
doctor_license = fields.Char(string="Licencia Médica", copy=False)
_sql_constraints = [
('patient_identifier_unique', 'unique(patient_identifier)', 'El identificador del paciente debe ser único.'),
('doctor_license_unique', 'unique(doctor_license)', 'La licencia médica debe ser única.')
]