You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
719 B
25 lines
719 B
import { useStore } from '@/store/root'
|
|
import Shop from '@/utils/Class/Shop'
|
|
import { useRouter } from 'vue-router'
|
|
|
|
export const useFacilityNav = () => {
|
|
const store = useStore()
|
|
const router = useRouter()
|
|
|
|
function handleFacility(name, floorOrder, floorName, logoPath, yaxis, isFacility) {
|
|
const shop = new Shop(name, floorOrder, floorName, logoPath, yaxis, isFacility)
|
|
store.SET_SHOP(shop)
|
|
}
|
|
|
|
function _handleFacility(item) {
|
|
store.showSearch && store.SET_SHOW_SEARCH(false)
|
|
store.showVoice && store.SET_SHOW_VOICE(false)
|
|
store.showDetail && store.SET_SHOW_DETAIL(false)
|
|
|
|
window.Map_QM.bounceIcon({ type: item.type })
|
|
|
|
router.push('/guide')
|
|
}
|
|
|
|
return { _handleFacility }
|
|
}
|
|
|