我正在测试以下代码, 我需要为以下变量创建条件(如果):
"date" : "rdvPrestationHoraireDate",
"heure" : "rdvPrestationHoraireHeure",
"heureDebut" : "rdvPrestationHoraireHeureDebut",
"heureFin" : "rdvPrestationHoraireHeureFin", `
更多详细信息:
pm.environment.set("rdvPrestationId", "");
pm.environment.set("rdvPrestationHoraireName", "HoraireFixe");
pm.environment.set("rdvPrestationHoraireDate", "{{aPartirDuLendemain}}");
pm.environment.set("rdvPrestationTypeName", "Telephonique");
pm.environment.set("rdvPrestationNomIntervenant", "STARK");
pm.environment.set("rdvPrestationPrenomIntervenant", "Tony");
pm.environment.set("rdvPrestationTelephoneIntervenant", "0549010203");
pm.environment.set("rdvPrestationReferenceIntervenant", "IM1234");
pm.environment.set("RdvMotifModificationName", "");
pm.environment.set("rdvPrestationNotes", "Notes pris pour rendez vous");
pm.environment.set("rdvPrestationDuree", "60");
var exempleFlux = {
"prestationId" : "rdvPrestationId",
"horaire" : {
"name" : "rdvPrestationHoraireName",
"value" : {
"date" : "rdvPrestationHoraireDate",
"heure" : "rdvPrestationHoraireHeure",
"heureDebut" : "rdvPrestationHoraireHeureDebut",
"heureFin" : "rdvPrestationHoraireHeureFin",
},
"label" : "",
},
"dureeRendezVous" : "rdvPrestationDuree",
"notes" : "rdvPrestationNotes",
"typeRendezVous" : {
"name" : "rdvPrestationTypeName"
},
"MotifModificationRdv":{
"name": "RdvMotifModificationName"
} ,
"nomIntervenant" : "rdvPrestationNomIntervenant",
"prenomIntervenant" : "rdvPrestationPrenomIntervenant",
"telephoneIntervenant" : "rdvPrestationTelephoneIntervenant",
"referenceIntervenant" : "rdvPrestationReferenceIntervenant",
}