Skip to content
GitLab
Explorer
Connexion
Navigation principale
Rechercher ou aller à…
Projet
M
mvh_crm
Gestion
Activité
Membres
Labels
Programmation
Tickets
Tableaux des tickets
Jalons
Code
Requêtes de fusion
Dépôt
Branches
Validations
Étiquettes
Graphe du dépôt
Comparer les révisions
Analyse
Données d'analyse des chaînes de valeur
Analyse des contributeurs
Données d'analyse du dépôt
Aide
Aide
Support
Documentation de GitLab
Comparer les forfaits GitLab
Forum de la communauté GitLab
Contribuer à GitLab
Donner votre avis
Raccourcis clavier
?
Extraits de code
Groupes
Projets
Afficher davantage de fils d'Ariane
Le Filament
MVH
mvh_crm
Validations
8b4a84bc
Valider
8b4a84bc
rédigé
Il y a 4 ans
par
Benjamin - Le Filament
Parcourir les fichiers
Options
Téléchargements
Correctifs
Plain Diff
[update] CRM fields and views
parent
89c394ac
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
Modifications
3
Afficher les modifications d'espaces
En ligne
Côte à côte
Affichage de
3 fichiers modifiés
models/crm_lead.py
+24
-35
24 ajouts, 35 suppressions
models/crm_lead.py
views/crm_lead_view.xml
+9
-20
9 ajouts, 20 suppressions
views/crm_lead_view.xml
views/res_partner_view.xml
+5
-15
5 ajouts, 15 suppressions
views/res_partner_view.xml
avec
38 ajouts
et
70 suppressions
models/crm_lead.py
+
24
−
35
Voir le fichier @
8b4a84bc
# Copyright 2019 Le Filament (<http://www.le-filament.com>)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from
odoo
import
models
,
fields
class
CRMleadMVH
(
models
.
Model
):
_inherit
=
'
crm.lead
'
# Critères du début Go/NoGo
budget
=
fields
.
Float
(
string
=
"
Budget au m²
"
)
eco_responsable
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
'
Eco-responsable
'
)
eco_responsable
=
fields
.
Boolean
(
string
=
'
Eco-responsable ?
'
)
elements_metriques
=
fields
.
Text
(
string
=
"
Eléments métriques
"
)
lieu
=
fields
.
Char
(
string
=
"
Lieu
"
)
propriete
=
fields
.
Text
(
string
=
"
Propriété
"
)
renovation_neuf
=
fields
.
Selection
(
[(
'
renovation
'
,
'
Rénovation
'
),
(
'
neuf
'
,
'
Neuf
'
)],
renovation_neuf
=
fields
.
Selection
(
[(
'
renovation
'
,
'
Rénovation
'
),
(
'
neuf
'
,
'
Neuf
'
)],
string
=
"
Projet
"
)
visite_payante
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
'
Visite payante
'
)
envie_achat
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
"
Envie d
'
achat
"
)
presence_plan
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
"
Plan
"
)
presence_planning
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
"
Planning réalisation
"
)
presence_permis
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
"
Permis de construire
"
)
presence_etude
=
fields
.
Selection
([(
'
yes
'
,
'
Oui
'
),
(
'
no
'
,
'
Non
'
)],
string
=
"
Etude de sol
"
)
visite_payante
=
fields
.
Boolean
(
'
Visite payante
'
)
envie_achat
=
fields
.
Boolean
(
"
Envie d
'
achat
"
)
presence_plan
=
fields
.
Boolean
(
"
Plan
"
)
presence_planning
=
fields
.
Boolean
(
"
Planning réalisation
"
)
presence_permis
=
fields
.
Boolean
(
"
Permis de construire
"
)
presence_etude
=
fields
.
Boolean
(
"
Etude de sol
"
)
# Adresse du chantier
rue
=
fields
.
Char
(
'
Rue
'
)
rue2
=
fields
.
Char
(
'
Rue2
'
)
code_postal
=
fields
.
Char
(
'
Code postal
'
,
change_default
=
True
)
ville
=
fields
.
Char
(
'
Ville
'
)
# Prescription technique
prescription_technique
=
fields
.
Text
(
string
=
"
Prescriptions techniques
"
)
# Partenaires projet
supplier_ids
=
fields
.
Many2many
(
'
res.partner
'
,
supplier_ids
=
fields
.
Many2many
(
comodel_name
=
'
res.partner
'
,
string
=
"
Architecte et fournisseurs
"
)
# Visite de chantier
description_technique
=
fields
.
Text
(
string
=
"
Description technique
"
,
track_visibility
=
'
onchange
'
)
reflexion_technique
=
fields
.
Text
(
string
=
"
Reflexion technique
"
,
description_technique
=
fields
.
Text
(
string
=
"
Description technique
"
,
track_visibility
=
'
onchange
'
)
presentation_detaillee
=
fields
.
Text
(
string
=
"
Présentation détaillée
"
,
reflexion_technique
=
fields
.
Text
(
string
=
"
Reflexion technique
"
,
track_visibility
=
'
onchange
'
)
presentation_detaillee
=
fields
.
Text
(
string
=
"
Présentation détaillée
"
)
Ce diff est replié.
Cliquez pour l'agrandir.
views/crm_lead_view.xml
+
9
−
20
Voir le fichier @
8b4a84bc
...
...
@@ -11,7 +11,6 @@
<attribute
name=
"invisible"
>
True
</attribute>
</field>
<xpath
expr=
"//page[1]"
position=
"attributes"
>
<attribute
name=
"string"
>
Descriptif court
</attribute>
</xpath>
...
...
@@ -21,16 +20,16 @@
<group>
<group
string=
"Infos générales"
>
<field
name=
"budget"
/>
<field
name=
"eco_responsable"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"eco_responsable"
widget=
"
boolean_toggle
"
/>
<field
name=
"renovation_neuf"
widget=
"radio"
options=
"{'horizontal': true}"
/>
<field
name=
"visite_payante"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"visite_payante"
widget=
"
boolean_toggle
"
/>
</group>
<group
string=
"Statut du projet"
>
<field
name=
"envie_achat"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"presence_plan"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"presence_planning"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"presence_permis"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"presence_etude"
widget=
"
radio"
options=
"{'horizontal': true}
"
/>
<field
name=
"envie_achat"
widget=
"
boolean_toggle
"
/>
<field
name=
"presence_plan"
widget=
"
boolean_toggle
"
/>
<field
name=
"presence_planning"
widget=
"
boolean_toggle
"
/>
<field
name=
"presence_permis"
widget=
"
boolean_toggle
"
/>
<field
name=
"presence_etude"
widget=
"
boolean_toggle
"
/>
</group>
</group>
</page>
...
...
@@ -38,8 +37,8 @@
<div
class=
"o_address_format"
>
<field
name=
"rue"
placeholder=
"Rue..."
class=
"o_address_street"
/>
<field
name=
"rue2"
placeholder=
"Rue 2..."
class=
"o_address_street"
/>
<field
name=
"ville"
placeholder=
"Ville"
class=
"o_address_city"
/>
<field
name=
"code_postal"
placeholder=
"Code postal"
class=
"o_address_zip"
/>
<field
name=
"ville"
placeholder=
"Ville"
class=
"o_address_city"
/>
</div>
</page>
<page
string=
"Prescriptions techniques"
>
...
...
@@ -49,8 +48,7 @@
</page>
<page
string=
"Partenaires du client"
>
<group>
<field
name=
"supplier_ids"
widget=
"many2many_kanban"
mode=
"kanban"
/>
<field
name=
"supplier_ids"
widget=
"many2many_kanban"
mode=
"kanban"
options=
"{'no_create': True}"
/>
</group>
</page>
<page
string=
"Visite de chantier"
>
...
...
@@ -60,17 +58,8 @@
<field
name=
"presentation_detaillee"
/>
</group>
</page>
</xpath>
<!-- <notebook position="inside">
<page string="Contacts">
<group>
<field name="child_ids" mode="tree"/>
</group>
</page>
</notebook> -->
</field>
</record>
...
...
Ce diff est replié.
Cliquez pour l'agrandir.
views/res_partner_view.xml
+
5
−
15
Voir le fichier @
8b4a84bc
...
...
@@ -6,23 +6,13 @@
<field
name=
"model"
>
res.partner
</field>
<field
name=
"inherit_id"
ref=
"base.view_partner_form"
/>
<field
name=
"arch"
type=
"xml"
>
<xpath
expr=
"//notebook/page"
position=
"before"
>
<page
string=
"Projets liés"
>
<field
name=
"opportunite"
/>
<field
name=
"opportunite"
readonly=
"1"
/>
</page>
</xpath>
</field>
</record>
<!-- <record id="mvh_res_partner_search" model="ir.ui.view">
<field name="name">mvh.res.partner.search</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_res_partner_filter"/>
<field name="arch" type="xml">
</field>
</record> -->
</data>
</odoo>
\ No newline at end of file
Ce diff est replié.
Cliquez pour l'agrandir.
Aperçu
0%
Chargement en cours
Veuillez réessayer
ou
joindre un nouveau fichier
.
Annuler
You are about to add
0
people
to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Enregistrer le commentaire
Annuler
Veuillez vous
inscrire
ou vous
se connecter
pour commenter