arbitre : rappel du choix retenu avant l'application d'EVCS
This commit is contained in:
@@ -56,7 +56,7 @@ async function application() {
|
|||||||
const st = loadState();
|
const st = loadState();
|
||||||
if (st.appliqueId === a.id || st.questionId !== a.id) return ''; // déjà relayé, ou arbitrage jamais posé par nous
|
if (st.appliqueId === a.id || st.questionId !== a.id) return ''; // déjà relayé, ou arbitrage jamais posé par nous
|
||||||
saveState({ ...st, appliqueId: a.id });
|
saveState({ ...st, appliqueId: a.id });
|
||||||
return `⚖️ ${String(a.application).trim()}`;
|
return `⚖️ ${a.reponse ? `Choix retenu : ${String(a.reponse).trim()}. ` : ''}${String(a.application).trim()}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
async function repondre(cleArg) {
|
async function repondre(cleArg) {
|
||||||
@@ -77,7 +77,7 @@ async function repondre(cleArg) {
|
|||||||
const va = v.attributes || {};
|
const va = v.attributes || {};
|
||||||
if (v.state === 'repondu' && va.id === a.id && va.application) {
|
if (v.state === 'repondu' && va.id === a.id && va.application) {
|
||||||
const st = loadState(); saveState({ ...st, questionId: a.id, appliqueId: a.id });
|
const st = loadState(); saveState({ ...st, questionId: a.id, appliqueId: a.id });
|
||||||
return `Choix ${c.cle} transmis. ⚖️ ${String(va.application).trim()}`;
|
return `Choix ${c.cle} transmis (${c.libelle}). ⚖️ ${String(va.application).trim()}`;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return `Choix ${c.cle} transmis (${c.libelle}). EVCS n'a pas encore confirmé ce qu'il a fait : sa réponse arrivera par WhatsApp.`;
|
return `Choix ${c.cle} transmis (${c.libelle}). EVCS n'a pas encore confirmé ce qu'il a fait : sa réponse arrivera par WhatsApp.`;
|
||||||
|
|||||||
Reference in New Issue
Block a user