Mercurial > gemma
annotate client/src/components/systemconfiguration/Systemconfiguration.vue @ 3678:8f58851927c0
client: make layer factory only return new layer config for individual maps
instead of each time it is invoked. The purpose of the factory was to support multiple maps with individual layers.
But returning a new config each time it is invoked leads to bugs that rely on the layer's state. Now this factory
reuses the same objects it created before, per map.
author | Markus Kottlaender <markus@intevation.de> |
---|---|
date | Mon, 17 Jun 2019 17:31:35 +0200 |
parents | a688a478e35f |
children | 0300282b9537 |
rev | line source |
---|---|
2213 | 1 <template> |
3588
cffa99aa523c
client: systemconfiguration: made container scrollable for more configuration options
Markus Kottlaender <markus@intevation.de>
parents:
2919
diff
changeset
|
2 <div class="d-flex h-100"> |
2919
6c5364ff0abb
client: removed a lot of unnecessary closing tags
Markus Kottlaender <markus@intevation.de>
parents:
2760
diff
changeset
|
3 <Spacer /> |
3588
cffa99aa523c
client: systemconfiguration: made container scrollable for more configuration options
Markus Kottlaender <markus@intevation.de>
parents:
2919
diff
changeset
|
4 <div class="card my-2 mr-2 flex-fill shadow-xs"> |
2760
c6fba10926cc
client:correct a set of strings marking
Fadi Abbud <fadi.abbud@intevation.de>
parents:
2534
diff
changeset
|
5 <UIBoxHeader icon="wrench" :title="systemconfigurationLabel" /> |
3597
d1bbfb9635ca
client: configuration: unified styles of different config components
Markus Kottlaender <markus@intevation.de>
parents:
3588
diff
changeset
|
6 <div class="text-left flex-fill" style="overflow: auto"> |
2247
e6fba449aa3c
merged pdf-export in default
Markus Kottlaender <markus@intevation.de>
parents:
2228
diff
changeset
|
7 <PDFTemplates /> |
2277
5f3110aa1ad1
made configuration page accessible for waterway admins
Markus Kottlaender <markus@intevation.de>
parents:
2276
diff
changeset
|
8 <ColorSettings v-if="isSysAdmin" /> |
3625
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
9 <MapLayers v-if="isSysAdmin" /> |
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
10 <DataAccuracy v-if="isSysAdmin" /> |
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
11 <MorphologyClassbreaks v-if="isSysAdmin" /> |
2213 | 12 </div> |
13 <!-- card-body --> | |
14 </div> | |
15 </div> | |
16 </template> | |
17 | |
18 <script> | |
19 /* This is Free Software under GNU Affero General Public License v >= 3.0 | |
20 * without warranty, see README.md and license for details. | |
21 * | |
22 * SPDX-License-Identifier: AGPL-3.0-or-later | |
23 * License-Filename: LICENSES/AGPL-3.0.txt | |
24 * | |
25 * Copyright (C) 2018 by via donau | |
26 * – Österreichische Wasserstraßen-Gesellschaft mbH | |
27 * Software engineering by Intevation GmbH | |
28 * | |
29 * Author(s): | |
30 * Thomas Junk <thomas.junk@intevation.de> | |
31 * Bernhard Reiter <bernhard@intevation.de> | |
2276
920fba6eef0d
moved color settings into own component
Markus Kottlaender <markus@intevation.de>
parents:
2247
diff
changeset
|
32 * Markus Kottländer <markus@intevation.de> |
2213 | 33 */ |
2277
5f3110aa1ad1
made configuration page accessible for waterway admins
Markus Kottlaender <markus@intevation.de>
parents:
2276
diff
changeset
|
34 import { mapGetters } from "vuex"; |
5f3110aa1ad1
made configuration page accessible for waterway admins
Markus Kottlaender <markus@intevation.de>
parents:
2276
diff
changeset
|
35 |
2213 | 36 export default { |
37 name: "systemconfiguration", | |
38 components: { | |
39 Spacer: () => import("../Spacer"), | |
2276
920fba6eef0d
moved color settings into own component
Markus Kottlaender <markus@intevation.de>
parents:
2247
diff
changeset
|
40 PDFTemplates: () => import("./PDFTemplates"), |
3625
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
41 ColorSettings: () => import("./ColorSettings"), |
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
42 MapLayers: () => import("./MapLayers"), |
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
43 DataAccuracy: () => import("./DataAccuracy"), |
a688a478e35f
implemented configuration backend and frontend
Markus Kottlaender <markus@intevation.de>
parents:
3597
diff
changeset
|
44 MorphologyClassbreaks: () => import("./MorphologyClassbreaks") |
2277
5f3110aa1ad1
made configuration page accessible for waterway admins
Markus Kottlaender <markus@intevation.de>
parents:
2276
diff
changeset
|
45 }, |
5f3110aa1ad1
made configuration page accessible for waterway admins
Markus Kottlaender <markus@intevation.de>
parents:
2276
diff
changeset
|
46 computed: { |
2760
c6fba10926cc
client:correct a set of strings marking
Fadi Abbud <fadi.abbud@intevation.de>
parents:
2534
diff
changeset
|
47 ...mapGetters("user", ["isSysAdmin"]), |
c6fba10926cc
client:correct a set of strings marking
Fadi Abbud <fadi.abbud@intevation.de>
parents:
2534
diff
changeset
|
48 systemconfigurationLabel() { |
c6fba10926cc
client:correct a set of strings marking
Fadi Abbud <fadi.abbud@intevation.de>
parents:
2534
diff
changeset
|
49 return this.$gettext("Systemconfiguration"); |
c6fba10926cc
client:correct a set of strings marking
Fadi Abbud <fadi.abbud@intevation.de>
parents:
2534
diff
changeset
|
50 } |
2213 | 51 } |
52 }; | |
53 </script> |