修复导航点击失效问题
This commit is contained in:
@@ -2,8 +2,8 @@
|
|||||||
<section class="primary">
|
<section class="primary">
|
||||||
<div flex class="content">
|
<div flex class="content">
|
||||||
<b class="headerTitle" v-text="title"/>
|
<b class="headerTitle" v-text="title"/>
|
||||||
<el-tabs class="fill">
|
<el-tabs class="fill" v-model="current" @tab-click="$emit('change', current)">
|
||||||
<el-tab-pane v-for="tab in tabs" :key="tab.id" :label="tab.label" @click.native="$emit('change',tab.id)"/>
|
<el-tab-pane v-for="tab in tabs" :key="tab.id" :label="tab.label" :name="tab.name"/>
|
||||||
</el-tabs>
|
</el-tabs>
|
||||||
<div class="rightPane" flex>
|
<div class="rightPane" flex>
|
||||||
<div class="item" v-text="currentTime"/>
|
<div class="item" v-text="currentTime"/>
|
||||||
@@ -38,6 +38,11 @@ export default {
|
|||||||
// {label: "测试哦哦", id: 10},
|
// {label: "测试哦哦", id: 10},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
current: ""
|
||||||
|
}
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getWeather() {
|
getWeather() {
|
||||||
this.$request.post("/app/weather/queryWeather").then(res => {
|
this.$request.post("/app/weather/queryWeather").then(res => {
|
||||||
@@ -101,7 +106,7 @@ export default {
|
|||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
font-family: "PingFang SC";
|
font-family: "PingFang SC";
|
||||||
padding: 0 16px;
|
user-select: none;
|
||||||
|
|
||||||
&.is-active {
|
&.is-active {
|
||||||
color: #02FEFF;
|
color: #02FEFF;
|
||||||
|
|||||||
@@ -86,6 +86,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import Layout from './Layout.vue'
|
import Layout from './Layout.vue'
|
||||||
import Sortable from 'sortablejs'
|
import Sortable from 'sortablejs'
|
||||||
|
import {mapActions} from "vuex"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Add',
|
name: 'Add',
|
||||||
@@ -136,6 +137,7 @@ export default {
|
|||||||
this.getInfo().then(() => this.$route.params?.id && this.onChange(this.$route.params))
|
this.getInfo().then(() => this.$route.params?.id && this.onChange(this.$route.params))
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapActions(['closePage']),
|
||||||
getInfo() {
|
getInfo() {
|
||||||
let {id} = this.$route.query
|
let {id} = this.$route.query
|
||||||
if (!id) return Promise.reject()
|
if (!id) return Promise.reject()
|
||||||
@@ -252,6 +254,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
cancel() {
|
cancel() {
|
||||||
|
this.closePage()
|
||||||
this.$router.push({})
|
this.$router.push({})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<section class="preview">
|
<section class="preview">
|
||||||
<ai-dv-wrapper :views="[{label: '返回'}]" :theme="config.theme" @change="$router.back()" v-if="screenId" :title="info.name">
|
<ai-dv-wrapper :views="[{label: '返回'}]" :theme="config.theme" @change="handleBack" v-if="screenId" :title="info.name">
|
||||||
<ai-dv-background
|
<ai-dv-background
|
||||||
:theme="config.theme"
|
:theme="config.theme"
|
||||||
v-if="config.length || config.theme === '1'"
|
v-if="config.length || config.theme === '1'"
|
||||||
@@ -12,6 +12,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import {mapActions} from "vuex"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "preview",
|
name: "preview",
|
||||||
props: {
|
props: {
|
||||||
@@ -33,6 +35,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
...mapActions(['closePage']),
|
||||||
getDvData() {
|
getDvData() {
|
||||||
let {id} = this.$route.query
|
let {id} = this.$route.query
|
||||||
this.instance.post(`${this.urlPrefix}/appdiylargescreen/queryLargeScreenDetailById?id=${id}`).then(res => {
|
this.instance.post(`${this.urlPrefix}/appdiylargescreen/queryLargeScreenDetailById?id=${id}`).then(res => {
|
||||||
@@ -41,6 +44,10 @@ export default {
|
|||||||
this.config = JSON.parse(res.data.config).dashboard
|
this.config = JSON.parse(res.data.config).dashboard
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
},
|
||||||
|
handleBack() {
|
||||||
|
this.$router.back()
|
||||||
|
this.closePage()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
|||||||
Reference in New Issue
Block a user