cloud-web-corejs 1.0.54-dev.745 → 1.0.54-dev.747
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 +194 -192
- package/src/App.vue +73 -71
- package/src/components/baseArea/index.vue +1628 -1628
- package/src/components/fileLibrary/categoryMoveDialog.vue +109 -109
- package/src/components/fileLibrary/fileObjAuthDialog.vue +297 -297
- package/src/components/fileLibrary/index.vue +1109 -1109
- package/src/components/fileLibrary/propertiesDialog.vue +190 -190
- package/src/components/fileLibrary/recycleBinDialog.vue +237 -237
- package/src/components/wf/mixins/setCandidateDialog.js +217 -217
- package/src/components/wf/mixins/setCandidateDialog2.js +252 -252
- package/src/components/xform/docs//345/257/271/346/257/224/345/212/237/350/203/275/350/220/275/345/234/260/346/226/271/346/241/210.md +986 -986
- package/src/components/xform/form-designer/form-widget/field-widget/area-select-widget.vue +272 -272
- package/src/components/xform/form-designer/form-widget/field-widget/baseAttachment-widget.vue +216 -216
- package/src/components/xform/form-designer/form-widget/field-widget/form-item-wrapper.vue +928 -928
- package/src/components/xform/form-designer/index.vue +195 -195
- package/src/components/xform/form-designer/indexMixin.js +848 -848
- package/src/components/xform/form-designer/setting-panel/index.vue +313 -313
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/columnRenderDialog.vue +124 -124
- package/src/components/xform/form-designer/setting-panel/propertyRegister.js +369 -369
- package/src/components/xform/form-designer/widget-panel/index.vue +389 -389
- package/src/components/xform/form-designer/widget-panel/indexMixin.js +343 -343
- package/src/components/xform/form-designer/widget-panel/widgetsConfig.js +4531 -4531
- package/src/components/xform/form-render/container-item/data-table-mixin.js +4748 -4576
- package/src/components/xform/form-render/container-item/tab-item.vue +125 -125
- package/src/components/xform/form-render/indexMixin.js +5061 -5078
- package/src/components/xform/lang/en-US.js +457 -457
- package/src/components/xform/lang/zh-CN.js +628 -628
- package/src/components/xform/utils/util.js +1585 -1554
- package/src/index.js +347 -230
- package/src/layout/components/AppMain.vue +122 -125
- package/src/layout/components/extractedCode/viewDialog.vue +207 -207
- package/src/layout/components/langTool.vue +128 -123
- package/src/layout/defaultLayout.vue +164 -158
- package/src/microRouter/index.js +389 -0
- package/src/permission.js +185 -135
- package/src/public-path.js +8 -0
- package/src/store/config/index.js +667 -669
- package/src/store/modules/micro.js +46 -0
- package/src/store/modules/permission.js +468 -373
- package/src/store/modules/user.js +419 -415
- package/src/utils/auth.js +27 -1
- package/src/utils/index.js +579 -6
- package/src/utils/keepAlive.js +4 -0
- package/src/utils/menuAdapter.js +183 -0
- package/src/utils/request.js +417 -28
- package/src/views/bd/setting/formVersion/ftHistoryDialog.vue +483 -483
- package/src/views/bd/setting/form_script/form_list.vue +174 -174
- package/src/views/bd/setting/form_script/mixins/form_list.js +330 -330
- package/src/views/bd/setting/form_template/formDesignerDialog.vue +171 -171
- package/src/views/bd/setting/form_template/wfObjConfigDialog.vue +253 -253
- package/src/views/user/menuFallback/index.vue +123 -0
- package/src/views/user/wf/wfReport/index.vue +625 -625
|
@@ -1,253 +1,253 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<el-dialog
|
|
3
|
-
:title="'设置组织流程单据类型('+formTemplate.formName+')'"
|
|
4
|
-
:append-to-body="true"
|
|
5
|
-
:modal-append-to-body="true"
|
|
6
|
-
:close-on-click-modal="false"
|
|
7
|
-
:visible.sync="dialogVisible"
|
|
8
|
-
:modal="false"
|
|
9
|
-
custom-class="dialog-style list-dialog dialog-checkbox pd_0"
|
|
10
|
-
width="1200px"
|
|
11
|
-
@close="closeDialog"
|
|
12
|
-
v-el-drag-dialog
|
|
13
|
-
v-el-dialog-center
|
|
14
|
-
>
|
|
15
|
-
<div id="containt">
|
|
16
|
-
<el-form ref="editForm" :model="formData">
|
|
17
|
-
<div class="grid-height" style="height: 500px">
|
|
18
|
-
<vxe-grid
|
|
19
|
-
class="is-pointer"
|
|
20
|
-
ref="table-m1"
|
|
21
|
-
:data="formData.wfObjConfigDTOs"
|
|
22
|
-
v-bind="vxeOption"
|
|
23
|
-
@resizable-change="$vxeTableUtil.onColumnWitchChange"
|
|
24
|
-
@custom="$vxeTableUtil.customHandle"
|
|
25
|
-
>
|
|
26
|
-
<template #form>
|
|
27
|
-
<div class="clearfix screen-btns">
|
|
28
|
-
<div class="fl">
|
|
29
|
-
<vxe-button status="primary" class="button-sty" icon="el-icon-plus"
|
|
30
|
-
@click="openCompanyDialog">
|
|
31
|
-
新增
|
|
32
|
-
</vxe-button>
|
|
33
|
-
<span class="button-sty tips">{{ $t1('选择表单所在的组织,填写组织对应的流程单据类型数据。') }}</span>
|
|
34
|
-
</div>
|
|
35
|
-
</div>
|
|
36
|
-
</template>
|
|
37
|
-
<template #objTypeName="{row,rowIndex}">
|
|
38
|
-
<el-form-item :prop="'wfObjConfigDTOs.'+rowIndex+'.objTypeName'"
|
|
39
|
-
:rules="[{ required: true, trigger: 'blur' }]">
|
|
40
|
-
<el-input v-model="row.objTypeName" clearable></el-input>
|
|
41
|
-
</el-form-item>
|
|
42
|
-
</template>
|
|
43
|
-
<template #operate="{row}">
|
|
44
|
-
<a
|
|
45
|
-
href="javascript:void(0);"
|
|
46
|
-
class="a-link"
|
|
47
|
-
@click="openEditDialog(row.id)"
|
|
48
|
-
>
|
|
49
|
-
<el-tooltip :enterable="false" effect="dark" :content="$t2('查看','common.view')" placement="top"
|
|
50
|
-
popper-class="tooltip-skin">
|
|
51
|
-
<i class="el-icon-edit"/>
|
|
52
|
-
</el-tooltip>
|
|
53
|
-
</a>
|
|
54
|
-
</template>
|
|
55
|
-
</vxe-grid>
|
|
56
|
-
</div>
|
|
57
|
-
</el-form>
|
|
58
|
-
</div>
|
|
59
|
-
|
|
60
|
-
<span slot="footer" class="dialog-footer">
|
|
61
|
-
<el-button type="primary" plain class="button-sty" @click="closeDialog">
|
|
62
|
-
<i class="el-icon-close el-icon"></i>
|
|
63
|
-
取 消
|
|
64
|
-
</el-button>
|
|
65
|
-
<el-button type="primary" @click="saveData" class="button-sty">
|
|
66
|
-
<i class="el-icon-check el-icon"></i>
|
|
67
|
-
确 定
|
|
68
|
-
</el-button>
|
|
69
|
-
</span>
|
|
70
|
-
<companyInfoDialog v-if="showCompanyInfoDialog" :visiable.sync="showCompanyInfoDialog"
|
|
71
|
-
@confirm="confirmCompanyDialog" :multi="true" :allCompany="true"/>
|
|
72
|
-
</el-dialog>
|
|
73
|
-
</template>
|
|
74
|
-
<script>
|
|
75
|
-
import companyInfoDialog from "@base/views/user/company_info/dialog.vue";
|
|
76
|
-
import fileObjNotifyEdit from "@base/components/fileLibrary/fileObjNotifyEdit.vue";
|
|
77
|
-
|
|
78
|
-
export default {
|
|
79
|
-
components: {fileObjNotifyEdit, companyInfoDialog},
|
|
80
|
-
props: ['formTemplate'],
|
|
81
|
-
data() {
|
|
82
|
-
return {
|
|
83
|
-
dialogVisible: true,
|
|
84
|
-
formData: {
|
|
85
|
-
objTypeCode: null,
|
|
86
|
-
wfObjConfigDTOs: []
|
|
87
|
-
},
|
|
88
|
-
operateIndex: 0,
|
|
89
|
-
showCompanyInfoDialog: false,
|
|
90
|
-
vxeOption: {}
|
|
91
|
-
}
|
|
92
|
-
},
|
|
93
|
-
created() {
|
|
94
|
-
|
|
95
|
-
},
|
|
96
|
-
mounted() {
|
|
97
|
-
this.formData.objTypeCode = this.formTemplate.objTypeCode;
|
|
98
|
-
this.getListByObjTypeCode();
|
|
99
|
-
this.initTableList()
|
|
100
|
-
},
|
|
101
|
-
methods: {
|
|
102
|
-
getListByObjTypeCode(callback) {
|
|
103
|
-
let formTemplate = this.formTemplate
|
|
104
|
-
this.$http({
|
|
105
|
-
url: `/${formTemplate.serviceName}/wf_obj_config/listByObjTypeCode`,
|
|
106
|
-
method: `post`,
|
|
107
|
-
data: {
|
|
108
|
-
stringOne: formTemplate.objTypeCode
|
|
109
|
-
},
|
|
110
|
-
isLoading: true,
|
|
111
|
-
success: res => {
|
|
112
|
-
let rows = res.objx || [];
|
|
113
|
-
this.formData.wfObjConfigDTOs = rows;
|
|
114
|
-
callback && callback(rows)
|
|
115
|
-
}
|
|
116
|
-
});
|
|
117
|
-
},
|
|
118
|
-
saveData() {
|
|
119
|
-
this.$refs.editForm.$baseValidate(valid => {
|
|
120
|
-
if (valid) {
|
|
121
|
-
this.$baseConfirm(this.$t1('您确定要保存吗?')).then(() => {
|
|
122
|
-
var url = `/${this.formTemplate.serviceName}/wf_obj_config/saveUpdates`;
|
|
123
|
-
this.$http({
|
|
124
|
-
url: url,
|
|
125
|
-
method: `post`,
|
|
126
|
-
data: this.formData,
|
|
127
|
-
isLoading: true,
|
|
128
|
-
success: res => {
|
|
129
|
-
this.$message({
|
|
130
|
-
message: res.content,
|
|
131
|
-
type: 'success',
|
|
132
|
-
duration: 1000
|
|
133
|
-
});
|
|
134
|
-
this.getListByObjTypeCode(rows => {
|
|
135
|
-
this.$emit('confirm', rows)
|
|
136
|
-
this.closeDialog();
|
|
137
|
-
})
|
|
138
|
-
}
|
|
139
|
-
});
|
|
140
|
-
});
|
|
141
|
-
}
|
|
142
|
-
});
|
|
143
|
-
},
|
|
144
|
-
addItem() {
|
|
145
|
-
let formTemplate = this.formTemplate;
|
|
146
|
-
let row = {
|
|
147
|
-
objTypeCode: formTemplate.objTypeCode,
|
|
148
|
-
objTypeName: formTemplate.objTypeName,
|
|
149
|
-
serviceId: formTemplate.serviceName,
|
|
150
|
-
url: "form",
|
|
151
|
-
companyCode: null,
|
|
152
|
-
companyName: null
|
|
153
|
-
}
|
|
154
|
-
this.formData.wfObjConfigDTOs.push(row);
|
|
155
|
-
},
|
|
156
|
-
closeDialog() {
|
|
157
|
-
this.dialogVisible = false;
|
|
158
|
-
this.$emit("update:visiable", false);
|
|
159
|
-
},
|
|
160
|
-
openCompanyDialog() {
|
|
161
|
-
this.showCompanyInfoDialog = true;
|
|
162
|
-
},
|
|
163
|
-
confirmCompanyDialog(rows) {
|
|
164
|
-
if (rows.length) {
|
|
165
|
-
let row = rows[0];
|
|
166
|
-
let formTemplate = this.formTemplate;
|
|
167
|
-
let companyCodes = this.formData.wfObjConfigDTOs.map(item => item.companyCode)
|
|
168
|
-
let items = rows.filter(item => !companyCodes.includes(item.companyCode)).map(item => {
|
|
169
|
-
return {
|
|
170
|
-
objTypeCode: formTemplate.objTypeCode,
|
|
171
|
-
objTypeName: formTemplate.objTypeName,
|
|
172
|
-
serviceId: formTemplate.serviceName,
|
|
173
|
-
url: "form",
|
|
174
|
-
companyCode: row.companyCode,
|
|
175
|
-
companyName: row.companyName
|
|
176
|
-
}
|
|
177
|
-
})
|
|
178
|
-
this.formData.wfObjConfigDTOs.push(...items);
|
|
179
|
-
}
|
|
180
|
-
},
|
|
181
|
-
initTableList() {
|
|
182
|
-
let that = this;
|
|
183
|
-
let tableOption = {
|
|
184
|
-
vue: this,
|
|
185
|
-
tableRef: 'table-m1',
|
|
186
|
-
tableName: 'user_form_template-wfObj-list-m1',
|
|
187
|
-
config: {
|
|
188
|
-
height: "auto"
|
|
189
|
-
},
|
|
190
|
-
columns: [
|
|
191
|
-
{type: 'checkbox', width: 48, resizable: false, fixed: 'left'},
|
|
192
|
-
{
|
|
193
|
-
title: this.$t1('单据类型名称'),
|
|
194
|
-
field: 'objTypeName',
|
|
195
|
-
width: 250,
|
|
196
|
-
slots: {
|
|
197
|
-
default: "objTypeName"
|
|
198
|
-
}
|
|
199
|
-
},
|
|
200
|
-
{
|
|
201
|
-
title: this.$t1('组织名称'),
|
|
202
|
-
field: 'companyName',
|
|
203
|
-
width: 200,
|
|
204
|
-
},
|
|
205
|
-
{
|
|
206
|
-
title: this.$t1('单据类型编码'),
|
|
207
|
-
field: 'objTypeCode',
|
|
208
|
-
width: 200
|
|
209
|
-
},
|
|
210
|
-
{
|
|
211
|
-
title: this.$t1('服务名'),
|
|
212
|
-
field: 'serviceId',
|
|
213
|
-
width: 150
|
|
214
|
-
},
|
|
215
|
-
{
|
|
216
|
-
width: 100,
|
|
217
|
-
fixed: 'right',
|
|
218
|
-
title: '',
|
|
219
|
-
sortable: false,
|
|
220
|
-
slots: {
|
|
221
|
-
default: ({row, rowIndex, $table}) => {
|
|
222
|
-
return [
|
|
223
|
-
<a
|
|
224
|
-
href="javascript:void(0);"
|
|
225
|
-
class="a-link"
|
|
226
|
-
onClick={() => {
|
|
227
|
-
this.formData.wfObjConfigDTOs.splice(rowIndex, 1)
|
|
228
|
-
}}
|
|
229
|
-
>
|
|
230
|
-
<el-tooltip enterable={false} effect="dark" content="删除" placement="top"
|
|
231
|
-
popper-class="tooltip-skin">
|
|
232
|
-
<i class="el-icon-delete"/>
|
|
233
|
-
</el-tooltip>
|
|
234
|
-
</a>
|
|
235
|
-
];
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
]
|
|
240
|
-
};
|
|
241
|
-
this.$vxeTableUtil.initVxeTable(tableOption).then(opts => {
|
|
242
|
-
this.vxeOption = opts;
|
|
243
|
-
});
|
|
244
|
-
// this.initData();
|
|
245
|
-
},
|
|
246
|
-
}
|
|
247
|
-
}
|
|
248
|
-
</script>
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
<style scoped>
|
|
252
|
-
|
|
253
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<el-dialog
|
|
3
|
+
:title="'设置组织流程单据类型('+formTemplate.formName+')'"
|
|
4
|
+
:append-to-body="true"
|
|
5
|
+
:modal-append-to-body="true"
|
|
6
|
+
:close-on-click-modal="false"
|
|
7
|
+
:visible.sync="dialogVisible"
|
|
8
|
+
:modal="false"
|
|
9
|
+
custom-class="dialog-style list-dialog dialog-checkbox pd_0"
|
|
10
|
+
width="1200px"
|
|
11
|
+
@close="closeDialog"
|
|
12
|
+
v-el-drag-dialog
|
|
13
|
+
v-el-dialog-center
|
|
14
|
+
>
|
|
15
|
+
<div id="containt">
|
|
16
|
+
<el-form ref="editForm" :model="formData">
|
|
17
|
+
<div class="grid-height" style="height: 500px">
|
|
18
|
+
<vxe-grid
|
|
19
|
+
class="is-pointer"
|
|
20
|
+
ref="table-m1"
|
|
21
|
+
:data="formData.wfObjConfigDTOs"
|
|
22
|
+
v-bind="vxeOption"
|
|
23
|
+
@resizable-change="$vxeTableUtil.onColumnWitchChange"
|
|
24
|
+
@custom="$vxeTableUtil.customHandle"
|
|
25
|
+
>
|
|
26
|
+
<template #form>
|
|
27
|
+
<div class="clearfix screen-btns">
|
|
28
|
+
<div class="fl">
|
|
29
|
+
<vxe-button status="primary" class="button-sty" icon="el-icon-plus"
|
|
30
|
+
@click="openCompanyDialog">
|
|
31
|
+
新增
|
|
32
|
+
</vxe-button>
|
|
33
|
+
<span class="button-sty tips">{{ $t1('选择表单所在的组织,填写组织对应的流程单据类型数据。') }}</span>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</template>
|
|
37
|
+
<template #objTypeName="{row,rowIndex}">
|
|
38
|
+
<el-form-item :prop="'wfObjConfigDTOs.'+rowIndex+'.objTypeName'"
|
|
39
|
+
:rules="[{ required: true, trigger: 'blur' }]">
|
|
40
|
+
<el-input v-model="row.objTypeName" clearable></el-input>
|
|
41
|
+
</el-form-item>
|
|
42
|
+
</template>
|
|
43
|
+
<template #operate="{row}">
|
|
44
|
+
<a
|
|
45
|
+
href="javascript:void(0);"
|
|
46
|
+
class="a-link"
|
|
47
|
+
@click="openEditDialog(row.id)"
|
|
48
|
+
>
|
|
49
|
+
<el-tooltip :enterable="false" effect="dark" :content="$t2('查看','common.view')" placement="top"
|
|
50
|
+
popper-class="tooltip-skin">
|
|
51
|
+
<i class="el-icon-edit"/>
|
|
52
|
+
</el-tooltip>
|
|
53
|
+
</a>
|
|
54
|
+
</template>
|
|
55
|
+
</vxe-grid>
|
|
56
|
+
</div>
|
|
57
|
+
</el-form>
|
|
58
|
+
</div>
|
|
59
|
+
|
|
60
|
+
<span slot="footer" class="dialog-footer">
|
|
61
|
+
<el-button type="primary" plain class="button-sty" @click="closeDialog">
|
|
62
|
+
<i class="el-icon-close el-icon"></i>
|
|
63
|
+
取 消
|
|
64
|
+
</el-button>
|
|
65
|
+
<el-button type="primary" @click="saveData" class="button-sty">
|
|
66
|
+
<i class="el-icon-check el-icon"></i>
|
|
67
|
+
确 定
|
|
68
|
+
</el-button>
|
|
69
|
+
</span>
|
|
70
|
+
<companyInfoDialog v-if="showCompanyInfoDialog" :visiable.sync="showCompanyInfoDialog"
|
|
71
|
+
@confirm="confirmCompanyDialog" :multi="true" :allCompany="true"/>
|
|
72
|
+
</el-dialog>
|
|
73
|
+
</template>
|
|
74
|
+
<script>
|
|
75
|
+
import companyInfoDialog from "@base/views/user/company_info/dialog.vue";
|
|
76
|
+
import fileObjNotifyEdit from "@base/components/fileLibrary/fileObjNotifyEdit.vue";
|
|
77
|
+
|
|
78
|
+
export default {
|
|
79
|
+
components: {fileObjNotifyEdit, companyInfoDialog},
|
|
80
|
+
props: ['formTemplate'],
|
|
81
|
+
data() {
|
|
82
|
+
return {
|
|
83
|
+
dialogVisible: true,
|
|
84
|
+
formData: {
|
|
85
|
+
objTypeCode: null,
|
|
86
|
+
wfObjConfigDTOs: []
|
|
87
|
+
},
|
|
88
|
+
operateIndex: 0,
|
|
89
|
+
showCompanyInfoDialog: false,
|
|
90
|
+
vxeOption: {}
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
created() {
|
|
94
|
+
|
|
95
|
+
},
|
|
96
|
+
mounted() {
|
|
97
|
+
this.formData.objTypeCode = this.formTemplate.objTypeCode;
|
|
98
|
+
this.getListByObjTypeCode();
|
|
99
|
+
this.initTableList()
|
|
100
|
+
},
|
|
101
|
+
methods: {
|
|
102
|
+
getListByObjTypeCode(callback) {
|
|
103
|
+
let formTemplate = this.formTemplate
|
|
104
|
+
this.$http({
|
|
105
|
+
url: `/${formTemplate.serviceName}/wf_obj_config/listByObjTypeCode`,
|
|
106
|
+
method: `post`,
|
|
107
|
+
data: {
|
|
108
|
+
stringOne: formTemplate.objTypeCode
|
|
109
|
+
},
|
|
110
|
+
isLoading: true,
|
|
111
|
+
success: res => {
|
|
112
|
+
let rows = res.objx || [];
|
|
113
|
+
this.formData.wfObjConfigDTOs = rows;
|
|
114
|
+
callback && callback(rows)
|
|
115
|
+
}
|
|
116
|
+
});
|
|
117
|
+
},
|
|
118
|
+
saveData() {
|
|
119
|
+
this.$refs.editForm.$baseValidate(valid => {
|
|
120
|
+
if (valid) {
|
|
121
|
+
this.$baseConfirm(this.$t1('您确定要保存吗?')).then(() => {
|
|
122
|
+
var url = `/${this.formTemplate.serviceName}/wf_obj_config/saveUpdates`;
|
|
123
|
+
this.$http({
|
|
124
|
+
url: url,
|
|
125
|
+
method: `post`,
|
|
126
|
+
data: this.formData,
|
|
127
|
+
isLoading: true,
|
|
128
|
+
success: res => {
|
|
129
|
+
this.$message({
|
|
130
|
+
message: res.content,
|
|
131
|
+
type: 'success',
|
|
132
|
+
duration: 1000
|
|
133
|
+
});
|
|
134
|
+
this.getListByObjTypeCode(rows => {
|
|
135
|
+
this.$emit('confirm', rows)
|
|
136
|
+
this.closeDialog();
|
|
137
|
+
})
|
|
138
|
+
}
|
|
139
|
+
});
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
});
|
|
143
|
+
},
|
|
144
|
+
addItem() {
|
|
145
|
+
let formTemplate = this.formTemplate;
|
|
146
|
+
let row = {
|
|
147
|
+
objTypeCode: formTemplate.objTypeCode,
|
|
148
|
+
objTypeName: formTemplate.objTypeName,
|
|
149
|
+
serviceId: formTemplate.serviceName,
|
|
150
|
+
url: "form",
|
|
151
|
+
companyCode: null,
|
|
152
|
+
companyName: null
|
|
153
|
+
}
|
|
154
|
+
this.formData.wfObjConfigDTOs.push(row);
|
|
155
|
+
},
|
|
156
|
+
closeDialog() {
|
|
157
|
+
this.dialogVisible = false;
|
|
158
|
+
this.$emit("update:visiable", false);
|
|
159
|
+
},
|
|
160
|
+
openCompanyDialog() {
|
|
161
|
+
this.showCompanyInfoDialog = true;
|
|
162
|
+
},
|
|
163
|
+
confirmCompanyDialog(rows) {
|
|
164
|
+
if (rows.length) {
|
|
165
|
+
let row = rows[0];
|
|
166
|
+
let formTemplate = this.formTemplate;
|
|
167
|
+
let companyCodes = this.formData.wfObjConfigDTOs.map(item => item.companyCode)
|
|
168
|
+
let items = rows.filter(item => !companyCodes.includes(item.companyCode)).map(item => {
|
|
169
|
+
return {
|
|
170
|
+
objTypeCode: formTemplate.objTypeCode,
|
|
171
|
+
objTypeName: formTemplate.objTypeName,
|
|
172
|
+
serviceId: formTemplate.serviceName,
|
|
173
|
+
url: "form",
|
|
174
|
+
companyCode: row.companyCode,
|
|
175
|
+
companyName: row.companyName
|
|
176
|
+
}
|
|
177
|
+
})
|
|
178
|
+
this.formData.wfObjConfigDTOs.push(...items);
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
initTableList() {
|
|
182
|
+
let that = this;
|
|
183
|
+
let tableOption = {
|
|
184
|
+
vue: this,
|
|
185
|
+
tableRef: 'table-m1',
|
|
186
|
+
tableName: 'user_form_template-wfObj-list-m1',
|
|
187
|
+
config: {
|
|
188
|
+
height: "auto"
|
|
189
|
+
},
|
|
190
|
+
columns: [
|
|
191
|
+
{type: 'checkbox', width: 48, resizable: false, fixed: 'left'},
|
|
192
|
+
{
|
|
193
|
+
title: this.$t1('单据类型名称'),
|
|
194
|
+
field: 'objTypeName',
|
|
195
|
+
width: 250,
|
|
196
|
+
slots: {
|
|
197
|
+
default: "objTypeName"
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
{
|
|
201
|
+
title: this.$t1('组织名称'),
|
|
202
|
+
field: 'companyName',
|
|
203
|
+
width: 200,
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
title: this.$t1('单据类型编码'),
|
|
207
|
+
field: 'objTypeCode',
|
|
208
|
+
width: 200
|
|
209
|
+
},
|
|
210
|
+
{
|
|
211
|
+
title: this.$t1('服务名'),
|
|
212
|
+
field: 'serviceId',
|
|
213
|
+
width: 150
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
width: 100,
|
|
217
|
+
fixed: 'right',
|
|
218
|
+
title: '',
|
|
219
|
+
sortable: false,
|
|
220
|
+
slots: {
|
|
221
|
+
default: ({row, rowIndex, $table}) => {
|
|
222
|
+
return [
|
|
223
|
+
<a
|
|
224
|
+
href="javascript:void(0);"
|
|
225
|
+
class="a-link"
|
|
226
|
+
onClick={() => {
|
|
227
|
+
this.formData.wfObjConfigDTOs.splice(rowIndex, 1)
|
|
228
|
+
}}
|
|
229
|
+
>
|
|
230
|
+
<el-tooltip enterable={false} effect="dark" content="删除" placement="top"
|
|
231
|
+
popper-class="tooltip-skin">
|
|
232
|
+
<i class="el-icon-delete"/>
|
|
233
|
+
</el-tooltip>
|
|
234
|
+
</a>
|
|
235
|
+
];
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
]
|
|
240
|
+
};
|
|
241
|
+
this.$vxeTableUtil.initVxeTable(tableOption).then(opts => {
|
|
242
|
+
this.vxeOption = opts;
|
|
243
|
+
});
|
|
244
|
+
// this.initData();
|
|
245
|
+
},
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
</script>
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
<style scoped>
|
|
252
|
+
|
|
253
|
+
</style>
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="menu-fallback">
|
|
3
|
+
<div class="menu-fallback-box">
|
|
4
|
+
<i
|
|
5
|
+
class="menu-fallback-icon"
|
|
6
|
+
:class="foreignApp ? 'el-icon-position' : 'el-icon-warning-outline'"
|
|
7
|
+
></i>
|
|
8
|
+
<div class="menu-fallback-title">{{ menuTitle }}</div>
|
|
9
|
+
<div class="menu-fallback-msg">{{ message }}</div>
|
|
10
|
+
<div v-if="detail" class="menu-fallback-detail">{{ detail }}</div>
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
</template>
|
|
14
|
+
|
|
15
|
+
<script>
|
|
16
|
+
import settings from "@/settings";
|
|
17
|
+
import { getFirstSegment, BASE_SEGMENT } from "@base/utils/menuAdapter";
|
|
18
|
+
|
|
19
|
+
export default {
|
|
20
|
+
name: "menuFallback",
|
|
21
|
+
props: {
|
|
22
|
+
componentPath: String,
|
|
23
|
+
loadError: String,
|
|
24
|
+
},
|
|
25
|
+
computed: {
|
|
26
|
+
menuTitle() {
|
|
27
|
+
let meta = (this.$route && this.$route.meta) || {};
|
|
28
|
+
return meta.title || (this.$route && this.$route.path) || "";
|
|
29
|
+
},
|
|
30
|
+
ownerSegment() {
|
|
31
|
+
return getFirstSegment((this.$route && this.$route.path) || "");
|
|
32
|
+
},
|
|
33
|
+
registryAppCodes() {
|
|
34
|
+
let permission = (this.$store && this.$store.state.permission) || {};
|
|
35
|
+
return permission.registryAppCodes || [];
|
|
36
|
+
},
|
|
37
|
+
foreignApp() {
|
|
38
|
+
// 只有首段命中注册表里的别家 appCode 才算"归属别家应用";
|
|
39
|
+
// 未命中(含注册表未配置)一律按组件加载失败处理,不误导去主平台
|
|
40
|
+
let seg = this.ownerSegment;
|
|
41
|
+
let own = settings.appCode || "";
|
|
42
|
+
return (
|
|
43
|
+
!!seg &&
|
|
44
|
+
seg !== BASE_SEGMENT &&
|
|
45
|
+
seg !== own &&
|
|
46
|
+
this.registryAppCodes.indexOf(seg) !== -1
|
|
47
|
+
);
|
|
48
|
+
},
|
|
49
|
+
message() {
|
|
50
|
+
if (this.foreignApp) {
|
|
51
|
+
if (!(settings.appCode || "")) {
|
|
52
|
+
// 主站视角:归属子应用的菜单本应委派 qiankun 渲染,走到本地加载即为注册/部署异常
|
|
53
|
+
return (
|
|
54
|
+
this.$t1("该菜单归属子应用") +
|
|
55
|
+
"「" +
|
|
56
|
+
this.ownerSegment +
|
|
57
|
+
"」" +
|
|
58
|
+
this.$t1(",加载失败,请检查应用注册表与子应用部署")
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
return (
|
|
62
|
+
this.$t1("该菜单归属应用") +
|
|
63
|
+
"「" +
|
|
64
|
+
this.ownerSegment +
|
|
65
|
+
"」" +
|
|
66
|
+
this.$t1(",当前应用未部署对应页面,请在主平台中访问")
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
return this.$t1("页面组件加载失败,请检查菜单配置或应用注册表");
|
|
70
|
+
},
|
|
71
|
+
detail() {
|
|
72
|
+
let parts = [];
|
|
73
|
+
if (this.componentPath) {
|
|
74
|
+
parts.push(this.componentPath);
|
|
75
|
+
}
|
|
76
|
+
if (this.loadError && !this.foreignApp) {
|
|
77
|
+
parts.push(this.loadError);
|
|
78
|
+
}
|
|
79
|
+
return parts.join(" | ");
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
};
|
|
83
|
+
</script>
|
|
84
|
+
|
|
85
|
+
<style lang="scss" scoped>
|
|
86
|
+
.menu-fallback {
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
89
|
+
justify-content: center;
|
|
90
|
+
min-height: 320px;
|
|
91
|
+
height: 100%;
|
|
92
|
+
|
|
93
|
+
.menu-fallback-box {
|
|
94
|
+
text-align: center;
|
|
95
|
+
padding: 32px;
|
|
96
|
+
color: #606266;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.menu-fallback-icon {
|
|
100
|
+
font-size: 48px;
|
|
101
|
+
color: #c0c4cc;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.menu-fallback-title {
|
|
105
|
+
margin-top: 16px;
|
|
106
|
+
font-size: 16px;
|
|
107
|
+
font-weight: 600;
|
|
108
|
+
color: #303133;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.menu-fallback-msg {
|
|
112
|
+
margin-top: 8px;
|
|
113
|
+
font-size: 14px;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.menu-fallback-detail {
|
|
117
|
+
margin-top: 12px;
|
|
118
|
+
font-size: 12px;
|
|
119
|
+
color: #909399;
|
|
120
|
+
word-break: break-all;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
</style>
|