Skip to content
Extraits de code Groupes Projets
Valider 8b0130d0 rédigé par Benjamin - Le Filament's avatar Benjamin - Le Filament
Parcourir les fichiers

[update] add new rule on contact_addresses notebook page & pre-commit

parent 1d231bd0
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -89,9 +89,13 @@
</field>
<field name="parent_id" position="attributes">
<attribute name="options">{'no_create': True}</attribute>
<attribute name="domain">[('is_company', '=', True), ('ur_id', '=', ur_id)]</attribute>
<attribute
name="domain"
>[('is_company', '=', True), ('ur_id', '=', ur_id)]</attribute>
<attribute name="placeholder">Société</attribute>
<attribute name="attrs" >{'invisible': [('is_company','=', True)]}</attribute>
<attribute
name="attrs"
>{'invisible': [('is_company','=', True)]}</attribute>
</field>
<xpath expr="//div[hasclass('oe_title')]" position="attributes">
<attribute name="class">oe_title oe_title_cgscop</attribute>
......@@ -126,7 +130,9 @@
<attribute name="placeholder">Rue 3</attribute>
</field>
<field name="zip_id" position="attributes">
<attribute name="placeholder">CP / Ville autocomplétion...</attribute>
<attribute
name="placeholder"
>CP / Ville autocomplétion...</attribute>
</field>
<field name="zip" position="replace" />
<field name="city" position="before">
......@@ -180,7 +186,8 @@
<xpath expr='//form/sheet/group/group[2]' position="replace">
<group col="1" name="partner_legal_info">
<group string="Informations juridiques"
<group
string="Informations juridiques"
attrs="{'invisible': [('is_company', '=', False)]}"
>
<label
......@@ -216,7 +223,8 @@
<field name="registration_date" />
</group>
<group string="Informations contact"
<group
string="Informations contact"
name="contact_legal_info"
attrs="{'invisible': ['|', ('is_company', '=', True), ('type', '!=', 'contact')]}"
>
......@@ -340,7 +348,8 @@
attrs="{'invisible': ['|', ('is_company','=', False), ('type', '!=', 'contact')]}"
/>
</group>
<group string="Féd. communication"
<group
string="Féd. communication"
groups="cgscop_partner.group_federation_com"
>
<field name="copadev_member" widget="boolean_toggle" />
......@@ -351,7 +360,8 @@
/>
</group>
</group>
<group string="Informations mouvement"
<group
string="Informations mouvement"
name="contact_segment_info"
attrs="{'invisible': ['|', ('is_company', '=', True), ('type', '!=', 'contact')]}"
>
......@@ -403,10 +413,6 @@
</field>
</xpath>
<xpath expr="//page[@name='contact_addresses']" position="attributes">
<attribute name="attrs">{'invisible': [('is_company','=', False)]}</attribute>
</xpath>
<xpath expr="//field[@name='child_ids']" position="replace">
<p>
<button
......@@ -417,7 +423,12 @@
/>
</p>
<field name="child_ids" mode="kanban" readonly="1" style="pointer-events: none;">
<field
name="child_ids"
mode="kanban"
readonly="1"
style="pointer-events: none;"
>
<kanban>
<field name="id" />
<field name="color" />
......@@ -512,10 +523,7 @@
><field name="function_lst_id" /></div>
<div
t-if="record.email.raw_value"
><field
name="email"
widget="email"
/></div>
><field name="email" widget="email" /></div>
<div
t-if="record.type.raw_value != 'contact'"
>
......@@ -550,11 +558,13 @@
</field>
</xpath>
<xpath expr="//notebook/page" position="attributes">
<xpath
expr="//notebook/page[@name='contact_addresses']"
position="attributes"
>
<attribute
name="attrs"
>{'invisible': [('is_cooperative','=', True)]}</attribute>
>{'invisible': ['|', ('is_cooperative','=', True), ('is_company','!=', True)]}</attribute>
</xpath>
<xpath
......@@ -1208,7 +1218,11 @@
string="Ajouter un dirigeant"
/>
</p>
<field name="director_ids" readonly="1" style="pointer-events:none;">
<field
name="director_ids"
readonly="1"
style="pointer-events:none;"
>
<kanban>
<field name="id" />
<field name="color" />
......@@ -1325,7 +1339,12 @@
string="Ajouter un contact"
/>
</p>
<field name="other_child_ids" mode="kanban" readonly="1" style="pointer-events: none;">
<field
name="other_child_ids"
mode="kanban"
readonly="1"
style="pointer-events: none;"
>
<kanban>
<field name="id" />
<field name="color" />
......@@ -1933,11 +1952,7 @@
<hr />
<group>
<group attrs="{'invisible': [('type', '=', 'contact')]}">
<field
name="name"
string="Nom"
required="1"
/>
<field name="name" string="Nom" required="1" />
<label for="street" string="Adresse" />
<div>
<div name="div_address" class="o_address_format">
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter