centaline-data-driven 1.1.22 → 1.1.26

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.
Files changed (72) hide show
  1. package/.vs/Centaline.Front_End.DataDriven/DesignTimeBuild/.dtbcache +0 -0
  2. package/build/centaline/centaline.path.js +2 -0
  3. package/build/centaline/webpack.centaline.conf.js +5 -3
  4. package/build/utils.js +2 -1
  5. package/config/dev.env.js +5 -2
  6. package/package.json +7 -5
  7. package/src/Detail.vue +28 -0
  8. package/src/Form.vue +4 -3
  9. package/src/SearchList.vue +5 -3
  10. package/src/SearchTree.vue +55 -0
  11. package/src/assets/Mvr.png +0 -0
  12. package/src/assets/VR.png +0 -0
  13. package/src/assets/collection.png +0 -0
  14. package/src/assets/dian.png +0 -0
  15. package/src/assets/ewm.png +0 -0
  16. package/src/assets/image.png +0 -0
  17. package/src/assets/location.png +0 -0
  18. package/src/assets/max-fold.png +0 -0
  19. package/src/assets/max-open.png +0 -0
  20. package/src/assets/mero.png +0 -0
  21. package/src/assets/node-collapse.png +0 -0
  22. package/src/assets/node-expand.png +0 -0
  23. package/src/assets/video.png +0 -0
  24. package/src/assets//350/256/241/347/256/227/345/231/250.png +0 -0
  25. package/src/centaline/comfirm/src/comfirm.vue +2 -2
  26. package/src/centaline/css/common.css +34 -33
  27. package/src/centaline/css/max.css +145 -0
  28. package/src/centaline/dynamicBtn/src/dynamicBtn.vue +35 -4
  29. package/src/centaline/dynamicCheckbox/src/dynamicCheckbox.vue +1 -1
  30. package/src/centaline/dynamicDetail/index.js +11 -0
  31. package/src/centaline/dynamicDetail/src/dynamicDetail.vue +39 -0
  32. package/src/centaline/dynamicDetail/src/dynamicPropertyDetailOFI.vue +1283 -0
  33. package/src/centaline/dynamicDetail/src/dynamicPropertyDetailRET.vue +29 -0
  34. package/src/centaline/dynamicForm/src/dynamicForm.vue +25 -9
  35. package/src/centaline/dynamicForm/src/dynamicFormList.vue +2 -2
  36. package/src/centaline/dynamicForm/src/dynamicFormListTable.vue +27 -6
  37. package/src/centaline/dynamicInputNumber/src/dynamicInputNumber.vue +4 -0
  38. package/src/centaline/dynamicSearchList/src/dynamicSearchList.vue +27 -6
  39. package/src/centaline/dynamicSearchList/src/dynamicSearchScreen.vue +10 -1
  40. package/src/centaline/dynamicSearchList/src/dynamicSearchTable.vue +59 -33
  41. package/src/centaline/dynamicSearchList/src/dynamicTableStatistics.vue +41 -0
  42. package/src/centaline/dynamicSearchList/src/dynamicTableToolbar.vue +7 -4
  43. package/src/centaline/dynamicSos/src/dynamicSos.vue +0 -1
  44. package/src/centaline/dynamicT/src/dynamicT.vue +18 -23
  45. package/src/centaline/dynamicTimeSelect/src/dynamicTimeSelect.vue +37 -3
  46. package/src/centaline/dynamicTree/index.js +11 -0
  47. package/src/centaline/dynamicTree/src/dynamicSearchTree.vue +66 -0
  48. package/src/centaline/dynamicTree/src/dynamicTree.vue +213 -0
  49. package/src/centaline/dynamicTree/src/dynamicTreeList.vue +65 -0
  50. package/src/centaline/loader/index.js +5 -6
  51. package/src/centaline/loader/src/ctl/Base.js +31 -2
  52. package/src/centaline/loader/src/ctl/Button.js +18 -1
  53. package/src/centaline/loader/src/ctl/ComboBoxWithTextBox.js +0 -8
  54. package/src/centaline/loader/src/ctl/Form.js +51 -7
  55. package/src/centaline/loader/src/ctl/FormList.js +7 -0
  56. package/src/centaline/loader/src/ctl/Mo.js +1 -9
  57. package/src/centaline/loader/src/ctl/Router.js +58 -1
  58. package/src/centaline/loader/src/ctl/SearchScreen.js +42 -2
  59. package/src/centaline/loader/src/ctl/SearchTable.js +28 -13
  60. package/src/centaline/loader/src/ctl/So.js +1 -9
  61. package/src/centaline/loader/src/ctl/Sos.js +2 -11
  62. package/src/centaline/loader/src/ctl/Tags.js +1 -9
  63. package/src/centaline/loader/src/ctl/TimeSelect.js +40 -13
  64. package/src/centaline/loader/src/ctl/Tree.js +154 -0
  65. package/src/centaline/loader/src/ctl/lib/Enum.js +12 -2
  66. package/src/centaline/loader/src/ctl/lib/LibFunction.js +13 -5
  67. package/src/centaline/loader/src/ctl.js +5 -1
  68. package/src/centaline/templateControls/src/dynamicTableCurrency.vue +14 -9
  69. package/src/main.js +1 -1
  70. package/src/router/index.js +11 -0
  71. package/wwwroot/static/centaline/centaline-data-driven.js +1 -7
  72. package/wwwroot/static/centaline/centaline-data-driven.js.map +1 -1
