annotate client/src/components/Statistics.vue @ 3198:b0328646e34f

statistics: include los selection
author Thomas Junk <thomas.junk@intevation.de>
date Wed, 08 May 2019 15:26:59 +0200
parents c0cd5dfec153
children 25a26f666ee8
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
1 <template>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
2 <div
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
3 :class="[
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
4 'box ui-element rounded bg-white text-nowrap',
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
5 { expanded: showStatistics }
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
6 ]"
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
7 >
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
8 <div style="width: 18rem">
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
9 <UIBoxHeader icon="chart-line" :title="label" :closeCallback="close" />
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
10 <div class="box-body">
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
11 <UISpinnerOverlay v-if="loading" />
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
12 <div class="mb-3 d-flex flex-row justify-content-between">
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
13 <div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
14 <input :value="$options.BOTTLENECKS" type="radio" v-model="type" />
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
15 <small class="ml-1 text-muted">
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
16 <translate>Bottlenecks</translate>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
17 </small>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
18 </div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
19 <div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
20 <input :value="$options.STRETCHES" type="radio" v-model="type" />
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
21 <small class="ml-1 text-muted">
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
22 <translate>Stretches</translate>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
23 </small>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
24 </div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
25 <div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
26 <input :value="$options.SECTIONS" type="radio" v-model="type" />
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
27 <small class="ml-1 text-muted">
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
28 <translate>Sections</translate>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
29 </small>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
30 </div>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
31 </div>
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
32 <div class="d-flex flex-column">
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
33 <select
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
34 @change="entrySelected"
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
35 class="form-control font-weight-bold"
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
36 v-model="selectedEntry"
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
37 >
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
38 <option :value="null">{{ empty }}</option>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
39 <option
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
40 v-for="(entry, index) in entries"
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
41 :value="entry"
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
42 :key="index"
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
43 >{{ entry.properties.name }}</option
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
44 >
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
45 </select>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
46 </div>
3185
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
47 <div class="d-flex flex-column mt-3">
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
48 <div class="d-flex flex-column mb-3">
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
49 <small class="my-auto text-muted"
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
50 ><translate>Type</translate></small
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
51 >
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
52 <select v-model="selectedFrequency" class="form-control">
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
53 <option
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
54 v-for="(option, index) in $options.FREQUENCIES"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
55 :value="option"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
56 :key="index"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
57 ><translate>{{ option }}</translate></option
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
58 >
3185
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
59 </select>
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
60 </div>
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
61 <div class="d-flex flex-column mb-3">
3198
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
62 <small class="my-auto text-muted"><translate>LOS</translate></small>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
63 <select v-model="los" class="form-control">
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
64 <option value="1">1</option>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
65 <option value="2">2</option>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
66 <option value="3">3</option>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
67 </select>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
68 </div>
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
69 <div class="d-flex flex-column mb-3">
3185
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
70 <small for="from" class="my-auto text-muted"
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
71 ><translate>Date from</translate></small
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
72 ><input
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
73 id="from"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
74 v-model="fromDate"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
75 class="form-control"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
76 type="date"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
77 />
3185
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
78 </div>
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
79 <div class="d-flex flex-column">
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
80 <small for="to" class="my-auto text-muted"
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
81 ><translate>Date to</translate></small
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
82 ><input id="to" v-model="toDate" class="form-control" type="date" />
3185
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
83 </div>
505414dfe3e7 available_fairway_depth: move statistic dialog to store
Thomas Junk <thomas.junk@intevation.de>
parents: 3184
diff changeset
84 </div>
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
85 <div class="mt-3">
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
86 <button
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
87 @click="openFairwaydepth"
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
88 :disabled="isComplete"
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
89 class="btn btn-info btn-sm w-100"
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
90 >
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
91 <translate>Available Fairway Depth</translate>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
92 </button>
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
93 </div>
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
94 </div>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
95 </div>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
96 </div>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
97 </template>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
98
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
99 <script>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
100 /* This is Free Software under GNU Affero General Public License v >= 3.0
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
101 * without warranty, see README.md and license for details.
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
102 *
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
103 * SPDX-License-Identifier: AGPL-3.0-or-later
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
104 * License-Filename: LICENSES/AGPL-3.0.txt
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
105 *
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
106 * Copyright (C) 2018 by via donau
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
107 * – Österreichische Wasserstraßen-Gesellschaft mbH
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
108 * Software engineering by Intevation GmbH
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
109 *
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
110 * Author(s):
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
111 * Markus Kottländer <markus.kottlaender@intevation.de>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
112 * Thomas Junk <thomas.junk@intevation.de>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
113 */
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
114
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
115 import app from "@/main";
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
116 import { displayError } from "@/lib/errors";
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
117 import { mapState, mapGetters } from "vuex";
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
118
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
119 export default {
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
120 data() {
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
121 return {
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
122 type: this.$options.BOTTLENECKS,
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
123 loading: false
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
124 };
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
125 },
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
126 methods: {
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
127 openFairwaydepth() {
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
128 this.loading = true;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
129 this.$store
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
130 .dispatch("diagram/loadAvailableFairwayDepth", {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
131 feature: this.selectedFairwayAvailabilityFeature,
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
132 from: this.from,
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
133 to: this.to,
3198
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
134 frequency: this.frequency,
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
135 LOS: this.los
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
136 })
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
137 .then(() => {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
138 this.loading = false;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
139 this.$store.commit("application/paneSetup", "AVAILABLEFAIRWAYDEPTH");
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
140 })
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
141 .catch(error => {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
142 console.log(error);
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
143 const { status, data } = error.response;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
144 displayError({
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
145 title: this.$gettext("Backend Error"),
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
146 message: `${status}: ${data.message || data}`
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
147 });
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
148 });
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
149 },
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
150 close() {
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
151 this.$store.commit("application/showStatistics", false);
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
152 },
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
153 entrySelected() {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
154 if (this.type === this.$options.BOTTLENECKS) {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
155 this.openLayersMap()
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
156 .getLayer("BOTTLENECKS")
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
157 .setVisible(true);
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
158 if (this.showProfiles) {
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
159 this.$store.dispatch(
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
160 "bottlenecks/setSelectedBottleneck",
3183
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
161 this.selectedFairwayAvailabilityFeature.properties.name
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
162 );
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
163 }
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
164 }
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
165 if (this.type === this.$options.STRETCHES) {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
166 this.openLayersMap()
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
167 .getLayer("STRETCHES")
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
168 .setVisible(true);
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
169 }
3183
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
170 if (this.selectedFairwayAvailabilityFeature) {
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
171 this.$store.dispatch("map/moveToFeauture", {
3183
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
172 feature: this.selectedFairwayAvailabilityFeature,
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
173 zoom: 17,
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
174 preventZoomOut: true
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
175 });
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
176 }
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
177 },
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
178 setSelectedBottleneck() {
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
179 const bn = this.bottlenecksList.filter(
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
180 x => x.properties.name === this.selectedBottleneck
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
181 )[0];
3184
1ba2a7d22fbb available_fairway_depth: display selected feature
Thomas Junk <thomas.junk@intevation.de>
parents: 3183
diff changeset
182 this.$store.commit("diagram/setSelectedFairwayAvailability", bn);
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
183 }
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
184 },
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
185 computed: {
3178
5ec34e08b01d available_fairway_depth: display mock
Thomas Junk <thomas.junk@intevation.de>
parents: 3175
diff changeset
186 ...mapState("application", ["showStatistics", "paneSetup", "showProfiles"]),
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
187 ...mapState("diagram", [
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
188 "selectedFairwayAvailabilityFeature",
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
189 "from",
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
190 "to",
3198
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
191 "frequency",
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
192 "LOS"
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
193 ]),
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
194 ...mapState("imports", ["stretches"]),
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
195 ...mapState("bottlenecks", ["bottlenecksList", "selectedBottleneck"]),
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
196 ...mapGetters("map", ["openLayersMap"]),
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
197 isComplete() {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
198 return (
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
199 this.from == null ||
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
200 this.to == null ||
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
201 this.frequency == null ||
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
202 this.selectedFairwayAvailabilityFeature == null
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
203 );
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
204 },
3198
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
205 los: {
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
206 get() {
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
207 return this.LOS;
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
208 },
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
209 set(value) {
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
210 this.$store.commit("diagram/setLOS", value);
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
211 }
b0328646e34f statistics: include los selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3191
diff changeset
212 },
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
213 fromDate: {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
214 get() {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
215 return this.from;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
216 },
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
217 set(value) {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
218 this.$store.commit("diagram/setFrom", value);
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
219 }
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
220 },
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
221 toDate: {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
222 get() {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
223 return this.to;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
224 },
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
225 set(value) {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
226 this.$store.commit("diagram/setTo", value);
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
227 }
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
228 },
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
229 selectedFrequency: {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
230 get() {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
231 return this.frequency;
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
232 },
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
233 set(value) {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
234 this.$store.commit("diagram/setFrequency", value);
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
235 }
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
236 },
3183
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
237 selectedEntry: {
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
238 get() {
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
239 return this.selectedFairwayAvailabilityFeature;
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
240 },
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
241 set(feature) {
3184
1ba2a7d22fbb available_fairway_depth: display selected feature
Thomas Junk <thomas.junk@intevation.de>
parents: 3183
diff changeset
242 this.$store.commit("diagram/setSelectedFairwayAvailability", feature);
3183
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
243 }
f64cc98746a1 statistics: put selected feature in fairwaystore
Thomas Junk <thomas.junk@intevation.de>
parents: 3178
diff changeset
244 },
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
245 entries() {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
246 if (this.type === this.$options.BOTTLENECKS) return this.bottlenecksList;
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
247 if (this.type === this.$options.STRETCHES) return this.stretches;
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
248 return [];
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
249 },
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
250 label() {
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
251 return this.$gettext("Statistics");
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
252 },
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
253 empty() {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
254 if (this.type === this.$options.BOTTLENECKS)
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
255 return this.$gettext("Select bottleneck");
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
256 if (this.type === this.$options.STRETCHES)
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
257 return this.$gettext("Select strectch");
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
258 return this.$gettext("Select section");
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
259 }
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
260 },
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
261 watch: {
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
262 selectedBottleneck() {
3174
aeb9d6fc640a statistics: sprinkled more fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3173
diff changeset
263 this.type = this.$options.BOTTLENECKS;
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
264 this.setSelectedBottleneck();
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
265 },
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
266 type() {
3175
296392d4539c client: statistics dialog: fix resetting selectedEntry
Markus Kottlaender <markus@intevation.de>
parents: 3174
diff changeset
267 if (this.type === this.$options.BOTTLENECKS && this.selectedBottleneck) {
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
268 this.setSelectedBottleneck();
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
269 } else {
3184
1ba2a7d22fbb available_fairway_depth: display selected feature
Thomas Junk <thomas.junk@intevation.de>
parents: 3183
diff changeset
270 this.$store.commit("diagram/setSelectedFairwayAvailability", null);
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
271 }
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
272 this.openLayersMap()
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
273 .getLayer("STRETCHES")
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
274 .setVisible(true);
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
275 },
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
276 showStatistics() {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
277 if (this.showStatistics) {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
278 this.loading = true;
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
279 this.$store.dispatch("bottlenecks/loadBottlenecksList").then(() => {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
280 this.$store.dispatch("imports/loadStretches").then(() => {
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
281 this.loading = false;
3173
1287b031424c statistics: sprinkled fairy dust on to bottleneck selection
Thomas Junk <thomas.junk@intevation.de>
parents: 3172
diff changeset
282 if (this.selectedBottleneck) this.setSelectedBottleneck();
3172
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
283 });
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
284 });
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
285 }
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
286 }
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
287 },
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
288 BOTTLENECKS: "bottlenecks",
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
289 SECTIONS: "sections",
975efa874acf statistic: choice between bottlenecks and stretches implemented
Thomas Junk <thomas.junk@intevation.de>
parents: 3159
diff changeset
290 STRETCHES: "stretches",
3191
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
291 AVAILABLEFAIRWAYDEPTH: app.$gettext("Available Fairway Depth"),
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
292 FREQUENCIES: {
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
293 MONTHLY: "monthly",
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
294 QUARTERLY: "quarterly",
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
295 YEARLY: "yearly"
c0cd5dfec153 statistics: persist fields to vuex
Thomas Junk <thomas.junk@intevation.de>
parents: 3185
diff changeset
296 }
3159
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
297 };
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
298 </script>
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
299
4f4905b57fcf toolbar: added statistics dialog component
Thomas Junk <thomas.junk@intevation.de>
parents:
diff changeset
300 <style></style>