bri-components 1.4.81 → 1.4.83

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": "bri-components",
3
- "version": "1.4.81",
3
+ "version": "1.4.83",
4
4
  "author": "dengshanghui",
5
5
  "description": "a component lib for vue project",
6
6
  "main": "src/index.js",
@@ -262,7 +262,6 @@
262
262
  loadingText: "加载中,请稍等……",
263
263
  finishedText: "暂无更多数据!",
264
264
  noDataText: "暂无数据",
265
- noDataImg: "https://apaas-static.oss-cn-beijing.aliyuncs.com/kongdata.png",
266
265
 
267
266
  ...this.propsObj
268
267
  };
@@ -83,9 +83,33 @@
83
83
  return {
84
84
  ...operationItem,
85
85
  width: operationItem.width || getOperationItemMaxWidth(operationItem),
86
- style: (operationItem._name_ || operationItem.name).split("/").length > 1
87
- ? `width: ${getOperationItemMaxWidth(operationItem)}px; `
88
- : undefined
86
+ style: {
87
+ ...(
88
+ (operationItem._name_ || operationItem.name).split("/").length > 1
89
+ ? { width: `${getOperationItemMaxWidth(operationItem)}px` }
90
+ : {}
91
+ ),
92
+ ...(
93
+ typeof operationItem.style === "object"
94
+ ? operationItem.style
95
+ : typeof operationItem.style === "string"
96
+ ? operationItem.style.split(";").reduce((styleObj, styleItem) => {
97
+ if (styleItem) {
98
+ const property = styleItem.split(":")[0];
99
+ const val = styleItem.split(":")[1];
100
+
101
+ return {
102
+ ...styleObj,
103
+ [property]: val
104
+ };
105
+ }
106
+ else {
107
+ return styleObj;
108
+ }
109
+ }, {})
110
+ : {}
111
+ )
112
+ }
89
113
  };
90
114
  });
91
115
  },
@@ -53,7 +53,7 @@
53
53
  :isLoading="isLoading"
54
54
  :columns="showColumns"
55
55
  :data="isLoading ? [] : showListData"
56
- :propsObj="tablePropsObj"
56
+ :propsObj="tableInModalPropsObj"
57
57
  @changeSelect="changeSelect"
58
58
  @selectAll="changeSelect"
59
59
  ></bri-table>
@@ -451,18 +451,13 @@ export default {
451
451
  .map(rowItem => rowItem._id)
452
452
  .filter(id => !!id);
453
453
  },
454
- // 渲染过的行
455
- renderedListData () {
456
- return this.allListData.filter(rowItem => {
457
- this.dealSearchShow(rowItem);
458
-
459
- return rowItem.__isRendered__;
460
- });
461
- },
462
454
  // 全部数据 或 筛选时符合条件的数据
463
455
  showListData () {
464
- return this.renderedListData
465
- .filter(rowItem => !!rowItem[this.controlShowKey])
456
+ return this.allListData
457
+ .filter(rowItem => {
458
+ this.dealSearchShow(rowItem);
459
+ return rowItem.__isRendered__ && !!rowItem[this.controlShowKey];
460
+ })
466
461
  .map((rowItem, rowIndex) => {
467
462
  rowItem.__index__ = rowIndex + 1;
468
463
  return rowItem;
@@ -25,7 +25,6 @@ export default {
25
25
  // btnType: "errorText",
26
26
  // icon: "ios-trash-outline",
27
27
  // size: "small",
28
- // color: "#E83636",
29
28
  // disabled: false,
30
29
  // event: "clickDeleteChilds"
31
30
  // }
@@ -54,7 +54,7 @@
54
54
  }
55
55
 
56
56
  return {
57
- class: ["cancel", "linkText", "primaryText", "errorLine", "errorText", "primaryLine"].includes(defaultType) ? `ivu-btn-${defaultType}` : "",
57
+ class: ["cancel", "errorLine", "primaryLine", "linkText", "primaryText", "errorText"].includes(defaultType) ? `ivu-btn-${defaultType}` : "",
58
58
  ...this.propsObj,
59
59
  btnType: setType,
60
60
  customIcon: this.propsObj.customIcon ? `bico-font ${this.propsObj.customIcon}` : undefined