@@ -0,0 +1,29 @@
1
+ <template>
2
+ <div>22222222222222222222222</div>
3
+ </template>
4
+
5
+
6
+ <script>
7
+ export default {
8
+ name: 'ct-PropertyDetail',
9
+ props: {
10
+ vmodel: Object,
11
+ api: String
12
+ },
13
+ data() {
14
+ return {
15
+ model:null
16
+ }
17
+ },
18
+ created() {
19
+ this.model = this.vmodel;
20
+ },
21
+ methods: {
22
+ }
23
+ }
24
+ </script>
25
+ <style>
26
+
27
+ </style>
28
+
29
+
@@ -1,9 +1,9 @@
1
1
  <template>
2
2
  <div v-loading="loading" style="width:100%">
3
- <div v-if="model !== null && !loading" class="ct-form">
3
+ <div v-if="model !== null && !loading" class="ct-form" :class="{'tableDisabled':model.pageDisabled}">
4
4
  <!--可根据场景判断显示el-card还是el-main-->
5
- <component :is="showTitle?'el-card':'el-main'">
6
- <div slot="header" class="clearfix" v-if="typeof model.title !== 'undefined' && showTitle">
5
+ <component :is="model.showTitle?'el-main':'el-card'">
6
+ <div slot="header" class="clearfix" v-if="typeof model.title !== 'undefined' && model.flagShowTitle">
7
7
  <span style="font-weight:bold">{{model.title}}</span>
8
8
  </div>
9
9
  <!--头部元素-->
@@ -93,7 +93,7 @@
93
93
  parentModel: Object,
94
94
  showTitle: {
95
95
  type: Boolean,
96
- default: true
96
+ default: false
97
97
  }
98
98
  },
99
99
  data() {
@@ -136,7 +136,7 @@
136
136
  this.$emit('failLoad', this.model);
137
137
  },
