Mercurial > gemma
comparison client/src/components/importoverview/ImportOverview.vue @ 3677:24fafb86b528
import_logs: client side sorting for country
author | Thomas Junk <thomas.junk@intevation.de> |
---|---|
date | Mon, 17 Jun 2019 17:27:24 +0200 |
parents | d02d4e31491b |
children | 2babdaa32709 |
comparison
equal
deleted
inserted
replaced
3676:f107e82b64ae | 3677:24fafb86b528 |
---|---|
167 "startDate", | 167 "startDate", |
168 "endDate", | 168 "endDate", |
169 "prev", | 169 "prev", |
170 "next" | 170 "next" |
171 ]), | 171 ]), |
172 ...mapGetters("usermanagement", ["userCountries"]), | |
172 ...mapGetters("imports", ["filters"]), | 173 ...mapGetters("imports", ["filters"]), |
173 countryLabel() { | 174 countryLabel() { |
174 return this.$gettext("Country"); | 175 return this.$gettext("Country"); |
175 }, | 176 }, |
176 importReviewLabel() { | 177 importReviewLabel() { |
302 this.$store.commit("imports/setStartDate", start); | 303 this.$store.commit("imports/setStartDate", start); |
303 this.$store.commit("imports/setEndDate", end); | 304 this.$store.commit("imports/setEndDate", end); |
304 this.loadLogs(); | 305 this.loadLogs(); |
305 }, | 306 }, |
306 filteredImports() { | 307 filteredImports() { |
307 return this.imports; | 308 return this.imports.map(x => { |
309 x["country"] = this.userCountries[x.user]; | |
310 return x; | |
311 }); | |
308 }, | 312 }, |
309 loadUpdatedLogs() { | 313 loadUpdatedLogs() { |
310 const now = new Date(); | 314 const now = new Date(); |
311 switch (this.selectedInterval) { | 315 switch (this.selectedInterval) { |
312 case this.$options.LAST_HOUR: | 316 case this.$options.LAST_HOUR: |