diff --git a/src/app/formulaire/definition/concrete/form-pab.ts b/src/app/formulaire/definition/concrete/form-pab.ts index 9c05c514a80f37d0c672a5951204fe5231d36e14..3a5bac9c4b167c4884821ca978c369090866920f 100644 --- a/src/app/formulaire/definition/concrete/form-pab.ts +++ b/src/app/formulaire/definition/concrete/form-pab.ts @@ -90,6 +90,11 @@ export class FormulairePab extends FormulaireBase { parent.deleteChild(parent.getIndexForChild(sn)); } + public doCompute() { + this.dumpPabStructure(this.pabNub); + super.doCompute(); + } + public createFieldset(parent: FormulaireNode, json: {}, data?: {}, nub?: Nub): FieldSet { if (json["calcType"] === "PabCloisons") { // indice après lequel insérer le nouveau FieldSet @@ -235,15 +240,27 @@ export class FormulairePab extends FormulaireBase { case "fs_bassin": switch (data.name) { case "modeleCloisons": - // change PabCloisons Nub property "modeleCloisons" and reinit it + // change PabCloisons property "modeleCloisons" and reinit it // with new Cloisons values const newModeleUID = sender.properties.getPropValue("modeleCloisons"); (sender.nub as PabCloisons).setModel(newModeleUID); // treat the fieldset as new to re-subscribe to Nub properties change events this.afterParseFieldset(sender); this.reset(); + break; + } + break; - // this.dumpPabStructure(this.currentNub as Pab); + case "fs_cloison_aval": + switch (data.name) { + case "modeleCloisonAval": + // change Pab property "modeleCloisonAval" and reinit it + // with new ParallelStructure values + const newModeleAvalUID = sender.properties.getPropValue("modeleCloisonAval"); + this.pabNub.setDownWall(newModeleAvalUID); + // treat the fieldset as new to re-subscribe to Nub properties change events + this.afterParseFieldset(sender); + this.reset(); break; } break;