138
138
  load(data) {
139
- this.$set(this, 'model', data)
139
+ this.$set(this, 'model', data);
140
140
  this.model.self = this;
141
141
  if (typeof this.model.scripts !== 'undefined') {
142
142
  this.model.scripts.formData = this.model.formData;
@@ -234,9 +234,10 @@
234
234
 
235
235
  if (verified) {
236
236
  //action有值,提交到后台
237
- if (field.action) {
237
+ if (field.action) {
238
238
  field.disabled = true;//提交按钮禁用
239
- field.doAction(self.model.getFormObj(), (data) => {
239
+ self.model.pageDisabled= true;
240
+ field.doAction(self.getFormObj(), (data) => {
240
241
  if (data.rtnCode === 200) {
241
242
  if (self.model.flagAlertClose) {
242
243
  self.$common.confirm('操作成功,是否关闭本页面?', '提示', {
@@ -262,7 +263,8 @@
262
263
  self.parentModel.$vue.closeTabThen(data);
263
264
  }
264
265
  }
265
- field.disabled = false;
266
+ field.disabled = false;
267
+ self.model.pageDisabled= false;
266
268
  });
267
269
  }
268
270
  //无值,触发submit事件
@@ -507,9 +509,23 @@
507
509
  f.self.resize();
508
510
  }
509
511
  });
510
- }
512
+ },
513
+ getFormObj()
514
+ {
515
+ let formData=this.model.getFormObj();
516
+ if(this.$route.query.pageStyle)
517
+ {
518
+ return Object.assign(formData,{'pageStyle':this.$route.query.pageStyle});
519
+ }
520
+ return formData;
521
+ },
522
+
511
523
  }
512
524
  }
513
525
  </script>
514
526
  <style>
527
+ .tableDisabled {
528
+ pointer-events: none;
529
+ opacity:0.4;
530
+ }
515
531
  </style>
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <div class="ct-form-list" :class="model.attrs.size?'ct-form-list-'+model.attrs.size:''">
3
- <div style="padding-bottom:5px;text-align:right">
4
- <el-button type="success" size="mini" icon="el-icon-circle-plus-outline" @click="addRow">新增</el-button>
3
+ <div style="padding-bottom:5px;text-align:right" class=" max-btn-add">
4
+ <el-button type="success" size="mini" class="max-btn-add" icon="el-icon-circle-plus-outline" @click="addRow">新增</el-button>
5
5
  </div>
6
6
  <div style="position:relative">
7
7
  <div style="width:100%;overflow:auto;">
@@ -1,18 +1,25 @@
1
1
  <template>
2
- <div class="ct-form-list" v-focus="foucus">
2
+ <div class="ct-form-list" v-focus="foucus" :class="{'tableDisabled':model.tableDisabled}">
3
3
  <div class="list-title">
4
4
  <h5>{{model.title}}</h5>
5
5
  </div>
6
- <div class="list-button">
7
- <el-button v-if="model.create" type="success" size="mini" icon="el-icon-circle-plus-outline" @click="addRow">新增</el-button>
6
+ <div class="list-button max-btn-add">
7
+ <el-button v-if="model.create" type="success" size="mini" icon="el-icon-circle-plus-outline" @click="addRow">
8
+ 新增
9
+ </el-button>
8
10
  </div>
9
11
 
10
12
  <div id="listTable">
11
13
  <el-row>
12
14
  <el-col :span="24">
13
- <el-table size="mini" :data="model.tableData" border style="width: 100%" highlight-current-row :show-summary="model.showSummary" :summary-method="getSummaries">
15
+ <el-table size="mini" class="max-table--border" :data="model.tableData" :key="itemKey" border style="width: 100%" highlight-current-row :show-summary="model.showSummary" :summary-method="getSummaries">
14
16
  <!--数据列-->
15
17
  <el-table-column v-for="(v,i) in model.rows[0].field" :key="i" :prop="v.id" :label="v.label" v-if="v.show !== false" header-align="center">
18
+ <template slot="header" slot-scope="scope">
19
+ <div class="cell" :class="{'ct-table-required':v.required&&model.rows[0].edit&& model.rows[0].delete&&!model.tableDisabled}">
20
+ {{v.label}}
21
+ </div>
22
+ </template>
16
23
  <template slot-scope="scope">
17
24
  <span v-if="scope.row.isSet">
18
25
  <!--<component v-if ref="Fields" :is="v.is" :vmodel="scope.row[v.id]" :api="model.OptApi"></component>-->
@@ -83,6 +90,7 @@
83
90
  return {
84
91
  model: null,
85
92
  foucus: false,
93
+ itemKey: Math.random()
86
94
  }
87
95
  },
88
96
  created() {
@@ -156,7 +164,7 @@
156
164
 
157
165
  row.isSet = false;
158
166
  app.model.currentRow.isSet = false;
159
-
167
+ app.itemKey = Math.random();
160
168
  this.model.change = this.model.formListChange;
161
169
  app.$emit('change');
162
170
  }
@@ -328,12 +336,14 @@
328
336
  display: flex;
329
337
  line-height: 34px;
330
338
  }
339
+
331
340
  .ct-form-list .list-title {
332
341
  padding-bottom: 5px;
333
342
  text-align: left;
334
343
  display: inline-table;
335
344
  width: 45%;
336
345
  }
346
+
337
347
  .ct-form-list .list-button {
338
348
  padding-bottom: 5px;
339
349
  text-align: right;
@@ -341,13 +351,24 @@
341
351
  display: inline-table;
342
352
  float: right;
343
353
  }
354
+
344
355
  .ct-table-inputnumber {
345
- text-align:right;
356
+ text-align: right;
346
357
  }
358
+
347
359
  .ct-form-list .el-table__footer-wrapper .el-table__footer .has-gutter div {
348
360
  text-align: right;
349
361
  }
362
+
350
363
  .ct-form-list .el-table__footer-wrapper .el-table__footer .has-gutter tr td:first-child div {
351
364
  text-align: left;
352
365
  }
366
+
367
+ .ct-table-required {
368
+ color: red;
369
+ }
370
+ .tableDisabled {
371
+ pointer-events: none;
372
+ opacity:0.4;
373
+ }
353
374
  </style>
@@ -50,6 +50,10 @@
50
50
  var self = this;
51
51
  this.$nextTick(function () {
52
52
 
53
+ if (typeof self.vmodel === 'undefined') {
54
+ self.model = self.loaderObj.InputNumber(this.source);
55
+ }
56
+
53
57
  if (self.vmodel) {
54
58
  self.load(self.vmodel);
55
59
  self.$emit('loaded');
@@ -1,7 +1,13 @@
1
1
  <template>
2
- <div class="ct-search-list" :style="searchListStyle">
3
- <ct-searchscreen ref="screen" :api="searchConditionApi" @loaded="screenLoaded" :screenPara="apiParam" @search="search()"></ct-searchscreen>
4
- <ct-searchtable ref="table" :api="searchDataApi" @toolbarClick="toolbarClickHandler" @refreshParent="refreshParentHandler"></ct-searchtable>
2
+ <div class="ct-search-list" :style="searchListStyle">
3
+ <div slot="header" class="clearfix" v-if="typeof title !== 'undefined' && showTitle">
4
+ <span style="font-weight:bold">{{title}}</span>
5
+ </div>
6
+ <ct-searchscreen ref="screen" :api="searchConditionApi" @loaded="screenLoaded" :screenPara="apiParam" @search="search()" @showTitle="showTitleScreenHandler"></ct-searchscreen>
7
+ <ct-searchtable ref="table" :api="searchDataApi" :searchDataStatisticsApi="searchDataStatisticsApi"
8
+ @toolbarClick="toolbarClickHandler"
9
+ @refreshParent="refreshParentHandler"
10
+ @showTitle="showTitleHandler"></ct-searchtable>
5
11
  </div>
6
12
  </template>
7
13
  <script>
@@ -21,11 +27,12 @@
21
27
  vmodel: Object,
22
28
  searchConditionApi: String,
23
29
  searchDataApi: String,
30
+ searchDataStatisticsApi: String,
24
31
  pageHeight: String,
25
32
  apiParam: {
26
33
  type: Object,
27
34
  default: () => { }
28
- }
35
+ },
29
36
  },
30
37
  created() {
31
38
  this.model = this.vmodel;
@@ -43,7 +50,9 @@
43
50
  loaded: {
44
51
  screenLoaded: false,
45
52
  tableLoaded: false
46
- }
53
+ },
54
+ title:'',
55
+ showTitle:false,
47
56
  }
48
57
  },
49
58
  methods: {
@@ -73,7 +82,19 @@
73
82
  },
74
83
  resize() {
75
84
  this.$refs.table.setTableHeight();
76
- }
85
+ },
86
+ showTitleHandler() {
87
+ if (this.$refs.table.model && this.$refs.table.model.flagShowTitle) {
88
+ this.title=this.$refs.table.model.title;
89
+ this.showTitle=this.$refs.table.model.flagShowTitle;
90
+ }
91
+ },
92
+ showTitleScreenHandler() {
93
+ if (this.$refs.screen.model && this.$refs.screen.model.flagShowTitle) {
94
+ this.title=this.$refs.screen.model.title;
95
+ this.showTitle=this.$refs.screen.model.flagShowTitle;
96
+ }
97
+ },
77
98
  }
78
99
  }
79
100
  </script>
@@ -18,7 +18,7 @@
18
18
  <component v-for="(col, index) in model.btnScreen" :key="index" :is="col.is" :vmodel="col" :api="model.optionApi" @click="clickHandler(col)"></component>
19
19
  </el-col>
20
20
  </el-row>-->
21
- <el-popover class="SeachScreenPop" placement="top" transition="el-zoom-in-top" v-model="highScreen" trigger="click" visible-arrow="false">
21
+ <el-popover class="SeachScreenPop max-seachpopper" placement="top" transition="el-zoom-in-top" v-model="highScreen" trigger="click" visible-arrow="false">
22
22
  <div style="width:100%">
