Skip to content
Snippets Groups Projects
Commit 8114dc64 authored by AUBRY JEAN-PASCAL's avatar AUBRY JEAN-PASCAL
Browse files

fix: add a conditionnal statement on search param field populate

Refs #668
parent 5b5cf8a9
No related branches found
No related tags found
2 merge requests!275Release v4.19.0,!265Resolve "Solveur: Les select d'une session chargée ne s'initialise pas"
Pipeline #204664 passed
This commit is part of merge request !265. Comments created here will be created in the context of that merge request.
......@@ -26,7 +26,15 @@ export class SelectFieldSearchedParam extends SelectField {
for (const p of searchableParams) {
if (p.visible) {
const calcTitle = fs.getTitlebyIdOnSelectedLoadedNubs(p.originNub.uid).title;
let calcTitle;
// if form already exist
if(fs.getFormulaireFromId(p.originNub.uid)) {
calcTitle = fs.getFormulaireFromId(p.originNub.uid).calculatorName;
}
// prevent issue #369 (loading session)
else {
calcTitle = fs.getTitlebyIdOnSelectedLoadedNubs(p.originNub.uid).title;
}
const varName = fs.expandVariableName(p.originNub.calcType, p.symbol);
const label = `${p.symbol} - ${varName} (${calcTitle})`;
this.addEntry(this.createOrGetEntry(this._entriesBaseId + p.getParentComputeNode(false).uid + "_" + p.symbol, p, decodeHtml(label)));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment