Mercurial > gemma
changeset 4445:950fecfec4ca
client: fix diagram-legend values (Available fairway depth)
* fix bug of showing wrong values in diagram legend on switching between features on AFD tab.
author | Fadi Abbud <fadi.abbud@intevation.de> |
---|---|
date | Fri, 20 Sep 2019 10:46:19 +0200 |
parents | edc0c2385a77 |
children | ec8c9793dbb7 |
files | client/src/components/fairway/AvailableFairwayDepthDialogue.vue |
diffstat | 1 files changed, 18 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/client/src/components/fairway/AvailableFairwayDepthDialogue.vue Fri Sep 20 09:46:52 2019 +0200 +++ b/client/src/components/fairway/AvailableFairwayDepthDialogue.vue Fri Sep 20 10:46:19 2019 +0200 @@ -448,6 +448,12 @@ } }, watch: { + depthLimitVisible() { + if (this.depthLimitVisible) { + this.depthLimit1 = 2.3; + this.depthLimit2 = 2.5; + } + }, selectedBottleneck() { this.type = this.$options.BOTTLENECK; this.setSelectedBottleneck(); @@ -501,6 +507,7 @@ }, methods: { openFairwaydepthLNWLDiagram() { + this.clearInvisibleFormValues(); this.loading = true; this.$store .dispatch("fairwayavailability/loadAvailableFairwayDepthLNWLDiagram", { @@ -533,8 +540,19 @@ this.loading = false; }); }, + clearInvisibleFormValues() { + if (!this.widthLimitVisible) { + this.widthLimit1 = null; + this.widthLimit2 = null; + } + if (!this.depthLimitVisible) { + this.depthLimit1 = null; + this.depthLimit2 = null; + } + }, openFairwaydepthDiagram() { this.loading = true; + this.clearInvisibleFormValues(); this.$store .dispatch("fairwayavailability/loadAvailableFairwayDepth", { feature: this.selectedFairwayAvailabilityFeature,