[IMP] partner_profiles_portal: new portal structures data management

refactors the way a portal user can edit the data of the structures he
is affiliated with.
All main, public and position profiles data are gathered in one
"structure" form.
Adds several navigation improvement (back to structures list,
validation message, ...)
This commit is contained in:
Stéphan Sainléger
2023-04-20 21:59:06 +02:00
parent 69de81a9e0
commit 56bec1eed7
13 changed files with 629 additions and 493 deletions

View File

@@ -9,22 +9,26 @@
<field name="arch" type="xml">
<!-- Main display -->
<xpath expr="//group[@name='profile_status']" position="after">
<group name="structure_access_rights" attrs="{'invisible': ['|', ('is_position_profile','=',False), ('parent_id','=',False)]}">
<field name="edit_structure_main_profile" />
<field name="edit_structure_public_profile" />
<group name="structure_access_rights"
attrs="{'invisible': ['|', ('is_position_profile','=',False), ('parent_id','=',False)]}">
<field name="edit_structure_profiles" />
</group>
</xpath>
<!-- page Contacts & Adresses -->
<xpath expr="//field[@name='child_ids']/form/sheet/group/group/field[@name='comment']" position="before">
<field name="edit_structure_main_profile" attrs="{'invisible': [('is_position_profile','=',False)]}" />
<field name="edit_structure_public_profile" attrs="{'invisible': [('is_position_profile','=',False)]}" />
<xpath
expr="//field[@name='child_ids']/form/sheet/group/group/field[@name='comment']"
position="before">
<field name="edit_structure_profiles"
attrs="{'invisible': [('is_position_profile','=',False)]}" />
</xpath>
<!-- page Other Positions -->
<xpath expr="//field[@name='other_contact_ids']/form/sheet/group/group/field[@name='parent_id']" position="after">
<field name="edit_structure_main_profile" attrs="{'invisible': [('is_position_profile','=',False)]}" />
<field name="edit_structure_public_profile" attrs="{'invisible': [('is_position_profile','=',False)]}" />
<xpath
expr="//field[@name='other_contact_ids']/form/sheet/group/group/field[@name='parent_id']"
position="after">
<field name="edit_structure_profiles"
attrs="{'invisible': [('is_position_profile','=',False)]}" />
</xpath>
</field>
</record>