From ff1a1bc1993589cd6245dc05b9fb2a797d85d161 Mon Sep 17 00:00:00 2001 From: Natsumi Date: Mon, 21 Jun 2021 14:34:01 +1200 Subject: [PATCH] Location bug fixes --- html/src/app.js | 4 +++- html/src/index.pug | 9 ++++----- html/src/vr.js | 1 + 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/html/src/app.js b/html/src/app.js index 65087c47..5cd4dead 100644 --- a/html/src/app.js +++ b/html/src/app.js @@ -785,6 +785,7 @@ speechSynthesis.getVoices(); }, methods: { parse() { + this.text = this.location; var L = API.parseLocation(this.location); if (L.isOffline) { this.text = 'Offline'; @@ -6027,7 +6028,8 @@ speechSynthesis.getVoices(); if ((props.location) && (props.location[0] !== 'offline') && (props.location[0] !== '') && - ((props.location[1] !== 'offline') && (props.location[0] !== 'private'))) { + (props.location[1] !== 'offline') && + (props.location[1] !== '')) { $app.addFeed('GPS', ref, { location: [ props.location[0], diff --git a/html/src/index.pug b/html/src/index.pug index e0d95580..ac5d5cfd 100644 --- a/html/src/index.pug +++ b/html/src/index.pug @@ -87,11 +87,10 @@ html template(v-once #default="scope") div(style="position:relative;font-size:14px") template(v-if="scope.row.type === 'GPS'") - template(v-if="scope.row.location[1]") - location(:location="scope.row.location[1]") - el-tag(type="info" effect="plain" size="mini" style="margin-left:5px") {{ scope.row.time | timeToText }} - br - span + location(v-if="scope.row.location[1]" :location="scope.row.location[1]") + el-tag(type="info" effect="plain" size="mini" style="margin-left:5px") {{ scope.row.time | timeToText }} + br + span i.el-icon-right location(v-if="scope.row.location[0]" :location="scope.row.location[0]") template(v-else-if="scope.row.type === 'Offline'") diff --git a/html/src/vr.js b/html/src/vr.js index 75abd23d..e8f24a4e 100644 --- a/html/src/vr.js +++ b/html/src/vr.js @@ -468,6 +468,7 @@ speechSynthesis.getVoices(); }, methods: { parse() { + this.text = this.location; var L = API.parseLocation(this.location); if (L.isOffline) { this.text = 'Offline';