ocpview-pro 0.1.7 → 0.1.9

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": "ocpview-pro",
3
- "version": "0.1.7",
3
+ "version": "0.1.9",
4
4
  "title": "ocpviewPlus",
5
5
  "description": "A high quality Service UI components Library with Vue.js",
6
6
  "homepage": "",
@@ -144,7 +144,14 @@
144
144
  :dictData="dictData"
145
145
  />
146
146
  <!-- 列表快捷查询 -->
147
- <div v-show="filterFlag" style="margin-top: 20px">
147
+ <Modal
148
+ v-model="filterFlag"
149
+ :title="$t('高级查询')"
150
+ :width="90"
151
+ footer-hide
152
+ :styles="{ top: '20px' }"
153
+ @on-cancel="onFilterModalCancel"
154
+ >
148
155
  <BillConditionsBox
149
156
  ref="filter"
150
157
  @doAction="doAction"
@@ -152,7 +159,7 @@
152
159
  :config="config"
153
160
  :dictData="dictData"
154
161
  />
155
- </div>
162
+ </Modal>
156
163
  </div>
157
164
  </template>
158
165
  <script>
@@ -246,7 +253,9 @@ export default {
246
253
  }
247
254
  },
248
255
  conditionAction(obj) {
249
- // this.filterFlag = false;
256
+ if (obj.name === 'condition_searchFilter' || obj.name === 'condition_closeFilter') {
257
+ this.filterFlag = false;
258
+ }
250
259
  let data = this.$refs.filter.getData();
251
260
  this.updateScene(data.scenename, data);
252
261
  this.$emit("conditionAction", obj);
@@ -143,7 +143,14 @@
143
143
  </Col>
144
144
  </Row>
145
145
  </Card>
146
- <div v-show="filterFlag" style="margin-top: 14px">
146
+ <Modal
147
+ v-model="filterFlag"
148
+ :title="$t('高级查询')"
149
+ :width="90"
150
+ footer-hide
151
+ :styles="{ top: '20px' }"
152
+ @on-cancel="onFilterModalCancel"
153
+ >
147
154
  <BillConditionsBox
148
155
  ref="filter"
149
156
  @doAction="doAction"
@@ -151,7 +158,7 @@
151
158
  :config="config"
152
159
  :dictData="dictData"
153
160
  />
154
- </div>
161
+ </Modal>
155
162
  </div>
156
163
  </template>
157
164
  <script>
@@ -245,7 +252,9 @@ export default {
245
252
  }
246
253
  },
247
254
  conditionAction(obj) {
248
- // this.filterFlag = false;
255
+ if (obj.name === 'condition_searchFilter' || obj.name === 'condition_closeFilter') {
256
+ this.filterFlag = false;
257
+ }
249
258
  let data = this.$refs.filter.getData();
250
259
  this.updateScene(data.scenename, data);
251
260
  this.$emit("conditionAction", obj);
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <Card :padding="0" style="padding:14px 16px;" dis-hover>
3
- <Row type="flex" justify="start" align="middle" style="max-height:120px;overflow-y:auto;overflow-x:hidden" >
3
+ <Row type="flex" justify="start" align="middle">
4
4
  <Col v-for="temp in data" :key="temp.index" span="12">
5
5
  <BillConditionBox v-if="reset" :config="myConfig" :ref="temp.index" :curIndex="temp.index" :valueData="temp.form" @doAction="doAction" @inputValue="input"/>
6
6
  </Col>
@@ -10,10 +10,10 @@
10
10
  <p @click.stop="doAdd" style="cursor:pointer">
11
11
  <Row type="flex" justify="start" align="middle">
12
12
  <Col>
13
- <Icon custom="iconfont icon-custom-addcond" size="20" color="#AF292E"/>
13
+ <Icon custom="iconfont icon-custom-addcond" size="20" :style="{color: 'var(--mss-primary-color)'}"/>
14
14
  </Col>
15
15
  <Col>
16
- <span style="margin-left:18px;color:#AF292E;font-size:14px"> {{ $t('添加条件') }} </span>
16
+ <span style="margin-left:18px;font-size:14px" class="add-cond-text"> {{ $t('添加条件') }} </span>
17
17
  </Col>
18
18
  </Row>
19
19
  </p>
@@ -118,7 +118,7 @@ export default {
118
118
  let obj = {};
119
119
  obj.index ='index_0';
120
120
  obj.form = {};
121
- this.data.push(obj);
121
+ this.data.push(obj);
122
122
  }
123
123
  });
124
124
  }
@@ -153,7 +153,7 @@ export default {
153
153
  let obj = {};
154
154
  obj.index ='index_0';
155
155
  obj.form = {};
156
- this.data.push(obj);
156
+ this.data.push(obj);
157
157
  },
158
158
  clearData() {
159
159
  this.data = [];
@@ -214,12 +214,12 @@ export default {
214
214
  Object.assign(param,temp3);
215
215
  }
216
216
  }
217
- } else {
217
+ } else {
218
218
  param[obj.field] = {};
219
219
  if (obj.value.value !== undefined) {
220
- param[obj.field][obj.oper] = obj.value.value;
220
+ param[obj.field][obj.oper] = obj.value.value;
221
221
  } else {
222
- param[obj.field][obj.oper] = obj.value;
222
+ param[obj.field][obj.oper] = obj.value;
223
223
  }
224
224
  }
225
225
  } else {
@@ -229,21 +229,21 @@ export default {
229
229
  } else {
230
230
  param[obj.field] = {};
231
231
  if (obj.value.value !== undefined) {
232
- param[obj.field][obj.oper] = obj.value.value;
232
+ param[obj.field][obj.oper] = obj.value.value;
233
233
  } else {
234
- param[obj.field][obj.oper] = obj.value;
234
+ param[obj.field][obj.oper] = obj.value;
235
235
  }
236
- }
236
+ }
237
237
  }
238
-
238
+
239
239
  }
240
-
240
+
241
241
  if (para === undefined) {
242
242
  return param;
243
243
  } else {
244
244
  para.push(param);
245
245
  }
246
-
246
+
247
247
  },
248
248
  getQuerySearchParam () {
249
249
  if (this.data.length === 0) {
@@ -268,7 +268,7 @@ export default {
268
268
  if (el.form.relevance === 'and') {
269
269
  this.getCommomParam(el.form, paraAnd);
270
270
  }
271
-
271
+
272
272
  }
273
273
  });
274
274
  if (paraOr.length > 0) {
@@ -368,45 +368,48 @@ export default {
368
368
  position: relative;
369
369
  }
370
370
  }
371
-
371
+
372
372
  .ivu-btn {
373
373
  height:40px;
374
374
  }
375
- .ivu-btn-red {
376
- color: #fff;
377
- background-color: #AF292E;
378
- }
379
- .ivu-btn-red:hover {
380
- background-color: #FFB5B8;
381
- border-color: #FFB5B8;
382
- }
383
- .ivu-btn-red :focus {
384
- background-color: #7A2531;
385
- border-color: #7A2531;
386
- }
387
- .ivu-btn-black {
388
- color: #fff;
389
- background-color: #4D4E53;
375
+ .add-cond-text {
376
+ color: var(--mss-primary-color);
390
377
  }
378
+ // .ivu-btn-red {
379
+ // color: #fff;
380
+ // background-color: var(--mss-primary-color);
381
+ // }
382
+ // .ivu-btn-red:hover {
383
+ // background-color: var(--mss-primary-color-hover);
384
+ // border-color: var(--mss-primary-color-hover);
385
+ // }
386
+ // .ivu-btn-red:focus {
387
+ // background-color: var(--mss-primary-color-active);
388
+ // border-color: var(--mss-primary-color-active);
389
+ // }
390
+ // .ivu-btn-black {
391
+ // color: #fff;
392
+ // background-color: var(--mss-info-color);
393
+ // }
391
394
 
392
- .ivu-btn-black:hover {
393
- background-color: #CDD0D6;
394
- border-color: #CDD0D6;;
395
- }
396
- .ivu-btn-black:focus {
397
- background-color: #000000;
398
- border-color: #000000;;
399
- }
400
- .ivu-btn-default:hover {
401
- color: #EF6E73;
402
- background-color: #FFF9F9;
403
- border-color: #EF6E73;;
404
- }
405
- .ivu-btn-default:focus {
406
- color: #DF3D43;
407
- background-color: #FFF9F9;
408
- border-color: #DF3D43;
409
- }
395
+ // .ivu-btn-black:hover {
396
+ // background-color: #CDD0D6;
397
+ // border-color: #CDD0D6;
398
+ // }
399
+ // .ivu-btn-black:focus {
400
+ // background-color: #000000;
401
+ // border-color: #000000;
402
+ // }
403
+ // .ivu-btn-default:hover {
404
+ // color: var(--mss-error-color);
405
+ // background-color: #FFF9F9;
406
+ // border-color: var(--mss-error-color);
407
+ // }
408
+ // .ivu-btn-default:focus {
409
+ // color: var(--mss-error-color-active);
410
+ // background-color: #FFF9F9;
411
+ // border-color: var(--mss-error-color-active);
412
+ // }
410
413
  .modulecodetext {
411
414
  height:40px;
412
415
  text-align:center;
@@ -420,7 +423,7 @@ export default {
420
423
  height:32px;
421
424
  }
422
425
  }
423
-
426
+
424
427
  }
425
428
 
426
429
 
@@ -39,7 +39,9 @@
39
39
  <Tooltip placement="top">
40
40
  <template #content>
41
41
  <div>
42
- <span style="font-size: 12px"> {{ $t('表头设计') }} </span>
42
+ <span style="font-size: 12px">
43
+ {{ $t("表头设计") }}
44
+ </span>
43
45
  </div>
44
46
  </template>
45
47
  <p style="cursor: pointer" @click.stop="openColSet">
@@ -78,18 +80,30 @@ import elementResizeDetectorMaker from "element-resize-detector";
78
80
  import QueryBar from "./querybar.vue";
79
81
  import GridColSet from "./gridcolset.vue";
80
82
  import { resolveComponent } from "vue";
83
+ const billstatusColorMap = {
84
+ A: { text: "#fa8c16", background: "#fff7e6", border: "#fa8c16" },
85
+ N: { text: "#1677ff", background: "#e6f7ff", border: "#1677ff" },
86
+ S: { text: "#1677ff", background: "#e6f7ff", border: "#1677ff" },
87
+ Q: { text: "#f5222d", background: "#fff2f0", border: "#f5222d" },
88
+ T: { text: "#f5222d", background: "#fff2f0", border: "#f5222d" },
89
+ W: { text: "#fa8c16", background: "#fff7e6", border: "#fa8c16" },
90
+ X: { text: "#00875a", background: "#d4edda", border: "#00875a" },
91
+ Y: { text: "#52c41a", background: "#f0fff4", border: "#52c41a" },
92
+ C: { text: "#666666", background: "#f5f5f5", border: "#8c8c8c" },
93
+ };
94
+ const cardBillstatus = {
95
+ ...billstatusColorMap,
96
+ F: { text: "#fa8c16", background: "#fff7e6", border: "#fa8c16" },
97
+ };
81
98
  const columnColorConfig = {
82
- billstatus: {
83
- A: { text: "#fa8c16", background: "#fff7e6", border: "#fa8c16" },
84
- N: { text: "#1677ff", background: "#e6f7ff", border: "#1677ff" },
85
- S: { text: "#1677ff", background: "#e6f7ff", border: "#1677ff" },
86
- Q: { text: "#f5222d", background: "#fff2f0", border: "#f5222d" },
87
- T: { text: "#f5222d", background: "#fff2f0", border: "#f5222d" },
88
- W: { text: "#fa8c16", background: "#fff7e6", border: "#fa8c16" },
89
- X: { text: "#00875a", background: "#d4edda", border: "#00875a" },
90
- Y: { text: "#52c41a", background: "#f0fff4", border: "#52c41a" },
91
- C: { text: "#666666", background: "#f5f5f5", border: "#8c8c8c" },
92
- },
99
+ billstatus: billstatusColorMap,
100
+ bcfhshbz: cardBillstatus,
101
+ bcahshbz: cardBillstatus,
102
+ bcrhshbz: cardBillstatus,
103
+ bcbfshbz: cardBillstatus,
104
+ bcshshbz: cardBillstatus,
105
+ bcthshbz: cardBillstatus,
106
+ bahshbz: cardBillstatus,
93
107
  };
94
108
  export default {
95
109
  name: "mbillquerygrid",
@@ -250,7 +264,7 @@ export default {
250
264
  this.rowBtnData = btns;
251
265
  }
252
266
  if (this.rowBtnData.length > 0) {
253
- this.actionConfig.label = this.$t('操作');
267
+ this.actionConfig.label = this.$t("操作");
254
268
  this.actionConfig.key = "actionbtn";
255
269
  this.actionConfig.align = "center";
256
270
  this.actionConfig.render = this.actionRender;
@@ -4,7 +4,7 @@ import SimpleTree from "./simpletree.vue";
4
4
  import RowBtnToolbar from "./rowbtntoolbar.vue";
5
5
  import DetailBtnToolbar from "./detailbtntoolbar.vue";
6
6
  import BillTemplate from "./layouttemplate.vue";
7
- import mListDetails from "./listdetails.vue";
7
+ import mListDetails from "./RewriteListdetails/indexV3.vue"; // 备份:./listdetails.vue
8
8
  import mLeftListRightDetails from "./leftlistrightdetails.vue";
9
9
  import mLeftTreeRightDetails from "./lefttreerightdetails.vue";
10
10
  import mLeftListRightList from "./leftlistrightlist.vue";
@@ -1,4 +1,4 @@
1
- <template>
1
+ <template>
2
2
  <div class="querybar" >
3
3
  <Row type="flex" :gutter="0">
4
4
  <Col span='16'>
@@ -22,7 +22,7 @@
22
22
  <Dropdown trigger="custom" :visible="filterSceneFlag" @on-click="filterAction" placement="bottom-start" @on-clickoutside="closeFilterScene">
23
23
  <Badge class-name="badgeclass" :count="sceneNum">
24
24
  <ButtonGroup>
25
- <Button customIcon="iconfont icon-custom-filter" @click="updataFilterScene">{{ $t('高级查询') }}</Button>
25
+ <Button customIcon="iconfont icon-custom-filter" @click="updataFilterScene">{{ $t('高级查询') }}</Button>
26
26
  <Button v-if="!filterSceneFlag && sceneFlag" icon="ios-arrow-down" @click="openFilterScene"> </Button>
27
27
  <Button v-if="filterSceneFlag && sceneFlag" icon="ios-arrow-up" @click="closeFilterScene"> </Button>
28
28
  </ButtonGroup>
@@ -41,7 +41,7 @@
41
41
  <Col style="padding-right:10px;">
42
42
  <Dropdown trigger="custom" :visible="btnFlag" @on-click="action" placement="bottom-start" @on-clickoutside="closeBtn">
43
43
  <ButtonGroup>
44
- <Button customIcon="iconfont icon-custom-add" v-if="addDataBtnFlag" @click="addData">{{ $t('新增') }}</Button>
44
+ <Button customIcon="iconfont icon-custom-add" v-if="addDataBtnFlag" @click="addData">{{ $t('新增') }}</Button>
45
45
  <Button v-if="!btnFlag && moreBtnFlag" icon="ios-arrow-down" @click="openBtn"> </Button>
46
46
  <Button v-if="btnFlag && moreBtnFlag" icon="ios-arrow-up" @click="closeBtn"> </Button>
47
47
  </ButtonGroup>
@@ -56,13 +56,20 @@
56
56
  </Col>
57
57
  <Col>
58
58
  <PromptMessages style="height:100%"/>
59
- </COl>
59
+ </COl>
60
60
  </Row>
61
61
  </Col>
62
62
  </Row>
63
- <div v-show="filterFlag" style="margin-top:20px">
63
+ <Modal
64
+ v-model="filterFlag"
65
+ :title="$t('高级查询')"
66
+ :width="90"
67
+ footer-hide
68
+ :styles="{ top: '20px' }"
69
+ @on-cancel="onFilterModalCancel"
70
+ >
64
71
  <BillConditionsBox ref="filter" @doAction="doAction" @conditionAction="conditionAction" :config="config" :dictData="dictData"/>
65
- </div>
72
+ </Modal>
66
73
  </div>
67
74
  </template>
68
75
  <script>
@@ -87,7 +94,7 @@
87
94
  moduleMethod:{
88
95
  type:Array,
89
96
  default: () => {
90
- return [];
97
+ return [];
91
98
  }
92
99
  }
93
100
  } ,
@@ -157,7 +164,7 @@
157
164
  }
