fix: 修改自定义组件设计返回逻辑,激活左侧菜单并重新请求数据,修改数据集的分页样式

main
wu.jian2 2 years ago
parent 6f28d97767
commit 2c80b9b04a

@ -1,6 +1,6 @@
{
"name": "@gcpaas/data-room-ui",
"version": "0.0.1-2023070501-Alpha",
"version": "0.0.1-2023070601-Alpha",
"description": "自定义大屏",
"author": "gc-starter",
"license": "MIT",

@ -14,7 +14,6 @@
</div>
</template>
<script>
export default {
components: {},
data () {
@ -37,23 +36,19 @@ export default {
}
},
created () {
const type = this.$route?.query?.type
if (type) {
this.componentHandle(this.componentList.find(item => item.type === type))
} else {
this.componentHandle(this.componentList[0])
const { globalData } = this.$router.app.$options
if (globalData?.componentsManagementType) {
this.activeType = globalData.componentsManagementType
this.$emit('getPageInfo', globalData.componentsManagementType)
// this.$router.app.$options.globalData.componentsManagementType
delete globalData.componentsManagementType
}
},
methods: {
//
componentHandle (com) {
this.activeType = com.type
this.$router.push({
path: window.BS_CONFIG?.routers?.componentUrl || '/big-screen-components',
query: {
type: com.type
}
})
this.$emit('getPageInfo', com.type)
}
}
}

@ -1,7 +1,7 @@
<template>
<div class="bs-manage-main-wrap">
<side-menu />
<menu-content />
<side-menu @getPageInfo="getPageInfo" />
<menu-content :catalog-info="catalogInfo" />
</div>
</template>
<script>
@ -14,10 +14,15 @@ export default {
components: { SideMenu, MenuContent },
data () {
return {
catalogInfo: 'component'
}
},
mounted () { },
methods: { }
mounted () {},
methods: {
getPageInfo (type) {
this.catalogInfo = type
}
}
}
</script>

@ -135,6 +135,12 @@ export default {
BizComponentPreview
},
props: {},
beforeRouteLeave (to, from, next) {
//
const data = { componentsManagementType: 'bizComponent' }
this.$router.app.$options.globalData = data //
next() //
},
data () {
return {
form: {
@ -231,10 +237,7 @@ export default {
},
backManagement () {
this.$router.push({
path: window.BS_CONFIG?.routers?.componentUrl || '/big-screen-components',
query: {
type: 'bizComponent'
}
path: window.BS_CONFIG?.routers?.componentUrl || '/big-screen-components'
})
},
save () {

@ -153,7 +153,6 @@
</div>
</div>
</div>
<div
v-if="catalogInfo !== 'system'"
class="footer-pagination-wrap"
@ -203,12 +202,16 @@ import innerRemoteComponents, { getRemoteComponents } from 'packages/RemoteCompo
export default {
name: 'BigScreenList',
mixins: [pageMixins],
props: { },
props: {
catalogInfo: {
type: String,
default: ''
}
},
components: { EditForm, CatalogEditForm },
data () {
return {
name: '',
catalogInfo: 'component',
catalogVisible: false,
templateLoading: false,
searchKey: '',
@ -235,8 +238,7 @@ export default {
}
},
watch: {
$route (val) {
this.catalogInfo = val.query.type || 'component'
catalogInfo () {
this.reset()
this.init()
},
@ -245,7 +247,6 @@ export default {
}
},
mounted () {
this.catalogInfo = this.$route.query.type || 'component'
this.init()
},
methods: {

@ -1071,13 +1071,11 @@ export default {
customClass: 'bs-el-message-box'
}).then(() => {
this.saveFun(formName)
}).catch(() => {
})
} else {
this.saveFun(formName)
}
},
/**
@ -1470,6 +1468,9 @@ export default {
}
.bs-pagination {
position: relative !important;
bottom: 0 !important;
padding: 0 12px 16px 16px !important;
::v-deep .el-input__inner {
width: 110px !important;
border: none;

@ -1081,10 +1081,8 @@ export default {
}
/deep/ .bs-table-box.is-Edit .el-table {
max-height: calc(100vh - 532px) !important;
.el-table__body-wrapper {
max-height: calc(100vh - 568px) !important;
max-height: unset !important;
}
}
@ -1114,6 +1112,9 @@ export default {
}
.bs-pagination {
position: relative !important;
bottom: 0 !important;
padding: 0 12px 16px 16px !important;
::v-deep .el-input__inner {
width: 110px !important;
border: none;

@ -608,6 +608,9 @@ export default {
padding-left: 16px !important;
}
.bs-pagination {
position: relative !important;
bottom: 0 !important;
padding: 0 12px 16px 16px !important;
::v-deep .el-input__inner {
width: 110px !important;
border:none;

@ -146,6 +146,22 @@ export default {
components: {
setDatasource
},
// -
beforeRouteLeave (to, from, next) {
const layoutEl = document.querySelector('.big-screen-router-view-wrap')
if (layoutEl) {
layoutEl.style.paddingLeft = '0'
}
next()
},
//
beforeRouteEnter (to, from, next) {
const layoutEl = document.querySelector('.big-screen-router-view-wrap')
if (layoutEl) {
layoutEl.style.paddingLeft = '16px'
}
next()
},
mixins: [pageMixins],
props: {
isDialog: {
@ -176,11 +192,12 @@ export default {
curRow: null
}
},
created () { },
mounted () {
this.init()
const layoutEl = document.querySelector('.big-screen-router-view-wrap')
if (layoutEl) {
layoutEl.style.padding = '16px'
layoutEl.style.paddingLeft = '16px'
}
},
methods: {

@ -1,6 +1,6 @@
window.ENV = 'development'
var developmentConfig = {
baseUrl: 'http://127.0.0.1:8081/bigScreenServer'
baseUrl: 'http://gcpaas.gccloud.com/bigScreenServer'
}
// 必须的
window.CONFIG = configDeepMerge(window.CONFIG, developmentConfig)

Loading…
Cancel
Save