cloud-web-corejs 1.0.54-dev.344 → 1.0.54-dev.345
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/VabUpload/view.vue +138 -55
- package/src/components/wf/content.vue +772 -411
- package/src/components/wf/mixins/wfFlowEleScriptDialog.js +131 -0
- package/src/components/wf/wf.js +2117 -1
- package/src/components/wf/wfFlowEleScriptDialog.vue +92 -0
- package/src/components/xform/form-designer/widget-panel/indexMixin.js +19 -19
- package/src/views/bd/setting/logic_param/edit.vue +31 -150
- package/src/views/bd/setting/logic_param/edit1.vue +106 -0
- package/src/views/bd/setting/logic_param/edit2.vue +122 -0
- package/src/views/bd/setting/logic_param/list.vue +5 -188
- package/src/views/bd/setting/logic_param/mixins/edit.js +93 -0
- package/src/views/bd/setting/logic_param/mixins/list.js +358 -0
@@ -0,0 +1,93 @@
|
|
1
|
+
let modules = {}
|
2
|
+
modules = {
|
3
|
+
name: "logic_paramEdit",
|
4
|
+
props: {
|
5
|
+
_dataId: [String, Number],
|
6
|
+
paramType: {
|
7
|
+
type: Number,
|
8
|
+
default: 0,
|
9
|
+
},
|
10
|
+
},
|
11
|
+
components: {},
|
12
|
+
data() {
|
13
|
+
return {
|
14
|
+
isEdit: false,
|
15
|
+
tabIndex: "first",
|
16
|
+
dataId: "",
|
17
|
+
logicParam: {
|
18
|
+
enabled: true,
|
19
|
+
paramValue: null,
|
20
|
+
paramType: this.paramType,
|
21
|
+
},
|
22
|
+
showCodeEditor: false,
|
23
|
+
paramTypeMap: {
|
24
|
+
0: "逻辑参数",
|
25
|
+
1: "操作日志编码",
|
26
|
+
2: "上传文件服务",
|
27
|
+
},
|
28
|
+
};
|
29
|
+
},
|
30
|
+
created() {
|
31
|
+
if (this._dataId && !isNaN(this._dataId)) this.dataId = this._dataId;
|
32
|
+
},
|
33
|
+
mounted() {
|
34
|
+
this.getData();
|
35
|
+
},
|
36
|
+
methods: {
|
37
|
+
getData() {
|
38
|
+
if (this.dataId && !isNaN(this.dataId)) {
|
39
|
+
this.isEdit = true;
|
40
|
+
this.$commonHttp({
|
41
|
+
url: USER_PREFIX + `/logic_param/get`,
|
42
|
+
method: `post`,
|
43
|
+
data: {
|
44
|
+
id: this.dataId,
|
45
|
+
},
|
46
|
+
isLoading: true,
|
47
|
+
modalStrictly: true,
|
48
|
+
success: (res) => {
|
49
|
+
this.logicParam = res.objx || {};
|
50
|
+
this.showCodeEditor = true;
|
51
|
+
},
|
52
|
+
});
|
53
|
+
} else {
|
54
|
+
this.showCodeEditor = true;
|
55
|
+
}
|
56
|
+
},
|
57
|
+
saveData() {
|
58
|
+
this.$refs.editForm.$baseValidate((valid) => {
|
59
|
+
if (valid) {
|
60
|
+
this.$baseConfirm(this.$t1("您确定要保存吗?")).then(() => {
|
61
|
+
var url =
|
62
|
+
USER_PREFIX + (this.isEdit ? `/logic_param/update` : `/logic_param/save`);
|
63
|
+
this.$http({
|
64
|
+
url: url,
|
65
|
+
method: `post`,
|
66
|
+
data: this.logicParam,
|
67
|
+
isLoading: true,
|
68
|
+
success: (res) => {
|
69
|
+
this.$message({
|
70
|
+
message: res.content,
|
71
|
+
type: "success",
|
72
|
+
duration: 500,
|
73
|
+
onClose: (t) => {
|
74
|
+
if (this.isEdit) {
|
75
|
+
this.$baseReload();
|
76
|
+
} else {
|
77
|
+
this.$baseReload({
|
78
|
+
updateParam: {
|
79
|
+
_dataId: res.objx
|
80
|
+
},
|
81
|
+
});
|
82
|
+
}
|
83
|
+
},
|
84
|
+
});
|
85
|
+
},
|
86
|
+
});
|
87
|
+
});
|
88
|
+
}
|
89
|
+
});
|
90
|
+
},
|
91
|
+
},
|
92
|
+
};
|
93
|
+
export default modules
|
@@ -0,0 +1,358 @@
|
|
1
|
+
import editView from "../edit.vue";
|
2
|
+
import editView1 from "../edit1.vue";
|
3
|
+
import editView2 from "../edit2.vue";
|
4
|
+
import tableForm from "@base/components/table/tableForm.vue";
|
5
|
+
import { getJsxBtnList, getJsxStatus } from "@base/views/bd/setting/utils/index";
|
6
|
+
|
7
|
+
let modules = {};
|
8
|
+
|
9
|
+
modules = {
|
10
|
+
props: {
|
11
|
+
paramType: {
|
12
|
+
type: Number,
|
13
|
+
default: 0,
|
14
|
+
},
|
15
|
+
},
|
16
|
+
components: { tableForm, editView, editView1, editView2 },
|
17
|
+
data() {
|
18
|
+
return {
|
19
|
+
activeName: "second",
|
20
|
+
dataId: 0,
|
21
|
+
showEdit: false,
|
22
|
+
vxeOption: {},
|
23
|
+
formData: {},
|
24
|
+
editViewName:"editView",
|
25
|
+
};
|
26
|
+
},
|
27
|
+
created() {
|
28
|
+
this.initEditViewName();
|
29
|
+
},
|
30
|
+
mounted() {
|
31
|
+
this.initTableList();
|
32
|
+
},
|
33
|
+
methods: {
|
34
|
+
initEditViewName(){
|
35
|
+
let paramTypeStr = this.paramType ? this.paramType : "";
|
36
|
+
this.editViewName = `editView${paramTypeStr}`;
|
37
|
+
|
38
|
+
},
|
39
|
+
searchEvent() {
|
40
|
+
this.$refs["table-m1"].commitProxy("reload");
|
41
|
+
},
|
42
|
+
resetEvent() {
|
43
|
+
this.formData = {};
|
44
|
+
this.advancedFormData = {};
|
45
|
+
this.$refs["table-m1"].commitProxy("reload");
|
46
|
+
},
|
47
|
+
openEditDialog(id) {
|
48
|
+
this.copyId = 0;
|
49
|
+
this.dataId = !id || typeof id == "object" ? 0 : id;
|
50
|
+
this.activeName = "first";
|
51
|
+
this.$openEditView("showEdit");
|
52
|
+
},
|
53
|
+
getColumnInfo0() {
|
54
|
+
//逻辑参数
|
55
|
+
let columns = [
|
56
|
+
{
|
57
|
+
title: this.$t1("参数编码"),
|
58
|
+
field: "paramCode",
|
59
|
+
width: 150,
|
60
|
+
fixed: "left",
|
61
|
+
},
|
62
|
+
{
|
63
|
+
title: this.$t1("参数值"),
|
64
|
+
field: "paramValue",
|
65
|
+
width: 150,
|
66
|
+
},
|
67
|
+
{
|
68
|
+
title: this.$t1("参数备注"),
|
69
|
+
field: "remark",
|
70
|
+
width: 150,
|
71
|
+
},
|
72
|
+
{
|
73
|
+
title: this.$t1("组织编码"),
|
74
|
+
field: "paramCompanyCode",
|
75
|
+
width: 150,
|
76
|
+
},
|
77
|
+
{
|
78
|
+
title: this.$t1("是否启用"),
|
79
|
+
field: "enabled",
|
80
|
+
width: 150,
|
81
|
+
slots: {
|
82
|
+
default: ({ row }) => {
|
83
|
+
if (row.enabled) {
|
84
|
+
return getJsxStatus(null, this.$t1("启用"));
|
85
|
+
} else {
|
86
|
+
return getJsxStatus("s-3", this.$t1("禁用"));
|
87
|
+
}
|
88
|
+
},
|
89
|
+
},
|
90
|
+
},
|
91
|
+
];
|
92
|
+
|
93
|
+
let searchColumns = [
|
94
|
+
{
|
95
|
+
title: this.$t1("参数编码"),
|
96
|
+
field: "paramCode",
|
97
|
+
type: "input",
|
98
|
+
common: true,
|
99
|
+
},
|
100
|
+
{
|
101
|
+
title: this.$t1("参数值"),
|
102
|
+
field: "paramValue",
|
103
|
+
type: "input",
|
104
|
+
common: true,
|
105
|
+
},
|
106
|
+
{
|
107
|
+
title: this.$t1("参数备注"),
|
108
|
+
field: "remark",
|
109
|
+
type: "input",
|
110
|
+
common: true,
|
111
|
+
},
|
112
|
+
{
|
113
|
+
title: this.$t1("组织编码"),
|
114
|
+
field: "paramCompanyCode",
|
115
|
+
type: "input",
|
116
|
+
common: true,
|
117
|
+
},
|
118
|
+
{
|
119
|
+
title: this.$t1("是否启用"),
|
120
|
+
field: "enabled",
|
121
|
+
type: "select",
|
122
|
+
itemOption: [
|
123
|
+
{
|
124
|
+
label: this.$t1("启用"),
|
125
|
+
value: true,
|
126
|
+
},
|
127
|
+
{
|
128
|
+
label: this.$t1("禁用"),
|
129
|
+
value: false,
|
130
|
+
},
|
131
|
+
],
|
132
|
+
common: true,
|
133
|
+
},
|
134
|
+
];
|
135
|
+
|
136
|
+
return { columns, searchColumns };
|
137
|
+
},
|
138
|
+
getColumnInfo1() {
|
139
|
+
//操作日志编码
|
140
|
+
let columns = [
|
141
|
+
{
|
142
|
+
title: this.$t1("参数值"),
|
143
|
+
field: "paramValue",
|
144
|
+
width: 150,
|
145
|
+
fixed: "left",
|
146
|
+
},
|
147
|
+
{
|
148
|
+
title: this.$t1("参数备注"),
|
149
|
+
field: "remark",
|
150
|
+
width: 150,
|
151
|
+
},
|
152
|
+
{
|
153
|
+
title: this.$t1("是否启用"),
|
154
|
+
field: "enabled",
|
155
|
+
width: 150,
|
156
|
+
slots: {
|
157
|
+
default: ({ row }) => {
|
158
|
+
if (row.enabled) {
|
159
|
+
return getJsxStatus(null, this.$t1("启用"));
|
160
|
+
} else {
|
161
|
+
return getJsxStatus("s-3", this.$t1("禁用"));
|
162
|
+
}
|
163
|
+
},
|
164
|
+
},
|
165
|
+
},
|
166
|
+
];
|
167
|
+
|
168
|
+
let searchColumns = [
|
169
|
+
{
|
170
|
+
title: this.$t1("参数值"),
|
171
|
+
field: "paramValue",
|
172
|
+
type: "input",
|
173
|
+
common: true,
|
174
|
+
},
|
175
|
+
{
|
176
|
+
title: this.$t1("参数备注"),
|
177
|
+
field: "remark",
|
178
|
+
type: "input",
|
179
|
+
common: true,
|
180
|
+
},
|
181
|
+
{
|
182
|
+
title: this.$t1("是否启用"),
|
183
|
+
field: "enabled",
|
184
|
+
type: "select",
|
185
|
+
itemOption: [
|
186
|
+
{
|
187
|
+
label: this.$t1("启用"),
|
188
|
+
value: true,
|
189
|
+
},
|
190
|
+
{
|
191
|
+
label: this.$t1("禁用"),
|
192
|
+
value: false,
|
193
|
+
},
|
194
|
+
],
|
195
|
+
common: true,
|
196
|
+
},
|
197
|
+
];
|
198
|
+
|
199
|
+
return { columns, searchColumns };
|
200
|
+
},
|
201
|
+
getColumnInfo2() {
|
202
|
+
//上传文件服务
|
203
|
+
let columns = [
|
204
|
+
{
|
205
|
+
title: this.$t1("参数编码"),
|
206
|
+
field: "paramCode",
|
207
|
+
width: 150,
|
208
|
+
fixed: "left",
|
209
|
+
},
|
210
|
+
{
|
211
|
+
title: this.$t1("参数备注"),
|
212
|
+
field: "remark",
|
213
|
+
width: 150,
|
214
|
+
},
|
215
|
+
{
|
216
|
+
title: this.$t1("是否启用"),
|
217
|
+
field: "enabled",
|
218
|
+
width: 150,
|
219
|
+
slots: {
|
220
|
+
default: ({ row }) => {
|
221
|
+
if (row.enabled) {
|
222
|
+
return getJsxStatus(null, this.$t1("启用"));
|
223
|
+
} else {
|
224
|
+
return getJsxStatus("s-3", this.$t1("禁用"));
|
225
|
+
}
|
226
|
+
},
|
227
|
+
},
|
228
|
+
},
|
229
|
+
];
|
230
|
+
|
231
|
+
let searchColumns = [
|
232
|
+
{
|
233
|
+
title: this.$t1("参数编码"),
|
234
|
+
field: "paramCode",
|
235
|
+
type: "input",
|
236
|
+
common: true,
|
237
|
+
},
|
238
|
+
{
|
239
|
+
title: this.$t1("参数值"),
|
240
|
+
field: "paramValue",
|
241
|
+
type: "input",
|
242
|
+
common: true,
|
243
|
+
},
|
244
|
+
{
|
245
|
+
title: this.$t1("参数备注"),
|
246
|
+
field: "remark",
|
247
|
+
type: "input",
|
248
|
+
common: true,
|
249
|
+
},
|
250
|
+
{
|
251
|
+
title: this.$t1("是否启用"),
|
252
|
+
field: "enabled",
|
253
|
+
type: "select",
|
254
|
+
itemOption: [
|
255
|
+
{
|
256
|
+
label: this.$t1("启用"),
|
257
|
+
value: true,
|
258
|
+
},
|
259
|
+
{
|
260
|
+
label: this.$t1("禁用"),
|
261
|
+
value: false,
|
262
|
+
},
|
263
|
+
],
|
264
|
+
common: true,
|
265
|
+
},
|
266
|
+
];
|
267
|
+
|
268
|
+
return { columns, searchColumns };
|
269
|
+
},
|
270
|
+
getColumnInfo() {
|
271
|
+
if (this.paramType === 0) {
|
272
|
+
return this.getColumnInfo0();
|
273
|
+
} else if (this.paramType === 1) {
|
274
|
+
return this.getColumnInfo1();
|
275
|
+
} else if (this.paramType === 2) {
|
276
|
+
return this.getColumnInfo2();
|
277
|
+
}
|
278
|
+
},
|
279
|
+
initTableList() {
|
280
|
+
let that = this;
|
281
|
+
let { columns, searchColumns } = this.getColumnInfo();
|
282
|
+
|
283
|
+
let tableOption = {
|
284
|
+
vue: this,
|
285
|
+
tableRef: "table-m1",
|
286
|
+
tableName: "logic_param_list-m" + this.paramType,
|
287
|
+
path: USER_PREFIX + "/logic_param/listPage",
|
288
|
+
param: () => {
|
289
|
+
return {
|
290
|
+
...this.formData,
|
291
|
+
paramType: this.paramType,
|
292
|
+
};
|
293
|
+
},
|
294
|
+
columns: [
|
295
|
+
{ type: "checkbox", width: 48, resizable: false, fixed: "left" },
|
296
|
+
...columns,
|
297
|
+
{
|
298
|
+
field: "createBy",
|
299
|
+
title: this.$t1("创建人"),
|
300
|
+
width: 150,
|
301
|
+
},
|
302
|
+
{
|
303
|
+
field: "createDate",
|
304
|
+
title: this.$t1("创建时间"),
|
305
|
+
width: 150,
|
306
|
+
},
|
307
|
+
{
|
308
|
+
field: "modifyBy",
|
309
|
+
title: this.$t1("更新人"),
|
310
|
+
width: 150,
|
311
|
+
},
|
312
|
+
{
|
313
|
+
field: "modifyDate",
|
314
|
+
title: this.$t1("更新时间"),
|
315
|
+
width: 150,
|
316
|
+
},
|
317
|
+
{
|
318
|
+
width: 47,
|
319
|
+
fixed: "right",
|
320
|
+
title: "",
|
321
|
+
sortable: false,
|
322
|
+
slots: {
|
323
|
+
default: ({ row }) => {
|
324
|
+
return [
|
325
|
+
<div>
|
326
|
+
<a
|
327
|
+
href="javascript:void(0);"
|
328
|
+
class="a-link"
|
329
|
+
onclick={() => {
|
330
|
+
this.openEditDialog(row.id);
|
331
|
+
}}
|
332
|
+
>
|
333
|
+
<el-tooltip
|
334
|
+
enterable={false}
|
335
|
+
effect="dark"
|
336
|
+
content={this.$t1("查看")}
|
337
|
+
placement="top"
|
338
|
+
popper-class="tooltip-skin"
|
339
|
+
>
|
340
|
+
<i class="el-icon-edit" />
|
341
|
+
</el-tooltip>
|
342
|
+
</a>
|
343
|
+
</div>,
|
344
|
+
];
|
345
|
+
},
|
346
|
+
},
|
347
|
+
},
|
348
|
+
],
|
349
|
+
searchColumns,
|
350
|
+
};
|
351
|
+
this.$vxeTableUtil.initVxeTable(tableOption).then((opts) => {
|
352
|
+
this.vxeOption = opts;
|
353
|
+
});
|
354
|
+
},
|
355
|
+
},
|
356
|
+
};
|
357
|
+
|
358
|
+
export default modules
|