158
165
  });
159
166
  }
160
-
167
+
161
168
  if (this.myConfig.btnData !== undefined) {
162
169
  this.btnData = this.$Method.copy(this.myConfig.btnData);
163
170
  }
@@ -168,7 +175,7 @@
168
175
  el.icon = null;
169
176
  }
170
177
  });
171
-
178
+
172
179
  if (this.myConfig.sceneData !== undefined) {
173
180
  this.sceneData = this.$Method.copy(this.myConfig.sceneData);
174
181
  }
@@ -229,7 +236,7 @@
229
236
  if (el.children && el.children.length > 0) {
230
237
  for (let i=0;i<el.children.length; i++) {
231
238
  this.initDictkey(el.children[i]);
232
- }
239
+ }
233
240
  } else {
234
241
  if (el.dictkey) {
235
242
  if (el.data === undefined) {
@@ -297,7 +304,9 @@
297
304
  this.$emit('conditionAction',temp);
298
305
  },
299
306
  conditionAction(obj) {
300
- this.filterFlag = false;
307
+ if (obj.name === 'condition_searchFilter' || obj.name === 'condition_closeFilter') {
308
+ this.filterFlag = false;
309
+ }
301
310
  let data = this.$refs.filter.getData();
302
311
  this.updateScene(data.scenename,data);
303
312
  this.$emit('conditionAction',obj);
@@ -322,7 +331,7 @@
322
331
  this.$nextTick(() =>{
323
332
  this.hackReset = true;
324
333
  });
325
-
334
+
326
335
  },
327
336
  customClear () {
328
337
  this.$refs.field.setValue('');
@@ -390,7 +399,7 @@
390
399
  return false;
391
400
  } else {
392
401
  this.sceneData.push(obj.para);
393
-
402
+
394
403
  }
395
404
  }
396
405
  if (obj.para.flag === 'U') {
@@ -412,7 +421,7 @@
412
421
  if (index > -1) {
413
422
  this.sceneData.splice(index,1)
414
423
  }
415
- this.filterFlag = false;
424
+ this.filterFlag = false;
416
425
  }
417
426
  if (this.sceneData.length > 0) {
418
427
  this.sceneFlag = true;
@@ -450,6 +459,9 @@
450
459
  });
451
460
  }
452
461
  },
462
+ onFilterModalCancel() {
463
+ this.filterSceneFlag = false;
464
+ },
453
465
  updataFilterScene() {
454
466
  this.filterFlag = !this.filterFlag
455
467
  if (!this.selectedScence && this.filterFlag) {
@@ -477,9 +489,9 @@
477
489
  this.selectedScence ='';
478
490
  }
479
491
  },
480
-
492
+
481
493
  }
482
-
494
+
483
495
  };
484
496
  </script>
485
497
  <style lang="less" scoped>
package/src/index.js CHANGED
@@ -195,7 +195,7 @@ const install = function(app, opts = {}) {
195
195
  app.use(localePlus, opts.locale);
196
196
  setupCopyFormatRestore()
197
197
 
198
- VXETable.install(app)
198
+ VXETable.install(app,localePlus.i18n);
199
199
  app.config.globalProperties.$utils = XEUtils;
200
200
 
201
201
  iviewCoustom.initEview(ViewUI);
@@ -233,7 +233,7 @@ VXETable.setup({
233
233
  const install = (app, i18n) => {
234
234
  VXETable.setup({
235
235
  // 对组件内置的提示语进行国际化翻译
236
- // i18n: (key, args) => i18n.global.t(key, args)
236
+ i18n: (key, args) => i18n.global.t(key, args)
237
237
  });
238
238
  app.use(VXETable);
239
239
  };