diff --git a/packages/bigscreen/designer/components/chartPicker.vue b/packages/bigscreen/designer/components/chartPicker.vue
index 05b225e5..75a05794 100644
--- a/packages/bigscreen/designer/components/chartPicker.vue
+++ b/packages/bigscreen/designer/components/chartPicker.vue
@@ -17,7 +17,7 @@
@@ -35,6 +36,10 @@ export default {
color: #FFFFFF;
font-size: 12px;
text-align: right;
+
+ &.bold {
+ font-weight: bold;
+ }
}
.el-select .el-tag {
diff --git a/packages/bigscreen/designer/components/groupItem.vue b/packages/bigscreen/designer/components/groupItem.vue
new file mode 100644
index 00000000..6eaeb132
--- /dev/null
+++ b/packages/bigscreen/designer/components/groupItem.vue
@@ -0,0 +1,32 @@
+
+
+
+
+
+
+
diff --git a/packages/bigscreen/designer/config.js b/packages/bigscreen/designer/config.js
index 579edfff..b5f36e26 100644
--- a/packages/bigscreen/designer/config.js
+++ b/packages/bigscreen/designer/config.js
@@ -473,6 +473,241 @@ const customHtml = {
html: `
自定义HTML
`
}]
}
+const tables = [{
+ type: 'table',
+ label: '表格',
+ title: '表格',
+ border: 'border6',
+ width: 650,
+ height: 400,
+ zIndex: 1,
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
+ dataX: '',
+ dataY: [],
+ rowNum: 7,
+ isShowIndex: '1',
+ sourceDataId: '',
+ api: '',
+ apiData: [],
+ dataType: 'staticData',
+ dynamicData: [],
+ staticData: [{name: '列1', v: 23, v2: 3}, {name: '列2', v: 12, v2: 4}, {name: '列2', v: 12, v2: 4}]
+}, {
+ type: 'AiDvTable',
+ label: '新版表格',
+ title: '新版表格',
+ border: 'border6',
+ width: 650,
+ height: 400,
+ zIndex: 1,
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
+ dataX: '',
+ dataY: [],
+ rowNum: 7,
+ stripe: '1',
+ isShowIndex: '1',
+ sourceDataId: '',
+ api: '',
+ config: [{
+ width: '', color: '', align: ''
+ }, {
+ width: '', color: '', align: ''
+ }, {
+ width: '', color: '', align: ''
+ }],
+ apiData: [],
+ dataType: 'staticData',
+ dynamicData: [],
+ staticData: [{name: '列1', v: 23, v2: 3}, {name: '列2', v: 12, v2: 4}, {name: '列2', v: 12, v2: 4}]
+}, {
+ type: 'AiRanking',
+ label: '排行榜',
+ title: '排行榜',
+ border: 'border6',
+ width: 523,
+ height: 400,
+ zIndex: 1,
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
+ dataX: '',
+ dataY: [],
+ rowNum: 7,
+ subType: 'Ranking1',
+ stripe: '1',
+ isShowIndex: '1',
+ sourceDataId: '',
+ api: '',
+ apiData: [],
+ dataType: 'staticData',
+ dynamicData: [],
+ staticData: [{name: '列1', value: 23}, {name: '列2', value: 12}, {name: '列2', value: 12}]
+}]
+const layouts = [
+ {
+ type: 'display',
+ label: '装饰',
+ display: 'display0',
+ width: 840,
+ height: 540,
+ isZoom: false,
+ zIndex: 1,
+ title: '标题',
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/display.png',
+ sourceDataId: '',
+ dataType: 'staticData',
+ staticData: [{
+ label: '个人服务办理', value: 247
+ }, {
+ label: '同比上月', value: 247
+ }]
+ }, {
+ type: 'panel',
+ label: '边框',
+ title: '边框',
+ border: 'border0',
+ width: 400,
+ height: 400,
+ isZoom: false,
+ zIndex: 1,
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/border.png'
+ }, {
+ type: 'summary',
+ label: '数据统计',
+ display: 'summary0',
+ width: 480,
+ height: 240,
+ zIndex: 1,
+ top: 0,
+ left: 0,
+ dataX: '',
+ dataY: [],
+ summaryTitle: '',
+ border: 'border3',
+ sourceDataId: '',
+ title: '数据统计',
+ dataType: 'staticData',
+ staticData: [{
+ key: '个人服务办理', value: 247
+ }, {
+ key: '同比上月', value: 247
+ }],
+ dynamicData: [],
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/total.png'
+ },
+]
+const others = [
+ {
+ label: "图片", list: [
+ {
+ label: "普通图片",
+ type: "img",
+ width: 500,
+ height: 400,
+ thumb: "https://cdn.cunwuyun.cn/dvcp/dv/img/display0-bg.png"
+ }
+ ]
+ },
+ {
+ label: '党组织', type: 'partyOrg', list: [{
+ type: 'partyOrg',
+ label: '党组织',
+ width: 840,
+ height: 800,
+ zIndex: 1,
+ top: 0,
+ left: 0,
+ dataX: '',
+ dataY: [],
+ title: '党组织',
+ border: 'border3',
+ sourceDataId: '',
+ dataType: 'staticData',
+ staticData: [{
+ key: '个人服务办理', value: 247
+ }, {
+ key: '同比上月', value: 247
+ }],
+ dynamicData: [],
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/total.png'
+ }]
+ }, {
+ label: '轮播图', list: [{
+ type: 'swiper',
+ label: '轮播图',
+ width: 400,
+ height: 300,
+ zIndex: 1,
+ border: 'border2',
+ dataType: 'staticData',
+ staticData: [{
+ img: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/pie.png', title: '湖羊', content: `歙县众城湖羊养殖专业合作社
+ 徐晓红 - 18273645627
+ 歙县郑村镇唐跃村碉墅`
+ }],
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png'
+ }, {
+ type: 'swiper',
+ label: '轮播图(点指示器)',
+ width: 800,
+ height: 358,
+ zIndex: 1,
+ border: 'border14',
+ dataType: 'staticData',
+ staticData: [{
+ content: `歙县众城湖羊养殖专业合作社
+ 徐晓红 - 18273645627
+ 歙县郑村镇唐跃村碉墅`
+ }, {
+ content: `歙县众城湖羊养殖专业合作社
+ 徐晓红 - 18273645627
+ 歙县郑村镇唐跃村碉墅`
+ },],
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png',
+ dotIndicator: true
+ }]
+ }, {
+ label: '视频播放器', type: 'video', list: [{
+ type: 'video',
+ label: '视频播放器',
+ width: 400,
+ height: 300,
+ zIndex: 1,
+ src: '',
+ border: 'border2',
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png'
+ }]
+ }, {
+ label: '视频监控', list: [
+ {
+ type: 'monitor',
+ label: '视频监控',
+ src: '',
+ width: 480,
+ height: 240,
+ zIndex: 1,
+ top: 0,
+ left: 0,
+ title: '',
+ moniterId: '',
+ monitorType: 'cmcc',
+ api: '/app/appzyvideoequipment/list2',
+ border: 'border2',
+ sourceDataId: '',
+ dataType: 'staticData',
+ staticData: '',
+ dynamicData: '',
+ thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/video.png'
+ },
+ {
+ type: "monitorCarousel",
+ label: "视频轮播",
+ width: 480,
+ height: 480,
+ zIndex: 1,
+ title: "视频轮播",
+ thumb: "https://cdn.cunwuyun.cn/dvcp/dv/tpl/video.png"
+ }
+ ]
+ }, customHtml]
const components = [{
label: '图表', list: [...chartTpl, {
label: "多维图", type: "plot", list: [{
@@ -498,130 +733,14 @@ const components = [{
}]
}]
-}, {
- label: '表格', list: [{
- type: 'table',
- label: '表格',
- title: '表格',
- border: 'border6',
- width: 650,
- height: 400,
- zIndex: 1,
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
- dataX: '',
- dataY: [],
- rowNum: 7,
- isShowIndex: '1',
- sourceDataId: '',
- api: '',
- apiData: [],
- dataType: 'staticData',
- dynamicData: [],
- staticData: [{name: '列1', v: 23, v2: 3}, {name: '列2', v: 12, v2: 4}, {name: '列2', v: 12, v2: 4}]
- }, {
- type: 'AiDvTable',
- label: '新版表格',
- title: '新版表格',
- border: 'border6',
- width: 650,
- height: 400,
- zIndex: 1,
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
- dataX: '',
- dataY: [],
- rowNum: 7,
- stripe: '1',
- isShowIndex: '1',
- sourceDataId: '',
- api: '',
- config: [{
- width: '', color: '', align: ''
- }, {
- width: '', color: '', align: ''
- }, {
- width: '', color: '', align: ''
- }],
- apiData: [],
- dataType: 'staticData',
- dynamicData: [],
- staticData: [{name: '列1', v: 23, v2: 3}, {name: '列2', v: 12, v2: 4}, {name: '列2', v: 12, v2: 4}]
- }, {
- type: 'AiRanking',
- label: '排行榜',
- title: '排行榜',
- border: 'border6',
- width: 523,
- height: 400,
- zIndex: 1,
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/table.png',
- dataX: '',
- dataY: [],
- rowNum: 7,
- subType: 'Ranking1',
- stripe: '1',
- isShowIndex: '1',
- sourceDataId: '',
- api: '',
- apiData: [],
- dataType: 'staticData',
- dynamicData: [],
- staticData: [{name: '列1', value: 23}, {name: '列2', value: 12}, {name: '列2', value: 12}]
- }]
},
+ {label: '表格', list: tables},
{
- label: "样式", list: [
- {
- type: 'display',
- label: '装饰',
- display: 'display0',
- width: 840,
- height: 540,
- isZoom: false,
- zIndex: 1,
- title: '标题',
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/display.png',
- sourceDataId: '',
- dataType: 'staticData',
- staticData: [{
- label: '个人服务办理', value: 247
- }, {
- label: '同比上月', value: 247
- }]
- }, {
- type: 'panel',
- label: '边框',
- title: '边框',
- border: 'border0',
- width: 400,
- height: 400,
- isZoom: false,
- zIndex: 1,
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/border.png'
- }, {
- type: 'summary',
- label: '数据统计',
- display: 'summary0',
- width: 480,
- height: 240,
- zIndex: 1,
- top: 0,
- left: 0,
- dataX: '',
- dataY: [],
- summaryTitle: '',
- border: 'border3',
- sourceDataId: '',
- title: '数据统计',
- dataType: 'staticData',
- staticData: [{
- key: '个人服务办理', value: 247
- }, {
- key: '同比上月', value: 247
- }],
- dynamicData: [],
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/total.png'
- }
- ]
+ label: "样式", list: [...layouts, {
+ type: "tabs", label: "TAB页签", border: "border13", width: 480,
+ height: 240, thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/tabs.png', top: 0, left: 0,
+ dataType: 'staticData', staticData: {}, title: "TAB页签"
+ }]
},
{label: '地图', list: maps}, {
type: 'ai3d', label: "3D", list: [{
@@ -646,122 +765,9 @@ const components = [{
thumb: "https://cdn.cunwuyun.cn/dvcp/dv/aiIcon.png"
}]
}, {
- label: '其他', list: [
- {
- label: "图片", list: [
- {
- label: "普通图片",
- type: "img",
- width: 500,
- height: 400,
- thumb: "https://cdn.cunwuyun.cn/dvcp/dv/img/display0-bg.png"
- }
- ]
- },
- {
- label: '党组织', type: 'partyOrg', list: [{
- type: 'partyOrg',
- label: '党组织',
- width: 840,
- height: 800,
- zIndex: 1,
- top: 0,
- left: 0,
- dataX: '',
- dataY: [],
- title: '党组织',
- border: 'border3',
- sourceDataId: '',
- dataType: 'staticData',
- staticData: [{
- key: '个人服务办理', value: 247
- }, {
- key: '同比上月', value: 247
- }],
- dynamicData: [],
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/total.png'
- }]
- }, {
- label: '轮播图', list: [{
- type: 'swiper',
- label: '轮播图',
- width: 400,
- height: 300,
- zIndex: 1,
- border: 'border2',
- dataType: 'staticData',
- staticData: [{
- img: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/pie.png', title: '湖羊', content: `歙县众城湖羊养殖专业合作社
- 徐晓红 - 18273645627
- 歙县郑村镇唐跃村碉墅`
- }],
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png'
- }, {
- type: 'swiper',
- label: '轮播图(点指示器)',
- width: 800,
- height: 358,
- zIndex: 1,
- border: 'border14',
- dataType: 'staticData',
- staticData: [{
- content: `歙县众城湖羊养殖专业合作社
- 徐晓红 - 18273645627
- 歙县郑村镇唐跃村碉墅`
- }, {
- content: `歙县众城湖羊养殖专业合作社
- 徐晓红 - 18273645627
- 歙县郑村镇唐跃村碉墅`
- },],
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png',
- dotIndicator: true
- }]
- }, {
- label: '视频播放器', type: 'video', list: [{
- type: 'video',
- label: '视频播放器',
- width: 400,
- height: 300,
- zIndex: 1,
- src: '',
- border: 'border2',
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/swiper.png'
- }]
- }, {
- label: '视频监控', list: [
- {
- type: 'monitor',
- label: '视频监控',
- src: '',
- width: 480,
- height: 240,
- zIndex: 1,
- top: 0,
- left: 0,
- title: '',
- moniterId: '',
- monitorType: 'cmcc',
- api: '/app/appzyvideoequipment/list2',
- border: 'border2',
- sourceDataId: '',
- dataType: 'staticData',
- staticData: '',
- dynamicData: '',
- thumb: 'https://cdn.cunwuyun.cn/dvcp/dv/tpl/video.png'
- },
- {
- type: "monitorCarousel",
- label: "视频轮播",
- width: 480,
- height: 480,
- zIndex: 1,
- title: "视频轮播",
- thumb: "https://cdn.cunwuyun.cn/dvcp/dv/tpl/video.png"
- }
- ]
- }, customHtml]
+ label: '其他', list: others
}]
-
+export const layers = [...chartTpl.map(e => e.list), maps, tables, layouts, ...others.map(e => e.list)].flat()
export {components}
/**
diff --git a/ui/dv/AiDvRender.vue b/ui/dv/AiDvRender.vue
index ca15e022..b21c9f64 100644
--- a/ui/dv/AiDvRender.vue
+++ b/ui/dv/AiDvRender.vue
@@ -65,6 +65,12 @@
+
+
+
+
@@ -75,14 +81,15 @@ import Vue from "vue"
import {mapState} from 'vuex'
import AiDvMap from "./AiDvMap";
import AiMonitor from "./AiMonitor/AiMonitor";
-import AiSwiper from './AiSwiper.vue'
+import AiSwiper from './AiSwiper'
import AiDvDisplay from "./layout/AiDvDisplay/AiDvDisplay";
import AiDvPanel from "./layout/AiDvPanel/AiDvPanel";
import AiDvSummary from "./layout/AiDvSummary/AiDvSummary";
-import AiDvPlot from "./layout/AiDvPlot/AiDvPlot.vue";
-import AiAssist from "./AiAssist.vue";
-import AiMonitorCarousel from "./AiMonitorCarousel.vue";
-import AiLinkageMap from "./AiLinkageMap.vue";
+import AiDvPlot from "./layout/AiDvPlot/AiDvPlot";
+import AiAssist from "./AiAssist";
+import AiMonitorCarousel from "./AiMonitorCarousel";
+import AiLinkageMap from "./AiLinkageMap";
+import AiDvTabs from "./AiDvTabs";
Vue.use(scrollBoard)
@@ -90,6 +97,7 @@ export default {
name: 'AiDvRender',
props: ['data', 'index', 'theme', 'instance'],
components: {
+ AiDvTabs,
AiLinkageMap,
AiMonitorCarousel,
AiAssist,
@@ -110,6 +118,7 @@ export default {
timer: null,
dvTableConfig: [],
mapDialog: false,
+ activeTab: '0'
}
},
computed: {
@@ -123,6 +132,22 @@ export default {
deep: true, handler() {
if (this.currentType == 'map') {
this.renderMap()
+ } else if (this.currentType === 'tabs') {
+ //数据驱动内容生成,新增tab中的内容由设置的数据来生成
+ const meta = this.$copy(this.data.tabs)
+ this.data.tabs = Object.entries(this.values).map(([label, v]) => {
+ const tab = meta.find(e => e.label === label)
+ const comps = []
+ if (Array.isArray(v.data)) {
+ comps.push({label: "内容", ...tab})
+ } else {
+ Object.keys(v.data).map(name => {
+ const layer = tab.comps.find(e => e.label === name)
+ comps.push({label: name, ...layer})
+ })
+ }
+ return {label, comps}
+ })
} else if (this.currentType === 'AiDvTable') {
this.dvTableConfig = this.data[this.data.dataType].map((v, i) => {
return {
@@ -241,7 +266,7 @@ export default {
diff --git a/ui/dv/AiDvTabs.vue b/ui/dv/AiDvTabs.vue
new file mode 100644
index 00000000..d76e9b54
--- /dev/null
+++ b/ui/dv/AiDvTabs.vue
@@ -0,0 +1,38 @@
+
+
+
+
+
+
+
diff --git a/ui/dv/layout/AiDvPanel/AiDvPanel.vue b/ui/dv/layout/AiDvPanel/AiDvPanel.vue
index a27da127..5539277c 100644
--- a/ui/dv/layout/AiDvPanel/AiDvPanel.vue
+++ b/ui/dv/layout/AiDvPanel/AiDvPanel.vue
@@ -4,6 +4,9 @@
+
+
+
diff --git a/ui/dv/layout/AiDvPanel/borders/border13.vue b/ui/dv/layout/AiDvPanel/borders/border13.vue
index 25dc4fe4..b9b7bd5c 100644
--- a/ui/dv/layout/AiDvPanel/borders/border13.vue
+++ b/ui/dv/layout/AiDvPanel/borders/border13.vue
@@ -1,8 +1,9 @@
-
+
-
{{ title }}
+
+
@@ -44,6 +45,10 @@ export default {
height: 28px;
margin-right: 8px;
}
+
+ &.right {
+ padding-right: 0;
+ }
}
&.border13-1 .border13-title {