fix(import_from_civicrm): corrige feuillu(s)

main
Vincent Adolphe 2022-05-10 23:38:50 +02:00
Parent 9cfc61a913
révision 19427db2c9
3 fichiers modifiés avec 6 ajouts et 6 suppressions

Voir le fichier

@ -399,7 +399,7 @@ CHOICES_PROD_REG = tuple(
)
)
CHOICES_FEUILLU = tuple(
CHOICES_FEUILLUS = tuple(
zip(
(
'1', # "Aulne"

Voir le fichier

@ -40,7 +40,7 @@ I2R_PK_M2M_PARAMS = (
('secteur_intervention',) * 2
+ (itc.SECTEUR_INTERVENTION, 'SecteurIntervention'),
('clients', 'type_client', itc.TYPE_CLIENT, 'TypeClient'),
('feuillu',) * 2 + (itc.FEUILLU, 'EssenceArbre'),
('feuillus',) * 2 + (itc.FEUILLU, 'EssenceArbre'),
('resineux',) * 2 + (itc.RESINEUX, 'EssenceArbre'),
('equipements',) * 2 + (itc.EQUIPEMENT, 'Equipement'),
('amenagement_paysager',) * 2

Voir le fichier

@ -19,7 +19,7 @@ from ..constants import (
CHOICES_EMBALLAGE,
CHOICES_EQUIPEMENTS,
CHOICES_ESSENCE_MAJ,
CHOICES_FEUILLU,
CHOICES_FEUILLUS,
CHOICES_MARQ_CE,
CHOICES_MENUIS_REVET,
CHOICES_NRJ_CONNEXE,
@ -96,7 +96,7 @@ class CivicrmContact(ExtFieldMixin, models.Model):
'extproduits__bois_energie_connexes',
'extsecondetransformation__menuiserie_et_revetement',
'extsecondetransformation__produits_en_bois_regionaux',
'extessences__feuillu',
'extessences__feuillus',
'extessences__resineux',
'extessences__essence_majoritaire',
'extrenseignements__direction_ou_filiale',
@ -652,8 +652,8 @@ class ExtEssences(SerializedCharFieldModelMixin, models.Model):
entity = models.OneToOneField(
'CivicrmContact', models.DO_NOTHING, unique=True
)
feuillu = SerializedCharField(
choices=CHOICES_FEUILLU,
feuillus = SerializedCharField(
choices=CHOICES_FEUILLUS,
db_column='feuillus_51',
max_length=255,
blank=True,