cloud-web-corejs 1.0.54-dev.137 → 1.0.54-dev.139
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/fileLibrary/mixins/fileObjAuthDialogMixin.js +325 -214
- package/src/components/fileLibrary/mixins/indexMixins.js +1 -1
- package/src/views/bd/setting/table_model/edit.vue +829 -484
- package/src/views/bd/setting/table_model/mixins/edit.js +1030 -1
- package/src/views/bd/setting/table_model/mixins/edit copy.js +0 -903
@@ -6,18 +6,23 @@ import roleDialog from "@base/views/user/role/dialog";
|
|
6
6
|
import fileObjAuthEditDialog from "../fileObjAuthEditDialog.vue";
|
7
7
|
import fileObjNotifyEdit from "../fileObjNotifyEdit.vue";
|
8
8
|
|
9
|
-
|
10
9
|
let modules = {};
|
11
10
|
modules = {
|
12
11
|
name: "fileObjAuthDialog",
|
13
12
|
props: {
|
14
13
|
fileObjId: Number,
|
15
|
-
treeNodeArr: Array
|
14
|
+
treeNodeArr: Array,
|
16
15
|
},
|
17
16
|
components: {
|
18
|
-
editView,
|
17
|
+
editView,
|
18
|
+
userDialog,
|
19
|
+
positionDialog,
|
20
|
+
saleOrgDialog,
|
21
|
+
roleDialog,
|
22
|
+
fileObjAuthEditDialog,
|
23
|
+
fileObjNotifyEdit,
|
19
24
|
},
|
20
|
-
inject: [
|
25
|
+
inject: ["current_prefix", "getFileStoreArea"],
|
21
26
|
mounted() {
|
22
27
|
this.initTableList();
|
23
28
|
},
|
@@ -25,9 +30,9 @@ modules = {
|
|
25
30
|
let that = this;
|
26
31
|
return {
|
27
32
|
showDialog: true,
|
28
|
-
activeName:
|
29
|
-
value10:
|
30
|
-
dataId:
|
33
|
+
activeName: "first",
|
34
|
+
value10: "",
|
35
|
+
dataId: "",
|
31
36
|
showEdit: false,
|
32
37
|
formData: {
|
33
38
|
saleOrgName: null,
|
@@ -53,39 +58,39 @@ modules = {
|
|
53
58
|
showRoleAddDialog: false,
|
54
59
|
showDetailDialog: false,
|
55
60
|
currentRow: null,
|
56
|
-
showFileObjNotifyEdit: true
|
61
|
+
showFileObjNotifyEdit: true,
|
57
62
|
};
|
58
63
|
},
|
59
64
|
computed: {
|
60
65
|
fileStoreArea() {
|
61
66
|
return this.getFileStoreArea();
|
62
|
-
}
|
67
|
+
},
|
63
68
|
},
|
64
69
|
methods: {
|
65
70
|
searchEvent() {
|
66
|
-
this.$refs[
|
71
|
+
this.$refs["table-m1"].commitProxy("reload");
|
67
72
|
},
|
68
73
|
resetEvent() {
|
69
74
|
this.formData = {};
|
70
|
-
this.$refs[
|
75
|
+
this.$refs["table-m1"].commitProxy("reload");
|
71
76
|
},
|
72
77
|
openEditDialog(id) {
|
73
|
-
this.dataId = !id || typeof id ==
|
74
|
-
this.activeName =
|
78
|
+
this.dataId = !id || typeof id == "object" ? 0 : id;
|
79
|
+
this.activeName = "first";
|
75
80
|
this.showViewDialog = true;
|
76
|
-
this.$openEditView(
|
81
|
+
this.$openEditView("showEdit");
|
77
82
|
},
|
78
83
|
|
79
84
|
initTableList() {
|
80
85
|
let that = this;
|
81
86
|
let valMap = {
|
82
|
-
0: this.$t2(
|
83
|
-
1: this.$t2(
|
87
|
+
0: this.$t2("否", "components.fileLibrary.auThLaebl0"),
|
88
|
+
1: this.$t2("是", "components.fileLibrary.auThLaebl1"),
|
84
89
|
};
|
85
90
|
let tableOption = {
|
86
91
|
vue: this,
|
87
|
-
tableRef:
|
88
|
-
tableName:
|
92
|
+
tableRef: "table-m1",
|
93
|
+
tableName: "user_fileLibrary-fileAuto-list-m1",
|
89
94
|
/*path: this.current_prefix + '/file_obj_auth/listPage',
|
90
95
|
param: () => {
|
91
96
|
return {
|
@@ -95,272 +100,360 @@ modules = {
|
|
95
100
|
},*/
|
96
101
|
config: {
|
97
102
|
height: "auto",
|
98
|
-
rowStyle: ({row, rowIndex}) => {
|
99
|
-
return row._isParent ? "background-color: #f3f3f3;" : ""
|
100
|
-
|
101
|
-
}
|
103
|
+
rowStyle: ({ row, rowIndex }) => {
|
104
|
+
return row._isParent ? "background-color: #f3f3f3;" : "";
|
105
|
+
},
|
102
106
|
},
|
103
107
|
columns: [
|
104
|
-
{type:
|
108
|
+
{ type: "checkbox", width: 48, resizable: false, fixed: "left" },
|
105
109
|
{
|
106
|
-
title: this.$t2(
|
107
|
-
field:
|
110
|
+
title: this.$t2("机构", "components.fileLibrary.saleOrg"),
|
111
|
+
field: "saleOrgName",
|
108
112
|
width: 150,
|
109
113
|
slots: {
|
110
|
-
default: "saleOrg"
|
111
|
-
}
|
114
|
+
default: "saleOrg",
|
115
|
+
},
|
112
116
|
},
|
113
117
|
{
|
114
|
-
title: this.$t2(
|
115
|
-
field:
|
118
|
+
title: this.$t2("岗位", "components.fileLibrary.position"),
|
119
|
+
field: "positionName",
|
116
120
|
width: 150,
|
117
121
|
slots: {
|
118
|
-
default: "position"
|
119
|
-
}
|
122
|
+
default: "position",
|
123
|
+
},
|
120
124
|
},
|
121
125
|
{
|
122
|
-
title: this.$t2(
|
123
|
-
field:
|
126
|
+
title: this.$t2("用户", "components.fileLibrary.user"),
|
127
|
+
field: "nickName",
|
124
128
|
width: 150,
|
125
129
|
slots: {
|
126
|
-
default: "user"
|
127
|
-
}
|
130
|
+
default: "user",
|
131
|
+
},
|
128
132
|
},
|
129
133
|
{
|
130
|
-
title: this.$t2(
|
131
|
-
field:
|
134
|
+
title: this.$t2("角色", "components.fileLibrary.role"),
|
135
|
+
field: "roleName",
|
132
136
|
width: 150,
|
133
137
|
slots: {
|
134
|
-
default: "role"
|
135
|
-
}
|
138
|
+
default: "role",
|
139
|
+
},
|
136
140
|
},
|
137
141
|
{
|
138
|
-
title: this.$t2(
|
139
|
-
field:
|
142
|
+
title: this.$t2("新增", "components.fileLibrary.add"),
|
143
|
+
field: "addAuth",
|
140
144
|
width: 150,
|
141
145
|
slots: {
|
142
|
-
default: ({row}) => {
|
146
|
+
default: ({ row }) => {
|
143
147
|
return [
|
144
|
-
<el-switch
|
145
|
-
|
148
|
+
<el-switch
|
149
|
+
v-model={row.addAuth}
|
150
|
+
active-value={1}
|
151
|
+
inactive-value={0}
|
152
|
+
disabled={row._isParent}
|
153
|
+
></el-switch>,
|
146
154
|
];
|
147
|
-
}
|
148
|
-
}
|
155
|
+
},
|
156
|
+
},
|
149
157
|
},
|
150
158
|
{
|
151
|
-
title: this.$t2(
|
152
|
-
field:
|
159
|
+
title: this.$t2("编辑", "components.fileLibrary.edit"),
|
160
|
+
field: "editAuth",
|
153
161
|
width: 150,
|
154
162
|
slots: {
|
155
|
-
default: ({row}) => {
|
163
|
+
default: ({ row }) => {
|
156
164
|
return [
|
157
|
-
<el-switch
|
158
|
-
|
165
|
+
<el-switch
|
166
|
+
v-model={row.editAuth}
|
167
|
+
active-value={1}
|
168
|
+
inactive-value={0}
|
169
|
+
disabled={row._isParent}
|
170
|
+
></el-switch>,
|
159
171
|
];
|
160
|
-
}
|
161
|
-
}
|
172
|
+
},
|
173
|
+
},
|
162
174
|
},
|
163
175
|
{
|
164
|
-
title: this.$t2(
|
165
|
-
field:
|
176
|
+
title: this.$t2("查看", "components.fileLibrary.view"),
|
177
|
+
field: "viewAuth",
|
166
178
|
width: 150,
|
167
179
|
slots: {
|
168
|
-
default: ({row}) => {
|
180
|
+
default: ({ row }) => {
|
169
181
|
return [
|
170
|
-
<el-switch
|
171
|
-
|
182
|
+
<el-switch
|
183
|
+
v-model={row.viewAuth}
|
184
|
+
active-value={1}
|
185
|
+
inactive-value={0}
|
186
|
+
disabled={row._isParent}
|
187
|
+
></el-switch>,
|
172
188
|
];
|
173
|
-
}
|
174
|
-
}
|
189
|
+
},
|
190
|
+
},
|
175
191
|
},
|
176
192
|
{
|
177
|
-
title: this.$t2(
|
178
|
-
field:
|
193
|
+
title: this.$t2("上传", "components.fileLibrary.upload"),
|
194
|
+
field: "uploadAuth",
|
179
195
|
width: 150,
|
180
196
|
slots: {
|
181
|
-
default: ({row}) => {
|
197
|
+
default: ({ row }) => {
|
182
198
|
return [
|
183
|
-
<el-switch
|
184
|
-
|
199
|
+
<el-switch
|
200
|
+
v-model={row.uploadAuth}
|
201
|
+
active-value={1}
|
202
|
+
inactive-value={0}
|
203
|
+
disabled={row._isParent}
|
204
|
+
></el-switch>,
|
185
205
|
];
|
186
|
-
}
|
187
|
-
}
|
206
|
+
},
|
207
|
+
},
|
188
208
|
},
|
189
209
|
{
|
190
|
-
title: this.$t2(
|
191
|
-
field:
|
210
|
+
title: this.$t2("下载", "components.fileLibrary.download"),
|
211
|
+
field: "downloadAuth",
|
192
212
|
width: 150,
|
193
213
|
slots: {
|
194
|
-
default: ({row}) => {
|
214
|
+
default: ({ row }) => {
|
195
215
|
return [
|
196
|
-
<el-switch
|
197
|
-
|
216
|
+
<el-switch
|
217
|
+
v-model={row.downloadAuth}
|
218
|
+
active-value={1}
|
219
|
+
inactive-value={0}
|
220
|
+
disabled={row._isParent}
|
221
|
+
></el-switch>,
|
198
222
|
];
|
199
|
-
}
|
200
|
-
}
|
223
|
+
},
|
224
|
+
},
|
201
225
|
},
|
202
226
|
{
|
203
|
-
title: this.$t2(
|
204
|
-
field:
|
227
|
+
title: this.$t2("移动", "components.fileLibrary.move"),
|
228
|
+
field: "moveAuth",
|
205
229
|
width: 150,
|
206
230
|
slots: {
|
207
|
-
default: ({row}) => {
|
231
|
+
default: ({ row }) => {
|
208
232
|
return [
|
209
|
-
<el-switch
|
210
|
-
|
233
|
+
<el-switch
|
234
|
+
v-model={row.moveAuth}
|
235
|
+
active-value={1}
|
236
|
+
inactive-value={0}
|
237
|
+
disabled={row._isParent}
|
238
|
+
></el-switch>,
|
211
239
|
];
|
212
|
-
}
|
213
|
-
}
|
240
|
+
},
|
241
|
+
},
|
214
242
|
},
|
215
243
|
{
|
216
|
-
title: this.$t2(
|
217
|
-
field:
|
244
|
+
title: this.$t2("复制", "components.fileLibrary.copy"),
|
245
|
+
field: "copyAuth",
|
218
246
|
width: 150,
|
219
247
|
slots: {
|
220
|
-
default: ({row}) => {
|
248
|
+
default: ({ row }) => {
|
221
249
|
return [
|
222
|
-
<el-switch
|
223
|
-
|
250
|
+
<el-switch
|
251
|
+
v-model={row.copyAuth}
|
252
|
+
active-value={1}
|
253
|
+
inactive-value={0}
|
254
|
+
disabled={row._isParent}
|
255
|
+
></el-switch>,
|
224
256
|
];
|
225
|
-
}
|
226
|
-
}
|
257
|
+
},
|
258
|
+
},
|
227
259
|
},
|
228
260
|
{
|
229
|
-
title: this.$t2(
|
230
|
-
field:
|
261
|
+
title: this.$t2("替换", "components.fileLibrary.replace"),
|
262
|
+
field: "replaceAuth",
|
231
263
|
width: 150,
|
232
264
|
slots: {
|
233
|
-
default: ({row}) => {
|
265
|
+
default: ({ row }) => {
|
234
266
|
return [
|
235
|
-
<el-switch
|
236
|
-
|
267
|
+
<el-switch
|
268
|
+
v-model={row.replaceAuth}
|
269
|
+
active-value={1}
|
270
|
+
inactive-value={0}
|
271
|
+
disabled={row._isParent}
|
272
|
+
></el-switch>,
|
237
273
|
];
|
238
|
-
}
|
239
|
-
}
|
274
|
+
},
|
275
|
+
},
|
240
276
|
},
|
241
277
|
{
|
242
|
-
title: this.$t2(
|
243
|
-
field:
|
278
|
+
title: this.$t2("删除文件", "components.fileLibrary.deleteFile"),
|
279
|
+
field: "deleteAuth",
|
244
280
|
width: 150,
|
245
281
|
slots: {
|
246
|
-
default: ({row}) => {
|
282
|
+
default: ({ row }) => {
|
247
283
|
return [
|
248
|
-
<el-switch
|
249
|
-
|
284
|
+
<el-switch
|
285
|
+
v-model={row.deleteAuth}
|
286
|
+
active-value={1}
|
287
|
+
inactive-value={0}
|
288
|
+
disabled={row._isParent}
|
289
|
+
></el-switch>,
|
250
290
|
];
|
251
|
-
}
|
252
|
-
}
|
291
|
+
},
|
292
|
+
},
|
253
293
|
},
|
254
294
|
{
|
255
|
-
title: this.$t2(
|
256
|
-
|
295
|
+
title: this.$t2(
|
296
|
+
"删除文件夹",
|
297
|
+
"components.fileLibrary.deleteCategory"
|
298
|
+
),
|
299
|
+
field: "deleteDirAuth",
|
257
300
|
width: 150,
|
258
301
|
slots: {
|
259
|
-
default: ({row}) => {
|
302
|
+
default: ({ row }) => {
|
260
303
|
return [
|
261
|
-
<el-switch
|
262
|
-
|
304
|
+
<el-switch
|
305
|
+
v-model={row.deleteDirAuth}
|
306
|
+
active-value={1}
|
307
|
+
inactive-value={0}
|
308
|
+
disabled={row._isParent}
|
309
|
+
></el-switch>,
|
263
310
|
];
|
264
|
-
}
|
265
|
-
}
|
311
|
+
},
|
312
|
+
},
|
266
313
|
},
|
267
314
|
{
|
268
|
-
title: this.$t2(
|
269
|
-
field:
|
315
|
+
title: this.$t2("查看历史", "components.fileLibrary.checkHistory"),
|
316
|
+
field: "historyAuth",
|
270
317
|
width: 150,
|
271
318
|
slots: {
|
272
|
-
default: ({row}) => {
|
319
|
+
default: ({ row }) => {
|
273
320
|
return [
|
274
|
-
<el-switch
|
275
|
-
|
321
|
+
<el-switch
|
322
|
+
v-model={row.historyAuth}
|
323
|
+
active-value={1}
|
324
|
+
inactive-value={0}
|
325
|
+
disabled={row._isParent}
|
326
|
+
></el-switch>,
|
276
327
|
];
|
277
|
-
}
|
278
|
-
}
|
328
|
+
},
|
329
|
+
},
|
279
330
|
},
|
280
331
|
{
|
281
|
-
title: this.$t2(
|
282
|
-
field:
|
332
|
+
title: this.$t2("分享", "components.fileLibrary.share"),
|
333
|
+
field: "shareAuth",
|
283
334
|
width: 150,
|
284
335
|
slots: {
|
285
|
-
default: ({row}) => {
|
336
|
+
default: ({ row }) => {
|
286
337
|
return [
|
287
|
-
<el-switch
|
288
|
-
|
338
|
+
<el-switch
|
339
|
+
v-model={row.shareAuth}
|
340
|
+
active-value={1}
|
341
|
+
inactive-value={0}
|
342
|
+
disabled={row._isParent}
|
343
|
+
></el-switch>,
|
289
344
|
];
|
290
|
-
}
|
291
|
-
}
|
345
|
+
},
|
346
|
+
},
|
292
347
|
},
|
293
|
-
...(this.fileStoreArea.toDownWatermark
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
348
|
+
...(this.fileStoreArea.toDownWatermark
|
349
|
+
? [
|
350
|
+
{
|
351
|
+
title: this.$t1("下载打水印 "),
|
352
|
+
field: "downWatermarkAuth",
|
353
|
+
width: 150,
|
354
|
+
slots: {
|
355
|
+
default: ({ row }) => {
|
356
|
+
return [
|
357
|
+
<el-switch
|
358
|
+
v-model={row.downWatermarkAuth}
|
359
|
+
active-value={1}
|
360
|
+
inactive-value={0}
|
361
|
+
disabled={row._isParent}
|
362
|
+
></el-switch>,
|
363
|
+
];
|
364
|
+
},
|
365
|
+
},
|
366
|
+
},
|
367
|
+
]
|
368
|
+
: []),
|
306
369
|
|
307
370
|
{
|
308
|
-
title: this.$t1(
|
309
|
-
field:
|
371
|
+
title: this.$t1("设置权限"),
|
372
|
+
field: "authAuth",
|
310
373
|
width: 150,
|
311
374
|
slots: {
|
312
|
-
default: ({row}) => {
|
375
|
+
default: ({ row }) => {
|
313
376
|
return [
|
314
|
-
<el-switch
|
315
|
-
|
377
|
+
<el-switch
|
378
|
+
v-model={row.authAuth}
|
379
|
+
active-value={1}
|
380
|
+
inactive-value={0}
|
381
|
+
disabled={row._isParent}
|
382
|
+
></el-switch>,
|
316
383
|
];
|
317
|
-
}
|
318
|
-
}
|
384
|
+
},
|
385
|
+
},
|
386
|
+
},
|
387
|
+
{
|
388
|
+
title: this.$t2("创建人", "system.label.createBy"),
|
389
|
+
field: "createBy",
|
390
|
+
width: 150,
|
391
|
+
},
|
392
|
+
{
|
393
|
+
title: this.$t2("创建时间", "system.label.createDate"),
|
394
|
+
field: "createDate",
|
395
|
+
width: 150,
|
396
|
+
},
|
397
|
+
{
|
398
|
+
title: this.$t2("更新人", "system.label.modifyBy"),
|
399
|
+
field: "modifyBy",
|
400
|
+
width: 150,
|
401
|
+
},
|
402
|
+
{
|
403
|
+
title: this.$t2("更新时间", "system.label.modifyDate"),
|
404
|
+
field: "modifyDate",
|
405
|
+
width: 150,
|
319
406
|
},
|
320
|
-
{title: this.$t2('创建人', 'system.label.createBy'), field: 'createBy', width: 150},
|
321
|
-
{title: this.$t2('创建时间', 'system.label.createDate'), field: 'createDate', width: 150},
|
322
|
-
{title: this.$t2('更新人', 'system.label.modifyBy'), field: 'modifyBy', width: 150},
|
323
|
-
{title: this.$t2('更新时间', 'system.label.modifyDate'), field: 'modifyDate', width: 150},
|
324
407
|
{
|
325
408
|
width: 100,
|
326
|
-
fixed:
|
327
|
-
title:
|
409
|
+
fixed: "right",
|
410
|
+
title: "",
|
328
411
|
sortable: false,
|
329
412
|
slots: {
|
330
|
-
default: ({row, rowIndex, $table}) => {
|
413
|
+
default: ({ row, rowIndex, $table }) => {
|
331
414
|
return [
|
332
415
|
<a
|
333
416
|
href="javascript:void(0);"
|
334
417
|
class="a-link"
|
335
418
|
onClick={() => {
|
336
|
-
this.openDetailDialog(row, rowIndex)
|
419
|
+
this.openDetailDialog(row, rowIndex);
|
337
420
|
}}
|
338
421
|
>
|
339
|
-
<el-tooltip
|
340
|
-
|
341
|
-
|
422
|
+
<el-tooltip
|
423
|
+
enterable={false}
|
424
|
+
effect="dark"
|
425
|
+
content="查看"
|
426
|
+
placement="top"
|
427
|
+
popper-class="tooltip-skin"
|
428
|
+
>
|
429
|
+
<i class="el-icon-edit" />
|
342
430
|
</el-tooltip>
|
343
431
|
</a>,
|
344
432
|
<a
|
345
433
|
href="javascript:void(0);"
|
346
434
|
class="a-link"
|
347
435
|
onClick={() => {
|
348
|
-
this.tableData.splice(rowIndex, 1)
|
436
|
+
this.tableData.splice(rowIndex, 1);
|
349
437
|
}}
|
350
438
|
v-show={!row._isParent}
|
351
439
|
>
|
352
|
-
<el-tooltip
|
353
|
-
|
354
|
-
|
440
|
+
<el-tooltip
|
441
|
+
enterable={false}
|
442
|
+
effect="dark"
|
443
|
+
content="删除"
|
444
|
+
placement="top"
|
445
|
+
popper-class="tooltip-skin"
|
446
|
+
>
|
447
|
+
<i class="el-icon-delete" />
|
355
448
|
</el-tooltip>
|
356
|
-
</a
|
449
|
+
</a>,
|
357
450
|
];
|
358
|
-
}
|
359
|
-
}
|
360
|
-
}
|
361
|
-
]
|
451
|
+
},
|
452
|
+
},
|
453
|
+
},
|
454
|
+
],
|
362
455
|
};
|
363
|
-
this.$vxeTableUtil.initVxeTable(tableOption).then(opts => {
|
456
|
+
this.$vxeTableUtil.initVxeTable(tableOption).then((opts) => {
|
364
457
|
this.vxeOption = opts;
|
365
458
|
});
|
366
459
|
this.initData();
|
@@ -368,34 +461,33 @@ modules = {
|
|
368
461
|
initData() {
|
369
462
|
let tableData = [];
|
370
463
|
this.$http({
|
371
|
-
url: this.current_prefix +
|
464
|
+
url: this.current_prefix + "/file_obj_auth/listParentPage",
|
372
465
|
method: `post`,
|
373
466
|
data: {
|
374
467
|
fileObjId: this.fileObjId,
|
375
468
|
},
|
376
469
|
isLoading: true,
|
377
470
|
modalStrictly: true,
|
378
|
-
success: res1 => {
|
471
|
+
success: (res1) => {
|
379
472
|
tableData = res1.objx?.records || [];
|
380
|
-
tableData.forEach(item => {
|
473
|
+
tableData.forEach((item) => {
|
381
474
|
item._isParent = true;
|
382
|
-
})
|
475
|
+
});
|
383
476
|
|
384
477
|
this.$http({
|
385
|
-
url: this.current_prefix +
|
478
|
+
url: this.current_prefix + "/file_obj_auth/listPage",
|
386
479
|
method: `post`,
|
387
480
|
data: {
|
388
481
|
fileObjId: this.fileObjId,
|
389
482
|
},
|
390
483
|
isLoading: true,
|
391
484
|
modalStrictly: true,
|
392
|
-
success: res2 => {
|
393
|
-
tableData.push(...(res2.objx?.records || []))
|
485
|
+
success: (res2) => {
|
486
|
+
tableData.push(...(res2.objx?.records || []));
|
394
487
|
this.tableData = tableData;
|
395
|
-
}
|
488
|
+
},
|
396
489
|
});
|
397
|
-
|
398
|
-
}
|
490
|
+
},
|
399
491
|
});
|
400
492
|
},
|
401
493
|
confirmInsertUser(rows) {
|
@@ -420,34 +512,42 @@ modules = {
|
|
420
512
|
}
|
421
513
|
},
|
422
514
|
dialogClose() {
|
423
|
-
this.$emit(
|
515
|
+
this.$emit("update:visiable", false);
|
424
516
|
},
|
425
517
|
deleteRows() {
|
426
|
-
let checkRows = this.$refs[
|
518
|
+
let checkRows = this.$refs["table-m1"].getCheckboxRecords(true);
|
427
519
|
if (!checkRows.length) {
|
428
520
|
this.$message({
|
429
|
-
message: this.$t2(
|
430
|
-
|
521
|
+
message: this.$t2(
|
522
|
+
"请选择需要删除的文件权限",
|
523
|
+
"components.fileLibrary.deleteAuthTip1"
|
524
|
+
),
|
525
|
+
type: "error",
|
431
526
|
showClose: true,
|
432
527
|
duration: 3000,
|
433
528
|
});
|
434
529
|
return;
|
435
530
|
}
|
436
|
-
this.$baseConfirm(
|
437
|
-
|
531
|
+
this.$baseConfirm(
|
532
|
+
this.$t2(
|
533
|
+
"您确定要删除吗?",
|
534
|
+
"components.fileLibrary.deleteAuthConfirmTip"
|
535
|
+
)
|
536
|
+
).then(() => {
|
537
|
+
let ids = checkRows.map((checkRow) => checkRow.id);
|
438
538
|
this.$http({
|
439
|
-
method:
|
440
|
-
url: this.current_prefix +
|
539
|
+
method: "post",
|
540
|
+
url: this.current_prefix + "/file_obj_auth/delete",
|
441
541
|
data: ids,
|
442
542
|
isLoading: true,
|
443
|
-
success: res => {
|
543
|
+
success: (res) => {
|
444
544
|
this.$message({
|
445
545
|
message: res.content,
|
446
|
-
type:
|
546
|
+
type: "success",
|
447
547
|
duration: 500,
|
448
548
|
});
|
449
549
|
this.searchEvent();
|
450
|
-
}
|
550
|
+
},
|
451
551
|
});
|
452
552
|
});
|
453
553
|
},
|
@@ -470,7 +570,7 @@ modules = {
|
|
470
570
|
confirmtUserRow(rows) {
|
471
571
|
if (rows.length) {
|
472
572
|
let row = rows[0];
|
473
|
-
let item = this.tableData[this.operateIndex]
|
573
|
+
let item = this.tableData[this.operateIndex];
|
474
574
|
item.userId = row.id;
|
475
575
|
item.nickName = row.nickName;
|
476
576
|
}
|
@@ -478,7 +578,7 @@ modules = {
|
|
478
578
|
confirmSaleOrgRow(rows) {
|
479
579
|
if (rows.length) {
|
480
580
|
let row = rows[0];
|
481
|
-
let item = this.tableData[this.operateIndex]
|
581
|
+
let item = this.tableData[this.operateIndex];
|
482
582
|
item.saleOrgId = row.id;
|
483
583
|
item.saleOrgName = row.name;
|
484
584
|
}
|
@@ -486,7 +586,7 @@ modules = {
|
|
486
586
|
confirmPositionRow(rows) {
|
487
587
|
if (rows.length) {
|
488
588
|
let row = rows[0];
|
489
|
-
let item = this.tableData[this.operateIndex]
|
589
|
+
let item = this.tableData[this.operateIndex];
|
490
590
|
item.positionId = row.id;
|
491
591
|
item.positionName = row.name;
|
492
592
|
}
|
@@ -494,7 +594,7 @@ modules = {
|
|
494
594
|
confirmRoleRow(rows) {
|
495
595
|
if (rows.length) {
|
496
596
|
let row = rows[0];
|
497
|
-
let item = this.tableData[this.operateIndex]
|
597
|
+
let item = this.tableData[this.operateIndex];
|
498
598
|
item.roleId = row.id;
|
499
599
|
item.roleName = row.name;
|
500
600
|
}
|
@@ -516,9 +616,11 @@ modules = {
|
|
516
616
|
if (rows.length) {
|
517
617
|
const tableData = this.tableData;
|
518
618
|
const map = {};
|
519
|
-
tableData
|
520
|
-
|
521
|
-
|
619
|
+
tableData
|
620
|
+
.filter((item) => !!item.userId)
|
621
|
+
.forEach(function (item) {
|
622
|
+
map[item.userId] = 1;
|
623
|
+
});
|
522
624
|
let items = [];
|
523
625
|
|
524
626
|
rows.forEach((row, index) => {
|
@@ -536,9 +638,11 @@ modules = {
|
|
536
638
|
if (rows.length) {
|
537
639
|
const tableData = this.tableData;
|
538
640
|
const map = {};
|
539
|
-
tableData
|
540
|
-
|
541
|
-
|
641
|
+
tableData
|
642
|
+
.filter((item) => !!item.saleOrgId && !item.positionId)
|
643
|
+
.forEach(function (item) {
|
644
|
+
map[item.saleOrgId] = 1;
|
645
|
+
});
|
542
646
|
let items = [];
|
543
647
|
|
544
648
|
rows.forEach((row, index) => {
|
@@ -556,9 +660,11 @@ modules = {
|
|
556
660
|
if (rows.length) {
|
557
661
|
const tableData = this.tableData;
|
558
662
|
const map = {};
|
559
|
-
tableData
|
560
|
-
|
561
|
-
|
663
|
+
tableData
|
664
|
+
.filter((item) => !!item.positionId && !item.saleOrgId)
|
665
|
+
.forEach(function (item) {
|
666
|
+
map[item.positionId] = 1;
|
667
|
+
});
|
562
668
|
let items = [];
|
563
669
|
|
564
670
|
rows.forEach((row, index) => {
|
@@ -576,9 +682,11 @@ modules = {
|
|
576
682
|
if (rows.length) {
|
577
683
|
const tableData = this.tableData;
|
578
684
|
const map = {};
|
579
|
-
tableData
|
580
|
-
|
581
|
-
|
685
|
+
tableData
|
686
|
+
.filter((item) => !!item.roleId)
|
687
|
+
.forEach(function (item) {
|
688
|
+
map[item.roleId] = 1;
|
689
|
+
});
|
582
690
|
let items = [];
|
583
691
|
|
584
692
|
rows.forEach((row, index) => {
|
@@ -593,24 +701,26 @@ modules = {
|
|
593
701
|
}
|
594
702
|
},
|
595
703
|
saveData() {
|
596
|
-
this.$baseConfirm(
|
704
|
+
this.$baseConfirm(
|
705
|
+
this.$t2("您确定要保存吗?", "system.message.sureSave")
|
706
|
+
).then(() => {
|
597
707
|
var url = this.current_prefix + `/file_obj_auth/saves`;
|
598
|
-
let formData = this.tableData.filter(item => !item._isParent);
|
708
|
+
let formData = this.tableData.filter((item) => !item._isParent);
|
599
709
|
this.$http({
|
600
710
|
url: url,
|
601
711
|
method: `post`,
|
602
712
|
data: formData,
|
603
713
|
isLoading: true,
|
604
|
-
success: res => {
|
714
|
+
success: (res) => {
|
605
715
|
this.$message({
|
606
716
|
message: res.content,
|
607
|
-
type:
|
717
|
+
type: "success",
|
608
718
|
duration: 500,
|
609
|
-
onClose: t => {
|
610
|
-
this.dialogClose()
|
611
|
-
}
|
719
|
+
onClose: (t) => {
|
720
|
+
this.dialogClose();
|
721
|
+
},
|
612
722
|
});
|
613
|
-
}
|
723
|
+
},
|
614
724
|
});
|
615
725
|
});
|
616
726
|
},
|
@@ -637,8 +747,9 @@ modules = {
|
|
637
747
|
historyAuth: 1,
|
638
748
|
shareAuth: 1,
|
639
749
|
downWatermarkAuth: 0,
|
640
|
-
|
641
|
-
|
750
|
+
authAuth: 1,
|
751
|
+
fileObjId: this.fileObjId,
|
752
|
+
};
|
642
753
|
return row;
|
643
754
|
},
|
644
755
|
openDetailDialog(row, rowIndex) {
|
@@ -647,9 +758,9 @@ modules = {
|
|
647
758
|
this.showDetailDialog = true;
|
648
759
|
},
|
649
760
|
confirmDetailDialog(row) {
|
650
|
-
this.tableData.splice(this.operateIndex, 1, row)
|
761
|
+
this.tableData.splice(this.operateIndex, 1, row);
|
651
762
|
this.showDetailDialog = false;
|
652
|
-
}
|
653
|
-
}
|
763
|
+
},
|
764
|
+
},
|
654
765
|
};
|
655
766
|
export default modules;
|