20/05/2025 - 21h

Signed-off-by: cherif <cherif.balde@yahoo.fr>
master
cherif 2025-05-20 20:53:46 +02:00
parent f7c8a84a78
commit 8e3300d74e
3 changed files with 1071 additions and 25 deletions

View File

@ -1,12 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="19/05/2025 - 20h"> <list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="20/05/2025 - 17h">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" 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$/Log/log_file.log" beforeDir="false" afterPath="$PROJECT_DIR$/Log/log_file.log" afterDir="false" />
<change beforePath="$PROJECT_DIR$/base_class_calcul_note.py" beforeDir="false" afterPath="$PROJECT_DIR$/base_class_calcul_note.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/jury_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/jury_mgt.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/jury_mgt.py" beforeDir="false" afterPath="$PROJECT_DIR$/jury_mgt.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" />
</list> </list>
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" /> <option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -83,13 +81,6 @@
<option name="presentableId" value="Default" /> <option name="presentableId" value="Default" />
<updated>1680804787304</updated> <updated>1680804787304</updated>
</task> </task>
<task id="LOCAL-00415" summary="27/11/2024 : 12h30">
<created>1732706635906</created>
<option name="number" value="00415" />
<option name="presentableId" value="LOCAL-00415" />
<option name="project" value="LOCAL" />
<updated>1732706635907</updated>
</task>
<task id="LOCAL-00416" summary="08/12/2024 - 12h"> <task id="LOCAL-00416" summary="08/12/2024 - 12h">
<created>1733655942461</created> <created>1733655942461</created>
<option name="number" value="00416" /> <option name="number" value="00416" />
@ -426,7 +417,14 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1747677885835</updated> <updated>1747677885835</updated>
</task> </task>
<option name="localTasksCounter" value="464" /> <task id="LOCAL-00464" summary="20/05/2025 - 17h">
<created>1747755919780</created>
<option name="number" value="00464" />
<option name="presentableId" value="LOCAL-00464" />
<option name="project" value="LOCAL" />
<updated>1747755919782</updated>
</task>
<option name="localTasksCounter" value="465" />
<servers /> <servers />
</component> </component>
<component name="Vcs.Log.Tabs.Properties"> <component name="Vcs.Log.Tabs.Properties">
@ -468,7 +466,6 @@
</option> </option>
</component> </component>
<component name="VcsManagerConfiguration"> <component name="VcsManagerConfiguration">
<MESSAGE value="10/02/205 - 21h" />
<MESSAGE value="11/02/2025 - 15h30" /> <MESSAGE value="11/02/2025 - 15h30" />
<MESSAGE value="11/02/2025 - 21h" /> <MESSAGE value="11/02/2025 - 21h" />
<MESSAGE value="18/02/2025 - 21h" /> <MESSAGE value="18/02/2025 - 21h" />
@ -493,6 +490,7 @@
<MESSAGE value="16/05/2025 - 18h" /> <MESSAGE value="16/05/2025 - 18h" />
<MESSAGE value="17/05/25 - 12h" /> <MESSAGE value="17/05/25 - 12h" />
<MESSAGE value="19/05/2025 - 20h" /> <MESSAGE value="19/05/2025 - 20h" />
<option name="LAST_COMMIT_MESSAGE" value="19/05/2025 - 20h" /> <MESSAGE value="20/05/2025 - 17h" />
<option name="LAST_COMMIT_MESSAGE" value="20/05/2025 - 17h" />
</component> </component>
</project> </project>

File diff suppressed because it is too large Load Diff

View File

