centaline-data-driven-v3 0.0.69 → 0.0.70

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "centaline-data-driven-v3",
3
- "version": "0.0.69",
3
+ "version": "0.0.70",
4
4
  "private": false,
5
5
  "description": "centaline-data-driven-v3",
6
6
  "main": "dist/centaline-data-driven-v3.umd.js",
@@ -167,7 +167,7 @@ function handleCompositionEnd() {
167
167
  }
168
168
  //弹出选择列表
169
169
  function popupSearchListHandle() {
170
- emit('popupSearchList', false, model, model.value.moreActionRouter, (optionArr) => {
170
+ emit('popupSearchList', !model.value.multiple, model, model.value.moreActionRouter, (optionArr) => {
171
171
  selectOptionArr(optionArr);
172
172
  });
173
173
  }
@@ -74,9 +74,6 @@
74
74
  </el-dropdown>
75
75
  </span>
76
76
 
77
-
78
-
79
-
80
77
  <template #file="{ file }">
81
78
  <div :title="file.fileName">
82
79
  <div class="cover-list-item">
@@ -536,7 +533,6 @@ function CheckQRCodeStatus() {
536
533
  }
537
534
  }
538
535
  function GetQRCodeUploadPhoto() {
539
-
540
536
  clearInterval(model.value.qrtimer);
541
537
  File.getQRCode(model.value, function (data) {
542
538
  model.value.qrCodeImg = data.qrCode;
@@ -624,13 +620,10 @@ function addClass(el, className) {
624
620
 
625
621
 
626
622
  //预览文件
627
-
628
623
  function viewerfile(file) {
629
624
  File.viewerfile(file, model.value)
630
625
  }
631
626
 
632
-
633
-
634
627
  function PasteUpload(event) {
635
628
  if (!model.value.locked && !model.value.disableUpload) {
636
629
  // 获取粘贴板中的图片
@@ -57,7 +57,7 @@
57
57
  </el-col>
58
58
  </template>
59
59
  </el-row>
60
- <div class="list-button" v-if="i > 0">
60
+ <div class="list-delbutton" v-if="i > 0">
61
61
  <el-button v-if="v.delete" type="success" size="small" class="btn-del" :icon="Delete"
62
62
  @click="deleteRow(i, v.$sourceIndex)">
63
63
  删除
@@ -136,7 +136,8 @@
136
136
  </span>
137
137
  <!--可点击的列-->
138
138
  <span v-else-if="v.router" :class="'cell'" style="display: flex;">
139
- <span>{{ scope.row.isSet }}</span>
139
+ <Tablecurrency :router="v.router" :colValue="scope.row[v.fieldName1].code1" :rowData="scope.row" @click="rolRouterClickHandler">
140
+ </Tablecurrency>
140
141
  </span>
141
142
  <ct-span v-else-if="scope.row[v.fieldName1]" :vmodel="scope.row[v.fieldName1]"
142
143
  :rowNum="scope.row.$sourceIndex" :rowData="scope.row"></ct-span>
@@ -191,6 +192,7 @@ import { ElMessage } from 'element-plus'
191
192
  import Enum from '../../utils/Enum'
192
193
  import common from '../../utils/common'
193
194
  import FormList from '../../loader/src/FormList'
195
+ import Tablecurrency from './SearchList/Tablecurrency.vue';
194
196
  import { initData } from '../../utils/mixins';
195
197
  import draggable from "vuedraggable";
196
198
  const emit = defineEmits(['click', 'input', 'change', 'popupSearchList', 'tableButtonClick'])
@@ -275,6 +277,7 @@ function addRow() {
275
277
  model.value.currentRow.isNew = true;
276
278
  model.value.currentRow.index = model.value.tableData.length - 1;
277
279
  if (model.value.flagRepeat) {
280
+ model.value.addSourceRow(newRow);
278
281
  FormList.allhiddenHandle(newRow, newRow.$sourceIndex, model.value)
279
282
  }
280
283
  }
@@ -491,12 +494,15 @@ function setcolumnminWidth(column) {
491
494
  function buttonClick(row, button) {
492
495
  var submitData = {};
493
496
  button.submitFormField.forEach((v) => {
494
- submitData[v] = row[common.initialsToUpperCase(v)].code1;
497
+ submitData[v] = row[v].code1;
495
498
  });
496
499
  model.value.currentRowIndex = model.value.source.rows.findIndex(v => v.$sourceIndex === row.$sourceIndex);
497
500
 
498
501
  emit('tableButtonClick', button, submitData);
499
502
  }
503
+ function rolRouterClickHandler(field, rowData,rowindex) {
504
+ buttonClick(rowData, field);
505
+ }
500
506
  function insertOrUpdateRow(row) {
501
507
  FormList.insertOrUpdateRow(row, true, model.value);
502
508
  }
@@ -616,11 +622,10 @@ defineExpose({
616
622
  width: 45%;
617
623
  }
618
624
 
619
- .ct-form-repeat .list-button {
625
+ .ct-form-repeat .list-delbutton {
620
626
  padding-bottom: 5px;
621
- text-align: right;
622
- display: inline-table;
623
- float: right;
627
+ justify-content: right;
628
+ display: flex;
624
629
  }
625
630
 
626
631
  .ct-form-repeat .ct-form-repeat-el-col {
@@ -2,12 +2,15 @@
2
2
 
3
3
  <ct-field :vmodel="model" v-if="model">
4
4
  <template #Control>
5
- <div class="ct-Radio">
5
+ <div class="ct-Radio" :class="[model.code1 !== '' && !model.locked ? 'hasValue' : '']">
6
6
  <el-radio-group v-model="model.code1" @change="change">
7
7
  <el-radio v-bind="model.attrs" v-for="(item, index) in model.selectItems1" :key="index"
8
8
  :label="item.code" :disabled="model.locked">
9
9
  {{ item.name }}
10
10
  </el-radio>
11
+ <el-icon @click="clearClickHandle" class="el-range__close-icon" style="margin-left: 10px;" v-if="!common.flagHK()">
12
+ <CircleClose />
13
+ </el-icon>
11
14
  </el-radio-group>
12
15
  </div>
13
16
  </template>
@@ -16,6 +19,7 @@
16
19
  <script lang="ts" setup>
17
20
  import { initData, changeHandler } from '../../utils/mixins';
18
21
  import RadioButton from '../../loader/src/RadioButton';
22
+ import common from '../../utils/common'
19
23
  const emit = defineEmits(['click', 'change','search'])
20
24
  const props = defineProps({
21
25
  parameterAction: String,
@@ -216,7 +216,7 @@
216
216
  v-if="!isLoading && model && !model.isLayout"></Tabletip>
217
217
  <Tabletip ref="refFooter" class="ct-search-table-footer" style="width: 100%;"
218
218
  :tip="model.footer + model.companyName" v-if="!isLoading && model && !model.isLayout"></Tabletip>
219
- <div ref="popupButton" v-if="flagPopupSearchlist"
219
+ <div ref="refPopupButton" v-if="flagPopupSearchlist"
220
220
  style="margin-top: 10px;width: 100%;display: inline-block;height: 30px;margin-bottom: 10px;">
221
221
  <el-button size="mini" @click="popupClickHandler()" class="max-search-btn" style="float:right;"
222
222
  type="primary">
@@ -324,6 +324,7 @@ const refListHeader = ref()
324
324
  const refListFooter = ref()
325
325
  const refTableStats = ref()
326
326
  const refTableParent = ref()
327
+ const refPopupButton = ref()
327
328
  const refRows = ref<HTMLElement[]>([]);
328
329
  const getRowsRef = (el, index) => {
329
330
  if (el) {
@@ -809,14 +810,18 @@ function setTableHeight() {
809
810
  if (refTableStats.value && refTableStats.value.tableStatistics) {
810
811
  h7 = refTableStats.value.tableStatistics.offsetHeight + 10 | 0;
811
812
  }
812
- let tableHeight = h1 - h2 - h3 - h4 - h5 - h6 - h7 - 16;
813
+ var h8 = 0;
814
+ if (refPopupButton.value) {
815
+ h8 = refPopupButton.value.offsetHeight + 21 | 0;
816
+ }
817
+
818
+ let tableHeight = h1 - h2 - h3 - h4 - h5 - h6 - h7 - h8 - 16;
813
819
  model.value.tableHeight = tableHeight < 40 ? 350 : tableHeight;
814
820
  nextTick(() => {
815
821
  getScrollAttr();
816
822
  });
817
823
  }
818
824
  })
819
-
820
825
  }
821
826
  //表头拖动开始
822
827
  function thMouseMoveHandle(ev) {
@@ -376,6 +376,8 @@ function setPublicClassify(classify, model) {
376
376
  function setClassify(classify, model) {
377
377
  classify.file.mediaLabelName = classify.option[model.optionModel.optionAttrs.label];
378
378
  classify.file.mediaLabelID = classify.option[model.optionModel.optionAttrs.value];
379
+ classify.file.source.mediaLabelName = classify.option[model.optionModel.optionAttrs.label];
380
+ classify.file.source.mediaLabelID = classify.option[model.optionModel.optionAttrs.value];
379
381
  }
380
382
  //上传成功
381
383
  function handleAvatarSuccess(res, file, fileList, model) {
@@ -71,7 +71,7 @@ function loadFromModel(source, isFormList) {
71
71
  }
72
72
  },
73
73
  getValueByFieldNameFromParent(id, attrKey) {
74
- if(this.form && this.form.parentModelForm){
74
+ if (this.form && this.form.parentModelForm) {
75
75
  return this.form.parentModelForm.getValueByFieldName(id, attrKey);
76
76
  }
77
77
  return null;
@@ -111,14 +111,14 @@ function loadFromModel(source, isFormList) {
111
111
  if (attrKey == 'name1') {
112
112
  rtn1["options"][0]["label"] = attrValue
113
113
  }
114
- if(rtn1.itemKey)rtn1.itemKey=Math.random()
114
+ if (rtn1.itemKey) rtn1.itemKey = Math.random()
115
115
  }
116
116
  hiddenHandle(rtn1, this.form);
117
117
  requiredHandle(rtn1, this.form);
118
118
  }
119
119
  },
120
120
  setValueByFieldNameFromParent(id, attrKey, attrValue) {
121
- if(this.form && this.form.parentModelForm){
121
+ if (this.form && this.form.parentModelForm) {
122
122
  return this.form.parentModelForm.setValueByFieldName(id, attrKey, attrValue);
123
123
  }
124
124
  return null;
@@ -411,24 +411,24 @@ function loadFromModel(source, isFormList) {
411
411
  common.message(message, type, center, duration, showClose, dangerouslyUseHTMLString)
412
412
  },
413
413
 
414
- },
414
+ },
415
415
  getValueByFieldName(id, attrKey) {
416
416
  attrKey = common.initialsToLowerCase(attrKey);
417
417
  var rtn1 = this.fieldsDic[id];
418
418
  if (rtn1) {
419
- return rtn1[attrKey];
419
+ return rtn1[attrKey];
420
420
  }
421
421
  },
422
422
  setValueByFieldName(id, attrKey, attrValue) {
423
423
  attrKey = common.initialsToLowerCase(attrKey);
424
424
  var rtn1 = this.fieldsDic[id];
425
425
  if (rtn1) {
426
- if(attrKey=='code1' && rtn1.controlType===4
427
- && attrValue!=undefined && attrValue!=null && attrValue!=''){
428
- if(rtn1.decimals1 != undefined && rtn1.decimals1 != null && rtn1.decimals1>-1){
429
- attrValue = Number(attrValue).toFixed(rtn1.decimals1)
430
- }
426
+ if (attrKey == 'code1' && rtn1.controlType === 4
427
+ && attrValue != undefined && attrValue != null && attrValue != '') {
428
+ if (rtn1.decimals1 != undefined && rtn1.decimals1 != null && rtn1.decimals1 > -1) {
429
+ attrValue = Number(attrValue).toFixed(rtn1.decimals1)
431
430
  }
431
+ }
432
432
  rtn1[attrKey] = attrValue;
433
433
  // this.self.hatchHandle(id, attrKey, attrValue, rtn1);
434
434
 
@@ -727,7 +727,7 @@ function loadFromModel(source, isFormList) {
727
727
  Object.assign(rtnFormObj, customizeColumnsObj);
728
728
  }
729
729
  else {
730
- if(f.hasOwnProperty('getFormObj') && typeof f.getFormObj === "function"){
730
+ if (f.hasOwnProperty('getFormObj') && typeof f.getFormObj === "function") {
731
731
  Object.assign(rtnFormObj, f.getFormObj());
732
732
  }
733
733
  }
@@ -758,7 +758,7 @@ function loadFromModel(source, isFormList) {
758
758
  return submitData;
759
759
  },
760
760
  //获取父级关联数据
761
- getParentFieldPara(parentFieldNameArr,model) {
761
+ getParentFieldPara(parentFieldNameArr, model) {
762
762
  let submitData = {};
763
763
  var tempFormData = rtn.getFormObj();
764
764
  parentFieldNameArr.forEach((v) => {
@@ -886,7 +886,7 @@ function requiredHandle(item, model) {
886
886
  //清除关联当前组件的组件值
887
887
  function clearRelatedHandle(field, fields) {
888
888
  var f = fields.filter((v) => {
889
- return v.parentField && field.fieldName1 && (','+v.parentField+',').indexOf(','+field.fieldName1+',') > -1;
889
+ return v.parentField && field.fieldName1 && (',' + v.parentField + ',').indexOf(',' + field.fieldName1 + ',') > -1;
890
890
  });
891
891
  f.forEach((v) => {
892
892
  if (v.reset) {
@@ -931,12 +931,16 @@ function popupSearchListHandler(singleSelectio, field, router, model, Fields, pr
931
931
 
932
932
  let check = true;
933
933
  let checkMsg;
934
+ var i = 0;
934
935
  router.submitFormField.forEach((v) => {
935
936
  Fields.forEach((f) => {
936
937
  if (f.model && f.model.fieldName1 === v) {
937
938
  if (typeof f.model.validExcute !== 'undefined') {
938
939
  if (!f.model.validExcute()) {
939
- common.message(f.model.displayValidMessage)
940
+ if (i == 0) {
941
+ common.message(f.model.displayValidMessage)
942
+ }
943
+ i++;
940
944
  verified = false;
941
945
  return;
942
946
  }
@@ -1018,9 +1022,9 @@ function popupSearchListHandler(singleSelectio, field, router, model, Fields, pr
1018
1022
  callBack(option);
1019
1023
  }
1020
1024
  if (typeof option === 'object' && option !== null && option.flagAlert) {
1021
- common.confirm(option.content, option.caption? option.caption : "提示", {
1022
- confirmButtonText: option.confirmButtonText? option.confirmButtonText : "确定",
1023
- cancelButtonText: option.cancelButtonText? option.cancelButtonText : "取消",
1025
+ common.confirm(option.content, option.caption ? option.caption : "提示", {
1026
+ confirmButtonText: option.confirmButtonText ? option.confirmButtonText : "确定",
1027
+ cancelButtonText: option.cancelButtonText ? option.cancelButtonText : "取消",
1024
1028
  center: Enum.HalignType.Center
1025
1029
  }).then(() => {
1026
1030
  model.$vue.changeCallBackHandler(field, router.callBackFunName, option);
@@ -314,10 +314,11 @@ function FormListModel(source, master,actionRouters) {
314
314
  if(form.fieldsDic[f]){
315
315
  let newField={...form.fieldsDic[f]};
316
316
  newField.is='ct-label';
317
- newField.type=Enum.ControlType.Label;
317
+ newField.controlType=Enum.ControlType.Label;
318
318
  newField.colspan=24;
319
319
  newField.required=false;
320
320
  newField.labelClass='';
321
+ newField.value=newField.code1;
321
322
  relfields.push(newField);
322
323
  }
323
324
  });
package/src/main.js CHANGED
@@ -26,7 +26,7 @@ app.use(centaline, {
26
26
  //baseUrl: "http://10.1.245.50:38735/max-uplink-api/",
27
27
  //baseUrl: "http://10.1.245.111:38028/",
28
28
  flagRouterSelf: true,
29
- flagApp: true,//是否app端
29
+ flagApp: false,//是否app端
30
30
  zindex: 999,
31
31
  showRequestSuccessMessage: true,
32
32
  showRequestErrorMessage: true,
@@ -837,9 +837,11 @@ export function RouterClickHandler(field, submitData, action, model, source, cal
837
837
  common.openDialog(dialogOption);
838
838
  }
839
839
  else {
840
- submitData = field.getActionPara(submitData).para;
841
840
  if (source == 'table') {
842
- model.$vue.operationLoading = true
841
+ model.$vue.operationLoading = true
842
+ }
843
+ else{
844
+ submitData = field.getActionPara(submitData).para;
843
845
  }
844
846
  field.doAction(submitData, (data) => {
845
847
  if (source == 'table') {
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <div class="data-driven" id="app-form" >
3
3
 
4
- <ct-form :api="'/admin/SchoolTeachingPlanActivityExamAnswer/readDetail'" :apiParam="apiParam" :flagNavbar="true"></ct-form>
4
+ <ct-form :api="'/salemanage/ContractByPoint/readDetail'" :apiParam="apiParam" :flagNavbar="true"></ct-form>
5
5
  <!-- <ct-form :api="'/api/third-dept-tran/tran-comm-adjust/task'" :apiParam="apiParam"></ct-form> -->
6
6
  <!-- <ct-form :api="'/PropertyTranToActive/getLayoutOfNew'" :apiParam="apiParam"></ct-form> -->
7
7
  <!-- <ct-textbox :source="source"></ct-textbox> -->
@@ -10,5 +10,5 @@
10
10
  </template>
11
11
  <script lang="ts" setup>
12
12
  //const apiParam={"originalTraId":"1739561435204980737","actionType":1,"pageStyle":2,"pageTitle":"成交报告","pageOnly":true}
13
- const apiParam={"rowId":"1900912713408843776","actionType":3}
13
+ const apiParam={"estateId":"2503120955255B0598513062476EB741","propertyId":"250312100237582995D2919948BDB1D2","actionType":2,"commissionMode":"1"}
14
14
  </script>
@@ -1,8 +1,7 @@
1
1
  <template>
2
2
  <div id="app-search" style="width:100%;height:100%;position: fixed;">
3
- <ct-searchlist :apiParam="apiParam" :searchConditionApi="'/propertyPublishList/getLayoutOfSearch'"
4
- :searchDataApi="'/propertyPublishList/getListOfSearchModel'"
5
- :searchStatsApi="'/propertyPublishList/getListStats'"></ct-searchlist>
3
+ <ct-searchlist :apiParam="apiParam" :searchConditionApi="'/batchcontractadjust/batchAdjustCommissionPointList/getLayoutOfSearch'"
4
+ :searchDataApi="'/batchcontractadjust/batchAdjustCommissionPointList/getList'"></ct-searchlist>
6
5
  <ct-dialoglist ref="dialogList"></ct-dialoglist>
7
6
 
8
7
  </div>