Merge pull request #6347 from expsa/samir_aladawi_fix_esterdad
[UPD] odex_takaful
This commit is contained in:
commit
930f3e156d
|
|
@ -7586,4 +7586,9 @@ msgstr "طباعة تقرير أم اليتيم/اليتيم"
|
|||
#. module: odex_takaful
|
||||
#: model_terms:ir.ui.view,arch_db:odex_takaful.takaful_account_move_inherit_form
|
||||
msgid "Previous Payments"
|
||||
msgstr "المدفوعات السابقة"
|
||||
msgstr "المدفوعات السابقة"
|
||||
|
||||
#. module: odex_takaful
|
||||
#: model:res.groups,name:odex_takaful.group_refund_change_mobile
|
||||
msgid "Change Sponsor Mobile in Refund Wizard"
|
||||
msgstr "تغيير جوال الكافل في معالج الاسترداد"
|
||||
|
|
|
|||
|
|
@ -92,11 +92,16 @@
|
|||
<field name="implied_ids" eval="[(6, 0, [ref('group_kufula_user')])]"/>
|
||||
</record>
|
||||
|
||||
<record id="group_sponsor_department_access" model="res.groups">
|
||||
<record id="group_sponsor_department_access" model="res.groups">
|
||||
<field name="name">Sponsor - Department Access</field>
|
||||
<field name="category_id" ref="module_category_kufula"/>
|
||||
</record>
|
||||
|
||||
<record id="group_refund_change_mobile" model="res.groups">
|
||||
<field name="name">Change Sponsor Mobile in Refund Wizard</field>
|
||||
<field name="category_id" ref="module_category_kufula"/>
|
||||
</record>
|
||||
|
||||
<record id="donation_officer_restrictions" model="ir.rule">
|
||||
<field name="name">Donations Officer: Own Donations</field>
|
||||
<field name="model_id" ref="model_takaful_sponsorship"/>
|
||||
|
|
@ -163,7 +168,7 @@
|
|||
<field name="domain_force">[
|
||||
'|',
|
||||
('branch_custom_id.branch.manager_id.user_id', 'in', [user.id, False]),
|
||||
('branch_custom_id.branch', 'child_of', user.employee_id.department_id.id)
|
||||
('branch_custom_id', 'child_of', user.branch_custom_id.id)
|
||||
]</field>
|
||||
</record>
|
||||
|
||||
|
|
@ -174,10 +179,10 @@
|
|||
<field name="domain_force">[
|
||||
'|', '|', '|',
|
||||
('sponsorship_id.branch_custom_id.branch.manager_id.user_id', 'in', [user.id, False]),
|
||||
('sponsorship_id.branch_custom_id.branch', 'child_of', user.employee_id.department_id.id),
|
||||
('sponsorship_id.branch_custom_id', 'child_of', user.branch_custom_id.id),
|
||||
|
||||
('sponsorship_mechanism_id.branch_custom_id.branch.manager_id.user_id', 'in', [user.id, False]),
|
||||
('sponsorship_mechanism_id.branch_custom_id.branch', 'child_of', user.employee_id.department_id.id)
|
||||
('sponsorship_mechanism_id.branch_custom_id', 'child_of', user.branch_custom_id.id)
|
||||
]</field>
|
||||
</record>
|
||||
|
||||
|
|
@ -189,11 +194,11 @@
|
|||
'|', '|', '|', '|',
|
||||
('create_uid', '=', user.id),
|
||||
|
||||
('create_uid.employee_id.department_id.manager_id.user_id', 'in', [user.id, False]),
|
||||
('create_uid.employee_id.department_id', 'child_of', user.employee_id.department_id.id),
|
||||
('create_uid.branch_custom_id.branch.manager_id.user_id', 'in', [user.id, False]),
|
||||
('create_uid.branch_custom_id', 'child_of', user.branch_custom_id.id),
|
||||
|
||||
('sponsorship_id.branch_custom_id.branch.manager_id.user_id', 'in', [user.id, False]),
|
||||
('sponsorship_id.branch_custom_id.branch', 'child_of', user.employee_id.department_id.id)
|
||||
('sponsorship_id.branch_custom_id', 'child_of', user.branch_custom_id.id)
|
||||
]</field>
|
||||
</record>
|
||||
|
||||
|
|
@ -201,7 +206,7 @@
|
|||
<field name="name">Sponsor - Department Based Access</field>
|
||||
<field name="model_id" ref="odex_takaful.model_takaful_sponsor"/>
|
||||
<field name="groups" eval="[(4, ref('group_sponsor_department_access')), (4, ref('branch_manager_group'))]"/>
|
||||
<field name="domain_force">[('branch_custom_id.branch', 'child_of', user.employee_id.department_id.id)]</field>
|
||||
<field name="domain_force">[('branch_custom_id', 'child_of', user.branch_custom_id.id)]</field>
|
||||
</record>
|
||||
|
||||
<record id="sponsorship_system_manager_restrictions" model="ir.rule">
|
||||
|
|
|
|||
|
|
@ -149,6 +149,8 @@ class EsterdadWizard(models.Model):
|
|||
})
|
||||
if rec.sponsor_id.sponsor_or_donor_type == 'unknown' and not rec.sponsor_id.sponsor_phone:
|
||||
rec.sponsor_id.sponsor_phone = rec.mobile
|
||||
if rec.sponsor_id.sponsor_or_donor_type == 'registered' and rec.id_num:
|
||||
rec.sponsor_id.sponsor_id.id_number == rec.id_num
|
||||
# context['default_payment_ids'] = [(6, 0, rec.payment_ids.ids)]
|
||||
view = self.env.ref('odex_takaful.view_otp_wizard_form')
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -50,7 +50,8 @@
|
|||
<page string="بيانات المتبرع">
|
||||
<group>
|
||||
<field name="sponsor_name"/>
|
||||
<field name="mobile"/>
|
||||
<field name="mobile" groups="odex_takaful.group_refund_change_mobile" />
|
||||
<field name="mobile" groups="!odex_takaful.group_refund_change_mobile" readonly="1" />
|
||||
<field name="id_num"/>
|
||||
</group>
|
||||
</page>
|
||||
|
|
|
|||
Loading…
Reference in New Issue