tianheng-ui 0.1.5 → 0.1.6

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,7 +1,7 @@
1
1
  {
2
2
  "name": "tianheng-ui",
3
3
  "description": "A Vue.js project",
4
- "version": "0.1.5",
4
+ "version": "0.1.6",
5
5
  "author": "shu lang <403732931@qq.com>",
6
6
  "license": "MIT",
7
7
  "private": false,
@@ -1,17 +1,19 @@
1
1
  <template>
2
2
  <div class="widgetTable">
3
3
  <div class="table-title">查询字段</div>
4
- <div class="searchList">
5
- <div class="table-header">
6
- <div>拖动</div>
4
+ <div class="tableList searchList">
5
+ <div class="table-item table-header">
6
+ <div class="table-item-custom">拖动</div>
7
7
  <div>列名</div>
8
8
  <!-- <div>字段</div> -->
9
9
  <div>类型</div>
10
10
  <div>默认值</div>
11
- <div>数据来源</div>
11
+ <!-- <div>数据来源</div> -->
12
+ <div class="table-item-custom"></div>
13
+ <div class="table-item-custom">隐藏</div>
12
14
  </div>
13
15
  <draggable
14
- class="table-content"
16
+ class="search-content"
15
17
  v-model="searchData"
16
18
  v-bind="{
17
19
  group: 'people',
@@ -21,12 +23,8 @@
21
23
  }"
22
24
  @end="handleSearchMoveEnd"
23
25
  >
24
- <div
25
- v-for="item in searchData"
26
- :key="item.key"
27
- class="table-content-item"
28
- >
29
- <div class="drag">
26
+ <div v-for="item in searchData" :key="item.prop" class="table-item">
27
+ <div class="table-item-custom drag">
30
28
  <i class="iconfont icon-drag drag-widget"></i>
31
29
  </div>
32
30
  <div>{{ item.label }}</div>
@@ -52,29 +50,34 @@
52
50
  v-model="item.defaultValue"
53
51
  placeholder="请输入内容"
54
52
  size="mini"
53
+ clearable
55
54
  ></el-input>
56
55
  </div>
57
- <div>
56
+ <!-- <div>
58
57
  <template v-if="item.type === 'select'">
59
58
  <el-button type="text" size="mini" @click="handleStaticData(item)"
60
59
  >静态</el-button
61
60
  >
62
61
  <el-button type="text" size="mini" disabled>远端</el-button>
63
62
  </template>
63
+ </div> -->
64
+ <div class="table-item-custom"></div>
65
+ <div class="table-item-custom">
66
+ <el-checkbox v-model="item.hide"></el-checkbox>
64
67
  </div>
65
68
  </div>
66
69
  </draggable>
67
70
  </div>
68
71
  <div class="table-title">列表字段</div>
69
- <div class="tableList">
70
- <div class="table-header">
72
+ <div class="tableList" style="height: calc(100% - 240px);">
73
+ <div class="table-item table-header">
71
74
  <div class="table-item-custom">拖动</div>
72
75
  <div>列名</div>
73
76
  <!-- <div>字段</div> -->
74
77
  <div>对齐</div>
75
78
  <div>宽度</div>
76
79
  <div class="table-item-custom">排序</div>
77
- <div class="table-item-custom" style="width:50px">隐藏</div>
80
+ <div class="table-item-custom">隐藏</div>
78
81
  </div>
79
82
  <draggable
80
83
  class="table-content"
@@ -87,11 +90,7 @@
87
90
  }"
88
91
  @end="handleTableMoveEnd"
89
92
  >
90
- <div
91
- v-for="item in tableData"
92
- :key="item.prop"
93
- class="table-content-item"
94
- >
93
+ <div v-for="item in tableData" :key="item.prop" class="table-item">
95
94
  <div class="table-item-custom drag">
96
95
  <i class="iconfont icon-drag drag-widget"></i>
97
96
  </div>
@@ -230,42 +229,39 @@ export default {
230
229
  margin: 10px 0;
231
230
  border: 1px solid #dcdfe6;
232
231
  box-sizing: border-box;
233
-
234
- .table-content {
232
+ .search-content {
235
233
  height: 120px;
236
234
  overflow-y: overlay;
237
235
  }
238
236
  }
239
237
  .tableList {
240
238
  margin-top: 10px;
241
- height: calc(100% - 240px);
242
239
  border: 1px solid #dcdfe6;
243
240
 
241
+ .table-header {
242
+ background-color: #f5f7f9;
243
+ div {
244
+ flex: 1;
245
+ padding: 0 10px;
246
+ height: 40px;
247
+ line-height: 40px;
248
+ }
249
+ }
250
+
244
251
  .table-content {
245
252
  height: calc(100% - 40px);
246
253
  overflow-y: overlay;
247
254
  }
248
- .el-input-number--mini {
249
- width: 100%;
250
- }
251
- }
252
255
 
253
- .table-header {
254
- display: flex;
255
- align-items: center;
256
- background-color: #f5f7f9;
257
- div {
258
- flex: 1;
259
- padding: 0 10px;
260
- height: 40px;
261
- line-height: 40px;
262
- }
263
- }
264
- .table-content {
265
- .table-content-item {
256
+ .table-item {
266
257
  display: flex;
267
258
  align-items: center;
268
-
259
+ > div {
260
+ flex: 1;
261
+ height: 40px;
262
+ line-height: 40px;
263
+ padding: 0 10px;
264
+ }
269
265
  .drag {
270
266
  i {
271
267
  font-size: 14px;
@@ -273,19 +269,21 @@ export default {
273
269
  cursor: move;
274
270
  }
275
271
  }
276
- > div {
277
- flex: 1;
278
- height: 40px;
279
- line-height: 40px;
280
- padding: 0 10px;
272
+ .table-item-custom {
273
+ flex: none !important;
274
+ width: 60px !important;
275
+ text-align: center;
281
276
  }
282
277
  }
278
+
279
+ .el-input-number--mini {
280
+ width: 100%;
281
+ }
282
+ .el-select {
283
+ width: 100%;
284
+ }
283
285
  }
284
- .table-item-custom {
285
- flex: none !important;
286
- width: 60px !important;
287
- text-align: center;
288
- }
286
+
289
287
  // .table-content:hover::-webkit-scrollbar-thumb {
290
288
  // background-color: rgba(69, 90, 100, 0.2);
291
289
  // }