19/04/2024 - 22h22
parent
3cf72f4788
commit
08b720adb6
|
@ -1,9 +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="17/04/2024 - 21h04">
|
<list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="18/04/2024 - 21h50">
|
||||||
<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$/partner_order.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_order.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" />
|
||||||
|
@ -73,13 +74,6 @@
|
||||||
<option name="presentableId" value="Default" />
|
<option name="presentableId" value="Default" />
|
||||||
<updated>1680804787304</updated>
|
<updated>1680804787304</updated>
|
||||||
</task>
|
</task>
|
||||||
<task id="LOCAL-00221" summary="13/02/2024 - 11h">
|
|
||||||
<created>1707817778812</created>
|
|
||||||
<option name="number" value="00221" />
|
|
||||||
<option name="presentableId" value="LOCAL-00221" />
|
|
||||||
<option name="project" value="LOCAL" />
|
|
||||||
<updated>1707817778813</updated>
|
|
||||||
</task>
|
|
||||||
<task id="LOCAL-00222" summary="17/02/2024 - 11h">
|
<task id="LOCAL-00222" summary="17/02/2024 - 11h">
|
||||||
<created>1708179293702</created>
|
<created>1708179293702</created>
|
||||||
<option name="number" value="00222" />
|
<option name="number" value="00222" />
|
||||||
|
@ -416,7 +410,14 @@
|
||||||
<option name="project" value="LOCAL" />
|
<option name="project" value="LOCAL" />
|
||||||
<updated>1713380709746</updated>
|
<updated>1713380709746</updated>
|
||||||
</task>
|
</task>
|
||||||
<option name="localTasksCounter" value="270" />
|
<task id="LOCAL-00270" summary="18/04/2024 - 21h50">
|
||||||
|
<created>1713470069720</created>
|
||||||
|
<option name="number" value="00270" />
|
||||||
|
<option name="presentableId" value="LOCAL-00270" />
|
||||||
|
<option name="project" value="LOCAL" />
|
||||||
|
<updated>1713470069721</updated>
|
||||||
|
</task>
|
||||||
|
<option name="localTasksCounter" value="271" />
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
<component name="Vcs.Log.Tabs.Properties">
|
<component name="Vcs.Log.Tabs.Properties">
|
||||||
|
@ -458,7 +459,6 @@
|
||||||
</option>
|
</option>
|
||||||
</component>
|
</component>
|
||||||
<component name="VcsManagerConfiguration">
|
<component name="VcsManagerConfiguration">
|
||||||
<MESSAGE value="12/03/2024 - 20h30" />
|
|
||||||
<MESSAGE value="19/03/2024 - 17h30" />
|
<MESSAGE value="19/03/2024 - 17h30" />
|
||||||
<MESSAGE value="20/03/2024 - 22h30" />
|
<MESSAGE value="20/03/2024 - 22h30" />
|
||||||
<MESSAGE value="20/03/2024 - 22h30d" />
|
<MESSAGE value="20/03/2024 - 22h30d" />
|
||||||
|
@ -483,6 +483,7 @@
|
||||||
<MESSAGE value="12/04/2024 - 15h05" />
|
<MESSAGE value="12/04/2024 - 15h05" />
|
||||||
<MESSAGE value="14/04/2024 - 23h05" />
|
<MESSAGE value="14/04/2024 - 23h05" />
|
||||||
<MESSAGE value="17/04/2024 - 21h04" />
|
<MESSAGE value="17/04/2024 - 21h04" />
|
||||||
<option name="LAST_COMMIT_MESSAGE" value="17/04/2024 - 21h04" />
|
<MESSAGE value="18/04/2024 - 21h50" />
|
||||||
|
<option name="LAST_COMMIT_MESSAGE" value="18/04/2024 - 21h50" />
|
||||||
</component>
|
</component>
|
||||||
</project>
|
</project>
|
2404
Log/log_file.log
2404
Log/log_file.log
File diff suppressed because it is too large
Load Diff
|
@ -935,7 +935,7 @@ def Add_Partner_Quotation(diction):
|
||||||
'order_line_tax', 'order_line_type_reduction', 'order_line_type_valeur',
|
'order_line_tax', 'order_line_type_reduction', 'order_line_type_valeur',
|
||||||
'order_line_montant_reduction']
|
'order_line_montant_reduction']
|
||||||
|
|
||||||
print(" ### order_line = ", order_line)
|
#print(" ### order_line = ", order_line)
|
||||||
incom_keys = order_line.keys()
|
incom_keys = order_line.keys()
|
||||||
for val in incom_keys:
|
for val in incom_keys:
|
||||||
if val not in field_list:
|
if val not in field_list:
|
||||||
|
@ -992,7 +992,7 @@ def Add_Partner_Quotation(diction):
|
||||||
# /!\ Affectation de la reference interne de la commande
|
# /!\ Affectation de la reference interne de la commande
|
||||||
data['order_header_ref_interne'] = retval_sequence_order['prefixe'] + str(current_seq_value)
|
data['order_header_ref_interne'] = retval_sequence_order['prefixe'] + str(current_seq_value)
|
||||||
|
|
||||||
print(" #### diction['order_header_ref_interne'] = ", str(data['order_header_ref_interne']))
|
#print(" #### diction['order_header_ref_interne'] = ", str(data['order_header_ref_interne']))
|
||||||
|
|
||||||
## Verifier qu'il n'y pas une commande avec la meme reference interne
|
## Verifier qu'il n'y pas une commande avec la meme reference interne
|
||||||
existe_cmd_ref_interne_count = MYSY_GV.dbname['partner_order_header'].count_documents(
|
existe_cmd_ref_interne_count = MYSY_GV.dbname['partner_order_header'].count_documents(
|
||||||
|
@ -2009,7 +2009,7 @@ def Add_Update_Partner_Order_Line(diction):
|
||||||
"""
|
"""
|
||||||
Verification des input acceptés
|
Verification des input acceptés
|
||||||
"""
|
"""
|
||||||
field_list = ['token', 'order_line_formation', 'order_line_qty', 'order_line_prix_unitaire',
|
field_list = ['token', 'order_line_formation', 'order_line_session_id', 'order_line_qty', 'order_line_prix_unitaire',
|
||||||
'order_line_tax', 'order_line_type_reduction', 'order_line_type_valeur',
|
'order_line_tax', 'order_line_type_reduction', 'order_line_type_valeur',
|
||||||
'order_line_montant_reduction', 'order_line_id', 'order_header_ref_interne',
|
'order_line_montant_reduction', 'order_line_id', 'order_header_ref_interne',
|
||||||
'order_header_id', 'order_line_status', 'order_line_type', 'order_line_comment',
|
'order_header_id', 'order_line_status', 'order_line_type', 'order_line_comment',
|
||||||
|
@ -2059,6 +2059,23 @@ def Add_Update_Partner_Order_Line(diction):
|
||||||
order_line_formation = diction['order_line_formation']
|
order_line_formation = diction['order_line_formation']
|
||||||
data['order_line_formation'] = order_line_formation
|
data['order_line_formation'] = order_line_formation
|
||||||
|
|
||||||
|
|
||||||
|
# Si l'utilisateur a choisi une session, verifier qu'elle est valide
|
||||||
|
order_line_session_id = ""
|
||||||
|
if( "order_line_session_id" in diction.keys() and diction['order_line_session_id']):
|
||||||
|
is_valide_session_id_count = MYSY_GV.dbname['session_formation'].count_documents({'_id':ObjectId(str(diction['order_line_session_id'])),
|
||||||
|
'partner_owner_recid':str(my_partner['recid']),
|
||||||
|
'valide':'1'})
|
||||||
|
|
||||||
|
if( is_valide_session_id_count <= 0 ):
|
||||||
|
mycommon.myprint(
|
||||||
|
str(inspect.stack()[0][3]) + " L'identifiant de session de formation "+str(diction['order_line_session_id'])+" n'est pas valide ")
|
||||||
|
return False, " L'identifiant de session de formation "+str(diction['order_line_session_id'])+" n'est pas valide "
|
||||||
|
|
||||||
|
order_line_session_id = str(diction['order_line_session_id'])
|
||||||
|
data['order_line_session_id'] = order_line_session_id
|
||||||
|
|
||||||
|
|
||||||
order_line_type = ""
|
order_line_type = ""
|
||||||
if ("order_line_type" in diction.keys()):
|
if ("order_line_type" in diction.keys()):
|
||||||
if diction['order_line_type']:
|
if diction['order_line_type']:
|
||||||
|
@ -3043,7 +3060,7 @@ def Get_Given_Partner_Order_Lines(diction):
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
print("#### Get_Given_Partner_Order_Lines : query pip= ", query)
|
#print("#### Get_Given_Partner_Order_Lines : query pip= ", query)
|
||||||
|
|
||||||
for retval in MYSY_GV.dbname['partner_order_line'].aggregate(query):
|
for retval in MYSY_GV.dbname['partner_order_line'].aggregate(query):
|
||||||
if ('myclass_collection' in retval.keys() and len(retval['myclass_collection']) > 0):
|
if ('myclass_collection' in retval.keys() and len(retval['myclass_collection']) > 0):
|
||||||
|
@ -3059,6 +3076,22 @@ def Get_Given_Partner_Order_Lines(diction):
|
||||||
user['valide'] = retval['valide']
|
user['valide'] = retval['valide']
|
||||||
user['locked'] = retval['locked']
|
user['locked'] = retval['locked']
|
||||||
|
|
||||||
|
if( "order_line_session_id" in retval.keys() ):
|
||||||
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
|
# Recuperation du code de la session
|
||||||
|
local_session_data = MYSY_GV.dbname['session_formation'].find_one({'_id':ObjectId(str(retval['order_line_session_id'])),
|
||||||
|
'partner_owner_recid':str(my_partner['recid']),
|
||||||
|
'valide':'1'})
|
||||||
|
if( local_session_data and "code_session" in local_session_data.keys() ):
|
||||||
|
user['order_line_session_code_session'] = local_session_data['code_session']
|
||||||
|
else:
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
else:
|
||||||
|
user['order_line_session_id'] = ""
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
|
||||||
|
|
||||||
if ("order_line_montant_reduction" in retval.keys()):
|
if ("order_line_montant_reduction" in retval.keys()):
|
||||||
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
||||||
else:
|
else:
|
||||||
|
@ -3242,6 +3275,23 @@ def Get_Given_Partner_Order_Lines_From_order_ref_interne(diction):
|
||||||
user['valide'] = retval['valide']
|
user['valide'] = retval['valide']
|
||||||
user['locked'] = retval['locked']
|
user['locked'] = retval['locked']
|
||||||
|
|
||||||
|
if ("order_line_session_id" in retval.keys()):
|
||||||
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
|
# Recuperation du code de la session
|
||||||
|
local_session_data = MYSY_GV.dbname['session_formation'].find_one(
|
||||||
|
{'_id': ObjectId(str(retval['order_line_session_id'])),
|
||||||
|
'partner_owner_recid': str(my_partner['recid']),
|
||||||
|
'valide': '1'})
|
||||||
|
if (local_session_data and "code_session" in local_session_data.keys()):
|
||||||
|
user['order_line_session_code_session'] = local_session_data['code_session']
|
||||||
|
else:
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
else:
|
||||||
|
user['order_line_session_id'] = ""
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
|
||||||
|
|
||||||
if( "order_line_montant_reduction" in retval.keys()):
|
if( "order_line_montant_reduction" in retval.keys()):
|
||||||
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
||||||
else:
|
else:
|
||||||
|
@ -3880,6 +3930,23 @@ def Get_Given_Line_Of_Partner_Order_Lines(diction):
|
||||||
user['order_header_id'] = retval['order_header_id']
|
user['order_header_id'] = retval['order_header_id']
|
||||||
user['order_header_ref_interne'] = retval['order_header_ref_interne']
|
user['order_header_ref_interne'] = retval['order_header_ref_interne']
|
||||||
|
|
||||||
|
if ("order_line_session_id" in retval.keys()):
|
||||||
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
|
# Recuperation du code de la session
|
||||||
|
local_session_data = MYSY_GV.dbname['session_formation'].find_one(
|
||||||
|
{'_id': ObjectId(str(retval['order_line_session_id'])),
|
||||||
|
'partner_owner_recid': str(my_partner['recid']),
|
||||||
|
'valide': '1'})
|
||||||
|
if (local_session_data and "code_session" in local_session_data.keys()):
|
||||||
|
user['order_line_session_code_session'] = local_session_data['code_session']
|
||||||
|
else:
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
else:
|
||||||
|
user['order_line_session_id'] = ""
|
||||||
|
user['order_line_session_code_session'] = ""
|
||||||
|
|
||||||
|
|
||||||
if ("order_line_montant_reduction" in retval.keys()):
|
if ("order_line_montant_reduction" in retval.keys()):
|
||||||
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
user['order_line_montant_reduction'] = retval['order_line_montant_reduction']
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue