UI update
This commit is contained in:
parent
f8ff438e5a
commit
15be4acd27
|
@ -96,11 +96,12 @@
|
||||||
<span class="font-weight-medium mr-1">On-line</span>
|
<span class="font-weight-medium mr-1">On-line</span>
|
||||||
</v-list-item-subtitle>
|
</v-list-item-subtitle>
|
||||||
<v-list-item-subtitle>
|
<v-list-item-subtitle>
|
||||||
<span v-if="userPresence.local" class="font-weight-medium">
|
<span v-if="userPresence.local">
|
||||||
|
<v-icon small>mdi-map-marker-account</v-icon>
|
||||||
{{ userPresence.local }}
|
{{ userPresence.local }}
|
||||||
</span>
|
</span>
|
||||||
<span v-else>
|
<span v-else>
|
||||||
Próximo ao AP
|
<v-icon small>mdi-access-point</v-icon>
|
||||||
{{ userPresence.apName }}
|
{{ userPresence.apName }}
|
||||||
</span>
|
</span>
|
||||||
</v-list-item-subtitle>
|
</v-list-item-subtitle>
|
||||||
|
@ -291,13 +292,15 @@ export default {
|
||||||
|
|
||||||
watch: {
|
watch: {
|
||||||
search(newValue) {
|
search(newValue) {
|
||||||
if (!newValue) this.$router.push({ query: {} })
|
if (this.$route.query.search != newValue) this.updateQuery()
|
||||||
else if (this.$route.query.search != newValue)
|
},
|
||||||
this.$router.push({ query: { search: newValue } })
|
onlyServants(newValue) {
|
||||||
|
if (this.$route.query.onlyServants != newValue) this.updateQuery()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.search = this.$route.query.search || ''
|
this.search = this.$route.query.search || ''
|
||||||
|
this.onlyServants = this.$route.query.onlyServants === 'true'
|
||||||
},
|
},
|
||||||
apollo: {
|
apollo: {
|
||||||
userPresence: {
|
userPresence: {
|
||||||
|
@ -357,6 +360,14 @@ export default {
|
||||||
RECENT: 'warning lighten-1',
|
RECENT: 'warning lighten-1',
|
||||||
OFFLINE: 'offline'
|
OFFLINE: 'offline'
|
||||||
}[status]
|
}[status]
|
||||||
|
},
|
||||||
|
updateQuery() {
|
||||||
|
this.$router.replace({
|
||||||
|
query: {
|
||||||
|
search: this.search,
|
||||||
|
onlyServants: this.onlyServants
|
||||||
|
}
|
||||||
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user