Skip to content

Commit

Permalink
Change made for better performance
Browse files Browse the repository at this point in the history
  • Loading branch information
idali0226 committed Jan 11, 2021
1 parent 2f90073 commit e8c8fcb
Showing 1 changed file with 2 additions and 18 deletions.
20 changes: 2 additions & 18 deletions georg-ui/src/views/Home.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

<script>
import { mapGetters, mapMutations } from 'vuex'
import Detail from '../components/Detail'
// import Detail from '../components/Detail'
import Map from '../components/Map'
import Message from '../components/Message'
import Results from '../components/Results'
Expand All @@ -35,16 +35,14 @@ const service = new Service()
export default {
name: 'Home',
components: {
Detail,
// LocaleSwitcher,
Detail: () => import('../components/Detail'),
Map,
Message,
Results,
Search,
},
data() {
return {
// dialog: false,
mapHeight: 'height: 1500px',
passInValue: null,
results: [],
Expand All @@ -55,9 +53,6 @@ export default {
created() {
window.addEventListener('resize', this.handleResize)
this.handleResize()
// this.errorMsg =
// "Koordinaterna måste anges på något av följande sätt:\n 57°46'7\" N 14°49'37\" E\n 57°46.113480' N 14°49.621740' E\n 57.768558 14.827029"
const { place_name, coordinates } = this.$route.query
if (place_name) {
const country = this.$route.query.country
Expand Down Expand Up @@ -199,7 +194,6 @@ export default {
this.setDetailView(false)
}
this.setMessages('coordinates')
// this.setMsgKey('result.hitsAndYourLocation')
this.setResults(this.results)
this.setIsErrorMsg(false)
this.setRezoom(true)
Expand All @@ -216,18 +210,8 @@ export default {
let messageKey
if (typeSearch === 'address') {
messageKey = 'addressSearch'
// numOfHits === 0
// ? 'home.noHits'
// : numOfHits === 1
// ? "home.hit'"
// : 'home.hits'
} else {
messageKey = 'coordinatesSearch'
// numOfHits === 1
// ? 'home.displyDinPlats'
// : numOfHits === 2
// ? 'result.hitAndYourLocation'
// : 'result.hitsAndYourLocation'
}
this.setMsgKey(messageKey)
},
Expand Down

0 comments on commit e8c8fcb

Please sign in to comment.