@ -2071,7 +2071,8 @@ def Add_Update_Jury_Soutenance(diction):
""" """
Verification des input acceptés Verification des input acceptés
""" """
field_list = ['token', 'jury_id', 'agenda_id', 'sujet', 'note', 'observation'] field_list = ['token', 'jury_id', 'jury_soutenance_id',
'agenda_id', 'sujet', 'note', 'observation']
incom_keys = diction.keys() incom_keys = diction.keys()
for val in incom_keys: for val in incom_keys:
@ -2083,7 +2084,8 @@ def Add_Update_Jury_Soutenance(diction):
""" """
Verification des champs obligatoires Verification des champs obligatoires
""" """
field_list_obligatoire = ['token', 'jury_id', 'agenda_id', 'sujet', 'note', 'observation'] field_list_obligatoire = ['token', 'jury_id', 'jury_soutenance_id',
'agenda_id', 'sujet', 'note', 'observation']
for val in field_list_obligatoire: for val in field_list_obligatoire:
if val not in diction: if val not in diction:
@ -2116,20 +2118,31 @@ def Add_Update_Jury_Soutenance(diction):
str(inspect.stack()[0][3]) + " L'identifiant du jury est invalide ") str(inspect.stack()[0][3]) + " L'identifiant du jury est invalide ")
return False, " L'identifiant du jury est invalide" return False, " L'identifiant du jury est invalide"
# Verfier la validité de la séance (agenda) # Verfier la validité de la soutenance de jury
is_jury_agenda_valide_count = MYSY_GV.dbname['agenda'].count_documents({'_id': ObjectId(str(diction['agenda_id'])), is_jury_soutenance_valide_count = MYSY_GV.dbname['jury_soutenance'].count_documents({'_id': ObjectId(str(diction['jury_soutenance_id'])),
'valide': '1', 'valide': '1',
'locked': '0', 'locked': '0',
'related_collection':'jury', 'partner_owner_recid': str(my_partner['recid'])})
'related_collection_recid':str(diction['jury_id']),
'partner_owner_recid': str( if (is_jury_soutenance_valide_count != 1):
my_partner['recid'])}) mycommon.myprint(
str(inspect.stack()[0][3]) + " L'identifiant de la soutenance est invalide ")
return False, " L'identifiant de la soutenance est invalide "
# Verfier la validité de la séance (agenda)
is_jury_agenda_valide_count = MYSY_GV.dbname['agenda'].count_documents({'_id': ObjectId(str(diction['agenda_id'])),
'valide': '1',
'locked': '0',
'related_collection':'jury_soutenance',
'related_collection_recid':str(diction['jury_soutenance_id']),
'partner_owner_recid': str( my_partner['recid'])})
if (is_jury_agenda_valide_count != 1): if (is_jury_agenda_valide_count != 1):
mycommon.myprint( mycommon.myprint(
str(inspect.stack()[0][3]) + " L'identifiant de la séance du jury est invalide ") str(inspect.stack()[0][3]) + " L'identifiant de l'agenda de la soutenance du jury est invalide ")
return False, " L'identifiant de la séance du jury est invalide " return False, " L'identifiant de l'agenda de la soutenance du jury est invalide "
my_token = str(diction['token']) my_token = str(diction['token'])
@ -2143,7 +2156,7 @@ def Add_Update_Jury_Soutenance(diction):
new_data['date_update'] = str(datetime.now()) new_data['date_update'] = str(datetime.now())
result = MYSY_GV.dbname['jury_soutenance'].find_one_and_update( result = MYSY_GV.dbname['jury_soutenance'].find_one_and_update(
{'agenda_id':str(diction['agenda_id']), {'_id':ObjectId(str(diction['jury_soutenance_id'])),
'jury_id':str(diction['jury_id']), 'jury_id':str(diction['jury_id']),
'partner_owner_recid':str(my_partner['recid']) 'partner_owner_recid':str(my_partner['recid'])
}, },
@ -2164,7 +2177,7 @@ def Add_Update_Jury_Soutenance(diction):
# Pour la collection inscription # Pour la collection inscription
history_event_dict = {} history_event_dict = {}
history_event_dict['token'] = str(diction['token']) history_event_dict['token'] = str(my_token)
history_event_dict['related_collection'] = "jury" history_event_dict['related_collection'] = "jury"
history_event_dict['related_collection_recid'] = str(diction['jury_id']) history_event_dict['related_collection_recid'] = str(diction['jury_id'])
history_event_dict['action_date'] = str(now) history_event_dict['action_date'] = str(now)