commit
4ed085c552
|
|
@ -3226,7 +3226,7 @@ msgstr "عمليات الكفالة"
|
||||||
#: model:ir.ui.menu,name:odex_takaful.kafalat_main_menu
|
#: model:ir.ui.menu,name:odex_takaful.kafalat_main_menu
|
||||||
#: model_terms:ir.ui.view,arch_db:odex_takaful.view_takaful_sponsor_form
|
#: model_terms:ir.ui.view,arch_db:odex_takaful.view_takaful_sponsor_form
|
||||||
msgid "Kafalat"
|
msgid "Kafalat"
|
||||||
msgstr "كفالة ونقاط بيع"
|
msgstr "كفالات و نقاط بيع"
|
||||||
|
|
||||||
#. module: odex_takaful
|
#. module: odex_takaful
|
||||||
#: model:ir.model,name:odex_takaful.model_takaful_wizard_report_kafalat_cancel
|
#: model:ir.model,name:odex_takaful.model_takaful_wizard_report_kafalat_cancel
|
||||||
|
|
@ -3258,7 +3258,7 @@ msgstr "نافذة معالج تقرير مدفوعات الكفالات"
|
||||||
#. module: odex_takaful
|
#. module: odex_takaful
|
||||||
#: model:ir.ui.menu,name:odex_takaful.takaful_kufula_app_top_menu
|
#: model:ir.ui.menu,name:odex_takaful.takaful_kufula_app_top_menu
|
||||||
msgid "Kafalat System"
|
msgid "Kafalat System"
|
||||||
msgstr "الكفالات ونقاط البيع"
|
msgstr "كفالة و نقاط بيع"
|
||||||
|
|
||||||
#. module: odex_takaful
|
#. module: odex_takaful
|
||||||
#: model:ir.ui.menu,name:odex_takaful.kafileen_main_menu
|
#: model:ir.ui.menu,name:odex_takaful.kafileen_main_menu
|
||||||
|
|
@ -7259,4 +7259,22 @@ msgstr "إضافة كافل/متبرع جديد"
|
||||||
#. module: odex_takaful
|
#. module: odex_takaful
|
||||||
#: model_terms:ir.ui.view,arch_db:odex_takaful.view_takaful_sponsor_form
|
#: model_terms:ir.ui.view,arch_db:odex_takaful.view_takaful_sponsor_form
|
||||||
msgid "Related Donors"
|
msgid "Related Donors"
|
||||||
msgstr "كافل/متبرع مرتبط"
|
msgstr "كافل/متبرع مرتبط"
|
||||||
|
|
||||||
|
#. module: odex_takaful
|
||||||
|
#: model:ir.model.fields,field_description:odex_takaful.field_family_member__kafala_status
|
||||||
|
msgid "Kafala Status"
|
||||||
|
msgstr "حالة الكفالة"
|
||||||
|
|
||||||
|
#. module: odex_takaful
|
||||||
|
#: model:ir.model.fields.selection,name:odex_takaful.selection__family_member__kafala_status__have_kafala
|
||||||
|
#: model_terms:ir.ui.view,arch_db:odex_takaful.family_member_search_inherit
|
||||||
|
msgid "Have Kafala"
|
||||||
|
msgstr "مكفول"
|
||||||
|
|
||||||
|
#. module: odex_takaful
|
||||||
|
#: model:ir.model.fields.selection,name:odex_takaful.selection__family_member__kafala_status__have_not_kafala
|
||||||
|
#: model_terms:ir.ui.view,arch_db:odex_takaful.family_member_search_inherit
|
||||||
|
msgid "Have not Kafala"
|
||||||
|
msgstr "غير مكفول"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -169,7 +169,7 @@ class DonationsDetailsLines(models.Model):
|
||||||
rec.state = 'active'
|
rec.state = 'active'
|
||||||
sponsor_id = rec.sponsorship_mechanism_id.sponsor_id.id if rec.sponsorship_mechanism_id else rec.sponsorship_id.sponsor_id.id
|
sponsor_id = rec.sponsorship_mechanism_id.sponsor_id.id if rec.sponsorship_mechanism_id else rec.sponsorship_id.sponsor_id.id
|
||||||
(rec.benefit_id | rec.benefit_ids).write(
|
(rec.benefit_id | rec.benefit_ids).write(
|
||||||
{'sponsor_related_id': sponsor_id, "sponsorship_end_date": rec.end_date if rec.end_date else False})
|
{'sponsor_related_id': sponsor_id, 'kafala_status': 'have_kafala', "sponsorship_end_date": rec.end_date if rec.end_date else False})
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def run_check_all_end_dates(self):
|
def run_check_all_end_dates(self):
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,11 @@ class FamilyMember(models.Model):
|
||||||
sponsorship_end_date = fields.Date(string='Sponsorship End Date')
|
sponsorship_end_date = fields.Date(string='Sponsorship End Date')
|
||||||
is_restricted = fields.Boolean(string="Is Restricted ?", default=False, readonly=True)
|
is_restricted = fields.Boolean(string="Is Restricted ?", default=False, readonly=True)
|
||||||
general_restriction = fields.Boolean(string="General Restriction", default=False, readonly=True)
|
general_restriction = fields.Boolean(string="General Restriction", default=False, readonly=True)
|
||||||
|
kafala_status = fields.Selection(
|
||||||
|
[('have_kafala', 'Have Kafala'), ('have_not_kafala', 'Have not Kafala')],
|
||||||
|
string='Kafala Status', default='have_not_kafala')
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def _compute_donation_details_count(self):
|
def _compute_donation_details_count(self):
|
||||||
for rec in self:
|
for rec in self:
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ class ProductTemplate(models.Model):
|
||||||
|
|
||||||
donation_category = fields.Selection(
|
donation_category = fields.Selection(
|
||||||
[('donation', 'Donation'), ('sponsorship', 'Sponsorship'), ('endowment', 'Endowment')],
|
[('donation', 'Donation'), ('sponsorship', 'Sponsorship'), ('endowment', 'Endowment')],
|
||||||
string='Donation Category', required=True, default='donation')
|
string='Donation Category')
|
||||||
fixed_value = fields.Boolean(string='Is Fixed Value?', compute='_compute_fixed_value')
|
fixed_value = fields.Boolean(string='Is Fixed Value?', compute='_compute_fixed_value')
|
||||||
sponsorship_duration = fields.Selection([('temporary', 'Temporary'), ('permanent', 'Permanent')],
|
sponsorship_duration = fields.Selection([('temporary', 'Temporary'), ('permanent', 'Permanent')],
|
||||||
string='Sponsorship Duration Type')
|
string='Sponsorship Duration Type')
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,8 @@
|
||||||
<field name="sponsorship_end_date" readonly="1"/>
|
<field name="sponsorship_end_date" readonly="1"/>
|
||||||
<field name="is_restricted" widget="boolean_toggle"/>
|
<field name="is_restricted" widget="boolean_toggle"/>
|
||||||
<field name="general_restriction" widget="boolean_toggle"/>
|
<field name="general_restriction" widget="boolean_toggle"/>
|
||||||
|
<field name="kafala_status" readonly="1"/>
|
||||||
|
|
||||||
</xpath>
|
</xpath>
|
||||||
|
|
||||||
<xpath expr="//header" position="inside">
|
<xpath expr="//header" position="inside">
|
||||||
|
|
@ -41,6 +43,11 @@
|
||||||
<field name="arch" type="xml">
|
<field name="arch" type="xml">
|
||||||
<field name="benefit_id" position="after">
|
<field name="benefit_id" position="after">
|
||||||
<separator/>
|
<separator/>
|
||||||
|
<filter name="have_kafala" string="Have Kafala"
|
||||||
|
domain="[('kafala_status','=','have_kafala')]"/>
|
||||||
|
<filter name="have_not_kafala" string="Have not Kafala"
|
||||||
|
domain="[('kafala_status','=','have_not_kafala')]"/>
|
||||||
|
<separator/>
|
||||||
<filter name="orphan_benefit_type" string="Orphans"
|
<filter name="orphan_benefit_type" string="Orphans"
|
||||||
domain="[('relationn_type', 'in', ['son', 'daughter'])]"/>
|
domain="[('relationn_type', 'in', ['son', 'daughter'])]"/>
|
||||||
<filter name="widow_benefit_type" string="Widows"
|
<filter name="widow_benefit_type" string="Widows"
|
||||||
|
|
@ -72,4 +79,17 @@
|
||||||
</field>
|
</field>
|
||||||
</field>
|
</field>
|
||||||
</record>
|
</record>
|
||||||
|
|
||||||
|
<record id="view_family_member_tree_inherit" model="ir.ui.view">
|
||||||
|
<field name="name">family.member.tree.inherit</field>
|
||||||
|
<field name="model">family.member</field>
|
||||||
|
<field name="inherit_id" ref="odex_benefit.family_member_tree"/>
|
||||||
|
<field name="arch" type="xml">
|
||||||
|
<xpath expr="//field[@name='member_status']" position="after">
|
||||||
|
<field name="kafala_status" widget="badge"
|
||||||
|
decoration-success="kafala_status == 'have_kafala'"
|
||||||
|
decoration-danger="kafala_status == 'have_not_kafala'"/>
|
||||||
|
</xpath>
|
||||||
|
</field>
|
||||||
|
</record>
|
||||||
</odoo>
|
</odoo>
|
||||||
|
|
@ -487,7 +487,7 @@
|
||||||
<page string="Orphans and Widows List"
|
<page string="Orphans and Widows List"
|
||||||
attrs="{'invisible': [('sponsorship_type', '!=', 'group')]}">
|
attrs="{'invisible': [('sponsorship_type', '!=', 'group')]}">
|
||||||
<!-- attrs="{'invisible': ['|', '|', '|', ('hide_beneficiary_group','=', True), ('parent.record_type','!=','sponsorship'), ('sponsorship_type', '!=', 'group'), ('benefit_type', '!=', 'both')]}">-->
|
<!-- attrs="{'invisible': ['|', '|', '|', ('hide_beneficiary_group','=', True), ('parent.record_type','!=','sponsorship'), ('sponsorship_type', '!=', 'group'), ('benefit_type', '!=', 'both')]}">-->
|
||||||
<field name="benefit_ids" nolabel="1">
|
<field name="benefit_ids" nolabel="1" options="{'no_create': True}">
|
||||||
<tree editable="bottom">
|
<tree editable="bottom">
|
||||||
<field name="name"/>
|
<field name="name"/>
|
||||||
<field name="age"/>
|
<field name="age"/>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue