centaline-data-driven 1.2.58 → 1.2.61
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/centaline/css/ccai.css +4 -0
- package/src/centaline/css/max.css +6 -0
- package/src/centaline/dynamicBtn/src/dynamicBtn.vue +10 -8
- package/src/centaline/dynamicDetail/src/dynamicContactList.vue +9 -5
- package/src/centaline/dynamicDetail/src/dynamicDetail.vue +3 -2
- package/src/centaline/dynamicDetail/src/dynamicPropertyDetailRET.vue +34 -6
- package/src/centaline/dynamicDetail/src/dynamicPropertySimpleDetailRET.vue +4 -4
- package/src/centaline/dynamicFile/src/dynamicFile.vue +9 -0
- package/src/centaline/dynamicSearchList/src/dynamicSearchTable.vue +1 -0
- package/src/centaline/dynamicSw/src/dynamicSw.vue +1 -1
- package/src/centaline/loader/src/ctl/ContactList.js +20 -4
- package/src/centaline/loader/src/ctl/Detail.js +1 -2
- package/src/centaline/loader/src/ctl/Router.js +3 -0
- package/src/centaline/loader/src/ctl/SearchTable.js +0 -1
- package/wwwroot/static/centaline/centaline-data-driven.js +3 -3
- package/wwwroot/static/centaline/centaline-data-driven.js.map +1 -1
package/package.json
CHANGED
|
@@ -34,31 +34,31 @@
|
|
|
34
34
|
<div>{{model.label}}</div>
|
|
35
35
|
<div style="color:red;font-weight:700;">{{model.subText}}</div>
|
|
36
36
|
</el-button>
|
|
37
|
-
<el-button v-else-if="model.isCallTel"
|
|
37
|
+
<el-button v-else-if="model.isCallTel" class="max"
|
|
38
38
|
:type="model.isHyperLink ? 'text' : 'primary'"
|
|
39
39
|
v-bind="model.attrs" @click="clickHandle"
|
|
40
40
|
:style="{color:model.textColor,backgroundColor:model.imgUrl?'transparent':model.bgColor,borderColor:model.imgUrl?'transparent':model.borderColor,padding:model.imgUrl?'0px':null}"
|
|
41
41
|
:icon="model.icon"
|
|
42
42
|
:disabled="model.disabled || model.locked">
|
|
43
|
-
<el-popover
|
|
43
|
+
<el-popover
|
|
44
44
|
class="Stats-popover" :popper-class="'el-popoverCallTel'" :placement="option.placement?option.placement:'left'"
|
|
45
45
|
v-model="visible" :trigger="option.trigger?option.trigger:''">
|
|
46
46
|
<div style="border-bottom:none">
|
|
47
47
|
<div style="color: #388cd3;text-align: center;">{{message}}</div>
|
|
48
48
|
<img v-show="qrCode" :src="qrCode" style="margin-top: 5px;" :style="{'width':width+'px','height':height+'px'}" />
|
|
49
49
|
</div>
|
|
50
|
-
<img v-if="model.imgUrl" slot="reference" :title="model.label" :src="tellImgUrl?tellImgUrl:model.imgUrl" height="
|
|
50
|
+
<img v-if="model.imgUrl" slot="reference" :title="model.label" :src="tellImgUrl?tellImgUrl:model.imgUrl" :height="model.buttonHeight+'px'" />
|
|
51
51
|
<span v-else slot="reference">{{model.label}}</span>
|
|
52
52
|
</el-popover>
|
|
53
53
|
</el-button>
|
|
54
|
-
<el-button v-else
|
|
54
|
+
<el-button v-else class="max"
|
|
55
55
|
:type="model.isHyperLink ? 'text' : 'primary'"
|
|
56
56
|
v-bind="model.attrs" @click="$emit('click',model)"
|
|
57
57
|
:style="{color:model.textColor,backgroundColor:model.imgUrl?'transparent':model.bgColor,borderColor:model.imgUrl?'transparent':model.borderColor,padding:model.imgUrl?'0px':null}"
|
|
58
58
|
:icon="model.icon"
|
|
59
59
|
:disabled="model.disabled || model.locked">
|
|
60
|
-
<img v-if="model.imgUrl" :title="model.label" :src="model.imgUrl" height="
|
|
61
|
-
|
|
60
|
+
<img v-if="model.imgUrl" :title="model.label" :src="model.imgUrl" :height="model.buttonHeight+'px'"/>
|
|
61
|
+
<span v-else>{{model.label}}</span>
|
|
62
62
|
</el-button>
|
|
63
63
|
</template>
|
|
64
64
|
<script>
|
|
@@ -69,6 +69,8 @@
|
|
|
69
69
|
vmodel: Object,
|
|
70
70
|
fileData: Object,
|
|
71
71
|
optionApi:String,
|
|
72
|
+
rowData: Object,
|
|
73
|
+
rowindex:Number,
|
|
72
74
|
},
|
|
73
75
|
mixins: [dynamicElement],
|
|
74
76
|
data: function () {
|
|
@@ -82,7 +84,7 @@
|
|
|
82
84
|
option: {
|
|
83
85
|
isHidden: true,//是否开启操作栏隐藏设置,默认开启
|
|
84
86
|
showNum: 3,//如果isHidden为true时,个数大于3就会隐藏,默认是3
|
|
85
|
-
appendId: '
|
|
87
|
+
appendId: '',//将浮动栏添加到对应id或者class节点中。或者.xxx。传空字符串是添加到body中。
|
|
86
88
|
trigger: 'manual',//触发方式,传值可查看Popper UI组件trigger属性
|
|
87
89
|
placement: 'bottom-start',//方向,传值可查看Popper UI组件placement属性
|
|
88
90
|
},
|
|
@@ -143,7 +145,7 @@
|
|
|
143
145
|
this.tellImgUrl='';
|
|
144
146
|
}
|
|
145
147
|
else{
|
|
146
|
-
this.$emit('click',this.model);
|
|
148
|
+
this.$emit('click',this.model,this.rowData,this.rowindex);
|
|
147
149
|
}
|
|
148
150
|
}
|
|
149
151
|
else{
|
|
@@ -91,9 +91,12 @@
|
|
|
91
91
|
</ct-tablecurrency>
|
|
92
92
|
</div>
|
|
93
93
|
<!--可点击的列-->
|
|
94
|
-
<
|
|
95
|
-
|
|
96
|
-
|
|
94
|
+
<div v-else-if="column.routers" :class="column.autoRowHeight ? 'lineFeedCell':'cell'" style="display: flex;">
|
|
95
|
+
<component v-for="(router, i) in column.routers" :key="i" :ref="'router'+router.id+rowindex" :rowData="row" :rowindex="rowindex"
|
|
96
|
+
v-if="!router.rightField || !row[router.rightField] || row[router.rightField] == 1"
|
|
97
|
+
:is="router.is" :vmodel="router" :api="model.optionApi" @click="rolRouterClickHandler">
|
|
98
|
+
</component>
|
|
99
|
+
</div>
|
|
97
100
|
<!--正常的列-->
|
|
98
101
|
<div v-else-if="typeof column.template === 'undefined'" :class="column.autoRowHeight ? 'lineFeedCell':'cell'">
|
|
99
102
|
{{row.rowHiddenColumns && row.rowHiddenColumns.includes(column.id)?"":row[column.id]}}
|
|
@@ -263,7 +266,8 @@
|
|
|
263
266
|
|
|
264
267
|
return true;
|
|
265
268
|
},
|
|
266
|
-
rolRouterClickHandler(field, rowData) {
|
|
269
|
+
rolRouterClickHandler(field, rowData,rowindex) {
|
|
270
|
+
field.rowindex=rowindex;
|
|
267
271
|
var submitData = {};
|
|
268
272
|
field.submitListField.forEach((k) => {
|
|
269
273
|
submitData[k] = rowData[k];
|
|
@@ -401,7 +405,7 @@
|
|
|
401
405
|
self.$forceUpdate();
|
|
402
406
|
}
|
|
403
407
|
else if(field.actionType===19){
|
|
404
|
-
self.$refs['router'+field.id][0].callTelClick(data);
|
|
408
|
+
self.$refs['router'+field.id+field.rowindex][0].callTelClick(data);
|
|
405
409
|
}
|
|
406
410
|
})
|
|
407
411
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<ct-PropertyDetailOFI :api="api" :apiParam="apiParam" class="ct-PropertyDetailOFI"
|
|
4
|
-
<ct-PropertyDetailRET :api="api" :apiParam="apiParam" class="ct-PropertyDetailRET"
|
|
3
|
+
<ct-PropertyDetailOFI :api="api" :apiParam="apiParam" :parentModel="parentModel" class="ct-PropertyDetailOFI" v-if="pageType=='PropertyDetailOFI'"></ct-PropertyDetailOFI>
|
|
4
|
+
<ct-PropertyDetailRET :api="api" :apiParam="apiParam" :parentModel="parentModel" class="ct-PropertyDetailRET" v-if="pageType=='PropertyDetailRET'"></ct-PropertyDetailRET>
|
|
5
5
|
<ct-PropertySimpleDetailRET :api="api" :apiParam="apiParam" :selectIndex="selectIndex" :rowCount="rowCount" class="ct-PropertySimpleDetailRET"
|
|
6
6
|
@clickNextHandler="clickNextHandler" @clickPrevHandler="clickPrevHandler" @simpleRouterclickHandler="simpleRouterclickHandler"
|
|
7
7
|
v-if="pageType=='PropertySimpleDetailRET'" @closeSideHandler="closeSideHandler"></ct-PropertySimpleDetailRET>
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
vmodel: Object,
|
|
24
24
|
api: String,
|
|
25
25
|
apiParam: Object,
|
|
26
|
+
parentModel: Object,
|
|
26
27
|
pageType: String,
|
|
27
28
|
selectIndex:Number,
|
|
28
29
|
rowCount:Number,
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
<div>
|
|
30
30
|
<component v-if="model.otherTradeActionRouter!==null" v-bind="model.otherTradeActionRouter" class="max-default"
|
|
31
31
|
:is="model.otherTradeActionRouter.is" :vmodel="model.otherTradeActionRouter" :api="model.optionApi" @click="fieldClickHandler(model.otherTradeActionRouter,$event)"></component>
|
|
32
|
-
<img src="../../../assets/T.png" alt="" style="width: 26px;height: 26px;vertical-align: bottom;margin-left:11px">
|
|
33
|
-
<img src="../../../assets/B.png" alt="" style="width: 26px;height: 26px;vertical-align: bottom;margin-left:8px">
|
|
32
|
+
<img :class="{'domDisabled':parentModel && parentModel.selectIndex<=0}" @click="clickPrevHandler" src="../../../assets/T.png" alt="" style="width: 26px;height: 26px;vertical-align: bottom;margin-left:11px;cursor: pointer">
|
|
33
|
+
<img :class="{'domDisabled':parentModel && parentModel.listData && parentModel.selectIndex===parentModel.listData.length-1}" @click="clickNextHandler" src="../../../assets/B.png" alt="" style="width: 26px;height: 26px;vertical-align: bottom;margin-left:8px;cursor: pointer">
|
|
34
34
|
</div>
|
|
35
35
|
<div class="mt5">
|
|
36
36
|
<component class="max-report w93" v-if="model.actionRouters!==null && model.actionRouters[0]!==null"
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
</div>
|
|
139
139
|
</div>
|
|
140
140
|
<div class="contacts-info base-box">
|
|
141
|
-
<ct-contactList v-if="model.contactApiRouter!==null" :apiRouter="model.contactApiRouter" ></ct-contactList>
|
|
141
|
+
<ct-contactList v-if="model.contactApiRouter!==null" :apiRouter="model.contactApiRouter" :key="'contact'+refershKey" ></ct-contactList>
|
|
142
142
|
</div>
|
|
143
143
|
<div class="tablist-info base-box">
|
|
144
144
|
<div class="details-tabs-box">
|
|
@@ -146,7 +146,7 @@
|
|
|
146
146
|
<el-tab-pane v-for="(col, index) in model.tags1" :key="col.appID"
|
|
147
147
|
:index="index.toString()" :name="index.toString()" :label="col.appName"></el-tab-pane>
|
|
148
148
|
</el-tabs>
|
|
149
|
-
<ct-searchlist v-if="model.searchConditionApiTags1" :key="
|
|
149
|
+
<ct-searchlist v-if="model.searchConditionApiTags1" :key="'list'+listKey.toString()+refershKey"
|
|
150
150
|
:apiParam="model.paramDataTags1" :flagFocus="false"
|
|
151
151
|
:searchConditionApi="model.searchConditionApiTags1"
|
|
152
152
|
:searchDataApi="model.searchDataApiTags1"></ct-searchlist>
|
|
@@ -301,6 +301,7 @@
|
|
|
301
301
|
vmodel: Object,
|
|
302
302
|
api: String,
|
|
303
303
|
apiParam: Object,
|
|
304
|
+
parentModel: Object,
|
|
304
305
|
},
|
|
305
306
|
data() {
|
|
306
307
|
return {
|
|
@@ -313,7 +314,9 @@
|
|
|
313
314
|
],
|
|
314
315
|
},
|
|
315
316
|
allInfo: false,
|
|
316
|
-
allIn:false,
|
|
317
|
+
allIn:false,
|
|
318
|
+
refershKey:0,
|
|
319
|
+
listKey:0,
|
|
317
320
|
}
|
|
318
321
|
},
|
|
319
322
|
mounted() {
|
|
@@ -340,6 +343,7 @@
|
|
|
340
343
|
var self = this;
|
|
341
344
|
this.model = data;
|
|
342
345
|
this.model.$vue = self;
|
|
346
|
+
this.refershKey=this.refershKey+1;
|
|
343
347
|
this.loadFields();
|
|
344
348
|
if(this.model.tags2 && this.model.tags2[0]){
|
|
345
349
|
this.model.getTags2List(0);
|
|
@@ -429,7 +433,7 @@
|
|
|
429
433
|
let i=key.index;
|
|
430
434
|
this.model.activeIndex1=i;
|
|
431
435
|
if(this.model.tags1 && this.model.tags1[i]){
|
|
432
|
-
this.
|
|
436
|
+
this.listKey=this.listKey+1;
|
|
433
437
|
this.model.searchConditionApiTags1=this.model.tags1[i].searchConditionApiUrl||'';
|
|
434
438
|
this.model.searchDataApiTags1=this.model.tags1[i].searchDataApiUrl||'';
|
|
435
439
|
this.model.paramDataTags1=this.model.tags1[i].paramData||'';
|
|
@@ -591,6 +595,30 @@
|
|
|
591
595
|
clickAcion(field,submitData);
|
|
592
596
|
}
|
|
593
597
|
},
|
|
598
|
+
clickNextHandler() {
|
|
599
|
+
if(this.parentModel){
|
|
600
|
+
let oldValue=this.parentModel.listData[this.parentModel.selectIndex][this.parentModel.primaryKey];
|
|
601
|
+
this.parentModel.$vue.rowKeyDownHandle(null,1);
|
|
602
|
+
let newValue=this.parentModel.listData[this.parentModel.selectIndex][this.parentModel.primaryKey];
|
|
603
|
+
if(oldValue!==newValue){
|
|
604
|
+
let parm=this.apiParam;
|
|
605
|
+
parm[this.parentModel.primaryKey]=newValue;
|
|
606
|
+
this.loaderObj.Detail(this.api,parm, this.load);
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
},
|
|
610
|
+
clickPrevHandler() {
|
|
611
|
+
if(this.parentModel){
|
|
612
|
+
let oldValue=this.parentModel.listData[this.parentModel.selectIndex][this.parentModel.primaryKey];
|
|
613
|
+
this.parentModel.$vue.rowKeyDownHandle(null,-1);
|
|
614
|
+
let newValue=this.parentModel.listData[this.parentModel.selectIndex][this.parentModel.primaryKey];
|
|
615
|
+
if(oldValue!==newValue){
|
|
616
|
+
let parm=this.apiParam;
|
|
617
|
+
parm[this.parentModel.primaryKey]=newValue;
|
|
618
|
+
this.loaderObj.Detail(this.api,parm, this.load);
|
|
619
|
+
}
|
|
620
|
+
}
|
|
621
|
+
},
|
|
594
622
|
}
|
|
595
623
|
}
|
|
596
624
|
</script>
|
|
@@ -223,10 +223,10 @@
|
|
|
223
223
|
let i=key.index;
|
|
224
224
|
this.model.activeIndex1=i;
|
|
225
225
|
if(this.model.tags1 && this.model.tags1[i]){
|
|
226
|
-
this.model.searchlistKey=this.model.searchlistKey+1;
|
|
227
|
-
this.model.searchConditionApiTags1=this.model.tags1[i].searchConditionApiUrl||'';
|
|
228
|
-
this.model.searchDataApiTags1=this.model.tags1[i].searchDataApiUrl||'';
|
|
229
|
-
this.model.paramDataTags1=this.model.tags1[i].paramData||'';
|
|
226
|
+
// this.model.searchlistKey=this.model.searchlistKey+1;
|
|
227
|
+
// this.model.searchConditionApiTags1=this.model.tags1[i].searchConditionApiUrl||'';
|
|
228
|
+
// this.model.searchDataApiTags1=this.model.tags1[i].searchDataApiUrl||'';
|
|
229
|
+
// this.model.paramDataTags1=this.model.tags1[i].paramData||'';
|
|
230
230
|
}
|
|
231
231
|
},
|
|
232
232
|
fieldClickHandler(field) {
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
:headers="headers"
|
|
14
14
|
:before-upload="beforeUploadProcess"
|
|
15
15
|
:on-success="handleAvatarSuccess"
|
|
16
|
+
:on-error="handleAvatarError"
|
|
16
17
|
:on-progress="uploadProcess"
|
|
17
18
|
:limit="parseInt(model.max||999)"
|
|
18
19
|
:on-exceed="handleExceed">
|
|
@@ -196,6 +197,14 @@
|
|
|
196
197
|
handleAvatarSuccess(res, file, fileList) {
|
|
197
198
|
this.model.handleAvatarSuccess(res, file, fileList);
|
|
198
199
|
},
|
|
200
|
+
handleAvatarError(res, file, fileList) {
|
|
201
|
+
if(res.status===404){
|
|
202
|
+
let m=JSON.parse(res.message);
|
|
203
|
+
if(m.error){
|
|
204
|
+
this.$message.warning('path('+m.path+') '+m.error);
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
},
|
|
199
208
|
//不能共用的数据校验
|
|
200
209
|
selfValidExcute: function (eventName) {
|
|
201
210
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="field-top">
|
|
3
|
-
<div v-if="model !== null" class="ct-Sw">
|
|
3
|
+
<div v-if="model !== null" class="ccai ct-Sw">
|
|
4
4
|
<div :class="[model.showLabel?'el-input-group el-input-group--prepend':'',!valid?'inputError':'']">
|
|
5
5
|
<div v-if="model.showLabel && model.label" class="el-input-group__prepend" :class="[model.labelClass]">
|
|
6
6
|
{{model.label}}
|
|
@@ -60,8 +60,8 @@ const ContactList = function (source,para ,callBack) {
|
|
|
60
60
|
if (data.content.actionRouters) {
|
|
61
61
|
data.content.actionRouters.forEach((v) => {
|
|
62
62
|
var router = Router(v);
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
router.is = "ct-btn";
|
|
64
|
+
router.attrs = { size: "mini" }
|
|
65
65
|
rtn._actionRouter.push(router);
|
|
66
66
|
});
|
|
67
67
|
}
|
|
@@ -180,8 +180,7 @@ const ContactList = function (source,para ,callBack) {
|
|
|
180
180
|
if (col._router !== null) {
|
|
181
181
|
return col._router;
|
|
182
182
|
}
|
|
183
|
-
|
|
184
|
-
if (typeof v.routerKey !== "undefined") {
|
|
183
|
+
if (typeof v.routerKey !== "undefined" && v.routerKey && v.routerKey.indexOf(',')===-1) {
|
|
185
184
|
let router = rtn.actionRouter.find(b => {
|
|
186
185
|
return b.id === v.routerKey;
|
|
187
186
|
});
|
|
@@ -189,6 +188,23 @@ const ContactList = function (source,para ,callBack) {
|
|
|
189
188
|
}
|
|
190
189
|
return null;
|
|
191
190
|
},
|
|
191
|
+
_routers: null,
|
|
192
|
+
get routers() {
|
|
193
|
+
if (col._routers !== null) {
|
|
194
|
+
return col._routers;
|
|
195
|
+
}
|
|
196
|
+
if (typeof v.routerKey !== "undefined" && v.routerKey) {
|
|
197
|
+
col._routers=[];
|
|
198
|
+
v.routerKey.split(',').forEach((v) => {
|
|
199
|
+
let router = rtn.actionRouter.find(b => {
|
|
200
|
+
return b.id === v;
|
|
201
|
+
});
|
|
202
|
+
col._routers.push(router);
|
|
203
|
+
});
|
|
204
|
+
return col._routers;
|
|
205
|
+
}
|
|
206
|
+
return null;
|
|
207
|
+
},
|
|
192
208
|
//是否高度自适应
|
|
193
209
|
get autoRowHeight() {
|
|
194
210
|
return v.autoRowHeight;
|
|
@@ -106,7 +106,6 @@ const SearchTable = function (data, callBack, searchModel, flagSearch, defaultSe
|
|
|
106
106
|
if (col._router !== null) {
|
|
107
107
|
return col._router;
|
|
108
108
|
}
|
|
109
|
-
//todo
|
|
110
109
|
if (typeof v.routerKey !== "undefined") {
|
|
111
110
|
let router = rtn.actionRouter.find(b => {
|
|
112
111
|
return b.id === v.routerKey;
|