23
23
  <!--<el-row v-if="highScreenRow.length > 0">
24
24
  <el-col v-for="(col, index) in highScreenRow" :key="index" :span="col.colspan" style="padding:10px" v-if="col.show !== false">
@@ -78,6 +78,14 @@
78
78
  switch (model.action) {
79
79
  case 'showHigh':
80
80
  this.$set(this, 'highScreen', !this.highScreen);
81
+ //高级搜索需要切换icon样式
82
+ if(model.icon==='max-open')
83
+ {
84
+ model.icon='max-fold'
85
+ }else
86
+ {
87
+ model.icon='max-open'
88
+ }
81
89
  break;
82
90
  case 'search':
83
91
  this.$emit('search', this.model);
@@ -147,6 +155,7 @@
147
155
  self.setScreenShow();
148
156
  self.isLoading = false;
149
157
  self.$emit('loaded', self.model.defaultSearch);
158
+ self.$emit('showTitle');
150
159
  }
151
160
  }
152
161
  }
@@ -1,11 +1,12 @@
1
1
  <template>
2
2
  <div style="width:100%;" class="ct-searchtable" ref="searchTable">
3
+ <ct-tableStatistics ref="listHeader" class="ct-search-table-list-header" :tip="model.listHeader" v-if="!isLoading && searchDataStatisticsApi"></ct-tableStatistics>
3
4
  <ct-tabletoolbar ref="toolbar" v-if="!isLoading" :buttons="model.buttons"
4
5
  @click="toolbarClickHandler($event)"
5
6
  @importComplete="importComplete"
7
+ :optionApi="model.optionApi"
6
8
  :searchModel="model.searchModel"></ct-tabletoolbar>
7
9
  <ct-tabletip ref="listHeader" class="ct-search-table-list-header" :tip="model.listHeader" v-if="!isLoading"></ct-tabletip>
8
-
9
10
  <div v-loading="tableLoading" v-if="!isLoading" :style="{'height':'0px','top':model.tableHeight*0.55+'px'}">
10
11
  </div>
11
12
  <div v-loading="operationLoading">
@@ -16,13 +17,13 @@
16
17
  @keydown.up="rowKeyDownHandle($event,0)" @keydown.down="rowKeyDownHandle($event,1)"
17
18
  tabindex="-1">
18
19
  <div class="ct-table-content">
19
- <table border="0" cellpadding="0" cellspacing="0"
20
+ <table border="0" cellpadding="0" cellspacing="0"
20
21
  :class="['ct-table',model.attrs.size?'ct-table-'+model.attrs.size:'']">
21
22
  <!--表头-->
22
23
  <thead ref="tableHead">
23
24
  <tr class="ct-tr" ref="headTr" v-for="(columns,columnsIndex) in model.columnsArr">
24
25
  <th v-if="model.isMulti && columnsIndex === 0" ref="headLeftThs" class="ct-td left-fixation-th checkbox-td">
25
- <input type="checkbox" @click="selectAll($event)" v-model="model.selectAll" />
26
+ <input type="checkbox" @click="selectAll($event)" v-model="model.selectAll" class="checkbox-td-1" />
26
27
  </th>
27
28
  <th :ref="column.fixed?(column.fixed==='left'?'headLeftThs':'headRightThs'):'headThs'" v-for="(column,colIndex) in columns"
28
29
  v-if="column.show" class="ct-td ct-searchtable-th"
@@ -34,8 +35,7 @@
34
35
  column.fixed === 'left'?'left-fixation-th':null,
35
36
  column.fixed === 'right'?'right-fixation-th':null,
36
37
  typeof column.fixed === 'undefined'?'right-no-fixation-th':null]"
37
- @mousemove="thMouseMoveHandle($event)" @mousedown="thMouseDownHandle($event,colIndex)"
38
- align="center"
38
+ @mousemove="thMouseMoveHandle($event)" @mousedown="thMouseDownHandle($event,colIndex)"
39
39
  v-bind="column.attrs">
40
40
 
41
41
  <span>{{column.name}}</span>
@@ -54,14 +54,13 @@
54
54
  <tbody>
55
55
  <!--这一行仅用于设置未加载数据时的列宽-->
56
56
  <!--<tr v-if="model.listData.length === 0" class="ct-tr" style="visibility: hidden;">
