bemade_sports_clinic: fixed an error in the record rules that caused DB admins to be unable to create patients.
This commit is contained in:
parent
a37acac519
commit
017f95d15f
2 changed files with 3 additions and 3 deletions
|
|
@ -1,7 +1,7 @@
|
|||
from odoo import models, fields, _, api
|
||||
from odoo.exceptions import ValidationError
|
||||
from datetime import date
|
||||
from dateutil import relativedelta
|
||||
from dateutil.relativedelta import relativedelta
|
||||
|
||||
|
||||
class Patient(models.Model):
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<record id="restrict_team_access_to_team_players" model="ir.rule">
|
||||
<field name="name">Restrict Team Staff Access to Their Players Only</field>
|
||||
<field name="model_id" ref="model_sports_patient"/>
|
||||
<field name="groups" eval="[4, ref('base.group_portal')]"/>
|
||||
<field name="groups" eval="[(6, 0, [ref('base.group_portal')])]"/>
|
||||
<field name="domain_force">
|
||||
[('id', 'in', user.partner_id.staff_team_ids.mapped('patient_ids').ids)]
|
||||
</field>
|
||||
|
|
@ -20,4 +20,4 @@
|
|||
</field>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
</odoo>
|
||||
|
|
|
|||
Loading…
Reference in a new issue