meixioacomponent 0.9.99 → 1.0.2

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.
@@ -45,6 +45,7 @@ declare class LinkViewClass implements LinkViewClassInterface {
45
45
  getPageConfig(): pageConfigType | null;
46
46
  getPermission(key: any): any;
47
47
  setActiveIndex(index: any): void;
48
+ deleteTableDataItemByProperty(property: string, value: any): void;
48
49
  }
49
50
  export default LinkViewClass;
50
51
  //# sourceMappingURL=LinkViewClass.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"LinkViewClass.d.ts","sourceRoot":"","sources":["../../packages/config/LinkViewClass.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,sBAAsB,EAAE,cAAc,EAAC,MAAM,iBAAiB,CAAC;AAGvE,cAAM,aAAc,YAAW,sBAAsB;IAC1C,KAAK,EAAE,IAAI,GAAG,QAAQ,CAAC;IACvB,QAAQ,EAAE,IAAI,CAAC;IACf,SAAS,EAAE,GAAG,EAAE,CAAC;IACjB,SAAS,EAAE;QACd,KAAK,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;KACnB,CAAC;IACK,UAAU,EAAE,IAAI,GAAG,cAAc,CAAC;IAClC,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;IACjD,cAAc,EAAE;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;IAChD,aAAa,EAAE;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/C,aAAa,EAAE;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;IAC/C,gBAAgB,EAAE,IAAI,CAAC;gBAElB,MAAM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d,IAAI;IAgBJ,cAAc;IAQd,aAAa;IAQb,gBAAgB;IAMhB,eAAe;IAIf,0BAA0B;IAI1B,YAAY;;;;;IAIZ,YAAY,IAAI,EAAE;IAOlB,aAAa;IAIb,aAAa,CAAC,GAAG,KAAA;IAIjB,cAAc,CAAC,KAAK,KAAA;IAIpB,6BAA6B,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG;CAS3D;AAED,eAAe,aAAa,CAAC"}
@@ -18,19 +18,19 @@ class LinkViewClass {
18
18
  this.pageConfig = null;
19
19
  this.activeIndex = 0;
20
20
  this.tablePermission = {
21
- key: '',
21
+ key: "",
22
22
  value: true,
23
23
  };
24
24
  this.editPermission = {
25
- key: '',
25
+ key: "",
26
26
  value: true,
27
27
  };
28
28
  this.delPermission = {
29
- key: '',
29
+ key: "",
30
30
  value: true,
31
31
  };
32
32
  this.addPermission = {
33
- key: '',
33
+ key: "",
34
34
  value: true,
35
35
  };
36
36
  this.refreshTableData = null;
@@ -48,8 +48,8 @@ class LinkViewClass {
48
48
  this.jugePermission();
49
49
  }
50
50
  jugePermission() {
51
- const { tablePermission, addPermission, editPermission, delPermission, } = this;
52
- const permissionList = componentConfig_1.default.store[`getters`]['permissions'];
51
+ const { tablePermission, addPermission, editPermission, delPermission } = this;
52
+ const permissionList = componentConfig_1.default.store[`getters`]["permissions"];
53
53
  tablePermission.value = (0, utils_1.judgeButtonPermission)(permissionList, tablePermission.key);
54
54
  editPermission.value = (0, utils_1.judgeButtonPermission)(permissionList, editPermission.key);
55
55
  delPermission.value = (0, utils_1.judgeButtonPermission)(permissionList, delPermission.key);
@@ -65,9 +65,9 @@ class LinkViewClass {
65
65
  current: 1,
66
66
  };
67
67
  this.pageConfig = {
68
- size: 'size',
69
- page: 'current',
70
- total: 'total',
68
+ size: "size",
69
+ page: "current",
70
+ total: "total",
71
71
  };
72
72
  }
73
73
  onHandNextData() {
@@ -114,5 +114,13 @@ class LinkViewClass {
114
114
  setActiveIndex(index) {
115
115
  this.activeIndex = index;
116
116
  }
117
+ deleteTableDataItemByProperty(property, value) {
118
+ let index = this.tableData.findIndex((item) => {
119
+ return item[`${property}`] === value;
120
+ });
121
+ if (index > -1) {
122
+ this.tableData.splice(index, 1);
123
+ }
124
+ }
117
125
  }
118
126
  exports.default = LinkViewClass;