57
- <td v-if="model.isMulti">
58
- </td>
59
- <td v-for="(column,colIndex) in model.dataFieldcolumns" class="ct-td" v-if="column.show">
60
- <div :style="{'width': column.width + 'px'}">
61
- </div>
62
- </td>
63
- </tr>-->
64
-
57
+ <td v-if="model.isMulti">
58
+ </td>
59
+ <td v-for="(column,colIndex) in model.dataFieldcolumns" class="ct-td" v-if="column.show">
60
+ <div :style="{'width': column.width + 'px'}">
61
+ </div>
62
+ </td>
63
+ </tr>-->
65
64
  <!--可视区域的行数据-->
66
65
  <tr v-for="(row,rowindex) in model.listData"
67
66
  v-if="pageRowMin <= rowindex && rowindex <= pageRowMax"
@@ -69,7 +68,7 @@
69
68
  class="ct-tr"
70
69
  :style="row.$style">
71
70
  <td v-if="model.isMulti" class="ct-td tdFiexd left-fixation checkbox-td" align="center">
72
- <input v-if="!model.rightMulti || row[model.rightMulti] == 1" type="checkbox" v-model="row.$select" @change="selectOne($event)" />
71
+ <input v-if="!model.rightMulti || row[model.rightMulti] == 1" type="checkbox" v-model="row.$select" @change="selectOne($event)" class="checkbox-td-1" />
73
72
  </td>
74
73
  <td :ref="column.fixed?(column.fixed==='left'?'headLeftTds':'headRightTds'):null"
75
74
  v-for="(column,colIndex) in model.dataFieldcolumns"
@@ -90,7 +89,7 @@
90
89
  </div>
91
90
 
92
91
  <!--可点击的列-->
93
- <ct-tablecurrency v-else-if="column.router" :class="column.autoRowHeight ? 'lineFeedCell':'cell'" :router="column.router" :colValue="row[column.id]" :rowData="row"
92
+ <ct-tablecurrency v-else-if="column.router" :align="column.attrs.align" :class="column.autoRowHeight ? 'lineFeedCell':'cell'" :router="column.router" :colValue="row[column.id]" :rowData="row"
94
93
  @click="rolRouterClickHandler">
95
94
  </ct-tablecurrency>
96
95
 
@@ -108,6 +107,8 @@
108
107
  </td>
109
108
  </tr>
110
109
 
110
+
111
+
111
112
  <!--适配滚动条-->
112
113
  <tr v-else v-bind:style="{ height: row.$heigth + 'px' }"></tr>
113
114
  </tbody>
@@ -124,17 +125,20 @@
124
125
  <script>
125
126
  import dynamicElement from '../../mixins/dynamicElement';
126
127
  import dynamicTableTip from './dynamicTableTip.vue';
127
- import dynamicTableToolbar from './dynamicTableToolbar.vue'
128
+ import dynamicTableToolbar from './dynamicTableToolbar.vue';
129
+ import dynamicTableStatistics from './dynamicTableStatistics.vue';
128
130
  export default {
129
131
  name: 'ct-searchtable',
130
132
  mixins: [dynamicElement],
131
133
  components: {
132
134
  'ct-tabletip': dynamicTableTip,
133
- 'ct-tabletoolbar': dynamicTableToolbar
135
+ 'ct-tabletoolbar': dynamicTableToolbar,
136
+ 'ct-tableStatistics': dynamicTableStatistics
134
137
  },
135
138
  props: {
136
139
  vmodel: Object,
137
- api: String
140
+ api: String,
141
+ searchDataStatisticsApi: String
138
142
  },
139
143
  computed: {
140
144
  },
@@ -165,6 +169,7 @@
165
169
  },
166
170
  activated() {
167
171
  this.$nextTick(() => {
172
+ this.calculatingRowHeight();
168
173
  this.setTableHeight();
169
174
  })
170
175
  },
@@ -191,9 +196,14 @@
191
196
  self.$forceUpdate();
192
197
 
193
198
  self.$emit('loaded');
199
+ self.$emit('showTitle');
194
200
  if (this.tempSearchModel !== null) {
195
201
  self.model.searchModel = this.tempSearchModel;
196
202
  }
203
+ //自动查询 调用合并列
204
+ if (self.model.rowMergedColumns.length > 0 && self.model.listData.length > 0) {
205
+ self.model.setRow(self.model.listData);
206
+ }
197
207
  self.tableComplate = true;
