diff --git a/frontend/packages/BasicComponents/InfoCardCollection/index.vue b/frontend/packages/BasicComponents/InfoCardCollection/index.vue new file mode 100644 index 0000000..964f17b --- /dev/null +++ b/frontend/packages/BasicComponents/InfoCardCollection/index.vue @@ -0,0 +1,326 @@ + + + + + \ No newline at end of file diff --git a/frontend/packages/BasicComponents/InfoCardCollection/setting.vue b/frontend/packages/BasicComponents/InfoCardCollection/setting.vue new file mode 100644 index 0000000..9ace6f1 --- /dev/null +++ b/frontend/packages/BasicComponents/InfoCardCollection/setting.vue @@ -0,0 +1,160 @@ + + + + diff --git a/frontend/packages/BasicComponents/InfoCardCollection/settingConfig.js b/frontend/packages/BasicComponents/InfoCardCollection/settingConfig.js new file mode 100644 index 0000000..93be784 --- /dev/null +++ b/frontend/packages/BasicComponents/InfoCardCollection/settingConfig.js @@ -0,0 +1,77 @@ +import { commonConfig, displayOption } from 'data-room-ui/js/config' + +export const settingConfig = { + padding: [30, 30, 50, 80], + legend: false, + isGroup: true, + data: [], + color: '', + theme: 'dark', + label: { + // 可手动配置 label 数据标签位置 + position: 'top', // 'top', 'bottom', 'middle', + // 配置样式 + content: '' + }, + seriesField: '', // 分组 + displayOption: { + ...displayOption, + metricField: { + // 指标 + label: '指标', + enable: false, + multiple: false // 是否多选 + }, + dimensionField: { + // 表格列 + label: '表格列', // 维度/查询字段 + enable: true, + multiple: true // 是否多选 + } + } +} +const customConfig = { + type: 'tables', + root: { + version: '2023071001', + contribution: false, + loading: false, + // 绕x轴旋转角度 + rotateX: 0, + // 绕y轴旋转角度 + rotateY: 0, + // 绕z轴旋转角度 + rotateZ: 0, + // 透视距离 + perspective: 0, + skewX: 0, + skewY: 0 + }, + + customize: { + theme: 'dark', // 'light'、'dark' + // 表格头部背景颜色 + headerBackgroundColor: '#232832', + // 表格头部字体颜色 + headerFontColor: '#fff', + // 表格头部字体大小 + headerFontSize: 14, + // 表格主体背景颜色 + bodyBackgroundColor: '', + // 表格主体字体颜色 + bodyFontColor: 'rgb(155 159 172)', + // 表格主体字体大小 + bodyFontSize: 14, + // 表格是否需要斑马纹 + stripe: false, + // 表格奇数行背景颜色 + oddRowBackgroundColor: '', + // 表格偶数行背景颜色‘ + evenRowBackgroundColor: '' + // 表格是否需要边框 + // border: false, + } +} +export const dataConfig = { + ...commonConfig(customConfig) +} diff --git a/frontend/packages/BigScreenDesign/DataViewDialog/index.vue b/frontend/packages/BigScreenDesign/DataViewDialog/index.vue index edb1520..c83b0dd 100644 --- a/frontend/packages/BigScreenDesign/DataViewDialog/index.vue +++ b/frontend/packages/BigScreenDesign/DataViewDialog/index.vue @@ -142,6 +142,7 @@ export default { // 通过option获取数据 getDataByOption (config) { let list = [] + // console.log(config.option, 'config.option') if (config.chartType === 'Treemap') { list = config.option.data.children } else if (config.type === 'tables') { diff --git a/frontend/packages/BigScreenDesign/index.vue b/frontend/packages/BigScreenDesign/index.vue index b270331..f242e11 100644 --- a/frontend/packages/BigScreenDesign/index.vue +++ b/frontend/packages/BigScreenDesign/index.vue @@ -261,12 +261,12 @@ export default { }, // 判断页面权限 permission() { - // this.$dataRoomAxios.get(`/bigScreen/permission/check/${this.pageCode}`).then(res => { + this.$dataRoomAxios.get(`/bigScreen/permission/check/${this.pageCode}`).then(res => { this.hasPermission = res - // if (res) { + if (res) { this.init() - // } - // }) + } + }) }, // 添加资源弹窗初始化 initDialog() { diff --git a/frontend/packages/js/config/basicComponentsConfig.js b/frontend/packages/js/config/basicComponentsConfig.js index 55db166..f466f9e 100644 --- a/frontend/packages/js/config/basicComponentsConfig.js +++ b/frontend/packages/js/config/basicComponentsConfig.js @@ -40,6 +40,7 @@ const typeList = [ "indicatorCard2", "indexCard", "indexCard2", + "infoCardCollection" ]; let basicConfigList = []; basicConfigList = typeList.map((type) => { diff --git a/frontend/packages/js/utils/getComponentConfig.js b/frontend/packages/js/utils/getComponentConfig.js index fd7ce78..9b5f86b 100644 --- a/frontend/packages/js/utils/getComponentConfig.js +++ b/frontend/packages/js/utils/getComponentConfig.js @@ -136,6 +136,19 @@ export default function getComponentConfig(type) { y: 0, type, }; + case 'infoCardCollection': + return { + name: "信息卡片集合", + title: "信息卡片集合", + icon: Icon.getNameList()[4], + className: + "com.gccloud.dataroom.core.module.chart.components.ScreenTablesChart", + w: 600, + h: 400, + x: 0, + y: 0, + type, + }; case "timeCountDown": return { name: "倒计时",