From a8cc2a14e0ccb93415c8457655175425c77c872a Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Tue, 13 Aug 2024 09:17:39 +0800 Subject: [PATCH 1/7] =?UTF-8?q?refactor(=E4=BB=AA=E8=A1=A8=E6=9D=BF?= =?UTF-8?q?=E3=80=81=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E6=96=87?= =?UTF-8?q?=E6=A1=88=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/core-frontend/src/custom-component/component-list.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/core-frontend/src/custom-component/component-list.ts b/core/core-frontend/src/custom-component/component-list.ts index 474d2eb9e3..f18cde8084 100644 --- a/core/core-frontend/src/custom-component/component-list.ts +++ b/core/core-frontend/src/custom-component/component-list.ts @@ -22,7 +22,7 @@ export const BASE_EVENTS = { { key: 'jump', label: '跳转' }, { key: 'download', label: '下载' }, { key: 'share', label: '分享' }, - { key: 'showHidden', label: '弹框区域' }, + { key: 'showHidden', label: '弹窗区域' }, { key: 'refreshDataV', label: '刷新' }, { key: 'refreshView', label: '刷新图表' } ], From f77bc85c875e16eaa23e26d46ddd3722a066cc6d Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Tue, 13 Aug 2024 09:43:35 +0800 Subject: [PATCH 2/7] =?UTF-8?q?fix(=E4=BB=AA=E8=A1=A8=E6=9D=BF):=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=89=B9=E9=87=8F=E8=AE=BE=E7=BD=AE=E6=97=A0?= =?UTF-8?q?=E6=B3=95=E9=80=89=E4=B8=ADtab=E7=BB=84=E4=BB=B6=E5=86=85?= =?UTF-8?q?=E7=9A=84=E7=BB=84=E4=BB=B6=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/data-visualization/canvas/Shape.vue | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/core/core-frontend/src/components/data-visualization/canvas/Shape.vue b/core/core-frontend/src/components/data-visualization/canvas/Shape.vue index 821b73581c..ebbcd7115f 100644 --- a/core/core-frontend/src/components/data-visualization/canvas/Shape.vue +++ b/core/core-frontend/src/components/data-visualization/canvas/Shape.vue @@ -64,7 +64,11 @@ :style="getPointStyle(item)" @mousedown="handleMouseDownOnPoint(item, $event)" > -
+
+ diff --git a/de-xpack b/de-xpack index 11a3b6a066..f02fc6a6f6 160000 --- a/de-xpack +++ b/de-xpack @@ -1 +1 @@ -Subproject commit 11a3b6a066147549ac484dce7d8b4bbc2508f93a +Subproject commit f02fc6a6f62bad5b32f2ac70111ea66dcf6c9dd9 From 26deecae506318999c15f70c1c89249535aa0fb7 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Tue, 13 Aug 2024 14:46:28 +0800 Subject: [PATCH 6/7] =?UTF-8?q?feat(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E4=BC=A0=E7=BB=9F=E8=BE=B9=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../data-visualization/canvas/CanvasCore.vue | 14 +- .../custom-component/common/CommonAttr.vue | 6 +- .../common/CommonBorderSetting.vue | 137 +++++++++++------- .../common/CommonStyleSet.vue | 50 ------- .../src/models/chart/editor.d.ts | 1 + .../editor/editor-style/ChartStyle.vue | 35 ++++- .../views/chart/components/editor/index.vue | 6 + .../js/panel/charts/bar/bidirectional-bar.ts | 2 + .../components/js/panel/charts/bar/common.ts | 3 + .../js/panel/charts/bar/progress-bar.ts | 2 + .../js/panel/charts/bar/waterfall.ts | 2 + .../components/js/panel/charts/line/common.ts | 2 + .../js/panel/charts/line/stock-line.ts | 1 + .../js/panel/charts/liquid/liquid.ts | 2 + .../components/js/panel/charts/map/common.ts | 2 + .../js/panel/charts/map/flow-map.ts | 1 + .../js/panel/charts/map/heat-map.ts | 1 + .../js/panel/charts/map/symbolic-map.ts | 1 + .../panel/charts/others/chart-mix-common.ts | 2 + .../js/panel/charts/others/funnel.ts | 2 + .../js/panel/charts/others/gauge.ts | 2 + .../js/panel/charts/others/indicator.ts | 2 + .../js/panel/charts/others/quadrant.ts | 1 + .../js/panel/charts/others/radar.ts | 1 + .../js/panel/charts/others/rich-text.ts | 3 +- .../js/panel/charts/others/sankey-common.ts | 2 + .../js/panel/charts/others/scatter.ts | 1 + .../js/panel/charts/others/treemap.ts | 2 + .../js/panel/charts/others/word-cloud.ts | 2 + .../components/js/panel/charts/pie/common.ts | 2 + .../js/panel/charts/table/common.ts | 2 + .../js/panel/charts/table/table-pivot.ts | 1 + 32 files changed, 183 insertions(+), 110 deletions(-) diff --git a/core/core-frontend/src/components/data-visualization/canvas/CanvasCore.vue b/core/core-frontend/src/components/data-visualization/canvas/CanvasCore.vue index e7f242a9eb..51e56d9970 100644 --- a/core/core-frontend/src/components/data-visualization/canvas/CanvasCore.vue +++ b/core/core-frontend/src/components/data-visualization/canvas/CanvasCore.vue @@ -202,6 +202,18 @@ const height = ref(0) const isShowArea = ref(false) const svgFilterAttrs = ['width', 'height', 'top', 'left', 'rotate', 'backgroundColor'] const commonFilterAttrs = ['width', 'height', 'top', 'left', 'rotate'] +const commonFilterAttrsFilterBorder = [ + 'width', + 'height', + 'top', + 'left', + 'rotate', + 'borderActive', + 'borderWidth', + 'borderRadius', + 'borderStyle', + 'borderColor' +] const userViewEnlargeRef = ref(null) const customDatasetParamsRef = ref(null) const linkJumpRef = ref(null) @@ -515,7 +527,7 @@ const handleContextMenu = e => { } const getComponentStyle = style => { - return getStyle(style, commonFilterAttrs) + return getStyle(style, style.borderActive ? commonFilterAttrs : commonFilterAttrsFilterBorder) } const getSvgComponentStyle = style => { diff --git a/core/core-frontend/src/custom-component/common/CommonAttr.vue b/core/core-frontend/src/custom-component/common/CommonAttr.vue index 116571ac31..385ce77957 100644 --- a/core/core-frontend/src/custom-component/common/CommonAttr.vue +++ b/core/core-frontend/src/custom-component/common/CommonAttr.vue @@ -97,7 +97,7 @@ const colorPickerWidth = computed(() => { }) const borderSettingShow = computed(() => { - return !!element.value.style['borderActive'] + return !!element.value.style['borderStyle'] }) // 暂时关闭 @@ -186,14 +186,14 @@ const stopEvent = e => { diff --git a/core/core-frontend/src/custom-component/common/CommonBorderSetting.vue b/core/core-frontend/src/custom-component/common/CommonBorderSetting.vue index ab8508ee2c..308c11994a 100644 --- a/core/core-frontend/src/custom-component/common/CommonBorderSetting.vue +++ b/core/core-frontend/src/custom-component/common/CommonBorderSetting.vue @@ -13,14 +13,14 @@ const { canvasStyleData } = storeToRefs(dvMainStore) const props = withDefaults( defineProps<{ themes?: EditorTheme - element: any + styleInfo: any }>(), { themes: 'dark' } ) const emits = defineEmits(['onStyleAttrChange']) -const { themes, element } = toRefs(props) +const { themes, styleInfo } = toRefs(props) const state = reactive({ fontSize: [], isSetting: false, @@ -38,16 +38,16 @@ const borderStyleList = [ ] const styleInit = () => { - if (element.value) { + if (styleInfo.value) { Object.keys(styleMounted.value).forEach(key => { styleMounted.value[key] = Math.round( - (element.value.style[key] * 100) / canvasStyleData.value.scale + (styleInfo.value[key] * 100) / canvasStyleData.value.scale ) }) } } -const styleForm = computed(() => element.value.style) +const styleForm = computed(() => styleInfo.value) const changeStyle = params => { snapshotStore.recordSnapshotCache() @@ -55,18 +55,16 @@ const changeStyle = params => { } const changeStylePre = key => { - changeStyle({ key: key, value: element.value.style[key] }) + changeStyle({ key: key, value: styleInfo.value[key] }) } const sizeChange = key => { - element.value.style[key] = Math.round( - (styleMounted.value[key] * canvasStyleData.value.scale) / 100 - ) - changeStyle({ key: key, value: element.value.style[key] }) + styleInfo.value[key] = (styleMounted.value[key] * canvasStyleData.value.scale) / 100 + changeStyle({ key: key, value: styleInfo.value[key] }) } watch( - () => element.value, + () => styleInfo.value, () => { styleInit() }, @@ -80,52 +78,85 @@ watch( diff --git a/core/core-frontend/src/custom-component/common/CommonStyleSet.vue b/core/core-frontend/src/custom-component/common/CommonStyleSet.vue index 1c345c5698..86d800adf1 100644 --- a/core/core-frontend/src/custom-component/common/CommonStyleSet.vue +++ b/core/core-frontend/src/custom-component/common/CommonStyleSet.vue @@ -350,7 +350,6 @@ const state = reactive({ const styleColorKeyArray = [ { value: 'color', label: '颜色', width: 90, icon: 'dv-style-color' }, - { value: 'borderColor', label: '边框颜色', width: 90, icon: 'dv-style-borderColor' }, { value: 'headFontColor', label: '头部字体颜色', @@ -388,34 +387,6 @@ const fontSizeList = computed(() => { return arr }) -const borderWidthList = computed(() => { - const arr = [] - for (let i = 0; i <= 20; i = i + 1) { - arr.push({ - name: i + '', - value: i - }) - } - return arr -}) - -const borderRadiusList = computed(() => { - const arr = [] - for (let i = 0; i <= 50; i = i + 1) { - arr.push({ - name: i + '', - value: i - }) - } - return arr -}) - -const borderStyleList = [ - { name: '实线', value: 'solid' }, - { name: '虚线', value: 'dashed' }, - { name: '点线', value: 'dotted' } -] - const styleOptionKeyArrayPre = [ { value: 'fontFamily', @@ -466,27 +437,6 @@ const styleOptionKeyArray = [ customOption: opacitySizeList, width: '90px', icon: 'dv-style-opacity' - }, - { - value: 'borderWidth', - label: '边框宽度', - customOption: borderWidthList.value, - width: '90px', - icon: 'dv-style-borderSize' - }, - { - value: 'borderRadius', - label: '圆角', - customOption: borderRadiusList.value, - width: '90px', - icon: 'dv-style-borderRadius' - }, - { - value: 'borderStyle', - label: '边框样式', - customOption: borderStyleList, - width: '90px', - icon: 'dv-style-borderStyle' } ] diff --git a/core/core-frontend/src/models/chart/editor.d.ts b/core/core-frontend/src/models/chart/editor.d.ts index 58b3bd8a86..72186e22dc 100644 --- a/core/core-frontend/src/models/chart/editor.d.ts +++ b/core/core-frontend/src/models/chart/editor.d.ts @@ -1,5 +1,6 @@ declare type EditorProperty = | 'background-overall-component' + | 'border-style' | 'basic-style-selector' | 'dual-basic-style-selector' | 'label-selector' diff --git a/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyle.vue b/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyle.vue index ae8f4b7b00..2d151b4241 100644 --- a/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyle.vue +++ b/core/core-frontend/src/views/chart/components/editor/editor-style/ChartStyle.vue @@ -27,6 +27,7 @@ import QuadrantSelector from '@/views/chart/components/editor/editor-style/compo import FlowMapLineSelector from '@/views/chart/components/editor/editor-style/components/FlowMapLineSelector.vue' import FlowMapPointSelector from '@/views/chart/components/editor/editor-style/components/FlowMapPointSelector.vue' import CommonEvent from '@/custom-component/common/CommonEvent.vue' +import CommonBorderSetting from '@/custom-component/common/CommonBorderSetting.vue' const dvMainStore = dvMainStoreWithOut() const { dvInfo, batchOptStatus } = storeToRefs(dvMainStore) @@ -43,6 +44,10 @@ const props = defineProps({ type: Object, required: false }, + commonBorderPop: { + type: Object, + required: false + }, eventInfo: { type: Object, required: false @@ -90,8 +95,15 @@ const props = defineProps({ } }) -const { chart, themes, properties, propertyInnerAll, commonBackgroundPop, selectorSpec } = - toRefs(props) +const { + chart, + themes, + properties, + propertyInnerAll, + commonBackgroundPop, + commonBorderPop, + selectorSpec +} = toRefs(props) const emit = defineEmits([ 'onColorChange', 'onMiscChange', @@ -104,6 +116,7 @@ const emit = defineEmits([ 'onLegendChange', 'onBasicStyleChange', 'onBackgroundChange', + 'onStyleAttrChange', 'onTableHeaderChange', 'onTableCellChange', 'onTableTotalChange', @@ -192,6 +205,10 @@ const onBackgroundChange = (val, prop) => { state.initReady && emit('onBackgroundChange', val, prop) } +const onStyleAttrChange = ({ key, value }) => { + state.initReady && emit('onStyleAttrChange', { custom: 'style', property: key, value: value }) +} + const onTableHeaderChange = (val, prop) => { emit('onTableHeaderChange', val, prop) } @@ -318,6 +335,20 @@ watch( component-position="component" /> + + + diff --git a/core/core-frontend/src/views/chart/components/editor/index.vue b/core/core-frontend/src/views/chart/components/editor/index.vue index 21180059c3..70f7ffddfd 100644 --- a/core/core-frontend/src/views/chart/components/editor/index.vue +++ b/core/core-frontend/src/views/chart/components/editor/index.vue @@ -1053,6 +1053,10 @@ const onBackgroundChange = val => { curComponent.value.commonBackground = val } +const onStyleAttrChange = val => { + curComponent.value.style[val.property] = val.value +} + const onAssistLineChange = val => { view.value.senior.assistLineCfg = val.data if (val.requestData) { @@ -2776,6 +2780,7 @@ const deleteChartFieldItem = id => { :property-inner-all="chartViewInstance.propertyInner" :selector-spec="chartViewInstance.selectorSpec" :common-background-pop="curComponent?.commonBackground" + :common-border-pop="curComponent?.style" :event-info="curComponent?.events" :chart="view" :themes="themes" @@ -2794,6 +2799,7 @@ const deleteChartFieldItem = id => { @onIndicatorNameChange="onIndicatorNameChange" @onLegendChange="onLegendChange" @onBackgroundChange="onBackgroundChange" + @onStyleAttrChange="onStyleAttrChange" @onBasicStyleChange="onBasicStyleChange" @onTableHeaderChange="onTableHeaderChange" @onTableCellChange="onTableCellChange" diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/bidirectional-bar.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/bidirectional-bar.ts index 2aef190e8c..ed2f0bfb2c 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/bidirectional-bar.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/bidirectional-bar.ts @@ -49,6 +49,7 @@ export class BidirectionalHorizontalBar extends G2PlotChartView< axis: AxisType[] = ['xAxis', 'yAxis', 'yAxisExt', 'filter', 'drill', 'extLabel', 'extTooltip'] properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'x-axis-selector', 'dual-y-axis-selector', @@ -62,6 +63,7 @@ export class BidirectionalHorizontalBar extends G2PlotChartView< ] propertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient', 'layout'], 'x-axis-selector': ['position', 'axisLabel', 'axisLine', 'splitLine'], 'y-axis-selector': [ diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/common.ts index b6578c4795..622c1d654a 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/common.ts @@ -1,5 +1,6 @@ export const BAR_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -14,6 +15,7 @@ export const BAR_EDITOR_PROPERTY: EditorProperty[] = [ ] export const BAR_RANGE_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -28,6 +30,7 @@ export const BAR_RANGE_EDITOR_PROPERTY: EditorProperty[] = [ export const BAR_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient', 'radiusColumnBar'], 'label-selector': ['fontSize', 'color', 'labelFormatter'], 'tooltip-selector': ['fontSize', 'color', 'tooltipFormatter', 'show'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/progress-bar.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/progress-bar.ts index 6fef38049f..fd9e6db110 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/progress-bar.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/progress-bar.ts @@ -34,6 +34,7 @@ export class ProgressBar extends G2PlotChartView { } properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -47,6 +48,7 @@ export class ProgressBar extends G2PlotChartView { ...BAR_EDITOR_PROPERTY_INNER, 'legend-selector': null, 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient'], 'label-selector': ['hPosition', 'color', 'fontSize'], 'tooltip-selector': ['fontSize', 'color', 'backgroundColor', 'tooltipFormatter', 'show'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/waterfall.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/waterfall.ts index 5357fe6663..f8d694b5c1 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/bar/waterfall.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/bar/waterfall.ts @@ -11,6 +11,7 @@ import { isEmpty } from 'lodash-es' export class Waterfall extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -21,6 +22,7 @@ export class Waterfall extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient'], 'label-selector': ['fontSize', 'color', 'vPosition', 'labelFormatter'], 'tooltip-selector': ['fontSize', 'color', 'backgroundColor', 'seriesTooltipFormatter', 'show'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/line/common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/line/common.ts index f1f7a5ed9c..7d88df7f9e 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/line/common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/line/common.ts @@ -1,5 +1,6 @@ export const LINE_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'x-axis-selector', 'y-axis-selector', @@ -14,6 +15,7 @@ export const LINE_EDITOR_PROPERTY: EditorProperty[] = [ ] export const LINE_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'label-selector': ['fontSize', 'color'], 'tooltip-selector': ['fontSize', 'color', 'backgroundColor', 'show'], 'basic-style-selector': [ diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/line/stock-line.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/line/stock-line.ts index 010545e475..1775d25737 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/line/stock-line.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/line/stock-line.ts @@ -17,6 +17,7 @@ const DEFAULT_DATA = [] export class StockLine extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'x-axis-selector', 'y-axis-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/liquid/liquid.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/liquid/liquid.ts index 8f71c29927..53524a18ee 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/liquid/liquid.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/liquid/liquid.ts @@ -16,6 +16,7 @@ const DEFAULT_LIQUID_DATA = [] export class Liquid extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'misc-selector', @@ -24,6 +25,7 @@ export class Liquid extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha'], 'label-selector': ['fontSize', 'color', 'labelFormatter'], 'misc-selector': ['liquidShape', 'liquidSize', 'liquidMaxType', 'liquidMaxField'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/map/common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/map/common.ts index 18335669da..7589f4d2b8 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/map/common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/map/common.ts @@ -1,5 +1,6 @@ export const MAP_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector', 'label-selector', @@ -12,6 +13,7 @@ export const MAP_EDITOR_PROPERTY: EditorProperty[] = [ export const MAP_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'areaBorderColor', 'zoom'], 'title-selector': [ 'title', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/map/flow-map.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/map/flow-map.ts index 8d7d3c494c..3ac0b2f8a9 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/map/flow-map.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/map/flow-map.ts @@ -21,6 +21,7 @@ const { t } = useI18n() export class FlowMap extends L7ChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector', 'flow-map-line-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/map/heat-map.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/map/heat-map.ts index b12600bc21..21fdf99bd4 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/map/heat-map.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/map/heat-map.ts @@ -21,6 +21,7 @@ const { t } = useI18n() export class HeatMap extends L7ChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector' ] diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/map/symbolic-map.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/map/symbolic-map.ts index da57787b44..d02a0c8798 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/map/symbolic-map.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/map/symbolic-map.ts @@ -22,6 +22,7 @@ const { t } = useI18n() export class SymbolicMap extends L7ChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector', 'label-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/chart-mix-common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/chart-mix-common.ts index ac6b0d8d35..e881172469 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/chart-mix-common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/chart-mix-common.ts @@ -2,6 +2,7 @@ import { DEFAULT_BASIC_STYLE } from '@/views/chart/components/editor/util/chart' export const CHART_MIX_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'dual-basic-style-selector', 'x-axis-selector', 'dual-y-axis-selector', @@ -16,6 +17,7 @@ export const CHART_MIX_EDITOR_PROPERTY: EditorProperty[] = [ ] export const CHART_MIX_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'label-selector': ['fontSize', 'color'], 'tooltip-selector': ['fontSize', 'color', 'backgroundColor', 'show'], 'dual-basic-style-selector': [ diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/funnel.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/funnel.ts index 35d1b652e1..ec14363616 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/funnel.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/funnel.ts @@ -14,6 +14,7 @@ const { t } = useI18n() export class Funnel extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -24,6 +25,7 @@ export class Funnel extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'seriesColor'], 'label-selector': ['fontSize', 'color', 'hPosition', 'showQuota', 'conversionTag'], 'tooltip-selector': ['color', 'fontSize', 'backgroundColor', 'seriesTooltipFormatter', 'show'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/gauge.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/gauge.ts index 60e937847a..6f7062d1f1 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/gauge.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/gauge.ts @@ -21,6 +21,7 @@ const DEFAULT_DATA = [] export class Gauge extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'misc-selector', @@ -29,6 +30,7 @@ export class Gauge extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient', 'gaugeAxisLine', 'gaugePercentLabel'], 'label-selector': ['fontSize', 'color', 'labelFormatter'], 'title-selector': [ diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/indicator.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/indicator.ts index 22f8973a12..2ce5c7934b 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/indicator.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/indicator.ts @@ -8,6 +8,7 @@ const { t } = useI18n() export class IndicatorChartView extends AbstractChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'title-selector', 'indicator-value-selector', 'indicator-name-selector', @@ -16,6 +17,7 @@ export class IndicatorChartView extends AbstractChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'title-selector': [ 'title', 'fontSize', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts index 4ddcc8456d..cc1400b945 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/quadrant.ts @@ -16,6 +16,7 @@ const { t } = useI18n() export class Quadrant extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'x-axis-selector', 'y-axis-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/radar.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/radar.ts index db57672dff..a2e01f71d4 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/radar.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/radar.ts @@ -13,6 +13,7 @@ const { t } = useI18n() export class Radar extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/rich-text.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/rich-text.ts index 3b54e11a33..b1963e47f0 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/rich-text.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/rich-text.ts @@ -6,9 +6,10 @@ const { t } = useI18n() * 富文本图表 */ export class RichTextChartView extends AbstractChartView { - properties: EditorProperty[] = ['background-overall-component', 'threshold'] + properties: EditorProperty[] = ['background-overall-component', 'border-style', 'threshold'] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], threshold: ['tableThreshold'] } axis: AxisType[] = ['xAxis', 'yAxis', 'filter'] diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/sankey-common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/sankey-common.ts index 90790b3fc3..d080ac6a39 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/sankey-common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/sankey-common.ts @@ -1,5 +1,6 @@ export const SANKEY_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'label-selector', 'tooltip-selector', @@ -10,6 +11,7 @@ export const SANKEY_EDITOR_PROPERTY: EditorProperty[] = [ export const SANKEY_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'gradient'], 'label-selector': ['fontSize', 'color', 'labelFormatter'], 'tooltip-selector': ['fontSize', 'color', 'tooltipFormatter'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/scatter.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/scatter.ts index bef607ecd4..ea2633b899 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/scatter.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/scatter.ts @@ -16,6 +16,7 @@ const { t } = useI18n() export class Scatter extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'x-axis-selector', 'y-axis-selector', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/treemap.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/treemap.ts index 8a12792044..0acf5777c7 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/treemap.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/treemap.ts @@ -16,6 +16,7 @@ const { t } = useI18n() export class Treemap extends G2PlotChartView { properties: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector', 'legend-selector', @@ -26,6 +27,7 @@ export class Treemap extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha', 'seriesColor'], 'label-selector': ['fontSize', 'color', 'showDimension', 'showQuota', 'showProportion'], 'legend-selector': ['icon', 'orient', 'fontSize', 'color', 'hPosition', 'vPosition'], diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/others/word-cloud.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/others/word-cloud.ts index 13afe0fa93..a83805b01c 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/others/word-cloud.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/others/word-cloud.ts @@ -19,6 +19,7 @@ export class WordCloud extends G2PlotChartView { properties: EditorProperty[] = [ 'basic-style-selector', 'background-overall-component', + 'border-style', 'title-selector', 'tooltip-selector', 'misc-selector', @@ -27,6 +28,7 @@ export class WordCloud extends G2PlotChartView { ] propertyInner: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'basic-style-selector': ['colors', 'alpha'], 'title-selector': [ 'title', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/pie/common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/pie/common.ts index 390700af28..f328109dbd 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/pie/common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/pie/common.ts @@ -4,6 +4,7 @@ const { t } = useI18n() export const PIE_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'title-selector', 'legend-selector', @@ -14,6 +15,7 @@ export const PIE_EDITOR_PROPERTY: EditorProperty[] = [ ] export const PIE_EDITOR_PROPERTY_INNER: EditorPropertyInner = { 'background-overall-component': ['all'], + 'border-style': ['all'], 'label-selector': [ 'fontSize', 'color', diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/table/common.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/table/common.ts index 20ab6289e6..08b146e102 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/table/common.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/table/common.ts @@ -1,5 +1,6 @@ export const TABLE_EDITOR_PROPERTY: EditorProperty[] = [ 'background-overall-component', + 'border-style', 'basic-style-selector', 'table-header-selector', 'table-cell-selector', @@ -12,6 +13,7 @@ export const TABLE_EDITOR_PROPERTY: EditorProperty[] = [ 'linkage' ] export const TABLE_EDITOR_PROPERTY_INNER: EditorPropertyInner = { + 'border-style': ['all'], 'background-overall-component': ['all'], 'basic-style-selector': ['tableColumnMode', 'tableBorderColor', 'tableScrollBarColor', 'alpha'], 'table-header-selector': [ diff --git a/core/core-frontend/src/views/chart/components/js/panel/charts/table/table-pivot.ts b/core/core-frontend/src/views/chart/components/js/panel/charts/table/table-pivot.ts index 08cc77152d..d0fa4bcb78 100644 --- a/core/core-frontend/src/views/chart/components/js/panel/charts/table/table-pivot.ts +++ b/core/core-frontend/src/views/chart/components/js/panel/charts/table/table-pivot.ts @@ -14,6 +14,7 @@ const { t } = useI18n() */ export class TablePivot extends S2ChartView { properties: EditorProperty[] = [ + 'border-style', 'background-overall-component', 'basic-style-selector', 'table-header-selector', From ab6b49791abc956d5b75b61c8dc7563b22a28bfa Mon Sep 17 00:00:00 2001 From: ulleo Date: Tue, 13 Aug 2024 14:46:39 +0800 Subject: [PATCH 7/7] =?UTF-8?q?feat(X-Pack):=20=E6=95=B0=E6=8D=AE=E5=A1=AB?= =?UTF-8?q?=E6=8A=A5=E6=89=B9=E9=87=8F=E4=B8=8A=E4=BC=A0=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/io/dataease/config/CommonConfig.java | 2 +- .../datasource/provider/CalciteProvider.java | 6 +- .../datasource/server/DatasourceServer.java | 1 - core/core-frontend/src/api/data-filling.ts | 226 ------------------ core/core-frontend/src/locales/en.ts | 1 + core/core-frontend/src/locales/tw.ts | 1 + core/core-frontend/src/locales/zh-CN.ts | 1 + .../src/store/modules/interactive.ts | 5 +- .../visualized/data/datasource/ExcelInfo.vue | 18 +- de-xpack | 2 +- .../api/xpack/dataFilling/DataFillingApi.java | 14 +- .../dto/DatasourceOptionsRequest.java | 6 +- .../xpack/dataFilling/dto/DfExcelData.java | 26 ++ .../xpack/dataFilling/dto/ExtTableField.java | 155 ++++++++++++ .../xpack/dataFilling/dto/RowDataDatum.java | 23 ++ .../io/dataease/exception/DEException.java | 2 + .../io/dataease}/utils/CommonThreadPool.java | 3 +- 17 files changed, 241 insertions(+), 251 deletions(-) delete mode 100644 core/core-frontend/src/api/data-filling.ts create mode 100644 sdk/api/api-base/src/main/java/io/dataease/api/xpack/dataFilling/dto/DfExcelData.java create mode 100644 sdk/api/api-base/src/main/java/io/dataease/api/xpack/dataFilling/dto/ExtTableField.java create mode 100644 sdk/api/api-base/src/main/java/io/dataease/api/xpack/dataFilling/dto/RowDataDatum.java rename {core/core-backend/src/main/java/io/dataease/commons => sdk/common/src/main/java/io/dataease}/utils/CommonThreadPool.java (97%) diff --git a/core/core-backend/src/main/java/io/dataease/config/CommonConfig.java b/core/core-backend/src/main/java/io/dataease/config/CommonConfig.java index 99e61a3ebb..7ed3a3833d 100644 --- a/core/core-backend/src/main/java/io/dataease/config/CommonConfig.java +++ b/core/core-backend/src/main/java/io/dataease/config/CommonConfig.java @@ -1,7 +1,7 @@ package io.dataease.config; import com.fit2cloud.autoconfigure.QuartzAutoConfiguration; -import io.dataease.commons.utils.CommonThreadPool; +import io.dataease.utils.CommonThreadPool; import org.springframework.boot.autoconfigure.AutoConfigureBefore; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; diff --git a/core/core-backend/src/main/java/io/dataease/datasource/provider/CalciteProvider.java b/core/core-backend/src/main/java/io/dataease/datasource/provider/CalciteProvider.java index 0c90d960e1..e038611fbb 100644 --- a/core/core-backend/src/main/java/io/dataease/datasource/provider/CalciteProvider.java +++ b/core/core-backend/src/main/java/io/dataease/datasource/provider/CalciteProvider.java @@ -1,7 +1,6 @@ package io.dataease.datasource.provider; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; -import io.dataease.commons.utils.CommonThreadPool; import io.dataease.dataset.utils.FieldUtils; import io.dataease.datasource.dao.auto.entity.CoreDatasource; import io.dataease.datasource.dao.auto.entity.CoreDriver; @@ -16,10 +15,7 @@ import io.dataease.extensions.datasource.provider.ExtendedJdbcClassLoader; import io.dataease.extensions.datasource.provider.Provider; import io.dataease.extensions.datasource.vo.DatasourceConfiguration; import io.dataease.i18n.Translator; -import io.dataease.utils.BeanUtils; -import io.dataease.utils.CommonBeanFactory; -import io.dataease.utils.JsonUtil; -import io.dataease.utils.LogUtil; +import io.dataease.utils.*; import jakarta.annotation.PostConstruct; import jakarta.annotation.Resource; import org.apache.calcite.adapter.jdbc.JdbcSchema; diff --git a/core/core-backend/src/main/java/io/dataease/datasource/server/DatasourceServer.java b/core/core-backend/src/main/java/io/dataease/datasource/server/DatasourceServer.java index e57cc64e7c..101a58d36e 100644 --- a/core/core-backend/src/main/java/io/dataease/datasource/server/DatasourceServer.java +++ b/core/core-backend/src/main/java/io/dataease/datasource/server/DatasourceServer.java @@ -14,7 +14,6 @@ import io.dataease.api.ds.vo.CoreDatasourceTaskLogDTO; import io.dataease.api.ds.vo.ExcelFileData; import io.dataease.api.ds.vo.ExcelSheetData; import io.dataease.commons.constants.TaskStatus; -import io.dataease.commons.utils.CommonThreadPool; import io.dataease.constant.LogOT; import io.dataease.constant.LogST; import io.dataease.dataset.manage.DatasetDataManage; diff --git a/core/core-frontend/src/api/data-filling.ts b/core/core-frontend/src/api/data-filling.ts deleted file mode 100644 index ff017ecf1d..0000000000 --- a/core/core-frontend/src/api/data-filling.ts +++ /dev/null @@ -1,226 +0,0 @@ -import request from '@/config/axios' -import dayjs from 'dayjs' - -export function formatDate(value, dateType) { - if (!value) { - return value - } - switch (dateType) { - case 'year': - return dayjs(value).format('YYYY') - case 'month': - case 'monthrange': - return dayjs(value).format('YYYY-MM') - case 'datetime': - case 'datetimerange': - return dayjs(value).format('YYYY-MM-DD HH:mm:ss') - default: - return dayjs(value).format('YYYY-MM-DD') - } -} -export interface ColumnItem { - props: string - label: string - date: boolean - dateType?: string - type: string - multiple: boolean - rangeIndex?: number - disabled?: boolean -} -export interface DataFillingOrFolder { - name: string - action?: string - id?: number | string - pid?: number | string - nodeType: 'folder' | 'data-filling' - union?: Array<{}> - allFields?: Array<{}> -} - -export interface Tree { - name: string - value?: string | number - id: string | number - nodeType: string - createBy?: string - level: number - leaf?: boolean - pid: string | number - type?: string - createTime: number - children?: Tree[] - request: any -} - -export interface DfFormSetting { - id?: string - name?: string - pid?: string - datasource?: string - tableName?: string - forms: Array - createIndex: boolean - tableIndexes: Array - - creator?: string - updater?: string - createTime?: number - updateTime?: number - weight?: number -} - -export interface DfFormItem { - type: string - typeName: string - icon: string - order?: number - value?: any - id?: string - settings: FormItemSetting - old?: boolean - removed?: boolean -} - -export interface FormItemSetting { - name?: string - placeholder?: string - required?: boolean - unique?: boolean - inputType?: string - optionSourceType?: 1 | 2 - optionDatasource?: number - optionTable?: string - optionColumn?: string - optionOrder?: string - multiple?: boolean - dateType?: 'date' | 'daterange' - rangeSeparator?: string - startPlaceholder?: string - endPlaceholder?: string - options?: Array - mapping: { - columnName?: string - columnName1?: string - columnName2?: string - type?: string - } -} - -export interface FormItemSettingOptions { - name: string - value: string -} - -export interface SimpleDatasource { - id: string - pid: string - name: string - type: string - typeAlias: string - status: string - enableDataFill: boolean -} - -export const listDataFillingForms = async (data): Promise => { - return request - .post({ url: '/data-filling/tree', data: { ...data, ...{ busiFlag: 'data-filling' } } }) - .then(res => { - return res?.data - }) -} - -export const createFolder = (data = {}): Promise => { - return request - .post({ url: '/data-filling/save', data: { ...data, nodeType: 'folder' } }) - .then(res => { - return res?.data - }) -} -export const save = (data = {}): Promise => { - return request.post({ url: '/data-filling/save', data }).then(res => { - return res?.data - }) -} - -export const move = (data = {}): Promise => { - return request.post({ url: '/data-filling/move', data }).then(res => { - return res?.data - }) -} - -export const reName = (data = {}): Promise => { - return request.post({ url: '/data-filling/rename', data }).then(res => { - return res?.data - }) -} -export const listDatasourceList = (): Promise> => { - return request.get({ url: '/data-filling/datasource/list' }).then(res => { - return res?.data - }) -} - -export const getDataFilling = async (id: string): Promise => { - return request.get({ url: `/data-filling/get/${id}` }).then(res => { - return res?.data - }) -} - -export const deleteById = (id: string): Promise => { - return request.get({ url: '/data-filling/delete/' + id }) -} - -export const deleteRowData = (formId: string, id: number): Promise => { - return request.get({ url: `/data-filling/form/${formId}/delete/${id}` }) -} - -export const batchDeleteRowData = (formId: string, data: Array): Promise => { - return request.post({ url: `/data-filling/form/${formId}/batch-delete`, data }) -} - -export const getTableColumnData = ( - optionDatasource, - optionTable, - optionColumn, - optionOrder -): Promise => { - return request.post({ - url: `/data-filling/form/${optionDatasource}/options`, - data: { - optionTable: optionTable, - optionColumn: optionColumn, - optionOrder: optionOrder - } - }) -} - -export const searchTable = (id, data): Promise => { - return request.post({ - url: '/data-filling/form/' + id + '/tableData', - data - }) -} - -export const saveFormRowData = (formId, data): Promise => { - return request - .post({ - url: '/data-filling/form/' + formId + '/rowData/save', - data - }) - .then(res => { - return res?.data - }) -} - -export const saveTask = (data): Promise => { - return request.post({ - url: `/data-filling/task/save`, - data - }) -} - -export const getTaskInfo = (taskId): Promise => { - return request.get({ - url: `/data-filling/task/info/${taskId}` - }) -} diff --git a/core/core-frontend/src/locales/en.ts b/core/core-frontend/src/locales/en.ts index e670b1b9c2..20bf288728 100644 --- a/core/core-frontend/src/locales/en.ts +++ b/core/core-frontend/src/locales/en.ts @@ -376,6 +376,7 @@ export default { commit_time: 'Commit Time', confirm_delete: 'Confirm delete?', add_data: 'Add Data', + batch_upload: 'Upload Data', download_template: 'Download Template', insert_data: 'Insert Data', update_data: 'Update Data', diff --git a/core/core-frontend/src/locales/tw.ts b/core/core-frontend/src/locales/tw.ts index 26131b7306..f405d7d45d 100644 --- a/core/core-frontend/src/locales/tw.ts +++ b/core/core-frontend/src/locales/tw.ts @@ -277,6 +277,7 @@ export default { commit_time: '提交時間', confirm_delete: '確認刪除?', add_data: '添加數據', + batch_upload: '批量上傳', download_template: '下載模板', insert_data: '插入數據', update_data: '更新數據', diff --git a/core/core-frontend/src/locales/zh-CN.ts b/core/core-frontend/src/locales/zh-CN.ts index 458c726f2a..1e2930737e 100644 --- a/core/core-frontend/src/locales/zh-CN.ts +++ b/core/core-frontend/src/locales/zh-CN.ts @@ -2707,6 +2707,7 @@ export default { commit_time: '提交时间', confirm_delete: '确认删除?', add_data: '添加数据', + batch_upload: '批量上传', download_template: '下载模板', insert_data: '插入数据', update_data: '更新数据', diff --git a/core/core-frontend/src/store/modules/interactive.ts b/core/core-frontend/src/store/modules/interactive.ts index c1e8292a02..43343ca89b 100644 --- a/core/core-frontend/src/store/modules/interactive.ts +++ b/core/core-frontend/src/store/modules/interactive.ts @@ -7,7 +7,6 @@ import type { BusiTreeRequest, BusiTreeNode } from '@/models/tree/TreeNode' import { pathValid } from '@/store/modules/permission' import { useCache } from '@/hooks/web/useCache' import { useAppStoreWithOut } from '@/store/modules/app' -import { listDataFillingForms } from '@/api/data-filling' const appStore = useAppStoreWithOut() const { wsCache } = useCache() export interface InnerInteractive { @@ -22,9 +21,9 @@ interface InteractiveState { data: Record } -const apiMap = [queryTreeApi, queryTreeApi, getDatasetTree, listDatasources, listDataFillingForms] +const apiMap = [queryTreeApi, queryTreeApi, getDatasetTree, listDatasources] -const busiFlagMap = ['dashboard', 'dataV', 'dataset', 'datasource', 'data-filling'] +const busiFlagMap = ['dashboard', 'dataV', 'dataset', 'datasource'] export const interactiveStore = defineStore('interactive', { state: (): InteractiveState => ({ diff --git a/core/core-frontend/src/views/visualized/data/datasource/ExcelInfo.vue b/core/core-frontend/src/views/visualized/data/datasource/ExcelInfo.vue index 1c27fd0ff7..d09846577c 100644 --- a/core/core-frontend/src/views/visualized/data/datasource/ExcelInfo.vue +++ b/core/core-frontend/src/views/visualized/data/datasource/ExcelInfo.vue @@ -1,10 +1,16 @@