centaline-data-driven 1.3.17 → 1.3.18
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/Form.vue +2 -2
- package/src/centaline/api/index.js +1 -1
- package/src/centaline/dynamicFile/src/dynamicFile.vue +25 -73
- package/src/centaline/loader/src/ctl/File.js +5 -3
- package/src/main.js +4 -4
- package/wwwroot/static/centaline/centaline-data-driven.js +1 -1
- package/wwwroot/static/centaline/centaline-data-driven.js.map +1 -1
package/package.json
CHANGED
package/src/Form.vue
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<div id="app-form" class="data-driven" style="width:100%;height:100%;overflow:auto">
|
|
3
3
|
<!-- <ct-form :api="'/PropertyRET/getLayoutOfNew'" :apiParam="apiParam"></ct-form> -->
|
|
4
4
|
<!-- <ct-form :source="formdata.content" :apiParam="apiParam"></ct-form> -->
|
|
5
|
-
<ct-form :api="'/
|
|
5
|
+
<ct-form :api="'/api/finance/collection-money/detail'" :apiParam="apiParam"></ct-form>
|
|
6
6
|
<!--<ct-form :api="'api/Form/formdata'"></ct-form>-->
|
|
7
7
|
<ct-dialog-list></ct-dialog-list>
|
|
8
8
|
</div>
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
data() {
|
|
15
15
|
return {
|
|
16
16
|
apiParam:{
|
|
17
|
-
actionType:2,
|
|
17
|
+
actionType: 2, originalTraId: "1542328321501380609", pageStyle: 2, pageTitle: "新增代收款", pageOnly: true
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
},
|
|
@@ -180,7 +180,7 @@ const api = {
|
|
|
180
180
|
}
|
|
181
181
|
|
|
182
182
|
if (data.rtnCode === Enum.ReturnCode.Successful) {
|
|
183
|
-
if (data.rtnMsg) {
|
|
183
|
+
if (data.rtnMsg && common.getDataDrivenOpts().showRequestSuccessMessage) {
|
|
184
184
|
if (data.MsgAlertStyle && data.MsgAlertStyle == Enum.MessageAlertStyle.Dialog) {
|
|
185
185
|
common.confirm(data.rtnMsg, '信息', { confirmButtonText: '确定', flagShowcCancelButton: '0' });
|
|
186
186
|
}
|
|
@@ -1,10 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div
|
|
3
|
-
style="width: 100%"
|
|
4
|
-
v-if="model !== null"
|
|
5
|
-
class="block ct-file"
|
|
6
|
-
:class="[model.attrs.size ? 'ct-checkbox-' + model.attrs.size : '']"
|
|
7
|
-
>
|
|
2
|
+
<div style="width: 100%" v-if="model !== null" class="block ct-file" :class="[model.attrs.size ? 'ct-checkbox-' + model.attrs.size : '']">
|
|
8
3
|
<el-upload
|
|
9
4
|
:class="disableUpload ? 'ct-upload-display-none' : ''"
|
|
10
5
|
:disabled="model.lock"
|
|
@@ -32,73 +27,36 @@
|
|
|
32
27
|
</div>
|
|
33
28
|
<div slot="file" slot-scope="{ file }" :title="file.fileName">
|
|
34
29
|
<div class="cover-list-item">
|
|
35
|
-
<el-image
|
|
36
|
-
fit="fill"
|
|
37
|
-
:src="file.url"
|
|
38
|
-
style="width: 100px; height: 100px"
|
|
39
|
-
:z-index="previewZIndex"
|
|
40
|
-
@click="viewerfile(file)"
|
|
41
|
-
>
|
|
30
|
+
<el-image fit="fill" :src="file.url" style="width: 100px; height: 100px" :z-index="previewZIndex" @click="viewerfile(file)">
|
|
42
31
|
</el-image>
|
|
43
|
-
<span
|
|
44
|
-
class="cover-list-item-span-delete"
|
|
45
|
-
v-if="!model.lock && file.rightDel"
|
|
46
|
-
>
|
|
32
|
+
<span class="cover-list-item-span-delete" v-if="!model.lock && file.rightDel">
|
|
47
33
|
<i class="el-icon-delete" @click="handleRemove(file)"></i>
|
|
48
34
|
</span>
|
|
49
|
-
<span
|
|
50
|
-
class="cover-list-item-span"
|
|
51
|
-
v-if="model.lock || model.paramName"
|
|
52
|
-
>
|
|
35
|
+
<span class="cover-list-item-span" v-if="model.lock || model.paramName">
|
|
53
36
|
<!--锁定-->
|
|
54
37
|
<span v-if="model.lock || !file.rightEdit" class="el-dropdown-link">
|
|
55
|
-
<span style="width: 80px; height: 26px; display: inline-flex"
|
|
56
|
-
> {{ file.mediaLabelName }}</span
|
|
57
|
-
>
|
|
38
|
+
<span style="width: 80px; height: 26px; display: inline-flex"> {{ file.mediaLabelName }}</span>
|
|
58
39
|
</span>
|
|
59
40
|
<!--复杂分类-->
|
|
60
|
-
<span
|
|
61
|
-
|
|
62
|
-
class="el-
|
|
63
|
-
@click="classifyFormClickHandle(file)"
|
|
64
|
-
>
|
|
65
|
-
<span style="width: 80px; height: 26px; display: inline-flex"
|
|
66
|
-
> {{ file.mediaLabelName }}</span
|
|
67
|
-
><i class="el-icon-arrow-down el-icon--right"></i>
|
|
41
|
+
<span v-else-if="model.isComplexClassify" class="el-dropdown-link" @click="classifyFormClickHandle(file)">
|
|
42
|
+
<span style="width: 80px; height: 26px; display: inline-flex"> {{ file.mediaLabelName }}</span>
|
|
43
|
+
<i class="el-icon-arrow-down el-icon--right"></i>
|
|
68
44
|
</span>
|
|
69
45
|
<!--简单分类-->
|
|
70
|
-
<el-dropdown
|
|
71
|
-
v-else
|
|
72
|
-
class="el-upload-list__item-preview"
|
|
73
|
-
trigger="click"
|
|
74
|
-
placement="top"
|
|
75
|
-
@command="classifySelectedClickHandle"
|
|
76
|
-
>
|
|
46
|
+
<el-dropdown v-else class="el-upload-list__item-preview" trigger="click" placement="top" @command="classifySelectedClickHandle">
|
|
77
47
|
<span class="el-dropdown-link" @click="classifyClickHandle">
|
|
78
|
-
<span style="width: 80px; height: 26px; display: inline-flex"
|
|
79
|
-
|
|
80
|
-
><i class="el-icon-arrow-down el-icon--right"></i>
|
|
48
|
+
<span style="width: 80px; height: 26px; display: inline-flex"> {{ file.mediaLabelName }}</span>
|
|
49
|
+
<i class="el-icon-arrow-down el-icon--right"></i>
|
|
81
50
|
</span>
|
|
82
|
-
<el-dropdown-menu
|
|
83
|
-
|
|
84
|
-
class="el-upload-list__item-preview"
|
|
85
|
-
>
|
|
86
|
-
<el-dropdown-item
|
|
87
|
-
v-for="(option, index) in model.optionModel.options"
|
|
88
|
-
:key="index"
|
|
89
|
-
:command="{ option: option, file: file }"
|
|
90
|
-
>
|
|
51
|
+
<el-dropdown-menu slot="dropdown" class="el-upload-list__item-preview">
|
|
52
|
+
<el-dropdown-item v-for="(option, index) in model.optionModel.options" :key="index" :command="{ option: option, file: file }">
|
|
91
53
|
{{ option[model.optionModel.optionAttrs.label] }}
|
|
92
54
|
</el-dropdown-item>
|
|
93
55
|
</el-dropdown-menu>
|
|
94
56
|
</el-dropdown>
|
|
95
57
|
</span>
|
|
96
58
|
</div>
|
|
97
|
-
<el-progress
|
|
98
|
-
type="circle"
|
|
99
|
-
v-if="file.progressFlag"
|
|
100
|
-
:percentage="file.loadProgress"
|
|
101
|
-
></el-progress>
|
|
59
|
+
<el-progress type="circle" v-if="file.progressFlag" :percentage="file.loadProgress"></el-progress>
|
|
102
60
|
</div>
|
|
103
61
|
</el-upload>
|
|
104
62
|
</div>
|
|
@@ -149,17 +107,14 @@ export default {
|
|
|
149
107
|
},
|
|
150
108
|
//删除
|
|
151
109
|
handleRemove(file) {
|
|
152
|
-
this.$common
|
|
153
|
-
.confirm("确定删除该附件?", "提示", {
|
|
110
|
+
this.$common.confirm("确定删除该附件?", "提示", {
|
|
154
111
|
confirmButtonText: "确定",
|
|
155
112
|
cancelButtonText: "取消",
|
|
156
113
|
//type: 'warning'
|
|
157
|
-
})
|
|
158
|
-
.then(() => {
|
|
114
|
+
}).then(() => {
|
|
159
115
|
this.model.deleteFile(file, false);
|
|
160
116
|
this.selfValidExcute("remove");
|
|
161
|
-
})
|
|
162
|
-
.catch(() => {});
|
|
117
|
+
}).catch(() => {});
|
|
163
118
|
},
|
|
164
119
|
handlePictureCardPreview(file) {
|
|
165
120
|
if (this.$common.isAssetTypeAnImage(this.getSuffix(file))) {
|
|
@@ -302,7 +257,8 @@ export default {
|
|
|
302
257
|
if (this.model.max) {
|
|
303
258
|
if (this.model.getfileListLength() >= this.model.max) {
|
|
304
259
|
this.disableUpload = true;
|
|
305
|
-
}
|
|
260
|
+
}
|
|
261
|
+
else {
|
|
306
262
|
this.disableUpload = false;
|
|
307
263
|
}
|
|
308
264
|
}
|
|
@@ -310,18 +266,14 @@ export default {
|
|
|
310
266
|
if (this.model.getfileListLength() < this.model.min) {
|
|
311
267
|
//change时需要判断有没有上传图片如果没有图片则不提示
|
|
312
268
|
if (eventName == "change" && this.model.getfileListLength() > 0) {
|
|
313
|
-
this.validMessage =
|
|
314
|
-
"附件数量还差" +
|
|
315
|
-
(parseInt(this.model.min) - this.model.getfileListLength()) +
|
|
316
|
-
"张";
|
|
269
|
+
this.validMessage = "附件数量还差" + (parseInt(this.model.min) - this.model.getfileListLength()) + "张";
|
|
317
270
|
this.valid = false;
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
(parseInt(this.model.min) - this.model.getfileListLength()) +
|
|
322
|
-
"张";
|
|
271
|
+
}
|
|
272
|
+
else if (eventName == "valid") {
|
|
273
|
+
this.validMessage = "附件数量还差" + (parseInt(this.model.min) - this.model.getfileListLength()) + "张";
|
|
323
274
|
this.valid = false;
|
|
324
|
-
}
|
|
275
|
+
}
|
|
276
|
+
else if (eventName == "remove") {
|
|
325
277
|
this.valid = true;
|
|
326
278
|
}
|
|
327
279
|
return false;
|
|
@@ -215,7 +215,6 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
215
215
|
classify.file.source.mediaLabelID = classify.option[rtn.optionModel.optionAttrs.value];
|
|
216
216
|
},
|
|
217
217
|
handleAvatarSuccess(res, file, fileList) {
|
|
218
|
-
|
|
219
218
|
if (res.rtnCode === Enum.ReturnCode.Successful) {
|
|
220
219
|
//下面的方式绑定,会有一些问题 todo 不强与页面关联
|
|
221
220
|
fileSourceList.push(res.content[0]);
|
|
@@ -240,11 +239,15 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
240
239
|
rtn.fileList = fileList;//无数据会监听不到
|
|
241
240
|
}
|
|
242
241
|
else {
|
|
242
|
+
for (let i = 0; i < fileList.length; i++) {
|
|
243
|
+
if (fileList[i].uid === file.uid) {
|
|
244
|
+
fileList.splice(i, 1);
|
|
245
|
+
}
|
|
246
|
+
}
|
|
243
247
|
Vue.prototype.$message.error(res.rtnMsg);
|
|
244
248
|
}
|
|
245
249
|
},
|
|
246
250
|
deleteFile(file, forceDelete) {
|
|
247
|
-
|
|
248
251
|
for (let i = 0; i < rtn.fileList.length; i++) {
|
|
249
252
|
if (rtn.fileList[i].uid === file.uid) {
|
|
250
253
|
if (forceDelete) {
|
|
@@ -275,7 +278,6 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
275
278
|
break;
|
|
276
279
|
}
|
|
277
280
|
}
|
|
278
|
-
console.log(rtn.fileList)
|
|
279
281
|
},
|
|
280
282
|
getFormObj() {
|
|
281
283
|
var rtnFormObj = {};
|
package/src/main.js
CHANGED
|
@@ -13,9 +13,9 @@ Vue.use(ElementUI, { size: 'mini'});
|
|
|
13
13
|
Vue.config.productionTip = false;
|
|
14
14
|
Vue.use(centaline, {
|
|
15
15
|
// baseUrl: "http://10.88.22.46:7070/v1/form/router",
|
|
16
|
-
baseUrl: "http://10.88.23.22:9999/v1/form/router",
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
// baseUrl: "http://10.88.23.22:9999/v1/form/router",
|
|
17
|
+
baseUrl: "http://10.88.22.69:8080/",
|
|
18
|
+
flagRouterSelf: true,
|
|
19
19
|
zindex: 999,
|
|
20
20
|
showRequestErrorMessage: true,
|
|
21
21
|
handler: {
|
|
@@ -39,7 +39,7 @@ Vue.use(centaline, {
|
|
|
39
39
|
// 获取请求头
|
|
40
40
|
getRequestHeaders: function () {
|
|
41
41
|
return {
|
|
42
|
-
oldToken: '
|
|
42
|
+
oldToken: 'f38e4a69-23f7-4c8e-b191-4028d08612d7',
|
|
43
43
|
originalRequestURL: 'http://10.88.22.67:8080',
|
|
44
44
|
EstateInfo: '{"estateId":"201703020943128D8A8FCF463E4016D6","estateName":"%E4%B8%87%E7%A7%91%E4%BA%91%E5%9F%8E"}',
|
|
45
45
|
Authorization:'Bearer eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImVjODhjOTI1LTU3OTktNDVmNy1iNDI3LWI3M2QwNGVkNWM2NSJ9.fyndFOEg4ThBHv4N2pi3pmPaWWlcD1CVPsYu0G5BKAB1hAgkL_GpOMpCZB5xdjMJLbBVomdoUjnRY7T6JSZb-g',
|