Skip to content
Snippets Groups Projects
Commit bd6738b1 authored by francois.grand's avatar francois.grand
Browse files

#48 FormComputeFixedVar : modif de getVariatedParameter() pour tenir compte...

 #48 FormComputeFixedVar : modif de getVariatedParameter() pour tenir compte des paramètres liés à un paramètre variable
parent 5576240a
No related branches found
No related tags found
1 merge request!22Resolve "Lier des paramètres ou des résultats entre les calculettes"
......@@ -15,7 +15,20 @@ export class FormComputeFixedVar extends FormCompute {
}
private getVariatedParameter(): NgParameter {
return this._formBase.getDisplayedParamFromState(ParamRadioConfig.VAR);
let res = this._formBase.getDisplayedParamFromState(ParamRadioConfig.VAR);
if (res !== undefined)
return res;
const pms = this._formBase.getDisplayedParamListFromState(ParamRadioConfig.LINK);
for (const p of pms)
if (p.valueMode === ParamValueMode.LINK)
switch (p.paramDefinition.referencedParamValues.valueMode) {
case ParamValueMode.LISTE:
case ParamValueMode.MINMAX:
return p;
}
return undefined;
}
private getComputedParameter(): NgParameter {
......
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