22/10/2023 - 18h00

master
cherif 2023-10-22 18:36:52 +02:00
parent 780fcc711f
commit beb3d87aad
4 changed files with 1449 additions and 45 deletions

View File

@ -1,42 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ChangeListManager">
<list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="zzzw">
<change afterPath="$PROJECT_DIR$/base_specific_fields.py" afterDir="false" />
<list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="22/10/2023 - 12h">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Activite.py" beforeDir="false" afterPath="$PROJECT_DIR$/Activite.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Contact.py" beforeDir="false" afterPath="$PROJECT_DIR$/Contact.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Dev_api_functions.py" beforeDir="false" afterPath="$PROJECT_DIR$/Dev_api_functions.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Inscription_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/Inscription_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Log/log_file.log" beforeDir="false" afterPath="$PROJECT_DIR$/Log/log_file.log" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Session_Formation.py" beforeDir="false" afterPath="$PROJECT_DIR$/Session_Formation.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/abonnement_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/abonnement_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/appel_offre.py" beforeDir="false" afterPath="$PROJECT_DIR$/appel_offre.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/articles_avis.py" beforeDir="false" afterPath="$PROJECT_DIR$/articles_avis.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/attached_file_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/attached_file_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/business_prices.py" beforeDir="false" afterPath="$PROJECT_DIR$/business_prices.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/class_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/class_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/code_promo_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/code_promo_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ela_factures_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/ela_factures_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ela_user_account.py" beforeDir="false" afterPath="$PROJECT_DIR$/ela_user_account.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/email_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/email_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/emargement.py" beforeDir="false" afterPath="$PROJECT_DIR$/emargement.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/lms_chamilo/mysy_lms.py" beforeDir="false" afterPath="$PROJECT_DIR$/lms_chamilo/mysy_lms.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partner_base_setup.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_base_setup.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partner_client.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_client.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partner_document_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_document_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partner_invoice.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_invoice.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partner_order.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_order.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/partners.py" beforeDir="false" afterPath="$PROJECT_DIR$/partners.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/product_service.py" beforeDir="false" afterPath="$PROJECT_DIR$/product_service.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/base_specific_fields.py" beforeDir="false" afterPath="$PROJECT_DIR$/base_specific_fields.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ressources_humaines.py" beforeDir="false" afterPath="$PROJECT_DIR$/ressources_humaines.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/ressources_materiels.py" beforeDir="false" afterPath="$PROJECT_DIR$/ressources_materiels.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/statistics.py" beforeDir="false" afterPath="$PROJECT_DIR$/statistics.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/strype_payement.py" beforeDir="false" afterPath="$PROJECT_DIR$/strype_payement.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/user_access_right.py" beforeDir="false" afterPath="$PROJECT_DIR$/user_access_right.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/user_message_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/user_message_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/wrapper.py" beforeDir="false" afterPath="$PROJECT_DIR$/wrapper.py" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -106,13 +75,6 @@
<option name="presentableId" value="Default" />
<updated>1680804787304</updated>
</task>
<task id="LOCAL-00084" summary="26/08/23 - 20h">
<created>1693072689877</created>
<option name="number" value="00084" />
<option name="presentableId" value="LOCAL-00084" />
<option name="project" value="LOCAL" />
<updated>1693072689879</updated>
</task>
<task id="LOCAL-00085" summary="27/08/23 - 13h">
<created>1693136101567</created>
<option name="number" value="00085" />
@ -449,7 +411,14 @@
<option name="project" value="LOCAL" />
<updated>1697820815600</updated>
</task>
<option name="localTasksCounter" value="133" />
<task id="LOCAL-00133" summary="22/10/2023 - 12h">
<created>1697981083215</created>
<option name="number" value="00133" />
<option name="presentableId" value="LOCAL-00133" />
<option name="project" value="LOCAL" />
<updated>1697981083215</updated>
</task>
<option name="localTasksCounter" value="134" />
<servers />
</component>
<component name="Vcs.Log.Tabs.Properties">
@ -464,7 +433,6 @@
</option>
</component>
<component name="VcsManagerConfiguration">
<MESSAGE value="15/09/2023 - 12h" />
<MESSAGE value="15/09/2023 - 18h" />
<MESSAGE value="22/09/2023 - 12h53" />
<MESSAGE value="22/09/2023 - 18h53" />
@ -489,6 +457,7 @@
<MESSAGE value="17/10/2023 - 22h40" />
<MESSAGE value="17/10/2023 - 22h45" />
<MESSAGE value="zzz" />
<option name="LAST_COMMIT_MESSAGE" value="zzz" />
<MESSAGE value="22/10/2023 - 12h" />
<option name="LAST_COMMIT_MESSAGE" value="22/10/2023 - 12h" />
</component>
</project>

File diff suppressed because it is too large Load Diff

View File

@ -161,13 +161,16 @@ def get_list_specific_field_partner_by_object(diction):
data_cle = {}
data_cle['partner_owner_recid'] = str(my_partner['recid'])
data_cle['related_collection'] = str(diction['object_name']).strip().lower()
data_cle['is_displayed'] = "1"
data_cle['valide'] = "1"
data_cle['locked'] = "0"
RetObject = []
val_tmp = 1
for retval in MYSY_GV.dbname['partner_order_line'].find(data_cle):
#print(" ### qtry = ", data_cle)
for retval in MYSY_GV.dbname['base_specific_fields'].find(data_cle):
user = retval
user['id'] = str(val_tmp)
val_tmp = val_tmp + 1
@ -179,4 +182,4 @@ def get_list_specific_field_partner_by_object(diction):
except Exception as e:
exc_type, exc_obj, exc_tb = sys.exc_info()
mycommon.myprint(str(inspect.stack()[0][3]) + " -" + str(e) + " - Line : " + str(exc_tb.tb_lineno))
return False, " Impossible de récupérer les champs "
return False, " Impossible de récupérer la liste des champs spécifiques "

View File

@ -449,6 +449,8 @@ def Update_Ressource_Humaine(diction):
inspect.stack()[0][3]) + " Le champ '" + val + "' n'existe pas")
return False, " Les informations fournies sont incorrectes",
"""
Verification des champs obligatoires
"""
@ -635,6 +637,28 @@ def Update_Ressource_Humaine(diction):
"""
Update du 22/10/2023 - Gestion des champs spécifiques ajoutés par le partenaire
"""
# Recuperation des champs spécifiques se trouvant dans le dictionnaire. ils commencent tous par 'my_'
for val in diction.keys():
if( val.startswith('my_') ):
if( MYSY_GV.dbname['base_specific_fields'].count_documents({'partner_owner_recid':str(my_partner['recid']),
'related_collection':'ressource_humaine',
'field_name':str(val),
'valide':'1',
'locked':'0'}) != 1):
mycommon.myprint(str(
inspect.stack()[0][3]) + " Le champ '" + val + "' n'est pas autorisé ")
return False, " Les informations fournies sont incorrectes"
data_update[str(val)] = diction[str(val)]
data_update['valide'] = '1'
data_update['locked'] = '0'
data_update['date_update'] = str(datetime.now())