feat:新增判断

main
liu.tao3 2 years ago
parent 1b8bb8910c
commit 88257e4c98

@ -155,6 +155,12 @@
<el-button type="primary" @click="confirm">
确定
</el-button>
<el-button
type='primary'
@click="jumpto"
>
组件管理
</el-button>
</div>
</el-dialog>
</template>
@ -204,6 +210,10 @@ export default {
this.remoteComponentlist = [...innerRemoteComponents, ...getRemoteComponents()]
},
methods: {
jumpto(){
let {href} = this.$router.resolve(`/big-screen-components?edit=1`)
window.open(href,'_blank')
},
chooseComponent(component) {
this.focus = _.cloneDeep(component)
},

@ -59,6 +59,12 @@
<el-button type="primary" @click="confirm">
确定
</el-button>
<el-button
type='primary'
@click="jumpto"
>
组件管理
</el-button>
</div>
</el-dialog>
</template>
@ -88,6 +94,10 @@ export default {
},
mounted() { },
methods: {
jumpto(){
let {href} = this.$router.resolve(`/big-screen-source?edit=1`)
window.open(href,'_blank')
},
chooseImg(img) {
this.focus = _.cloneDeep(img)
},

@ -280,7 +280,6 @@ export default {
// eslint-disable-next-line eqeqeq
if (row.editable == 1 && !this.appCode) return
dataSourceCheck(row.id).then((res)=>{
console.log(res)
if(res.canDelete){
this.$confirm('确定删除当前数据源吗?', '提示', {
confirmButtonText: '确定',

@ -39,12 +39,29 @@ export default {
},
computed: {
title () {
if (this.$route.query.edit) return '智能报表平台'
return window?.BS_CONFIG?.starter?.title
},
logo () {
return window?.BS_CONFIG?.starter?.logo || require('./images/logo.png')
},
tabList () {
if (this.$route.query.edit) {
return [
{
id: 1,
name: '资源库',
path: window?.BS_CONFIG?.routers?.sourceUrl || '/big-screen-source',
icon: 'icon-tupian'
},
{
id: 2,
name: '组件库',
path: window?.BS_CONFIG?.routers?.componentUrl || '/big-screen-components',
icon: 'icon-zujian1'
}
]
}
return [
{
id: 0,
@ -90,9 +107,16 @@ export default {
created () {},
methods: {
changeTab (tab) {
if (this.$route.query.edit) {
this.$router.push({
path: tab.path,
query: { edit: 1 }
})
}else{
this.$router.push({
path: tab.path
})
}
}
}
}

@ -17,7 +17,7 @@ const datasetPage = (params = {}, flag = false) => Vue.prototype.$dataRoomAxios.
* @param flag
* @returns {*}
*/
const dataSourceCheck = (id='-1', flag = false) => Vue.prototype.$dataRoomAxios.post(`/datasource/deleteCheck/${id}`, {}, flag)
const datasetCheck = (id='-1', flag = false) => Vue.prototype.$dataRoomAxios.post(`/dataset/deleteCheck/${id}`, {}, flag)
/**
@ -123,5 +123,5 @@ export {
categoryAdd,
categoryUpdate,
categoryRemove,
dataSourceCheck
datasetCheck
}

Loading…
Cancel
Save