1
0

Highlight the current list when something list related is called

This commit is contained in:
kolaente
2020-05-08 21:07:33 +02:00
parent 5724b98358
commit 8ae03fa6e9
5 changed files with 30 additions and 5 deletions

View File

@ -26,6 +26,7 @@
import ListModel from '../../models/list'
import ListService from '../../services/list'
import {CURRENT_LIST} from "../../store/mutation-types";
export default {
data() {
@ -65,6 +66,8 @@
return
}
this.$store.commit(CURRENT_LIST, Number(this.$route.params.listId))
// We create an extra list object instead of creating it in this.list because that would trigger a ui update which would result in bad ux.
let list = new ListModel({id: this.$route.params.listId})
this.listService.get(list)