New routes, notifications, other impovements in side drwaer

This commit is contained in:
shpuld 2018-12-28 21:39:54 +02:00
parent 4752081818
commit 85c058e95c
25 changed files with 313 additions and 138 deletions

View file

@ -9,6 +9,7 @@ const userSearch = {
],
data () {
return {
username: '',
users: []
}
},
@ -21,7 +22,14 @@ const userSearch = {
}
},
methods: {
newQuery (query) {
this.$router.push({ name: 'user-search', query: { query } })
},
search (query) {
if (!query) {
this.users = []
return
}
userSearchApi.search({query, store: this.$store})
.then((res) => {
this.users = res