You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

33 lines
1.6 KiB

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="1">
<!-- Record rule of group doctor to access doctor allocation records-->
<record id="doctor_allocation_rule_doctor" model="ir.rule">
<field name="name">Doctor Allocation Rule Doctor</field>
<field name="model_id" ref="model_doctor_allocation"/>
<field name="domain_force">
[('doctor_id.user_id','=',user.id)]
</field>
<field name="groups"
eval="[(4, ref('base_hospital_management.base_hospital_management_group_doctor'))]"/>
</record>
<!-- Record rule of group doctor to access manager allocation records-->
<record id="doctor_allocation_rule_manager" model="ir.rule">
<field name="name">Doctor Allocation Rule Manager</field>
<field name="model_id" ref="model_doctor_allocation"/>
<field name="domain_force">
[(1,'=',1)]
</field>
<field name="groups"
eval="[(4, ref('base_hospital_management.base_hospital_management_group_manager'))]"/>
</record>
<!-- Multi company rule for doctor allocation records-->
<record id="doctor_allocation_rule_company" model="ir.rule">
<field name="name">Doctor Allocation Rule Company</field>
<field name="model_id" ref="model_doctor_slot"/>
<field name="domain_force">
['|',('company_id','=',False),('company_id', 'in', company_ids)]
</field>
</record>
</data>
</odoo>