198
208
  this.setTableHeight();
199
209
  this.$nextTick(() => {
@@ -312,8 +322,8 @@
312
322
  self.tableLoading = false;
313
323
  self.rowColorChange();
314
324
  self.resetScroll();
315
- self.getScrollAttr();
316
325
  self.calculatingRowHeight();
326
+ self.getScrollAttr();
317
327
  }
318
328
  self.setfixedSize();
319
329
  });
@@ -398,6 +408,9 @@
398
408
  },
399
409
  getScrollAttr(e) {
400
410
  if (typeof this.$refs.tableParent !== 'undefined' && typeof this.$refs.headThs !== 'undefined') {
411
+
412
+ this.calculatingRowHeight();
413
+
401
414
  var scrollTop = this.$refs.tableParent.scrollTop;
402
415
  var scrollLeft = this.$refs.tableParent.scrollLeft;
403
416
  var scrollRight = this.$refs.tableParent.scrollWidth - scrollLeft - this.$refs.tableParent.clientWidth;
@@ -426,7 +439,6 @@
426
439
  setTrLazyLoading() {
427
440
  this.pageRowMax = this.firstRow + this.displayRowNumber;
428
441
  this.pageRowMin = this.firstRow - this.displayRowNumber;
429
-
430
442
  if (this.pageRowMin > 0 && this.model.listData[this.pageRowMin].$rowspan === 0) {
431
443
  for (let i = this.pageRowMin; i >= 0; i--) {
432
444
  if (this.model.listData[i].$rowspan > 0) {
@@ -469,8 +481,8 @@
469
481
  var h4 = this.$refs.footer.$el.offsetHeight | 0;
470
482
  var h5 = this.$refs.listHeader.$el.offsetHeight | 0;
471
483
  var h6 = this.$refs.listFooter.$el.offsetHeight | 0;
472
- let tableHeight = h1 - h2 - h3 - h4 - h5 - h6 - 10;
473
-
484
+ let tableHeight = h1 - h2 - h3 - h4 - h5 - h6 - 30;
485
+
474
486
  this.model.tableHeight = tableHeight < 50 ? 350 : tableHeight;
475
487
  this.$nextTick(() => {
476
488
  self.getScrollAttr();
@@ -629,12 +641,16 @@
629
641
  routerClickHandler(field, submitData, action) {
630
642
  let self = this;
631
643
  action = action || field.action;
632
-
644
+
633
645
  var clickAcion = function () {
634
646
  //若不是客户端方法,则直接访问接口
635
647
  if (!field.isClientFuntion) {
636
648
  if (field.isFormPageInTab || field.isSearchPageInTab) {// 外部框架tab页打开
637
649
  submitData = field.getActionPara(submitData).para;
650
+ if(field.pageStyle)
651
+ {
652
+ submitData.pageStyle=field.pageStyle;
653
+ }
638
654
  self.$common.getDataDrivenOpts().handler.openTab(action, submitData, field.pageTitle, self.model);
639
655
  }
640
656
  else if (field.isBrowserNewTab) {// 浏览器打开
@@ -775,12 +791,19 @@
775
791
  calculatingRowHeight() {
776
792
  let self = this;
777
793
  let count = 0;
778
-
779
- self.model.listData.forEach((v, i) => {
780
- if (typeof v.$heigth === "undefined" && self.$refs["rows." + i] && self.$refs["rows." + i].length > 0) {
781
- self.$set(v, "$heigth", self.$refs["rows." + i][0].clientHeight);
782
- }
783
- });
794
+
795
+ //查询出所有没有设置$heigth的数据并重新设置$heigth
796
+ let notHeigthData= self.model.listData.filter(item=>{
797
+ return item.$heigth=== undefined || item.$heigth<=0
798
+ })
799
+ if(notHeigthData&&notHeigthData.length>0)
800
+ {
801
+ notHeigthData.forEach((v, i) => {
802
+ if (self.$refs["rows." + i] && self.$refs["rows." + i].length > 0) {
803
+ self.$set(v, "$heigth", self.$refs["rows." + i][0].clientHeight);
804
+ }
805
+ });
806
+ }
784
807
 
785
808
  //for (let i = 0; i < self.model.listData.length; i++) {
786
809
  // if (self.$refs[]) {
@@ -855,9 +878,9 @@
855
878
  .ct-searchtable .ct-tr > .ct-td {
856
879
  /*border: 1px solid #e7e8eb;*/
857
880
  border-bottom: 1px solid #e7e8eb;
858
- /*border-right: 1px solid #e7e8eb;*/
859
- border-left: 1px solid #e7e8eb;
860
- padding: 2px 10px;
881
+ /*border-right: 1px solid #e7e8eb;
882
+ border-left: 1px solid #e7e8eb;*/
883
+ padding: 2px 20px;
861
884
  cursor: default;
862
885
  background-color: #ffffff;
863
886
  }
@@ -1018,7 +1041,7 @@
1018
1041
  }
1019
1042
 
1020
1043
  .ct-table .ct-searchtable-th {
1021
- text-align: center
1044
+ /*text-align: center*/
1022
1045
  }
1023
1046
 
1024
1047
  .ct-table .checkbox-td {
@@ -1026,4 +1049,7 @@
1026
1049
  width: 20px;
1027
1050
  left: 0px;
1028
1051
  }
1052
+ .ct-table .checkbox-td .checkbox-td-1{
1053
+ vertical-align: inherit;
1054
+ }
1029
1055
  </style>
@@ -0,0 +1,41 @@
1
+ <template>
2
+ <div class="ct-table-Statistics">
3
+ <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
4
+ <el-tab-pane v-for="(item, index) in editableTabs" :key="item.name" :label="item.title" :name="item.name" lazy>
5
+ </el-tab-pane>
6
+ </el-tabs>
7
+ </div>
8
+ </template>
9
+ <script>
10
+ export default {
11
+ name: 'ct-tableStatistics',
12
+ props: {
13
+ tip: String,
14
+ size: String
15
+ },
16
+ data() {
17
+ return {
18
+ activeName: '1',
19
+ editableTabs: [
20
+ { name: '1', title: '用户管理' },
21
+ { name: '2', title: '配置管理' },
22
+ { name: '3', title: '角色管理' },
23
+ { name: '4', title: '定时任务补偿' },
24
+ { name: '5', title: '定时任务补偿2' },
25
+ { name: '6', title: '定时任务补偿3' },
26
+ { name: '7', title: '定时任务补偿4' },
27
+ { name: '8', title: '定时任务补偿5' },
28
+ { name: '9', title: '定时任务补偿6' },
29
+ { name: '10', title: '定时任务补偿7' }
30
+ ],
31
+ }
32
+ },
33
+ methods: {
34
+ handleClick(tab, event) {
35
+ console.log(tab, event);
36
+ }
37
+ }
38
+ }
39
+ </script>
40
+ <style>
41
+ </style>
@@ -1,11 +1,12 @@
1
1
  <template>
2
2
  <div class="ct-tableToolbar" style="width:100%;" v-if="buttons && buttons.length > 0">
3
3
  <ul>
4
- <li v-for="btn in buttons" class="ct-ToolbarButton">
4
+ <li v-for="btn in buttons" class="ct-ToolbarButton max-ToolbarButton">
5
5
  <component :is="btn.is" :vmodel="btn"
6
6
  @click="clickHandler(btn,$event)"
7
7
  @importComplete="importComplete"
8
8
  v-if="btn.show"
9
+ :optionApi="optionApi"
9
10
  :fileData="getFileData(btn)"></component>
10
11
  </li>
11
12
  </ul>
@@ -16,7 +17,8 @@
16
17
  name: 'ctTableToolbar',
17
18
  props: {
18
19
  buttons: Array,
19
- searchModel: Object
20
+ searchModel: Object,
21
+ optionApi:String
20
22
  },
21
23
  data() {
22
24
  return {};
@@ -42,8 +44,9 @@
42
44
  width:100%;
43
45
  position:relative;
44
46
  float:left;
45
- padding:10px;
46
- background-color:#fafafa;
47
+ padding:0 15px 10px 15px;
48
+ background-color:#fff;
49
+ border-radius: 6px;
47
50
  }
48
51
  .ct-tableToolbar ul {
49
52
  list-style: none; /* 去掉ul前面的符号 */
@@ -166,7 +166,6 @@
166
166
  this.$set(this, 'focus', false);
167
167
  },
168
168
  clickHandle: function () {
169
- debugger;
170
169
  if (this.model.lock) {
171
170
  return false;
172
171
  }