centaline-data-driven 1.1.52 → 1.1.56
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/build/centaline/webpack.centaline.conf.js +1 -1
- package/package.json +1 -1
- package/src/Form.vue +2 -2
- package/src/centaline/css/common.css +11 -0
- package/src/centaline/dynamicDetail/src/dynamicPropertyDetailOFI.vue +3 -3
- package/src/centaline/dynamicDetail/src/dynamicPropertyDetailRET.vue +4 -6
- package/src/centaline/dynamicFile/src/dynamicFile.vue +10 -5
- package/src/centaline/dynamicForm/src/dynamicForm.vue +138 -110
- package/src/centaline/dynamicL/src/dynamicL.vue +1 -1
- package/src/centaline/formData/index.js +0 -1
- package/src/centaline/imgPreview/src/imgPreview.vue +2 -2
- package/src/centaline/loader/src/ctl/File.js +4 -0
- package/src/centaline/loader/src/ctl/Form.js +17 -0
- package/src/main.js +4 -5
- 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
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div id="app-form" class="data-driven" style="width:100%;height:100%;overflow:auto">
|
|
3
|
-
<ct-form :api="'
|
|
3
|
+
<ct-form :api="'/roomtype/readDetail'" :apiParam="apiParam"></ct-form>
|
|
4
4
|
<!-- <ct-form :source="formdata.content" :apiParam="apiParam"></ct-form> -->
|
|
5
5
|
<!--:api="'FormSample/formdata'"-->
|
|
6
6
|
<!--<ct-form :source="formdata.content"></ct-form>-->
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
return {
|
|
18
18
|
apiParam: {
|
|
19
19
|
actionType: 2,
|
|
20
|
-
|
|
20
|
+
jsonData: {searchFields: {fields: []}}
|
|
21
21
|
} ,
|
|
22
22
|
}
|
|
23
23
|
},
|
|
@@ -736,3 +736,14 @@ html {
|
|
|
736
736
|
.ct-dialog_body .el-card__body{
|
|
737
737
|
padding: 0px 3px 10px 10px!important;
|
|
738
738
|
}
|
|
739
|
+
.ct-text .ct-font-size-mini{
|
|
740
|
+
padding-left: 5px!important;
|
|
741
|
+
}
|
|
742
|
+
.ct-text .ct-font-size-mini span{
|
|
743
|
+
display: inline-block;
|
|
744
|
+
margin-top: 1px;
|
|
745
|
+
color: #388cd3;
|
|
746
|
+
}
|
|
747
|
+
.lableinput .el-input__inner{
|
|
748
|
+
border: none !important;
|
|
749
|
+
}
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
|
|
34
34
|
<div class="head-but">
|
|
35
35
|
<button type="button" class="el-button f-wb el-button--default el-button--mini max-default">去出租 >></button>
|
|
36
|
-
<button type="button" class="el-button el-button--info el-button--mini max-report">
|
|
36
|
+
<button type="button" class="el-button el-button--info el-button--mini max-report rel">
|
|
37
37
|
<img src="../../../assets/dian.png" alt="" class="report">
|
|
38
38
|
<ul class="report-cont">
|
|
39
39
|
<li>举报房源</li>
|
|
@@ -753,14 +753,14 @@
|
|
|
753
753
|
}
|
|
754
754
|
.report-cont{
|
|
755
755
|
display: none;
|
|
756
|
-
width:
|
|
756
|
+
width: 115px;
|
|
757
757
|
background: #fff;
|
|
758
758
|
-webkit-box-shadow: 0 0 10px 0 rgb(0 0 0 / 15%);
|
|
759
759
|
box-shadow: 0 0 10px 0 rgb(0 0 0 / 15%);
|
|
760
760
|
border-radius: 5px;
|
|
761
761
|
list-style: none;
|
|
762
762
|
position: absolute;
|
|
763
|
-
left: -
|
|
763
|
+
left: -61px;
|
|
764
764
|
top: 26px;
|
|
765
765
|
padding: 5px 0;
|
|
766
766
|
color: #333;
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
:is="model.actionRouters[1].is" :vmodel="model.actionRouters[1]" :api="model.optionApi"></component>
|
|
39
39
|
</div>
|
|
40
40
|
<div class="mt5">
|
|
41
|
-
<button type="button" class="el-button el-button--info el-button--mini max-report"
|
|
41
|
+
<button type="button" class="el-button el-button--info el-button--mini max-report rel"
|
|
42
42
|
v-if="model.actionRoutersMoreList !== null">
|
|
43
43
|
<img src="../../../assets/dian.png" alt="" class="report">
|
|
44
44
|
<ul class="report-cont">
|
|
@@ -144,9 +144,7 @@
|
|
|
144
144
|
<div class="row-i"><span>装修:</span><span>豪装</span></div>
|
|
145
145
|
<div class="row-i"><span>租赁期:</span><span>半年</span></div>
|
|
146
146
|
<div class="row-i"><span>付款方式:</span><span>一次性全款</span></div>
|
|
147
|
-
<div class="row-i">
|
|
148
|
-
<span>可否注册公司:</span><span>是</span>
|
|
149
|
-
</div>
|
|
147
|
+
<div class="row-i"><span>可否注册公司:</span><span>是</span></div>
|
|
150
148
|
</div>
|
|
151
149
|
</div>
|
|
152
150
|
<div class="info-conten-b" v-show="allInfo">
|
|
@@ -767,14 +765,14 @@
|
|
|
767
765
|
}
|
|
768
766
|
.report-cont{
|
|
769
767
|
display: none;
|
|
770
|
-
width:
|
|
768
|
+
width: 115px;
|
|
771
769
|
background: #fff;
|
|
772
770
|
-webkit-box-shadow: 0 0 10px 0 rgb(0 0 0 / 15%);
|
|
773
771
|
box-shadow: 0 0 10px 0 rgb(0 0 0 / 15%);
|
|
774
772
|
border-radius: 5px;
|
|
775
773
|
list-style: none;
|
|
776
774
|
position: absolute;
|
|
777
|
-
left: -
|
|
775
|
+
left: -61px;
|
|
778
776
|
top: 26px;
|
|
779
777
|
padding: 5px 0;
|
|
780
778
|
color: #333;
|
|
@@ -13,9 +13,9 @@
|
|
|
13
13
|
:headers="headers"
|
|
14
14
|
:before-upload="beforeUploadProcess"
|
|
15
15
|
:on-success="handleAvatarSuccess"
|
|
16
|
-
|
|
16
|
+
>
|
|
17
17
|
<i slot="default" class="el-icon-plus"></i>
|
|
18
|
-
<div slot="tip" class="el-upload__tip errorMessage" v-show="!
|
|
18
|
+
<div slot="tip" class="el-upload__tip errorMessage" v-show="!imgValid">{{validMessage}}</div>
|
|
19
19
|
<div slot="file" slot-scope="{file}" :title="file.fileName">
|
|
20
20
|
<div class="cover-list-item">
|
|
21
21
|
<el-image fit="fill" :src="file.url"
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
<span class="cover-list-item-span-delete" v-if="!model.lock && file.rightDel">
|
|
28
28
|
<i class="el-icon-delete" @click="handleRemove(file)"></i>
|
|
29
29
|
</span>
|
|
30
|
-
<span class="cover-list-item-span">
|
|
30
|
+
<span class="cover-list-item-span" v-if="model.paramName">
|
|
31
31
|
<!--锁定-->
|
|
32
32
|
<span v-if="model.lock || !file.rightEdit" class="el-dropdown-link">
|
|
33
33
|
{{file.mediaLabelName}}
|
|
@@ -65,6 +65,7 @@
|
|
|
65
65
|
},
|
|
66
66
|
data() {
|
|
67
67
|
return {
|
|
68
|
+
imgValid:true,
|
|
68
69
|
};
|
|
69
70
|
},
|
|
70
71
|
computed: {
|
|
@@ -107,7 +108,7 @@
|
|
|
107
108
|
},
|
|
108
109
|
handlePictureCardPreview(file) {
|
|
109
110
|
if (this.$common.isAssetTypeAnImage(this.getSuffix(file))) {
|
|
110
|
-
//this.$openPreview([file.mediaUrl]);
|
|
111
|
+
// this.$openPreview([file.mediaUrl]);
|
|
111
112
|
}
|
|
112
113
|
else {
|
|
113
114
|
if (file.rightDownload) {
|
|
@@ -153,10 +154,14 @@
|
|
|
153
154
|
},
|
|
154
155
|
//上传之前的钩子
|
|
155
156
|
beforeUploadProcess(files) {
|
|
157
|
+
let that=this;
|
|
156
158
|
if (this.model.max) {
|
|
157
159
|
if (this.model.getfileListLength() >= this.model.max) {
|
|
158
160
|
this.validMessage = "附件最多" + this.model.max + "个";
|
|
159
|
-
this.
|
|
161
|
+
this.imgValid = false;
|
|
162
|
+
setTimeout(() => {
|
|
163
|
+
that.imgValid = true;
|
|
164
|
+
}, 3000)
|
|
160
165
|
return false;
|
|
161
166
|
}
|
|
162
167
|
}
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
</el-tabs>
|
|
34
34
|
<!--分组-->
|
|
35
35
|
<el-collapse v-else v-model="collapseActiveNames" @change="collapseHandleChange">
|
|
36
|
-
<el-collapse-item v-for="(item, index) in collapse" v-if="item.show !== false" :key="index" :title="item.label" :name="index">
|
|
36
|
+
<el-collapse-item v-for="(item, index) in collapse" v-if="item.show !== false" :key="index" :title="item.label" :name="index" :disabled="item.lock">
|
|
37
37
|
<template slot="title">
|
|
38
38
|
<i class="sign"></i>
|
|
39
39
|
{{item.label}}
|
|
@@ -167,7 +167,7 @@
|
|
|
167
167
|
}
|
|
168
168
|
else if (v.is === 'ct-group') {
|
|
169
169
|
self.collapse.push(v);
|
|
170
|
-
if (v.isExpand) {
|
|
170
|
+
if (v.lock || v.isExpand) {
|
|
171
171
|
realCollapseActiveNames.push(self.collapse.length - 1);
|
|
172
172
|
}
|
|
173
173
|
self.collapseActiveNames.push(self.collapse.length - 1);
|
|
@@ -217,6 +217,16 @@
|
|
|
217
217
|
var router = this.model.buttons.find((v) => {
|
|
218
218
|
return v.id === field.id;
|
|
219
219
|
});
|
|
220
|
+
if(router==undefined){
|
|
221
|
+
router = this.model.links.find((v) => {
|
|
222
|
+
return v.id === field.id;
|
|
223
|
+
});
|
|
224
|
+
}
|
|
225
|
+
if(router==undefined){
|
|
226
|
+
router = this.model.actionRouters.find((v) => {
|
|
227
|
+
return v.id === field.id;
|
|
228
|
+
});
|
|
229
|
+
}
|
|
220
230
|
this.clickHandler(router);
|
|
221
231
|
},
|
|
222
232
|
clickHandler(field, submitData) {
|
|
@@ -224,61 +234,139 @@
|
|
|
224
234
|
this.model.scripts.$fd = field.id;
|
|
225
235
|
this.model.scripts.$result = [];
|
|
226
236
|
|
|
227
|
-
var clickAcion = function (field) {
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
if (
|
|
237
|
+
var clickAcion = function (field) {
|
|
238
|
+
//若不是客户端方法,则直接访问接口
|
|
239
|
+
if (!field.isClientFuntion) {
|
|
240
|
+
if (field.isSubmit) {
|
|
241
|
+
let verified = true;
|
|
242
|
+
if (self.validExcute()) {
|
|
243
|
+
if (typeof field.onClick !== 'undefined') {
|
|
244
|
+
verified = self.$common.excute.call(self.model.scripts, field.onClick);
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
if (verified) {
|
|
248
|
+
//action有值,提交到后台
|
|
249
|
+
if (field.action) {
|
|
250
|
+
field.disabled = true;//提交按钮禁用
|
|
251
|
+
self.model.pageDisabled= true;
|
|
252
|
+
field.doAction(self.getFormObj(), (data) => {
|
|
253
|
+
if (data.rtnCode === 200) {
|
|
254
|
+
if (self.model.flagAlertClose) {
|
|
255
|
+
self.$common.confirm('操作成功,是否关闭本页面?', '提示', {
|
|
256
|
+
confirmButtonText: '确定',
|
|
257
|
+
cancelButtonText: '取消',
|
|
258
|
+
type: 'warning'
|
|
259
|
+
}).then(() => {
|
|
260
|
+
//如果没有弹框 则关闭tab页
|
|
261
|
+
if (self.$common.dialogList && self.$common.dialogList.List.length === 0) {
|
|
262
|
+
if (typeof self.$common.getDataDrivenOpts().handler.closeTab === 'function') {
|
|
263
|
+
self.$common.getDataDrivenOpts().handler.closeTab();
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
self.$emit('submit', { formData: self.model, responseData: data });
|
|
267
|
+
}).catch(() => {
|
|
268
|
+
self.init();
|
|
269
|
+
});
|
|
270
|
+
}
|
|
271
|
+
else {
|
|
272
|
+
self.$emit('submit', { formData: self.model, responseData: data });
|
|
273
|
+
}
|
|
274
|
+
if (self.parentModel) {
|
|
275
|
+
self.parentModel.$vue.closeTabThen(data);
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
field.disabled = false;
|
|
279
|
+
self.model.pageDisabled= false;
|
|
280
|
+
});
|
|
281
|
+
}
|
|
282
|
+
//无值,触发submit事件
|
|
283
|
+
else {
|
|
284
|
+
self.$emit('submit', { formData: self.model, responseData: {} });
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
else {
|
|
231
290
|
if (typeof field.onClick !== 'undefined') {
|
|
232
291
|
verified = self.$common.excute.call(self.model.scripts, field.onClick);
|
|
233
292
|
}
|
|
234
293
|
|
|
235
|
-
if (
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
294
|
+
if (!submitData) {
|
|
295
|
+
submitData = {};
|
|
296
|
+
var tempFormData = self.model.getFormObj();
|
|
297
|
+
field.submitFormField.forEach((v) => {
|
|
298
|
+
submitData[v] = tempFormData[v];
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
if (field.isOpenForm) {
|
|
303
|
+
var dialogOption = {
|
|
304
|
+
title: field.pageTitle,
|
|
305
|
+
pane: self.$common.getParentPane(self),
|
|
306
|
+
content: [{
|
|
307
|
+
component: 'ct-form',
|
|
308
|
+
attrs: {
|
|
309
|
+
//ssource: data.content,
|
|
310
|
+
api: field.action,
|
|
311
|
+
apiParam: field.getActionPara(submitData).para,
|
|
312
|
+
showTitle: false,
|
|
313
|
+
width: field.dialogWidth + 'px',
|
|
314
|
+
height: field.dialogHeight + 'px'
|
|
315
|
+
},
|
|
316
|
+
on: {
|
|
317
|
+
submit(ev) {
|
|
318
|
+
self.model.updateFields(ev, () => {
|
|
319
|
+
self.$refs.Fields.forEach((fd) => {
|
|
320
|
+
fd.$forceUpdate();
|
|
321
|
+
});
|
|
257
322
|
});
|
|
323
|
+
self.$common.closeDialog(dialogOption.dialog);
|
|
258
324
|
}
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
325
|
+
}
|
|
326
|
+
}]
|
|
327
|
+
};
|
|
328
|
+
self.$common.openDialog(dialogOption);
|
|
329
|
+
}
|
|
330
|
+
else if (field.isOpenList) {
|
|
331
|
+
var dialogOption = {
|
|
332
|
+
title: field.pageTitle,
|
|
333
|
+
pane: self.$common.getParentPane(self),
|
|
334
|
+
content: [{
|
|
335
|
+
component: 'ct-searchlist',
|
|
336
|
+
attrs: {
|
|
337
|
+
searchConditionApi: field.actionForSearchLayout,
|
|
338
|
+
searchDataApi: field.actionForSearch,
|
|
339
|
+
apiParam: submitData,
|
|
340
|
+
width: field.dialogWidth + 'px',
|
|
341
|
+
height: field.dialogHeight + 'px'
|
|
342
|
+
},
|
|
343
|
+
on: {
|
|
344
|
+
submit(ev) {
|
|
345
|
+
self.model.updateFields(ev, () => {
|
|
346
|
+
self.$refs.Fields.forEach((fd) => {
|
|
347
|
+
fd.$forceUpdate();
|
|
348
|
+
});
|
|
349
|
+
});
|
|
350
|
+
self.$common.closeDialog(dialogOption.dialog);
|
|
264
351
|
}
|
|
265
352
|
}
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
353
|
+
}]
|
|
354
|
+
};
|
|
355
|
+
self.$common.openDialog(dialogOption);
|
|
356
|
+
}
|
|
357
|
+
else if (field.isFormPageInTab || field.isSearchPageInTab) {// 外部框架tab页打开
|
|
358
|
+
submitData = field.getActionPara(submitData).para;
|
|
359
|
+
self.$common.getDataDrivenOpts().handler.openTab(field.action, submitData, field.pageTitle);
|
|
360
|
+
}
|
|
361
|
+
else if (field.isBrowserNewTab) {// 浏览器打开
|
|
362
|
+
submitData = field.getActionPara(submitData).para;
|
|
363
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
364
|
+
window.open(field.action + query, "_blank");
|
|
274
365
|
}
|
|
275
366
|
}
|
|
276
367
|
}
|
|
368
|
+
//执行客户端脚本
|
|
277
369
|
else {
|
|
278
|
-
if (typeof field.onClick !== 'undefined') {
|
|
279
|
-
verified = self.$common.excute.call(self.model.scripts, field.onClick);
|
|
280
|
-
}
|
|
281
|
-
|
|
282
370
|
if (!submitData) {
|
|
283
371
|
submitData = {};
|
|
284
372
|
var tempFormData = self.model.getFormObj();
|
|
@@ -286,71 +374,11 @@
|
|
|
286
374
|
submitData[v] = tempFormData[v];
|
|
287
375
|
});
|
|
288
376
|
}
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
content: [{
|
|
295
|
-
component: 'ct-form',
|
|
296
|
-
attrs: {
|
|
297
|
-
//ssource: data.content,
|
|
298
|
-
api: field.action,
|
|
299
|
-
apiParam: field.getActionPara(submitData).para,
|
|
300
|
-
showTitle: false,
|
|
301
|
-
width: field.dialogWidth + 'px',
|
|
302
|
-
height: field.dialogHeight + 'px'
|
|
303
|
-
},
|
|
304
|
-
on: {
|
|
305
|
-
submit(ev) {
|
|
306
|
-
self.model.updateFields(ev, () => {
|
|
307
|
-
self.$refs.Fields.forEach((fd) => {
|
|
308
|
-
fd.$forceUpdate();
|
|
309
|
-
});
|
|
310
|
-
});
|
|
311
|
-
self.$common.closeDialog(dialogOption.dialog);
|
|
312
|
-
}
|
|
313
|
-
}
|
|
314
|
-
}]
|
|
315
|
-
};
|
|
316
|
-
self.$common.openDialog(dialogOption);
|
|
317
|
-
}
|
|
318
|
-
else if (field.isOpenList) {
|
|
319
|
-
var dialogOption = {
|
|
320
|
-
title: field.pageTitle,
|
|
321
|
-
pane: self.$common.getParentPane(self),
|
|
322
|
-
content: [{
|
|
323
|
-
component: 'ct-searchlist',
|
|
324
|
-
attrs: {
|
|
325
|
-
searchConditionApi: field.actionForSearchLayout,
|
|
326
|
-
searchDataApi: field.actionForSearch,
|
|
327
|
-
apiParam: submitData,
|
|
328
|
-
width: field.dialogWidth + 'px',
|
|
329
|
-
height: field.dialogHeight + 'px'
|
|
330
|
-
},
|
|
331
|
-
on: {
|
|
332
|
-
submit(ev) {
|
|
333
|
-
self.model.updateFields(ev, () => {
|
|
334
|
-
self.$refs.Fields.forEach((fd) => {
|
|
335
|
-
fd.$forceUpdate();
|
|
336
|
-
});
|
|
337
|
-
});
|
|
338
|
-
self.$common.closeDialog(dialogOption.dialog);
|
|
339
|
-
}
|
|
340
|
-
}
|
|
341
|
-
}]
|
|
342
|
-
};
|
|
343
|
-
self.$common.openDialog(dialogOption);
|
|
344
|
-
}
|
|
345
|
-
else if (field.isFormPageInTab || field.isSearchPageInTab) {// 外部框架tab页打开
|
|
346
|
-
submitData = field.getActionPara(submitData).para;
|
|
347
|
-
self.$common.getDataDrivenOpts().handler.openTab(field.action, submitData, field.pageTitle);
|
|
348
|
-
}
|
|
349
|
-
else if (field.isBrowserNewTab) {// 浏览器打开
|
|
350
|
-
submitData = field.getActionPara(submitData).para;
|
|
351
|
-
let query = self.$common.objectToQueryStr(submitData);
|
|
352
|
-
window.open(field.action + query, "_blank");
|
|
353
|
-
}
|
|
377
|
+
submitData = field.getActionPara(submitData).para;
|
|
378
|
+
let title=field.pageTitle==undefined ?field.label:field.pageTitle;
|
|
379
|
+
submitData.actionType=field.actionType;
|
|
380
|
+
var fun =self.$common.getDataDrivenOpts().handler[field.action];
|
|
381
|
+
fun(submitData,title,self.model);
|
|
354
382
|
}
|
|
355
383
|
}
|
|
356
384
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
<div class="field-top">
|
|
3
3
|
<div class="ct-text" style="width:100%;display:flex" v-if="model !== null">
|
|
4
4
|
<el-input v-model="model.labelValue" v-bind="model.attrs"
|
|
5
|
-
:class="[model.showLabel?'showLabel':'',!valid?'inputError':'']"
|
|
5
|
+
:class="[model.showLabel?'showLabel':'',!valid?'inputError':'','lableinput']"
|
|
6
6
|
:type="model.showLabel? 'text':'textarea'"
|
|
7
7
|
style="flex:1" autosize :readonly="true" :disabled="model.lock" autocomplete="on">
|
|
8
8
|
<div v-if="model.showLabel && model.label" slot="prepend" class="" :class="[model.labelClass]">
|
|
@@ -231,7 +231,6 @@ const formData = {
|
|
|
231
231
|
//获取后台数据,并返回脚本。
|
|
232
232
|
execServerScript(action, object, successCallback) {
|
|
233
233
|
let formData = this;//作用域保存
|
|
234
|
-
debugger;
|
|
235
234
|
//是否是行内触发的
|
|
236
235
|
let data = this.getListField(this.form.scripts.$fd, null, null);
|
|
237
236
|
object.editMode = data ? 1 : 0;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
</template>
|
|
6
6
|
<script>
|
|
7
7
|
//该组件打包被排除(会导致包大很多),不排除的话无法使用,todo待更新
|
|
8
|
-
//import ElImageViewer from "element-ui/packages/image/src/image-viewer";
|
|
8
|
+
// import ElImageViewer from "element-ui/packages/image/src/image-viewer";
|
|
9
9
|
export default {
|
|
10
10
|
name: 'ctImgPreview',
|
|
11
11
|
data() {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
};
|
|
16
16
|
},
|
|
17
17
|
components: {
|
|
18
|
-
//ElImageViewer
|
|
18
|
+
// ElImageViewer
|
|
19
19
|
},
|
|
20
20
|
methods: {
|
|
21
21
|
closeViewer() {
|
|
@@ -27,6 +27,7 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
27
27
|
},
|
|
28
28
|
_fileList: [],
|
|
29
29
|
get fileList() {
|
|
30
|
+
debugger
|
|
30
31
|
if (this._fileList.length !== 0) {
|
|
31
32
|
return rtn._fileList;
|
|
32
33
|
}
|
|
@@ -41,6 +42,7 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
41
42
|
return rtn._fileList;
|
|
42
43
|
},
|
|
43
44
|
getfileListLength() {
|
|
45
|
+
debugger;
|
|
44
46
|
return rtn.fileList.length;
|
|
45
47
|
},
|
|
46
48
|
optionModel: {
|
|
@@ -210,6 +212,7 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
210
212
|
classify.file.source.mediaLabelID = classify.option[rtn.optionModel.optionAttrs.value];
|
|
211
213
|
},
|
|
212
214
|
handleAvatarSuccess(res, file, fileList) {
|
|
215
|
+
debugger;
|
|
213
216
|
if (res.rtnCode === Enum.ReturnCode.Successful) {
|
|
214
217
|
//下面的方式绑定,会有一些问题 todo 不强与页面关联
|
|
215
218
|
fileSourceList.push(res.content[0]);
|
|
@@ -238,6 +241,7 @@ const box = function (source, fileSourceList, router, optionApi) {
|
|
|
238
241
|
}
|
|
239
242
|
},
|
|
240
243
|
deleteFile(file, forceDelete) {
|
|
244
|
+
debugger;
|
|
241
245
|
for (let i = 0; i < rtn.fileList.length; i++) {
|
|
242
246
|
if (rtn.fileList[i].uid === file.uid) {
|
|
243
247
|
if (forceDelete) {
|
|
@@ -118,6 +118,23 @@ const Form = function (source, callBack, apiParam, failCallBack, isFormList) {
|
|
|
118
118
|
return rtn._links;
|
|
119
119
|
}
|
|
120
120
|
},
|
|
121
|
+
_actionRouters: null,
|
|
122
|
+
get actionRouters() {
|
|
123
|
+
if (rtn._actionRouters !== null) {
|
|
124
|
+
return rtn._actionRouters;
|
|
125
|
+
}
|
|
126
|
+
else {
|
|
127
|
+
rtn._actionRouters = [];
|
|
128
|
+
if (source.actionRouters) {
|
|
129
|
+
source.actionRouters.forEach((v) => {
|
|
130
|
+
var button = Router(v);
|
|
131
|
+
button.is = "ct-btn";
|
|
132
|
+
rtn._actionRouters.push(button);
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
return rtn._actionRouters;
|
|
136
|
+
}
|
|
137
|
+
},
|
|
121
138
|
get optionApi() {
|
|
122
139
|
return source.parameterAction;
|
|
123
140
|
},
|
package/src/main.js
CHANGED
|
@@ -12,7 +12,7 @@ Vue.use(ElementUI, { size: 'mini'});
|
|
|
12
12
|
// 关闭生产模式下给出的提示
|
|
13
13
|
Vue.config.productionTip = false;
|
|
14
14
|
Vue.use(centaline, {
|
|
15
|
-
baseUrl: 'http://10.88.22.
|
|
15
|
+
baseUrl: 'http://10.88.22.67:9999/v1/form/router',
|
|
16
16
|
zindex: 999,
|
|
17
17
|
showRequestErrorMessage: true,
|
|
18
18
|
handler: {
|
|
@@ -27,10 +27,9 @@ Vue.use(centaline, {
|
|
|
27
27
|
// 获取请求头
|
|
28
28
|
getRequestHeaders: function () {
|
|
29
29
|
return {
|
|
30
|
-
Authorization: 'Bearer eyJhbGciOiJIUzUxMiJ9.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
originalRequestURL: 'http://localhost:8080'
|
|
30
|
+
Authorization: 'Bearer eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6IjFiNTBiODcyLTdhZDAtNDIzZC05MDBhLTU1NzUwOTA0OTMyNSJ9.yQA99wDa3a-dZKSemFOrWZxyKZ6NtWmYVehf10OSUK8eO8Par7aZqboxCNMfEjIlXDGu5NH9u0KFcHQ7_17YMg',
|
|
31
|
+
originalRequestURL: 'http://10.88.22.67:9999',
|
|
32
|
+
EstateInfo: '{"estateId":"201509230915485D942241BBA30FF49F","estateName":"A-%E7%88%B1%E7%90%B4%E6%B5%B7B%E7%BB%84"}'
|
|
34
33
|
};
|
|
35
34
|
},
|
|
36
35
|
// 请求完成事件,可判断是否登录过期执行响应操作
|