dddssx
parent
55f8fc300b
commit
5eb922559d
|
@ -1,11 +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="ddd">
|
<list default="true" id="c6d0259a-16e1-410d-91a1-830590ee2a08" name="Changes" comment="dddss">
|
||||||
<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$/Session_Formation.py" beforeDir="false" afterPath="$PROJECT_DIR$/Session_Formation.py" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/Session_Formation.py" beforeDir="false" afterPath="$PROJECT_DIR$/Session_Formation.py" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/partner_order.py" beforeDir="false" afterPath="$PROJECT_DIR$/partner_order.py" 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" />
|
||||||
|
@ -76,13 +75,6 @@
|
||||||
<option name="presentableId" value="Default" />
|
<option name="presentableId" value="Default" />
|
||||||
<updated>1680804787304</updated>
|
<updated>1680804787304</updated>
|
||||||
</task>
|
</task>
|
||||||
<task id="LOCAL-00323" summary="qsdsqsqdsq">
|
|
||||||
<created>1717601060943</created>
|
|
||||||
<option name="number" value="00323" />
|
|
||||||
<option name="presentableId" value="LOCAL-00323" />
|
|
||||||
<option name="project" value="LOCAL" />
|
|
||||||
<updated>1717601060943</updated>
|
|
||||||
</task>
|
|
||||||
<task id="LOCAL-00324" summary="05/06/2024 - 23h">
|
<task id="LOCAL-00324" summary="05/06/2024 - 23h">
|
||||||
<created>1717621132734</created>
|
<created>1717621132734</created>
|
||||||
<option name="number" value="00324" />
|
<option name="number" value="00324" />
|
||||||
|
@ -419,7 +411,14 @@
|
||||||
<option name="project" value="LOCAL" />
|
<option name="project" value="LOCAL" />
|
||||||
<updated>1723555903066</updated>
|
<updated>1723555903066</updated>
|
||||||
</task>
|
</task>
|
||||||
<option name="localTasksCounter" value="372" />
|
<task id="LOCAL-00372" summary="dddss">
|
||||||
|
<created>1723804083490</created>
|
||||||
|
<option name="number" value="00372" />
|
||||||
|
<option name="presentableId" value="LOCAL-00372" />
|
||||||
|
<option name="project" value="LOCAL" />
|
||||||
|
<updated>1723804083490</updated>
|
||||||
|
</task>
|
||||||
|
<option name="localTasksCounter" value="373" />
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
<component name="Vcs.Log.Tabs.Properties">
|
<component name="Vcs.Log.Tabs.Properties">
|
||||||
|
@ -461,7 +460,6 @@
|
||||||
</option>
|
</option>
|
||||||
</component>
|
</component>
|
||||||
<component name="VcsManagerConfiguration">
|
<component name="VcsManagerConfiguration">
|
||||||
<MESSAGE value="13/07/2024 - 22h" />
|
|
||||||
<MESSAGE value="14/07/2024 - 22h" />
|
<MESSAGE value="14/07/2024 - 22h" />
|
||||||
<MESSAGE value="dqsdqs" />
|
<MESSAGE value="dqsdqs" />
|
||||||
<MESSAGE value="dqsdqss" />
|
<MESSAGE value="dqsdqss" />
|
||||||
|
@ -486,6 +484,7 @@
|
||||||
<MESSAGE value="11/08/2024 - 18h32s" />
|
<MESSAGE value="11/08/2024 - 18h32s" />
|
||||||
<MESSAGE value="dd" />
|
<MESSAGE value="dd" />
|
||||||
<MESSAGE value="ddd" />
|
<MESSAGE value="ddd" />
|
||||||
<option name="LAST_COMMIT_MESSAGE" value="ddd" />
|
<MESSAGE value="dddss" />
|
||||||
|
<option name="LAST_COMMIT_MESSAGE" value="dddss" />
|
||||||
</component>
|
</component>
|
||||||
</project>
|
</project>
|
|
@ -1138,7 +1138,7 @@ def GetActiveSession_Cities_And_Distance_Formation_List(diction):
|
||||||
|
|
||||||
RetObject = []
|
RetObject = []
|
||||||
|
|
||||||
print(" ### GetActiveSessionFormation_List myquery = ", myquery)
|
print(" ### GetActiveSession_Cities_And_Distance_Formation_List myquery = ", myquery)
|
||||||
for retval in coll_session.find(myquery):
|
for retval in coll_session.find(myquery):
|
||||||
|
|
||||||
local_tmp = retval
|
local_tmp = retval
|
||||||
|
@ -1147,6 +1147,10 @@ def GetActiveSession_Cities_And_Distance_Formation_List(diction):
|
||||||
tmp_debut_inscritp = str(local_tmp['date_debut_inscription']).strip().split(" ")
|
tmp_debut_inscritp = str(local_tmp['date_debut_inscription']).strip().split(" ")
|
||||||
tmp_fin_inscritp = str(local_tmp['date_fin_inscription']).strip().split(" ")
|
tmp_fin_inscritp = str(local_tmp['date_fin_inscription']).strip().split(" ")
|
||||||
|
|
||||||
|
local_status_tmp_debut_inscritp = mycommon.CheckisDate(str(tmp_debut_inscritp[0]))
|
||||||
|
local_status_tmp_fin_inscritp = mycommon.CheckisDate(str(tmp_fin_inscritp[0]))
|
||||||
|
|
||||||
|
if( local_status_tmp_debut_inscritp and local_status_tmp_fin_inscritp ):
|
||||||
debut_inscr = datetime.strptime(str(tmp_debut_inscritp[0]).strip(), '%d/%m/%Y')
|
debut_inscr = datetime.strptime(str(tmp_debut_inscritp[0]).strip(), '%d/%m/%Y')
|
||||||
fin_inscr = datetime.strptime(str(tmp_fin_inscritp[0]).strip(), '%d/%m/%Y')
|
fin_inscr = datetime.strptime(str(tmp_fin_inscritp[0]).strip(), '%d/%m/%Y')
|
||||||
|
|
||||||
|
@ -1539,6 +1543,7 @@ def GetAllValideSessionPartner_List(diction):
|
||||||
|
|
||||||
RetObject.append(mycommon.JSONEncoder().encode(val))
|
RetObject.append(mycommon.JSONEncoder().encode(val))
|
||||||
|
|
||||||
|
|
||||||
return True, RetObject
|
return True, RetObject
|
||||||
|
|
||||||
|
|
||||||
|
@ -4215,12 +4220,26 @@ def Delete_SessionFormation(diction):
|
||||||
|
|
||||||
# Verifier qu'il n'y a pas d'incription valide
|
# Verifier qu'il n'y a pas d'incription valide
|
||||||
inscription_count_qry = {'session_id':str(session_id), 'status':{'$in':['0', '1', '2']} , 'partner_owner_recid':str(partner_recid)}
|
inscription_count_qry = {'session_id':str(session_id), 'status':{'$in':['0', '1', '2']} , 'partner_owner_recid':str(partner_recid)}
|
||||||
print(" #### inscription_count_qry aa =", inscription_count_qry)
|
#print(" #### inscription_count_qry aa =", inscription_count_qry)
|
||||||
inscription_count = MYSY_GV.dbname['inscription'].count_documents(inscription_count_qry)
|
inscription_count = MYSY_GV.dbname['inscription'].count_documents(inscription_count_qry)
|
||||||
if( inscription_count > 0 ):
|
if( inscription_count > 0 ):
|
||||||
mycommon.myprint(str(inspect.stack()[0][3]) + " - Impossible de supprimer la session. Vous avez "+str(inscription_count)+" inscription(s) associée(s) ")
|
mycommon.myprint(str(inspect.stack()[0][3]) + " - Impossible de supprimer la session. Vous avez "+str(inscription_count)+" inscription(s) associée(s) ")
|
||||||
return False, "Impossible de supprimer la session. Vous avez "+str(inscription_count)+" inscription(s) associée(s)"
|
return False, "Impossible de supprimer la session. Vous avez "+str(inscription_count)+" inscription(s) associée(s)"
|
||||||
|
|
||||||
|
|
||||||
|
"""
|
||||||
|
Verifier que l'inscription n'est pas utilisée dans un devis : 'partner_order_line'
|
||||||
|
"""
|
||||||
|
is_session_in_partner_order_line_count = MYSY_GV.dbname['partner_order_line'].count_documents({'order_line_session_id':str(session_id),
|
||||||
|
'partner_owner_recid':str(partner_recid)})
|
||||||
|
|
||||||
|
if( is_session_in_partner_order_line_count > 0 ):
|
||||||
|
mycommon.myprint(str(inspect.stack()[0][3]) + " - Impossible de supprimer la session. Vous avez " + str(
|
||||||
|
is_session_in_partner_order_line_count) + " devis ou commandes (s) associé(s) ")
|
||||||
|
return False, "Impossible de supprimer la session. Vous avez " + str(
|
||||||
|
is_session_in_partner_order_line_count) + " devis ou commandes (s) associé(s) "
|
||||||
|
|
||||||
|
|
||||||
# Suppression des insciption eventuellement annulées
|
# Suppression des insciption eventuellement annulées
|
||||||
MYSY_GV.dbname['inscription'].delete_many({'session_id':str(session_id)})
|
MYSY_GV.dbname['inscription'].delete_many({'session_id':str(session_id)})
|
||||||
|
|
||||||
|
@ -4316,9 +4335,25 @@ def Delete_List_SessionFormation(diction):
|
||||||
inscription_count = MYSY_GV.dbname['inscription'].count_documents(inscription_count_qry)
|
inscription_count = MYSY_GV.dbname['inscription'].count_documents(inscription_count_qry)
|
||||||
if( inscription_count > 0 ):
|
if( inscription_count > 0 ):
|
||||||
session_formation_data = MYSY_GV.dbname['session_formation'].find_one({'_id':ObjectId(str(session_id)), 'partner_owner_recid':str(partner_recid)})
|
session_formation_data = MYSY_GV.dbname['session_formation'].find_one({'_id':ObjectId(str(session_id)), 'partner_owner_recid':str(partner_recid)})
|
||||||
mycommon.myprint(str(inspect.stack()[0][3]) + " - Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez "+str(inscription_count)+" inscriptions associées.Suppression en masse annulée ")
|
mycommon.myprint(str(inspect.stack()[0][3]) + " Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez "+str(inscription_count)+" inscriptions associées.Suppression en masse annulée ")
|
||||||
return False, "Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez "+str(inscription_count)+" inscriptions associées. Suppression en masse annulée"
|
return False, "Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez "+str(inscription_count)+" inscriptions associées. Suppression en masse annulée"
|
||||||
|
|
||||||
|
"""
|
||||||
|
Verifier que l'inscription n'est pas utilisée dans un devis : 'partner_order_line'
|
||||||
|
"""
|
||||||
|
is_session_in_partner_order_line_count = MYSY_GV.dbname['partner_order_line'].count_documents(
|
||||||
|
{'order_line_session_id': str(session_id),
|
||||||
|
'partner_owner_recid': str(partner_recid)})
|
||||||
|
|
||||||
|
if (is_session_in_partner_order_line_count > 0):
|
||||||
|
session_formation_data = MYSY_GV.dbname['session_formation'].find_one(
|
||||||
|
{'_id': ObjectId(str(session_id)), 'partner_owner_recid': str(partner_recid)})
|
||||||
|
|
||||||
|
mycommon.myprint(str(inspect.stack()[0][3]) + " Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez " + str(
|
||||||
|
is_session_in_partner_order_line_count) + " devis ou commandes (s) associé(s) ")
|
||||||
|
return False, "Impossible de supprimer la session "+str(session_formation_data['code_session'])+". Vous avez " + str(
|
||||||
|
is_session_in_partner_order_line_count) + " devis ou commandes (s) associé(s) "
|
||||||
|
|
||||||
# Suppression des insciption eventuellement annulées
|
# Suppression des insciption eventuellement annulées
|
||||||
MYSY_GV.dbname['inscription'].delete_many({'session_id':{'$in':list_session_id}})
|
MYSY_GV.dbname['inscription'].delete_many({'session_id':{'$in':list_session_id}})
|
||||||
|
|
||||||
|
@ -12540,7 +12575,7 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
'lms_class_code',
|
'lms_class_code',
|
||||||
'session_ondemande', 'source', 'session_etape', 'pays', 'formateur_id',
|
'session_ondemande', 'source', 'session_etape', 'pays', 'formateur_id',
|
||||||
'titre', 'location_type', 'is_bpf', 'site_formation_id', 'price_by',
|
'titre', 'location_type', 'is_bpf', 'site_formation_id', 'price_by',
|
||||||
'quotation_line_id']
|
'quotation_line_id', 'resa_inscrit']
|
||||||
|
|
||||||
incom_keys = diction.keys()
|
incom_keys = diction.keys()
|
||||||
for val in incom_keys:
|
for val in incom_keys:
|
||||||
|
@ -12553,7 +12588,7 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
Verification de la liste des champs obligatoires
|
Verification de la liste des champs obligatoires
|
||||||
"""
|
"""
|
||||||
field_list_obligatoire = ['token', 'date_debut', 'date_fin', 'nb_participant',
|
field_list_obligatoire = ['token', 'date_debut', 'date_fin', 'nb_participant',
|
||||||
'class_id','code_session', 'quotation_line_id' ]
|
'class_id','code_session', 'quotation_line_id', 'resa_inscrit' ]
|
||||||
|
|
||||||
for val in field_list_obligatoire:
|
for val in field_list_obligatoire:
|
||||||
if val not in diction:
|
if val not in diction:
|
||||||
|
@ -12610,10 +12645,17 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
str(inspect.stack()[0][3]) + " Le devis n'est pas valide ")
|
str(inspect.stack()[0][3]) + " Le devis n'est pas valide ")
|
||||||
return False, " Le devis n'est pas valide "
|
return False, " Le devis n'est pas valide "
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
local_resa_inscrit = diction['resa_inscrit']
|
||||||
|
local_line_qotation_qty = diction['nb_participant']
|
||||||
|
local_quotation_line_id = diction['quotation_line_id']
|
||||||
|
|
||||||
|
|
||||||
mydata = diction
|
mydata = diction
|
||||||
|
|
||||||
|
|
||||||
del diction['token']
|
del diction['token']
|
||||||
|
del diction['resa_inscrit']
|
||||||
|
del diction['quotation_line_id']
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -12628,6 +12670,9 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
mydata['price_by'] = "persession"
|
mydata['price_by'] = "persession"
|
||||||
mydata['session_status'] = "1"
|
mydata['session_status'] = "1"
|
||||||
|
|
||||||
|
mydata['date_debut_inscription'] = str(mydata['date_debut'])
|
||||||
|
mydata['date_fin_inscription'] = str(mydata['date_fin'])
|
||||||
|
|
||||||
mydata['date_update'] = str(datetime.now())
|
mydata['date_update'] = str(datetime.now())
|
||||||
mydata['update_by'] = str(my_partner['_id'])
|
mydata['update_by'] = str(my_partner['_id'])
|
||||||
mydata['partner_owner_recid'] = str(my_partner['recid'])
|
mydata['partner_owner_recid'] = str(my_partner['recid'])
|
||||||
|
@ -12687,7 +12732,7 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
Apres la creation de la session, on met à jour la ligne du devis en ajoutant l'id de la session
|
Apres la creation de la session, on met à jour la ligne du devis en ajoutant l'id de la session
|
||||||
"""
|
"""
|
||||||
update_quotation_line_id = MYSY_GV.dbname['partner_order_line'].find_one_and_update(
|
update_quotation_line_id = MYSY_GV.dbname['partner_order_line'].find_one_and_update(
|
||||||
{'_id': ObjectId(str(diction['quotation_line_id'])),
|
{'_id': ObjectId(str(local_quotation_line_id)),
|
||||||
'partner_owner_recid': str(my_partner['recid']),
|
'partner_owner_recid': str(my_partner['recid']),
|
||||||
'valide': '1',
|
'valide': '1',
|
||||||
'locked': '0'},
|
'locked': '0'},
|
||||||
|
@ -12697,6 +12742,71 @@ def Add_SessionFormation_From_Quotation_Line(diction):
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
"""
|
||||||
|
Si l'option de reservation des inscrit est activée alors on reserve les places
|
||||||
|
|
||||||
|
"""
|
||||||
|
if( local_resa_inscrit == "1"):
|
||||||
|
cpt = 0
|
||||||
|
line_qotation_qty = mycommon.tryInt(local_line_qotation_qty )
|
||||||
|
|
||||||
|
quotation_line_data = MYSY_GV.dbname['partner_order_line'].find_one(
|
||||||
|
{'_id': ObjectId(str(local_quotation_line_id)),
|
||||||
|
'valide': '1',
|
||||||
|
'locked': '0',
|
||||||
|
'partner_owner_recid': str(my_partner['recid']),
|
||||||
|
'order_line_type': 'devis',
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
quotation_header_data = MYSY_GV.dbname['partner_order_header'].find_one(
|
||||||
|
{'_id':ObjectId(str(quotation_line_data['order_header_id'])),
|
||||||
|
'order_header_ref_interne':str(quotation_line_data['order_header_ref_interne']),
|
||||||
|
'valide': '1',
|
||||||
|
'locked': '0',
|
||||||
|
'partner_owner_recid': str(my_partner['recid']),
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
|
nb_resa_line = 0
|
||||||
|
while (cpt < line_qotation_qty):
|
||||||
|
cpt = cpt + 1
|
||||||
|
|
||||||
|
new_data = {}
|
||||||
|
new_data['nom'] = str(quotation_header_data['order_header_ref_interne']) + "_Reservation_Nom_" + str(cpt)
|
||||||
|
new_data['prenom'] = str(quotation_header_data['order_header_ref_interne']) + "_Reservation_Prenom_" + str(cpt)
|
||||||
|
new_data['email'] = str(quotation_header_data['order_header_ref_interne']) + "_Reservation_mail_" + str( cpt) + "@mail.com"
|
||||||
|
new_data['telephone'] = "01010101"
|
||||||
|
new_data['modefinancement'] = ""
|
||||||
|
new_data['class_internal_url'] = str(class_id_data['internal_url'])
|
||||||
|
new_data['session_id'] = str(local_inserted_id)
|
||||||
|
|
||||||
|
new_data['client_rattachement_id'] = str(quotation_header_data['order_header_client_id'])
|
||||||
|
new_data['civilite'] = "neutre"
|
||||||
|
new_data['quotation_id'] = str(quotation_line_data['order_header_id'])
|
||||||
|
new_data['status'] = "0"
|
||||||
|
|
||||||
|
"""
|
||||||
|
/!\
|
||||||
|
22/04/2024 :On a besoin du token pour utiliser la fonction standard.
|
||||||
|
On va aller recuperer le token du compte principale du partner
|
||||||
|
/!\
|
||||||
|
"""
|
||||||
|
main_account_data = MYSY_GV.dbname['partnair_account'].find_one(
|
||||||
|
{'recid': str(diction['partner_owner_recid']),
|
||||||
|
'active': '1', 'is_partner_admin_account': '1'})
|
||||||
|
new_data['token'] = str(main_account_data['token'])
|
||||||
|
|
||||||
|
local_insert_status, local_insert_retval = Inscription_mgt.AddStagiairetoClass(new_data)
|
||||||
|
|
||||||
|
if (local_insert_status is False):
|
||||||
|
is_warning = "1"
|
||||||
|
warning_msg = warning_msg + "\n" + str(local_insert_retval)
|
||||||
|
|
||||||
|
else:
|
||||||
|
nb_resa_line = nb_resa_line + 1
|
||||||
|
|
||||||
return True, " La session de formation à bien été créée"
|
return True, " La session de formation à bien été créée"
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -2268,6 +2268,10 @@ def Add_Update_Partner_Order_Line(diction):
|
||||||
return False, " 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'])
|
order_line_session_id = str(diction['order_line_session_id'])
|
||||||
|
|
||||||
|
"""
|
||||||
|
/!\ : Il peut arrivé qu'on souhaite supprimer la session du devis ou la commande, alors on autorise la mise à jour meme si vide
|
||||||
|
"""
|
||||||
data['order_line_session_id'] = order_line_session_id
|
data['order_line_session_id'] = order_line_session_id
|
||||||
|
|
||||||
|
|
||||||
|
@ -3359,7 +3363,7 @@ 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() ):
|
if( "order_line_session_id" in retval.keys() and retval['order_line_session_id']):
|
||||||
user['order_line_session_id'] = retval['order_line_session_id']
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
# Recuperation du code de la session
|
# Recuperation du code de la session
|
||||||
|
@ -3521,7 +3525,7 @@ 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()):
|
if ("order_line_session_id" in retval.keys() and retval['order_line_session_id']):
|
||||||
user['order_line_session_id'] = retval['order_line_session_id']
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
# Recuperation du code de la session
|
# Recuperation du code de la session
|
||||||
|
@ -4515,7 +4519,7 @@ 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()):
|
if ("order_line_session_id" in retval.keys() and retval['order_line_session_id']):
|
||||||
user['order_line_session_id'] = retval['order_line_session_id']
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
# Recuperation du code de la session
|
# Recuperation du code de la session
|
||||||
|
@ -4680,7 +4684,7 @@ def Get_Given_Line_Of_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()):
|
if ("order_line_session_id" in retval.keys() and retval['order_line_session_id']):
|
||||||
user['order_line_session_id'] = retval['order_line_session_id']
|
user['order_line_session_id'] = retval['order_line_session_id']
|
||||||
|
|
||||||
# Recuperation du code de la session
|
# Recuperation du code de la session
|
||||||
|
@ -4830,7 +4834,7 @@ def Compute_Order_Header(diction):
|
||||||
partner_taux_tva = IsInt_retval
|
partner_taux_tva = IsInt_retval
|
||||||
|
|
||||||
|
|
||||||
print(" ### COMPUTE : le taux de TVA = ", str(partner_taux_tva))
|
#print(" ### COMPUTE : le taux de TVA = ", str(partner_taux_tva))
|
||||||
|
|
||||||
# Verification de la validité de l'order
|
# Verification de la validité de l'order
|
||||||
qry = {'_id':ObjectId(str(diction['_id'])), 'valide':'1', 'locked':'0', 'partner_owner_recid':str(my_partner['recid'])}
|
qry = {'_id':ObjectId(str(diction['_id'])), 'valide':'1', 'locked':'0', 'partner_owner_recid':str(my_partner['recid'])}
|
||||||
|
|
Loading…
Reference in New Issue