cloud-web-corejs 1.0.214 → 1.0.216
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/dropdown-item-widget.vue +10 -1
- package/src/components/xform/form-designer/form-widget/field-widget/dropdown-widget.vue +128 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/dropdownFlag-editor.vue +89 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/name-editor.vue +2 -0
- package/src/components/xform/form-designer/setting-panel/propertyRegister.js +2 -2
- package/src/components/xform/form-designer/widget-panel/widgetsConfig.js +15 -11
- package/src/components/xform/form-render/indexMixin.js +81 -62
- package/src/components/xform/lang/zh-CN.js +1 -1
- package/src/components/xform/utils/formula-util.js +3 -0
- package/src/components/xform/utils/util.js +14 -9
- package/src/views/user/fieldTranslation/list.vue +1 -1
package/package.json
CHANGED
package/src/components/xform/form-designer/form-widget/field-widget/dropdown-item-widget.vue
CHANGED
|
@@ -65,7 +65,16 @@ export default {
|
|
|
65
65
|
},
|
|
66
66
|
|
|
67
67
|
methods: {
|
|
68
|
-
|
|
68
|
+
setHidden: function (e) {
|
|
69
|
+
this.field.options.hidden = e;
|
|
70
|
+
this.hidden = e;
|
|
71
|
+
this.$emit('hiddenChange' )
|
|
72
|
+
},
|
|
73
|
+
setDisabled: function (e) {
|
|
74
|
+
this.field.options.disabled = e;
|
|
75
|
+
this.disabled = e;
|
|
76
|
+
this.$emit('disabledChange')
|
|
77
|
+
},
|
|
69
78
|
}
|
|
70
79
|
|
|
71
80
|
}
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<static-content-wrapper :designer="designer" :field="field" :design-state="designState"
|
|
3
|
+
:display-style="field.options.displayStyle"
|
|
4
|
+
:parent-widget="parentWidget" :parent-list="parentList"
|
|
5
|
+
:index-of-parent-list="indexOfParentList"
|
|
6
|
+
:sub-form-row-index="subFormRowIndex" :sub-form-col-index="subFormColIndex"
|
|
7
|
+
:sub-form-row-id="subFormRowId">
|
|
8
|
+
<el-dropdown trigger="hover" :disabled="field.options.disabled">
|
|
9
|
+
|
|
10
|
+
<el-button type="primary" class="button-sty" size="mini">
|
|
11
|
+
<span>{{ getI18nLabel(field.options.label) }}</span><span class="line"></span> <i
|
|
12
|
+
class="el-icon-arrow-down el-icon--right"></i>
|
|
13
|
+
</el-button>
|
|
14
|
+
<el-dropdown-menu slot="dropdown">
|
|
15
|
+
<template v-for="(subWidget,index) in field.widgetList">
|
|
16
|
+
<el-dropdown-item v-show="!subWidget.options.hidden" :key="index" :icon="subWidget.options.icon"
|
|
17
|
+
@click.native="(e) => handleSubButtonWidgetClick(e,index)" :disabled="subWidget.options.disabled">
|
|
18
|
+
<!-- {{ getI18nLabel(subWidget.options.label) }}-->
|
|
19
|
+
<dropdownItemWidget :field="subWidget" :parent-list="field.widgetList"
|
|
20
|
+
:index-of-parent-list="index" :parent-widget="field" :tableParam="tableParam"
|
|
21
|
+
:formItemProp="formItemProp" :ref="'item'+index" @hiddenChange="handleHidden"
|
|
22
|
+
@disabledChange="handleDisabled">
|
|
23
|
+
</dropdownItemWidget>
|
|
24
|
+
</el-dropdown-item>
|
|
25
|
+
|
|
26
|
+
</template>
|
|
27
|
+
</el-dropdown-menu>
|
|
28
|
+
</el-dropdown>
|
|
29
|
+
</static-content-wrapper>
|
|
30
|
+
</template>
|
|
31
|
+
|
|
32
|
+
<script>
|
|
33
|
+
import StaticContentWrapper from './static-content-wrapper'
|
|
34
|
+
import emitter from '../../../utils/emitter'
|
|
35
|
+
import i18n from "../../../utils/i18n";
|
|
36
|
+
import fieldMixin from "./fieldMixin";
|
|
37
|
+
import dropdownItemWidget from './dropdown-item-widget.vue';
|
|
38
|
+
|
|
39
|
+
export default {
|
|
40
|
+
name: "dropdown-widget",
|
|
41
|
+
componentName: 'FieldWidget', //必须固定为FieldWidget,用于接收父级组件的broadcast事件
|
|
42
|
+
mixins: [emitter, fieldMixin, i18n],
|
|
43
|
+
props: {
|
|
44
|
+
field: Object,
|
|
45
|
+
parentWidget: Object,
|
|
46
|
+
parentList: Array,
|
|
47
|
+
indexOfParentList: Number,
|
|
48
|
+
designer: Object,
|
|
49
|
+
|
|
50
|
+
designState: {
|
|
51
|
+
type: Boolean,
|
|
52
|
+
default: false
|
|
53
|
+
},
|
|
54
|
+
|
|
55
|
+
subFormRowIndex: { /* 子表单组件行索引,从0开始计数 */
|
|
56
|
+
type: Number,
|
|
57
|
+
default: -1
|
|
58
|
+
},
|
|
59
|
+
subFormColIndex: { /* 子表单组件列索引,从0开始计数 */
|
|
60
|
+
type: Number,
|
|
61
|
+
default: -1
|
|
62
|
+
},
|
|
63
|
+
subFormRowId: { /* 子表单组件行Id,唯一id且不可变 */
|
|
64
|
+
type: String,
|
|
65
|
+
default: ''
|
|
66
|
+
},
|
|
67
|
+
|
|
68
|
+
},
|
|
69
|
+
components: {
|
|
70
|
+
StaticContentWrapper,
|
|
71
|
+
dropdownItemWidget
|
|
72
|
+
},
|
|
73
|
+
computed: {
|
|
74
|
+
|
|
75
|
+
},
|
|
76
|
+
beforeCreate() {
|
|
77
|
+
/* 这里不能访问方法和属性!! */
|
|
78
|
+
},
|
|
79
|
+
|
|
80
|
+
created() {
|
|
81
|
+
/* 注意:子组件mounted在父组件created之后、父组件mounted之前触发,故子组件mounted需要用到的prop
|
|
82
|
+
需要在父组件created中初始化!! */
|
|
83
|
+
this.registerToRefList()
|
|
84
|
+
this.initEventHandler()
|
|
85
|
+
this.init()
|
|
86
|
+
this.handleOnCreated()
|
|
87
|
+
},
|
|
88
|
+
|
|
89
|
+
mounted() {
|
|
90
|
+
this.handleOnMounted()
|
|
91
|
+
},
|
|
92
|
+
|
|
93
|
+
beforeDestroy() {
|
|
94
|
+
this.unregisterFromRefList()
|
|
95
|
+
},
|
|
96
|
+
|
|
97
|
+
methods: {
|
|
98
|
+
init(){
|
|
99
|
+
if(this.designState)return
|
|
100
|
+
let isShow = this.field.widgetList.some((item) => !item.options.hidden)
|
|
101
|
+
if(!isShow){
|
|
102
|
+
this.field.options.hidden = true
|
|
103
|
+
}
|
|
104
|
+
let isEnabled = this.field.widgetList.some((item) => !item.options.disabled)
|
|
105
|
+
if(!isEnabled){
|
|
106
|
+
this.field.options.disabled = true
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
handleSubButtonWidgetClick(e, index) {
|
|
110
|
+
this.$refs["item"+index][0].handleButtonWidgetClick(e)
|
|
111
|
+
},
|
|
112
|
+
handleHidden() {
|
|
113
|
+
let isShow = this.field.widgetList.some((item) => !item.options.hidden)
|
|
114
|
+
this.setHidden(!isShow)
|
|
115
|
+
},
|
|
116
|
+
handleDisabled() {
|
|
117
|
+
let isEnabled = this.field.widgetList.some((item) => !item.options.disabled)
|
|
118
|
+
this.setDisabled(!isEnabled)
|
|
119
|
+
},
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
}
|
|
123
|
+
</script>
|
|
124
|
+
|
|
125
|
+
<style lang="scss" scoped>
|
|
126
|
+
@import "~@/styles/global.scss"; //* static-content-wrapper已引入,还需要重复引入吗? *//
|
|
127
|
+
|
|
128
|
+
</style>
|
package/src/components/xform/form-designer/setting-panel/property-editor/dropdownFlag-editor.vue
ADDED
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<el-form-item label-width="0">
|
|
4
|
+
<el-divider class="custom-divider">下拉按钮设置</el-divider>
|
|
5
|
+
</el-form-item>
|
|
6
|
+
<el-form-item label="当前下拉按钮"></el-form-item>
|
|
7
|
+
<el-form-item label-width="0">
|
|
8
|
+
<draggable tag="ul" class="draggable-box" :list="selectedWidget.widgetList"
|
|
9
|
+
v-bind="{ group: 'optionsGroup', ghostClass: 'ghost', handle: '.drag-option' }">
|
|
10
|
+
<li v-for="(colItem, colIdx) in selectedWidget.widgetList" :key="colIdx" class="col-item">
|
|
11
|
+
<i class="el-icon-s-operation drag-option"></i>
|
|
12
|
+
<el-input v-model="colItem.options.label" class="cell-span-input"></el-input>
|
|
13
|
+
<el-button circle plain size="mini" type="button"
|
|
14
|
+
icon="el-icon-edit" class="col-delete-button" style="position: unset;" @click="openEditFormatConfigDialog(colItem, colIdx)"></el-button>
|
|
15
|
+
<el-button circle plain size="mini" type="danger" @click="deleteCol(selectedWidget, colIdx)"
|
|
16
|
+
icon="el-icon-minus" class="col-delete-button" style="position: unset;"></el-button>
|
|
17
|
+
</li>
|
|
18
|
+
</draggable>
|
|
19
|
+
<div>
|
|
20
|
+
<el-button type="text" @click="addNewCol(selectedWidget)" icon="el-icon-circle-plus-outline" class="add-option">
|
|
21
|
+
增加
|
|
22
|
+
</el-button>
|
|
23
|
+
</div>
|
|
24
|
+
</el-form-item>
|
|
25
|
+
</div>
|
|
26
|
+
</template>
|
|
27
|
+
|
|
28
|
+
<script>
|
|
29
|
+
import Draggable from 'vuedraggable';
|
|
30
|
+
import i18n from "../../../utils/i18n"
|
|
31
|
+
import {deepClone, generateId} from "../../../utils/util"
|
|
32
|
+
|
|
33
|
+
export default {
|
|
34
|
+
name: "dropdownFlag-editor",
|
|
35
|
+
mixins: [i18n],
|
|
36
|
+
components: {
|
|
37
|
+
Draggable,
|
|
38
|
+
},
|
|
39
|
+
props: {
|
|
40
|
+
designer: Object,
|
|
41
|
+
selectedWidget: Object,
|
|
42
|
+
optionModel: Object,
|
|
43
|
+
},
|
|
44
|
+
inject: ['openWidgetPropertyDialog'],
|
|
45
|
+
methods: {
|
|
46
|
+
deleteCol(gridWidget, colIdx) {
|
|
47
|
+
if (!!gridWidget && !!gridWidget.widgetList) {
|
|
48
|
+
gridWidget.widgetList.splice(colIdx, 1);
|
|
49
|
+
}
|
|
50
|
+
this.designer.emitHistoryChange()
|
|
51
|
+
},
|
|
52
|
+
|
|
53
|
+
addNewCol(gridWidget) {
|
|
54
|
+
let newGridCol = deepClone(this.designer.getFieldWidgetByType('dropdown-item'));
|
|
55
|
+
let tmpId = generateId();
|
|
56
|
+
newGridCol.id = 'dropdown-item-' + tmpId;
|
|
57
|
+
newGridCol.options.name = 'dropdownItem' + tmpId;
|
|
58
|
+
newGridCol.options.label = 'dropdownItem' + tmpId;
|
|
59
|
+
gridWidget.widgetList.push(newGridCol);
|
|
60
|
+
this.designer.emitHistoryChange()
|
|
61
|
+
},
|
|
62
|
+
openEditFormatConfigDialog(fieldWidget, index) {
|
|
63
|
+
this.openWidgetPropertyDialog({
|
|
64
|
+
columnSelectedWidget: deepClone(fieldWidget),
|
|
65
|
+
callback: (columnOption) => {
|
|
66
|
+
fieldWidget.options = columnOption;
|
|
67
|
+
},
|
|
68
|
+
});
|
|
69
|
+
},
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
</script>
|
|
73
|
+
|
|
74
|
+
<style lang="scss" scoped>
|
|
75
|
+
li.col-item {
|
|
76
|
+
list-style: none;
|
|
77
|
+
|
|
78
|
+
span.col-span-title {
|
|
79
|
+
display: inline-block;
|
|
80
|
+
font-size: 13px;
|
|
81
|
+
width: 120px;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.col-delete-button {
|
|
85
|
+
margin-left: 6px;
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
</style>
|
|
@@ -115,8 +115,8 @@ const COMMON_PROPERTIES = {
|
|
|
115
115
|
'showRuleFlag': 'showRuleFlag-editor',
|
|
116
116
|
'widgetShowRuleFlag': 'widgetShowRuleFlag-editor',
|
|
117
117
|
|
|
118
|
-
'
|
|
119
|
-
'dropdownItemFlag': 'dropdown-item-editor',
|
|
118
|
+
'dropdownFlag': 'dropdownFlag-editor',
|
|
119
|
+
// 'dropdownItemFlag': 'dropdown-item-editor',
|
|
120
120
|
|
|
121
121
|
'oplogFlag': 'oplogFlag-editor',
|
|
122
122
|
'ganttConfig': 'gantt-editor',
|
|
@@ -252,6 +252,7 @@ export const containers = [
|
|
|
252
252
|
accessParam: null,
|
|
253
253
|
accessCallback: null,*/
|
|
254
254
|
isQueryTable: false,
|
|
255
|
+
searchOnSwitchTab: false,
|
|
255
256
|
entityTableCode: null,
|
|
256
257
|
entityTableDesc: null,
|
|
257
258
|
|
|
@@ -900,8 +901,9 @@ export const hiddenWidgetTypesOfWf = [
|
|
|
900
901
|
"import-button",
|
|
901
902
|
"import2-button",
|
|
902
903
|
"print-button",
|
|
904
|
+
"dropdown-item",
|
|
903
905
|
];
|
|
904
|
-
export const freeWidgetTypesOfWf = ["reset_button","copy_button", "a-link", "a-text"];
|
|
906
|
+
export const freeWidgetTypesOfWf = ["reset_button","copy_button", "a-link", "a-text", 'dropdown'];
|
|
905
907
|
|
|
906
908
|
export const basicFields = [
|
|
907
909
|
{
|
|
@@ -3377,9 +3379,9 @@ export const advancedFields = [
|
|
|
3377
3379
|
},
|
|
3378
3380
|
},
|
|
3379
3381
|
{
|
|
3380
|
-
type: "dropdown
|
|
3382
|
+
type: "dropdown",
|
|
3381
3383
|
icon: "tab",
|
|
3382
|
-
|
|
3384
|
+
commonFlag: !0,
|
|
3383
3385
|
// columnFlag: true,
|
|
3384
3386
|
widgetList: [],
|
|
3385
3387
|
options: {
|
|
@@ -3387,12 +3389,9 @@ export const advancedFields = [
|
|
|
3387
3389
|
label: "",
|
|
3388
3390
|
hidden: !1,
|
|
3389
3391
|
disabled: !1,
|
|
3390
|
-
height: "",
|
|
3391
|
-
// isFullscreen: false,
|
|
3392
|
-
tabClass: "tab-boxCard tabCard-sty1",
|
|
3393
3392
|
customClass: "",
|
|
3394
|
-
|
|
3395
|
-
...defaultWfConfig,
|
|
3393
|
+
dropdownFlag: 1,
|
|
3394
|
+
// ...defaultWfConfig,
|
|
3396
3395
|
onCreated: "",
|
|
3397
3396
|
onMounted: "",
|
|
3398
3397
|
},
|
|
@@ -3405,12 +3404,14 @@ export const advancedFields = [
|
|
|
3405
3404
|
name: "",
|
|
3406
3405
|
label: "",
|
|
3407
3406
|
hidden: !1,
|
|
3408
|
-
active: !1,
|
|
3409
3407
|
disabled: !1,
|
|
3410
3408
|
customClass: "",
|
|
3411
3409
|
dropdownItemFlag: 1,
|
|
3412
3410
|
|
|
3413
3411
|
onClick: "",
|
|
3412
|
+
onCreated: "",
|
|
3413
|
+
onMounted: "",
|
|
3414
|
+
|
|
3414
3415
|
clickBindEvent: null,
|
|
3415
3416
|
onBeforeClickButton: null,
|
|
3416
3417
|
searchDialogConfig: {
|
|
@@ -3420,6 +3421,9 @@ export const advancedFields = [
|
|
|
3420
3421
|
tableRef: null,
|
|
3421
3422
|
tableData: {},
|
|
3422
3423
|
},
|
|
3424
|
+
|
|
3425
|
+
...defaultWfConfig,
|
|
3426
|
+
...defaultWidgetShowRuleConfig,
|
|
3423
3427
|
},
|
|
3424
3428
|
},
|
|
3425
3429
|
{
|
|
@@ -3483,7 +3487,7 @@ export const advancedFields = [
|
|
|
3483
3487
|
},
|
|
3484
3488
|
},
|
|
3485
3489
|
|
|
3486
|
-
{
|
|
3490
|
+
/* {
|
|
3487
3491
|
type: "vue-page",
|
|
3488
3492
|
icon: "html-text",
|
|
3489
3493
|
commonFlag: !0,
|
|
@@ -3501,7 +3505,7 @@ export const advancedFields = [
|
|
|
3501
3505
|
labelHidden: !1,
|
|
3502
3506
|
|
|
3503
3507
|
},
|
|
3504
|
-
},
|
|
3508
|
+
}, */
|
|
3505
3509
|
];
|
|
3506
3510
|
|
|
3507
3511
|
export const businessFields = [
|
|
@@ -534,7 +534,7 @@ modules = {
|
|
|
534
534
|
loopHandleWidget(this.formJson.widgetList, (widget, parentWidget) => {
|
|
535
535
|
if (callback) {
|
|
536
536
|
callback(widget);
|
|
537
|
-
if (widget.type
|
|
537
|
+
if (widget.type === "data-table") {
|
|
538
538
|
widget.options.tableColumns.forEach((item) => {
|
|
539
539
|
columnLoopDo(item);
|
|
540
540
|
});
|
|
@@ -545,7 +545,7 @@ modules = {
|
|
|
545
545
|
handleAllTableColumnWidget() {
|
|
546
546
|
traverseAllWidgetsNew(this.formJson.widgetList, (widget) => {
|
|
547
547
|
//修复data-table旧数据表格列widget与editWidget为空的问题
|
|
548
|
-
if (widget.type
|
|
548
|
+
if (widget.type === "data-table") {
|
|
549
549
|
this.handleTableColumnWidget(widget);
|
|
550
550
|
}
|
|
551
551
|
});
|
|
@@ -554,7 +554,7 @@ modules = {
|
|
|
554
554
|
//修复data-table旧数据表格列widget与editWidget为空的问题
|
|
555
555
|
if (
|
|
556
556
|
!widget
|
|
557
|
-
|| widget.type
|
|
557
|
+
|| widget.type !== "data-table"
|
|
558
558
|
|| !widget.options.tableColumns
|
|
559
559
|
)
|
|
560
560
|
return;
|
|
@@ -637,7 +637,7 @@ modules = {
|
|
|
637
637
|
//有流程,且不匹配流程节点可编辑表单设置信息
|
|
638
638
|
//设置组件的有流程可编辑,有流程隐藏
|
|
639
639
|
this.hanldeWfWidgetNew1(widget);
|
|
640
|
-
if (wfInfo.taskStep
|
|
640
|
+
if (wfInfo.taskStep === "9999") {
|
|
641
641
|
this.hanldeWfWidgetItemNew(widget);
|
|
642
642
|
} else if (toModify) {
|
|
643
643
|
//后台返回流程可以修改单据
|
|
@@ -686,8 +686,8 @@ modules = {
|
|
|
686
686
|
let companyCodes = companyCodeStr
|
|
687
687
|
? companyCodeStr.split(",").filter((item) => !!item)
|
|
688
688
|
: [];
|
|
689
|
-
let flag1 = !item.serveName || item.serveName
|
|
690
|
-
// let flag2 = !item.modelKey || item.modelKey
|
|
689
|
+
let flag1 = !item.serveName || item.serveName === bdService;
|
|
690
|
+
// let flag2 = !item.modelKey || item.modelKey === modelKey;
|
|
691
691
|
let flag2
|
|
692
692
|
= item.modelOrders === undefined
|
|
693
693
|
|| item.modelOrders === null
|
|
@@ -728,8 +728,8 @@ modules = {
|
|
|
728
728
|
let companyCodes = companyCodeStr
|
|
729
729
|
? companyCodeStr.split(",").filter((item) => !!item)
|
|
730
730
|
: [];
|
|
731
|
-
let flag1 = !item.serveName || item.serveName
|
|
732
|
-
// let flag2 = !item.modelKey || item.modelKey
|
|
731
|
+
let flag1 = !item.serveName || item.serveName === bdService;
|
|
732
|
+
// let flag2 = !item.modelKey || item.modelKey === modelKey;
|
|
733
733
|
let flag2
|
|
734
734
|
= item.modelOrders === undefined
|
|
735
735
|
|| item.modelOrders === null
|
|
@@ -752,7 +752,7 @@ modules = {
|
|
|
752
752
|
let result
|
|
753
753
|
= freeWidgetTypesOfWf.includes(widgetType)
|
|
754
754
|
|| (sourceType && freeWidgetTypesOfWf.includes(sourceType));
|
|
755
|
-
return widget.options.label
|
|
755
|
+
return widget.options.label === "重置" || result;
|
|
756
756
|
},
|
|
757
757
|
getIsHiddenWidgetTypesOfWf(widget) {
|
|
758
758
|
if (!widget) return false;
|
|
@@ -817,7 +817,6 @@ modules = {
|
|
|
817
817
|
if (!options || !options.wfEdit) return;
|
|
818
818
|
let wfConfigData = options.wfConfigData || [];
|
|
819
819
|
let flag = false;
|
|
820
|
-
|
|
821
820
|
wfConfigData.forEach((item) => {
|
|
822
821
|
let type = item.type;
|
|
823
822
|
let taskStepList = item.taskSteps ? item.taskSteps.split(",") : [];
|
|
@@ -826,8 +825,8 @@ modules = {
|
|
|
826
825
|
let companyCodes = companyCodeStr
|
|
827
826
|
? companyCodeStr.split(",").filter((item) => !!item)
|
|
828
827
|
: [];
|
|
829
|
-
let flag1 = !item.serveName || item.serveName
|
|
830
|
-
// let flag2 = !item.modelKey || item.modelKey
|
|
828
|
+
let flag1 = !item.serveName || item.serveName === bdService;
|
|
829
|
+
// let flag2 = !item.modelKey || item.modelKey === modelKey;
|
|
831
830
|
|
|
832
831
|
let flag2
|
|
833
832
|
= item.modelOrders === undefined
|
|
@@ -859,7 +858,7 @@ modules = {
|
|
|
859
858
|
}
|
|
860
859
|
}
|
|
861
860
|
});
|
|
862
|
-
/*if (flag && e && widget.type
|
|
861
|
+
/*if (flag && e && widget.type === 'baseAttachment') {
|
|
863
862
|
e.initOption();
|
|
864
863
|
}*/
|
|
865
864
|
};
|
|
@@ -879,7 +878,7 @@ modules = {
|
|
|
879
878
|
if (optionModel.widgetShowRuleEnabled) {
|
|
880
879
|
let companyCode = this.$store.getters.companyCode;
|
|
881
880
|
let bdService = this.bdService;
|
|
882
|
-
let userRoleDTOs = this.
|
|
881
|
+
let userRoleDTOs = this.userRoleDTO2s;
|
|
883
882
|
let userRoleCodes = userRoleDTOs.map((item) => item.roleCode);
|
|
884
883
|
|
|
885
884
|
let widgetShowRuleConfig = optionModel.widgetShowRuleConfig || [];
|
|
@@ -925,10 +924,10 @@ modules = {
|
|
|
925
924
|
let flag = userRoleCodes.some((roleCode) =>
|
|
926
925
|
roleCodes.includes(roleCode)
|
|
927
926
|
);
|
|
928
|
-
if (showRuleItem.type
|
|
927
|
+
if (showRuleItem.type === 1) {
|
|
929
928
|
//符合条件的角色显示,否则隐藏
|
|
930
929
|
optionModel.hidden = flag ? false : true;
|
|
931
|
-
} else if (showRuleItem.type
|
|
930
|
+
} else if (showRuleItem.type === 2) {
|
|
932
931
|
//符合条件的角色隐藏,否则显示
|
|
933
932
|
optionModel.hidden = flag ? true : false;
|
|
934
933
|
}
|
|
@@ -972,7 +971,7 @@ modules = {
|
|
|
972
971
|
// setDisabled(target,false);
|
|
973
972
|
disabled = false;
|
|
974
973
|
}
|
|
975
|
-
if (widgetType
|
|
974
|
+
if (widgetType === "reset_button" && enabledByWf === undefined) {
|
|
976
975
|
// setDisabled(target,false)
|
|
977
976
|
disabled = false;
|
|
978
977
|
}
|
|
@@ -993,7 +992,7 @@ modules = {
|
|
|
993
992
|
}
|
|
994
993
|
if (
|
|
995
994
|
widget
|
|
996
|
-
&& widgetType
|
|
995
|
+
&& widgetType === "save_button"
|
|
997
996
|
&& hiddenByWf === undefined
|
|
998
997
|
) {
|
|
999
998
|
// setHidden(target,true)
|
|
@@ -1009,7 +1008,7 @@ modules = {
|
|
|
1009
1008
|
}
|
|
1010
1009
|
}
|
|
1011
1010
|
|
|
1012
|
-
if (widget?.type
|
|
1011
|
+
if (widget?.type === "data-table") {
|
|
1013
1012
|
let loopDo = (t, e) => {
|
|
1014
1013
|
if (t.children && t.children.length) {
|
|
1015
1014
|
t.children.forEach((item) => {
|
|
@@ -1028,7 +1027,7 @@ modules = {
|
|
|
1028
1027
|
});
|
|
1029
1028
|
});
|
|
1030
1029
|
}
|
|
1031
|
-
/*if (target && widgetType
|
|
1030
|
+
/*if (target && widgetType === 'baseAttachment') {
|
|
1032
1031
|
target.initOption();
|
|
1033
1032
|
}*/
|
|
1034
1033
|
};
|
|
@@ -1102,8 +1101,8 @@ modules = {
|
|
|
1102
1101
|
let companyCodes = companyCodeStr
|
|
1103
1102
|
? companyCodeStr.split(",").filter((item) => !!item)
|
|
1104
1103
|
: [];
|
|
1105
|
-
let flag1 = !item.serveName || item.serveName
|
|
1106
|
-
let flag2 = !item.modelKey || item.modelKey
|
|
1104
|
+
let flag1 = !item.serveName || item.serveName === bdService;
|
|
1105
|
+
let flag2 = !item.modelKey || item.modelKey === modelKey;
|
|
1107
1106
|
let flag3
|
|
1108
1107
|
= !companyCodes.length || companyCodes.includes(companyCode);
|
|
1109
1108
|
if (flag1 && flag2 && flag3) {
|
|
@@ -1130,12 +1129,12 @@ modules = {
|
|
|
1130
1129
|
}
|
|
1131
1130
|
}
|
|
1132
1131
|
});
|
|
1133
|
-
/*if (flag && e && widget.type
|
|
1132
|
+
/*if (flag && e && widget.type === 'baseAttachment') {
|
|
1134
1133
|
e.initOption();
|
|
1135
1134
|
}*/
|
|
1136
1135
|
};
|
|
1137
1136
|
handleWfConfigData(widget);
|
|
1138
|
-
if (widget.type
|
|
1137
|
+
if (widget.type === "data-table") {
|
|
1139
1138
|
let loopDo = (t) => {
|
|
1140
1139
|
if (t.children && t.children.length) {
|
|
1141
1140
|
t.children.forEach((item) => {
|
|
@@ -1380,13 +1379,13 @@ modules = {
|
|
|
1380
1379
|
let valIds = value.map((item) => item.id);
|
|
1381
1380
|
if (valIds.length) {
|
|
1382
1381
|
let result = !widget.options.hidden;
|
|
1383
|
-
if (ruleType
|
|
1382
|
+
if (ruleType === 1) {
|
|
1384
1383
|
result = valIds.includes(userId) ? isShow : !isShow;
|
|
1385
|
-
} else if (ruleType
|
|
1384
|
+
} else if (ruleType === 2) {
|
|
1386
1385
|
result = saleOrgIds.find((item) => valIds.includes(item))
|
|
1387
1386
|
? isShow
|
|
1388
1387
|
: !isShow;
|
|
1389
|
-
} else if (ruleType
|
|
1388
|
+
} else if (ruleType === 3) {
|
|
1390
1389
|
result = roleIds.find((item) => valIds.includes(item))
|
|
1391
1390
|
? isShow
|
|
1392
1391
|
: !isShow;
|
|
@@ -1637,7 +1636,7 @@ modules = {
|
|
|
1637
1636
|
handleCustomEvent(funtionStr, eventParamNames = [], eventParamValues = []) {
|
|
1638
1637
|
if (!this.designState && funtionStr) {
|
|
1639
1638
|
let eventParam = this.getEventParam();
|
|
1640
|
-
|
|
1639
|
+
let e = new Function(
|
|
1641
1640
|
...eventParam.eventParamNames,
|
|
1642
1641
|
...eventParamNames,
|
|
1643
1642
|
funtionStr
|
|
@@ -1717,7 +1716,7 @@ modules = {
|
|
|
1717
1716
|
if (!!subFormName) {
|
|
1718
1717
|
let subFormRef = this.getWidgetRef(subFormName);
|
|
1719
1718
|
if (!!subFormRef) {
|
|
1720
|
-
if (subFormRef.widget.type
|
|
1719
|
+
if (subFormRef.widget.type === "data-table") {
|
|
1721
1720
|
let rows = subFormRef.getValue();
|
|
1722
1721
|
if (rows) {
|
|
1723
1722
|
rows.forEach((row) => {
|
|
@@ -2135,7 +2134,7 @@ modules = {
|
|
|
2135
2134
|
let widgetName = widget.options.name;
|
|
2136
2135
|
let fieldKeyName = this.getFieldKeyName(widget);
|
|
2137
2136
|
if (widget.tableField) {
|
|
2138
|
-
if (flag
|
|
2137
|
+
if (flag === 1) {
|
|
2139
2138
|
fieldMap[fieldKeyName] = widget;
|
|
2140
2139
|
} else {
|
|
2141
2140
|
fieldMap[fieldKeyName] = fieldKeyName;
|
|
@@ -2145,14 +2144,14 @@ modules = {
|
|
|
2145
2144
|
}
|
|
2146
2145
|
}
|
|
2147
2146
|
} else {
|
|
2148
|
-
if (widget.category
|
|
2147
|
+
if (widget.category === "container") {
|
|
2149
2148
|
let itemField = itemFieldMap[widget.type];
|
|
2150
2149
|
if (itemField) {
|
|
2151
|
-
if ("table"
|
|
2150
|
+
if ("table" === widget.type) {
|
|
2152
2151
|
widget[itemField].forEach((item) => {
|
|
2153
2152
|
loopDo(item.cols);
|
|
2154
2153
|
});
|
|
2155
|
-
} else if ("h5-table"
|
|
2154
|
+
} else if ("h5-table" === widget.type) {
|
|
2156
2155
|
widget[itemField].forEach((item) => {
|
|
2157
2156
|
loopDo(item.cols);
|
|
2158
2157
|
});
|
|
@@ -2174,7 +2173,7 @@ modules = {
|
|
|
2174
2173
|
isVabsearchFlagWidget(widget) {
|
|
2175
2174
|
let type = widget?.type;
|
|
2176
2175
|
return (
|
|
2177
|
-
type
|
|
2176
|
+
type === "vabsearch" || type === "singerSearch" || type === "multiSearch"
|
|
2178
2177
|
);
|
|
2179
2178
|
},
|
|
2180
2179
|
getFormTemplateTableDTOs() {
|
|
@@ -2204,7 +2203,7 @@ modules = {
|
|
|
2204
2203
|
if (!widgetList) return;
|
|
2205
2204
|
widgetList.forEach((widget) => {
|
|
2206
2205
|
let submitFlag = widget.options.submitFlag || false;
|
|
2207
|
-
if (widget.formItemFlag || widget.type
|
|
2206
|
+
if (widget.formItemFlag || widget.type === "data-table") {
|
|
2208
2207
|
if (widget.options.submitFlag === void 0) {
|
|
2209
2208
|
submitFlag = true;
|
|
2210
2209
|
}
|
|
@@ -2213,7 +2212,7 @@ modules = {
|
|
|
2213
2212
|
let uniqueName = widget.options.name;
|
|
2214
2213
|
let widgetName = this.getFieldKeyName(widget);
|
|
2215
2214
|
let entityTableCode = widget.options.entityTableCode;
|
|
2216
|
-
if (widget.type
|
|
2215
|
+
if (widget.type === "data-table" || widget.type === "list-h5") {
|
|
2217
2216
|
let isTreeTable = widget.options.isTreeTable || false;
|
|
2218
2217
|
if (submitFlag) {
|
|
2219
2218
|
let vailColumns = widget.options.tableColumns.filter(
|
|
@@ -2221,7 +2220,7 @@ modules = {
|
|
|
2221
2220
|
);
|
|
2222
2221
|
let itemFields = [];
|
|
2223
2222
|
vailColumns.forEach((item) => {
|
|
2224
|
-
if (item.formatS
|
|
2223
|
+
if (item.formatS === "editSearch") {
|
|
2225
2224
|
itemFields.push({
|
|
2226
2225
|
fieldDesc: item.label + "ID",
|
|
2227
2226
|
fieldName: item.prop,
|
|
@@ -2255,7 +2254,7 @@ modules = {
|
|
|
2255
2254
|
formTemplateTableDTOs.push(formTemplateTable);
|
|
2256
2255
|
}
|
|
2257
2256
|
}
|
|
2258
|
-
} else if (widget.type
|
|
2257
|
+
} else if (widget.type === "vabUpload") {
|
|
2259
2258
|
if (submitFlag) {
|
|
2260
2259
|
let formTemplateTable = {
|
|
2261
2260
|
tableAlias: widgetName,
|
|
@@ -2266,7 +2265,7 @@ modules = {
|
|
|
2266
2265
|
};
|
|
2267
2266
|
formTemplateTableDTOs.push(formTemplateTable);
|
|
2268
2267
|
}
|
|
2269
|
-
} else if (widget.type
|
|
2268
|
+
} else if (widget.type === "project-tag") {
|
|
2270
2269
|
if (submitFlag) {
|
|
2271
2270
|
let formTemplateTable = {
|
|
2272
2271
|
tableAlias: widgetName,
|
|
@@ -2277,7 +2276,7 @@ modules = {
|
|
|
2277
2276
|
};
|
|
2278
2277
|
formTemplateTableDTOs.push(formTemplateTable);
|
|
2279
2278
|
}
|
|
2280
|
-
} else if (widget.type
|
|
2279
|
+
} else if (widget.type === "table2") {
|
|
2281
2280
|
if (submitFlag) {
|
|
2282
2281
|
let formTemplateTable = {
|
|
2283
2282
|
tableAlias: widgetName,
|
|
@@ -2312,14 +2311,14 @@ modules = {
|
|
|
2312
2311
|
});
|
|
2313
2312
|
}
|
|
2314
2313
|
} else {
|
|
2315
|
-
if (widget.category
|
|
2314
|
+
if (widget.category === "container") {
|
|
2316
2315
|
let itemField = itemFieldMap[widget.type];
|
|
2317
2316
|
if (itemField) {
|
|
2318
|
-
if ("table"
|
|
2317
|
+
if ("table" === widget.type) {
|
|
2319
2318
|
widget[itemField].forEach((item) => {
|
|
2320
2319
|
loopDo(item.cols);
|
|
2321
2320
|
});
|
|
2322
|
-
} else if ("h5-table"
|
|
2321
|
+
} else if ("h5-table" === widget.type) {
|
|
2323
2322
|
widget[itemField].forEach((item) => {
|
|
2324
2323
|
loopDo(item.cols);
|
|
2325
2324
|
});
|
|
@@ -2364,10 +2363,10 @@ modules = {
|
|
|
2364
2363
|
let newFormData = {};
|
|
2365
2364
|
formTemplateTableDTOs.forEach((formTemplateTableDTO) => {
|
|
2366
2365
|
let tableAlias
|
|
2367
|
-
= formTemplateTableDTO.tableType
|
|
2366
|
+
= formTemplateTableDTO.tableType === 0
|
|
2368
2367
|
? formCode
|
|
2369
2368
|
: formTemplateTableDTO.tableAlias;
|
|
2370
|
-
if (formTemplateTableDTO.tableType
|
|
2369
|
+
if (formTemplateTableDTO.tableType === 0) {
|
|
2371
2370
|
let item = this.$baseLodash.cloneDeep(this.formData);
|
|
2372
2371
|
Object.keys(item).forEach((key) => {
|
|
2373
2372
|
if (Array.isArray(item[key])) {
|
|
@@ -2417,10 +2416,10 @@ modules = {
|
|
|
2417
2416
|
let newFormData = {};
|
|
2418
2417
|
formTemplateTableDTOs.forEach((formTemplateTableDTO) => {
|
|
2419
2418
|
let tableAlias
|
|
2420
|
-
= formTemplateTableDTO.tableType
|
|
2419
|
+
= formTemplateTableDTO.tableType === 0
|
|
2421
2420
|
? formCode
|
|
2422
2421
|
: formTemplateTableDTO.tableAlias;
|
|
2423
|
-
if (formTemplateTableDTO.tableType
|
|
2422
|
+
if (formTemplateTableDTO.tableType === 0) {
|
|
2424
2423
|
let item = this.$baseLodash.cloneDeep(this.currentFormData);
|
|
2425
2424
|
Object.keys(item).forEach((key) => {
|
|
2426
2425
|
if (Array.isArray(item[key])) {
|
|
@@ -2488,7 +2487,7 @@ modules = {
|
|
|
2488
2487
|
let formData = this.$baseLodash.cloneDeep(formData0[formCode]);
|
|
2489
2488
|
if (formData) {
|
|
2490
2489
|
Object.keys(formData0).forEach((key) => {
|
|
2491
|
-
if (key
|
|
2490
|
+
if (key !== formCode) {
|
|
2492
2491
|
formData[key] = formData0[key];
|
|
2493
2492
|
}
|
|
2494
2493
|
});
|
|
@@ -2539,6 +2538,26 @@ modules = {
|
|
|
2539
2538
|
target = this.getWidgetRef(this.formJsonObj.widgetList[0].options.name);
|
|
2540
2539
|
}
|
|
2541
2540
|
return target;
|
|
2541
|
+
|
|
2542
|
+
return this.getGridWidgetRef();
|
|
2543
|
+
|
|
2544
|
+
},
|
|
2545
|
+
getGridWidgetRef() {
|
|
2546
|
+
//获取表单的第一个data-table组件
|
|
2547
|
+
return this.getFirstWidgetRefByType("data-table");
|
|
2548
|
+
|
|
2549
|
+
},
|
|
2550
|
+
getFirstWidgetRefByType(type) {
|
|
2551
|
+
//获取表单的第一个组件
|
|
2552
|
+
let result = null;
|
|
2553
|
+
traverseAllWidgetsNew(this.formJsonObj.widgetList, (widget) => {
|
|
2554
|
+
if (!result && widget.type === type) {
|
|
2555
|
+
result = widget;
|
|
2556
|
+
}
|
|
2557
|
+
});
|
|
2558
|
+
let target = result? this.getWidgetRef(result.options.name):null;
|
|
2559
|
+
return target;
|
|
2560
|
+
|
|
2542
2561
|
},
|
|
2543
2562
|
switchToListTab(option) {
|
|
2544
2563
|
//切换到列表页的tab
|
|
@@ -2549,12 +2568,12 @@ modules = {
|
|
|
2549
2568
|
}
|
|
2550
2569
|
if (handleType) {
|
|
2551
2570
|
let listTabFormRef = this.getListTabFormRef();
|
|
2552
|
-
if (handleType
|
|
2571
|
+
if (handleType === "reload") {
|
|
2553
2572
|
listTabFormRef.reloadForm();
|
|
2554
|
-
} else if (handleType
|
|
2555
|
-
listTabFormRef.
|
|
2556
|
-
} else if (handleType
|
|
2557
|
-
listTabFormRef.
|
|
2573
|
+
} else if (handleType === "searchEvent") {
|
|
2574
|
+
listTabFormRef.getGridWidgetRef().searchEvent();
|
|
2575
|
+
} else if (handleType === "resethEvent") {
|
|
2576
|
+
listTabFormRef.getGridWidgetRef().resethEvent();
|
|
2558
2577
|
}
|
|
2559
2578
|
}
|
|
2560
2579
|
},
|
|
@@ -2745,42 +2764,42 @@ modules = {
|
|
|
2745
2764
|
columnSelectedWidget.options.required = row.required || false;
|
|
2746
2765
|
}
|
|
2747
2766
|
|
|
2748
|
-
if ("editDelete"
|
|
2767
|
+
if ("editDelete" === formatS) {
|
|
2749
2768
|
columnSelectedWidget.options.prefixIcon = "el-icon-delete";
|
|
2750
2769
|
columnSelectedWidget.options.label = "删除";
|
|
2751
2770
|
columnSelectedWidget.options.labelHidden = true;
|
|
2752
2771
|
columnSelectedWidget.options.hiddenByWf = true;
|
|
2753
2772
|
columnSelectedWidget.options.onClick
|
|
2754
2773
|
= "let tableParam = this.tableParam;\nlet tableRef = this.getWidgetRef(this.parentWidget.options.name);\ntableRef.deleteRow(tableParam.row,tableParam.rowIndex);";
|
|
2755
|
-
} else if ("editButton"
|
|
2774
|
+
} else if ("editButton" === formatS) {
|
|
2756
2775
|
columnSelectedWidget.options.prefixIcon = "el-icon-edit";
|
|
2757
2776
|
columnSelectedWidget.options.label = "查看";
|
|
2758
2777
|
columnSelectedWidget.options.labelHidden = true;
|
|
2759
2778
|
columnSelectedWidget.options.onClick
|
|
2760
2779
|
= "let tableParam = this.tableParam;\nlet tableRef = this.getWidgetRef(this.parentWidget.options.name);\ntableRef.openEditDialog(tableParam.row)";
|
|
2761
|
-
} else if ("addSiblingEditRow"
|
|
2780
|
+
} else if ("addSiblingEditRow" === formatS) {
|
|
2762
2781
|
columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
|
2763
2782
|
columnSelectedWidget.options.label = "新增兄弟节点";
|
|
2764
2783
|
columnSelectedWidget.options.labelHidden = false;
|
|
2765
2784
|
columnSelectedWidget.options.onClick
|
|
2766
2785
|
= "let tableParam = this.tableParam;\nthis.getParentTarget().addSiblingTreeRow(null,tableParam);";
|
|
2767
|
-
} else if ("addChildTreeRow"
|
|
2786
|
+
} else if ("addChildTreeRow" === formatS) {
|
|
2768
2787
|
columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
|
2769
2788
|
columnSelectedWidget.options.label = "新增子节点";
|
|
2770
2789
|
columnSelectedWidget.options.labelHidden = false;
|
|
2771
2790
|
columnSelectedWidget.options.onClick
|
|
2772
2791
|
= "let tableParam = this.tableParam;\nthis.getParentTarget().addChildTreeRow(null,tableParam);";
|
|
2773
|
-
} else if ("moveUpRow"
|
|
2792
|
+
} else if ("moveUpRow" === formatS) {
|
|
2774
2793
|
columnSelectedWidget.options.label = "↑上移";
|
|
2775
2794
|
columnSelectedWidget.options.labelHidden = false;
|
|
2776
2795
|
columnSelectedWidget.options.onClick
|
|
2777
2796
|
= "let tableParam = this.tableParam;\nthis.getParentTarget().moveUpRow(tableParam);";
|
|
2778
|
-
} else if ("moveDownRow"
|
|
2797
|
+
} else if ("moveDownRow" === formatS) {
|
|
2779
2798
|
columnSelectedWidget.options.label = "↓下移";
|
|
2780
2799
|
columnSelectedWidget.options.labelHidden = false;
|
|
2781
2800
|
columnSelectedWidget.options.onClick
|
|
2782
2801
|
= "let tableParam = this.tableParam;\nthis.getParentTarget().moveDownRow(tableParam);";
|
|
2783
|
-
} else if ("removeTreeRow"
|
|
2802
|
+
} else if ("removeTreeRow" === formatS) {
|
|
2784
2803
|
columnSelectedWidget.options.prefixIcon = "el-icon-delete";
|
|
2785
2804
|
columnSelectedWidget.options.label = "删除";
|
|
2786
2805
|
columnSelectedWidget.options.labelHidden = true;
|
|
@@ -2795,7 +2814,7 @@ modules = {
|
|
|
2795
2814
|
columnSelectedWidget.options.name = row.prop;
|
|
2796
2815
|
}
|
|
2797
2816
|
|
|
2798
|
-
if (type
|
|
2817
|
+
if (type !== "button" && type !== "a-link") {
|
|
2799
2818
|
columnSelectedWidget.options.label = row.label;
|
|
2800
2819
|
columnSelectedWidget.options.labelHidden = true;
|
|
2801
2820
|
}
|
|
@@ -2805,7 +2824,7 @@ modules = {
|
|
|
2805
2824
|
doScriptAccess(scriptUuid, callback) {
|
|
2806
2825
|
if (scriptUuid) {
|
|
2807
2826
|
let scripts = this.formJson.formConfig.scriptList || [];
|
|
2808
|
-
let item = scripts.find((item) => item.scriptUuid
|
|
2827
|
+
let item = scripts.find((item) => item.scriptUuid === scriptUuid);
|
|
2809
2828
|
if (item && item.enabled) {
|
|
2810
2829
|
let path = "";
|
|
2811
2830
|
let reportTemplate = this.getReportTemplate();
|
|
@@ -281,31 +281,31 @@ export function traverseAllWidgetsNew(widgetList, callback) {
|
|
|
281
281
|
if (!widgetList) {
|
|
282
282
|
return;
|
|
283
283
|
}
|
|
284
|
-
let columnLoopDo = (t,
|
|
284
|
+
let columnLoopDo = (t, parentWidget) => {
|
|
285
285
|
if (t.children && t.children.length) {
|
|
286
286
|
t.children.forEach((item) => {
|
|
287
|
-
columnLoopDo(item);
|
|
287
|
+
columnLoopDo(item, parentWidget);
|
|
288
288
|
});
|
|
289
289
|
} else {
|
|
290
290
|
if (t.widget) {
|
|
291
|
-
callback && callback(t.widget);
|
|
291
|
+
callback && callback(t.widget, parentWidget);
|
|
292
292
|
}
|
|
293
293
|
if (t.editWidget) {
|
|
294
|
-
callback && callback(t.editWidget);
|
|
294
|
+
callback && callback(t.editWidget, parentWidget);
|
|
295
295
|
}
|
|
296
296
|
if (t.widgetList && t.widgetList.length) {
|
|
297
297
|
loopHandleWidget(t.widgetList, (widget) => {
|
|
298
|
-
callback && callback(widget);
|
|
298
|
+
callback && callback(widget, parentWidget);
|
|
299
299
|
});
|
|
300
300
|
}
|
|
301
301
|
}
|
|
302
302
|
};
|
|
303
303
|
loopHandleWidget(widgetList, (widget, parentWidget) => {
|
|
304
304
|
if (callback) {
|
|
305
|
-
callback(widget);
|
|
305
|
+
callback(widget, parentWidget);
|
|
306
306
|
if (widget.type == "data-table") {
|
|
307
307
|
for (let item of widget.options.tableColumns) {
|
|
308
|
-
columnLoopDo(item);
|
|
308
|
+
columnLoopDo(item, parentWidget);
|
|
309
309
|
}
|
|
310
310
|
}
|
|
311
311
|
}
|
|
@@ -317,8 +317,8 @@ export function traverseAllWidgets(widgetList, handler) {
|
|
|
317
317
|
return;
|
|
318
318
|
}
|
|
319
319
|
|
|
320
|
-
loopHandleWidget(widgetList, (w,
|
|
321
|
-
handler(w);
|
|
320
|
+
loopHandleWidget(widgetList, (w, parentWidget) => {
|
|
321
|
+
handler(w, parentWidget);
|
|
322
322
|
});
|
|
323
323
|
|
|
324
324
|
/* widgetList.forEach((w) => {
|
|
@@ -1449,6 +1449,11 @@ function loopHandleWidgetItem(e, p, callback) {
|
|
|
1449
1449
|
}
|
|
1450
1450
|
} else {
|
|
1451
1451
|
callback && callback(e);
|
|
1452
|
+
if (e.widgetList) {
|
|
1453
|
+
e.widgetList.forEach(function (childItem) {
|
|
1454
|
+
loopHandleWidgetItem(childItem, e, callback);
|
|
1455
|
+
});
|
|
1456
|
+
}
|
|
1452
1457
|
}
|
|
1453
1458
|
}
|
|
1454
1459
|
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
<tableForm :formData.sync="formData" @searchEvent="searchEvent" @resetEvent="resetEvent">
|
|
33
33
|
<template #buttonLeft>
|
|
34
34
|
<vxe-button status="primary" class="button-sty" icon="el-icon-plus"
|
|
35
|
-
@click="openFieldTranslationEditDialog()" :disabled="!currentDataType.id"
|
|
35
|
+
@click="openFieldTranslationEditDialog()" :disabled="!currentDataType.id">
|
|
36
36
|
{{ $t1('新增') }}
|
|
37
37
|
</vxe-button>
|
|
38
38
|
<base-table-export :option="{ title: $t1('多语言'), targetRef: 'table-m1'}"
|