bri-components 1.4.93 → 1.4.94

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 (156) hide show
  1. package/README.md +83 -83
  2. package/lib/0.bri-components.min.js +1 -0
  3. package/lib/1.bri-components.min.js +1 -0
  4. package/lib/10.bri-components.min.js +1 -0
  5. package/lib/11.bri-components.min.js +1 -0
  6. package/lib/2.bri-components.min.js +1 -0
  7. package/lib/3.bri-components.min.js +1 -0
  8. package/lib/4.bri-components.min.js +1 -0
  9. package/lib/5.bri-components.min.js +1 -0
  10. package/lib/6.bri-components.min.js +1 -0
  11. package/lib/7.bri-components.min.js +1 -0
  12. package/lib/8.bri-components.min.js +1 -0
  13. package/lib/9.bri-components.min.js +1 -0
  14. package/lib/bri-components.min.js +18 -0
  15. package/lib/styles/bundle.css +12 -12
  16. package/lib/styles/font/fontello.svg +31 -31
  17. package/package.json +125 -125
  18. package/src/.DS_Store +0 -0
  19. package/src/components/.DS_Store +0 -0
  20. package/src/components/Error/Error403.vue +42 -42
  21. package/src/components/Error/Error404.vue +40 -40
  22. package/src/components/Error/Error500.vue +51 -51
  23. package/src/components/Error/error.less +162 -162
  24. package/src/components/Error/errorBack.vue +40 -40
  25. package/src/components/controls/.DS_Store +0 -0
  26. package/src/components/controls/DshControlInput.vue +195 -195
  27. package/src/components/controls/base/BriUpload/BriUpload.vue +434 -434
  28. package/src/components/controls/base/BriUpload/BriUploadImage.vue +373 -373
  29. package/src/components/controls/base/BriUpload/uploadList.vue +724 -724
  30. package/src/components/controls/base/BriUpload/uploadMixin.js +446 -446
  31. package/src/components/controls/base/DshCascader/DshCascader.vue +210 -210
  32. package/src/components/controls/base/DshCascader/components/cascaderModal.vue +366 -366
  33. package/src/components/controls/base/DshCascader/components/cascaderPicker.vue +416 -416
  34. package/src/components/controls/base/DshCascader/components/cascaderSimple.vue +143 -143
  35. package/src/components/controls/base/DshCoordinates.vue +577 -577
  36. package/src/components/controls/base/DshDate/DshDate.vue +191 -191
  37. package/src/components/controls/base/DshDate/DshDaterange.vue +186 -186
  38. package/src/components/controls/base/DshDivider.vue +201 -201
  39. package/src/components/controls/base/DshEditor.vue +274 -274
  40. package/src/components/controls/base/DshInput/BriInputs.vue +166 -166
  41. package/src/components/controls/base/DshInput/DshInput.vue +255 -255
  42. package/src/components/controls/base/DshNumber/BriInputNumber/BriInputNumber.vue +435 -435
  43. package/src/components/controls/base/DshNumber/BriInputNumber/mixins/emitter.js +34 -34
  44. package/src/components/controls/base/DshNumber/BriInputNumber/mixins/form.js +14 -14
  45. package/src/components/controls/base/DshNumber/BriInputNumber/utils/assist.js +322 -322
  46. package/src/components/controls/base/DshNumber/DshNumber.vue +143 -143
  47. package/src/components/controls/base/DshNumber/DshNumberange.vue +109 -109
  48. package/src/components/controls/base/DshSelect/DshCheckbox.vue +168 -168
  49. package/src/components/controls/base/DshSelect/DshSelect.vue +180 -180
  50. package/src/components/controls/base/DshSwitch/DshSwitch.vue +115 -115
  51. package/src/components/controls/control.less +324 -324
  52. package/src/components/controls/controlMap.js +114 -114
  53. package/src/components/controls/extra/DshColor.vue +81 -81
  54. package/src/components/controls/extra/themeColor.vue +104 -104
  55. package/src/components/controls/extra/themeIcon.vue +114 -114
  56. package/src/components/controls/mixins/cascaderMixin.js +295 -295
  57. package/src/components/controls/mixins/cascaderPickerMixin.js +216 -216
  58. package/src/components/controls/mixins/cascaderTableMixin.js +130 -130
  59. package/src/components/controls/mixins/controlMixin.js +368 -368
  60. package/src/components/controls/mixins/dateMixin.js +149 -149
  61. package/src/components/controls/mixins/flatTableMixin.js +111 -111
  62. package/src/components/controls/mixins/numberMixin.js +112 -112
  63. package/src/components/controls/mixins/selectMixin.js +233 -233
  64. package/src/components/controls/mixins/switchMixin.js +87 -87
  65. package/src/components/controls/mixins/userAndDepartMixin.js +218 -218
  66. package/src/components/controls/senior/.DS_Store +0 -0
  67. package/src/components/controls/senior/DshLabels.vue +331 -331
  68. package/src/components/controls/senior/DshPackage.vue +57 -57
  69. package/src/components/controls/senior/cascaderTable.vue +210 -210
  70. package/src/components/controls/senior/flatTable.vue +135 -135
  71. package/src/components/controls/senior/selectDepartments.vue +438 -438
  72. package/src/components/controls/senior/selectUsers/departMenu.vue +293 -293
  73. package/src/components/controls/senior/selectUsers/selectUsers.vue +752 -752
  74. package/src/components/controls/special/DshBack.vue +42 -42
  75. package/src/components/controls/special/DshUndeveloped.vue +41 -41
  76. package/src/components/form/DshAdvSearch.vue +510 -510
  77. package/src/components/form/DshDefaultSearch.vue +258 -258
  78. package/src/components/form/DshForm.vue +494 -494
  79. package/src/components/form/searchMixin.js +375 -375
  80. package/src/components/list/BriCard.vue +95 -95
  81. package/src/components/list/BriTable.vue +205 -205
  82. package/src/components/list/BriTree.vue +529 -529
  83. package/src/components/list/BriTreeItem.vue +163 -163
  84. package/src/components/list/DshBox/DshBox.vue +219 -219
  85. package/src/components/list/DshBox/DshCard.vue +446 -446
  86. package/src/components/list/DshBox/DshCrossTable.vue +827 -827
  87. package/src/components/list/DshBox/DshList.vue +404 -404
  88. package/src/components/list/DshBox/DshPanel.vue +669 -669
  89. package/src/components/list/DshBox/DshSingleData.vue +119 -119
  90. package/src/components/list/DshBox/DshTable.vue +239 -239
  91. package/src/components/list/DshCascaderTable.vue +115 -115
  92. package/src/components/list/DshFlatTable.vue +339 -339
  93. package/src/components/list/DshPage.vue +194 -194
  94. package/src/components/list/DshTreeTable.vue +113 -113
  95. package/src/components/list/common/importModal.vue +243 -243
  96. package/src/components/list/common/quoteListModal.vue +206 -206
  97. package/src/components/list/mixins/DshCascaderTableMixin.js +278 -278
  98. package/src/components/list/mixins/DshFlatTableMixin.js +493 -493
  99. package/src/components/list/mixins/DshTreeTableMixin.js +286 -286
  100. package/src/components/list/mixins/tableBaseMixin.js +1661 -1661
  101. package/src/components/list/mixins/treeTableBaseMixin.js +149 -149
  102. package/src/components/other/BriAvatar.vue +166 -166
  103. package/src/components/other/BriCode.vue +125 -125
  104. package/src/components/other/BriCollapseTree.vue +207 -207
  105. package/src/components/other/BriGantt.vue +1084 -1084
  106. package/src/components/other/BriIframe.vue +116 -116
  107. package/src/components/other/BriLoading.vue +171 -171
  108. package/src/components/other/BriSvg.vue +28 -28
  109. package/src/components/other/DshColorPanel.vue +128 -128
  110. package/src/components/other/DshMenuNav.vue +188 -188
  111. package/src/components/small/BriButton.vue +71 -71
  112. package/src/components/small/BriDrawer.vue +169 -169
  113. package/src/components/small/BriTooltip.vue +87 -87
  114. package/src/components/small/DshBtnModal.vue +68 -68
  115. package/src/components/small/DshButtons.vue +324 -324
  116. package/src/components/small/DshDropdown.vue +225 -225
  117. package/src/components/small/DshIcons.vue +59 -59
  118. package/src/components/small/DshListRender.js +21 -21
  119. package/src/components/small/DshModal.vue +160 -160
  120. package/src/components/small/DshSteps.vue +141 -141
  121. package/src/components/small/DshTabs.vue +598 -598
  122. package/src/components/small/DshTabsSet.vue +309 -309
  123. package/src/components/small/DshTags.vue +251 -251
  124. package/src/components/small/DshTitle.vue +50 -50
  125. package/src/components/small/render.js +20 -20
  126. package/src/components/unit/DshFormUnit.vue +398 -398
  127. package/src/components/unit/DshListUnit.vue +115 -115
  128. package/src/components/unit/unitMixin.js +86 -86
  129. package/src/data/index.js +9 -9
  130. package/src/index.js +271 -271
  131. package/src/styles/.DS_Store +0 -0
  132. package/src/styles/bundle.css +12 -12
  133. package/src/styles/components/.DS_Store +0 -0
  134. package/src/styles/components/BriButton.less +292 -292
  135. package/src/styles/components/BriTable.less +344 -344
  136. package/src/styles/components/DshModal.less +257 -250
  137. package/src/styles/components/index.less +3 -3
  138. package/src/styles/global/animate.less +11 -11
  139. package/src/styles/global/base.less +45 -45
  140. package/src/styles/global/box.less +186 -186
  141. package/src/styles/global/control.less +122 -122
  142. package/src/styles/global/flex.less +282 -282
  143. package/src/styles/global/global.less +8 -8
  144. package/src/styles/global/text.less +59 -59
  145. package/src/styles/global/variables.less +85 -85
  146. package/src/styles/iconfont/iconfont.css +254 -254
  147. package/src/styles/iconfont/iconfont.json +422 -422
  148. package/src/styles/iconfont/iconfont.svg +137 -137
  149. package/src/styles/index.less +11 -11
  150. package/src/styles/reset-easytable.less +21 -21
  151. package/src/styles/reset-iview-controls.less +145 -145
  152. package/src/styles/reset-iview-other.less +49 -49
  153. package/src/styles/reset-iview-variables.less +34 -34
  154. package/src/styles/reset.less +45 -45
  155. package/src/utils/index.js +5 -5
  156. package/src/utils/table.js +175 -175
@@ -1,149 +1,149 @@
1
- import controlMixin from "./controlMixin.js";
2
- import { dynDateData } from "bri-datas";
3
-
4
- export default {
5
- mixins: [
6
- controlMixin
7
- ],
8
- components: {},
9
- props: {},
10
- data () {
11
- return {
12
- open: false,
13
- open0: false,
14
- open1: false
15
- };
16
- },
17
- computed: {
18
- basePropsObj () {
19
- return {
20
- _dateType: "date", // 子类型5种,"date", "datetime", "year", "month", "time"
21
-
22
- _useDynDate: false, // 使用动态时间
23
- _dynDateType: undefined, // 使用什么类型的动态时间,"start","end"
24
- _dynDateKeys: [], // 仅使用一些指定的动态时间
25
- _dynSearchKeys: [], // 筛选时-仅使用一些指定的动态时间
26
-
27
- _minDate: undefined, // 最小日期
28
- _maxDate: undefined, // 最大日期
29
- _transfer: true,
30
-
31
- ...this.propsObj,
32
- ...this.commonDealPropsObj
33
- };
34
- },
35
-
36
- subType () {
37
- return this.selfPropsObj._dateType;
38
- },
39
- useDynDate () {
40
- return this.isInSearch
41
- ? true
42
- : this.selfPropsObj._useDynDate;
43
- },
44
- dynDateType () {
45
- return this.selfPropsObj._dynDateType;
46
- },
47
- dynDateKeys () {
48
- return this.isInSearch
49
- ? this.selfPropsObj._dynSearchKeys
50
- : this.selfPropsObj._dynDateKeys;
51
- },
52
- dynDateList () {
53
- return (
54
- this.dynDateKeys.length
55
- ? this.dynDateKeys
56
- .map(dynDateKey =>
57
- dynDateData.find(dynDateItem => dynDateItem._key === dynDateKey)
58
- )
59
- .filter(dynDateItem => !!dynDateItem)
60
- : dynDateData
61
- ).filter(dynDateItem => dynDateItem.dateTypes.includes(this.subType));
62
- },
63
-
64
- curVal0: {
65
- get () {
66
- return this.getVal(this.value[this.controlKey][0]);
67
- },
68
- set (val) {
69
- this.$set(this.value, this.controlKey, [this.transformVal(val), this.value[this.controlKey][1] || ""]);
70
- this.change();
71
- }
72
- },
73
- curVal1: {
74
- get () {
75
- return this.getVal(this.value[this.controlKey][1]);
76
- },
77
- set (val) {
78
- this.$set(this.value, this.controlKey, [this.value[this.controlKey][0] || "", this.transformVal(val)]);
79
- this.change();
80
- }
81
- },
82
- showVal0 () {
83
- return this.getShowVal(this.curVal0);
84
- },
85
- showVal1 () {
86
- return this.getShowVal(this.curVal1);
87
- },
88
- mulShowVal () {
89
- return this.$isEmptyData(this.curValList[0]) && this.$isEmptyData(this.curValList[1])
90
- ? this.emptyShowVal
91
- : `${this.$transformToDateStr(this.curValList[0], "-", this.subType)} - ${this.$transformToDateStr(this.curValList[1], "-", this.subType)}`;
92
- }
93
- },
94
- created () { },
95
- methods: {
96
- // 点击快捷日期
97
- clickDynDate (val, index) {
98
- this[`curVal${index}`] = val;
99
- this.changeOpen(false, index);
100
- },
101
- // 点击清空
102
- clickClear (val, index) {
103
- this[`curVal${index}`] = val;
104
- // this.changeOpen(false, index);
105
- },
106
- // 日期值变化回调
107
- changeVal (val, index) {
108
- this[`curVal${index}`] = val;
109
- this.subType !== "datetime" && this.changeOpen(false, index);
110
- },
111
- changeOpen (bool, index) {
112
- if (!this.disabled) {
113
- this[`open${index}`] = bool;
114
- }
115
- },
116
-
117
- /* -------- 方法 ------- */
118
- getVal (val) {
119
- return this.$isDynDate(val)
120
- ? val
121
- : this.$transformToDateObj(val);
122
- },
123
- transformVal (val) {
124
- return this.$isDynDate(val)
125
- ? val
126
- : this.$transformToDateStr(val, "-", this.subType);
127
- },
128
- getShowVal (val) {
129
- return this.$isDynDate(val)
130
- ? (this.dynDateList.find(dynDateItem => dynDateItem._key === val) || { name: `"${val}"动态时间不存在` }).name
131
- : this.$transformToDateStr(val, "-", this.subType);
132
- },
133
-
134
- getShortCuts (index) {
135
- return this.useDynDate
136
- ? this.dynDateList
137
- .filter(dynDateItem =>
138
- index || index === 0 ? dynDateItem.numbers.includes(index) : true
139
- )
140
- .map(dynDateItem => ({
141
- text: dynDateItem.name,
142
- onClick: () => {
143
- this.clickDynDate(dynDateItem._key, index);
144
- }
145
- }))
146
- : [];
147
- }
148
- }
149
- };
1
+ import controlMixin from "./controlMixin.js";
2
+ import { dynDateData } from "bri-datas";
3
+
4
+ export default {
5
+ mixins: [
6
+ controlMixin
7
+ ],
8
+ components: {},
9
+ props: {},
10
+ data () {
11
+ return {
12
+ open: false,
13
+ open0: false,
14
+ open1: false
15
+ };
16
+ },
17
+ computed: {
18
+ basePropsObj () {
19
+ return {
20
+ _dateType: "date", // 子类型5种,"date", "datetime", "year", "month", "time"
21
+
22
+ _useDynDate: false, // 使用动态时间
23
+ _dynDateType: undefined, // 使用什么类型的动态时间,"start","end"
24
+ _dynDateKeys: [], // 仅使用一些指定的动态时间
25
+ _dynSearchKeys: [], // 筛选时-仅使用一些指定的动态时间
26
+
27
+ _minDate: undefined, // 最小日期
28
+ _maxDate: undefined, // 最大日期
29
+ _transfer: true,
30
+
31
+ ...this.propsObj,
32
+ ...this.commonDealPropsObj
33
+ };
34
+ },
35
+
36
+ subType () {
37
+ return this.selfPropsObj._dateType;
38
+ },
39
+ useDynDate () {
40
+ return this.isInSearch
41
+ ? true
42
+ : this.selfPropsObj._useDynDate;
43
+ },
44
+ dynDateType () {
45
+ return this.selfPropsObj._dynDateType;
46
+ },
47
+ dynDateKeys () {
48
+ return this.isInSearch
49
+ ? this.selfPropsObj._dynSearchKeys
50
+ : this.selfPropsObj._dynDateKeys;
51
+ },
52
+ dynDateList () {
53
+ return (
54
+ this.dynDateKeys.length
55
+ ? this.dynDateKeys
56
+ .map(dynDateKey =>
57
+ dynDateData.find(dynDateItem => dynDateItem._key === dynDateKey)
58
+ )
59
+ .filter(dynDateItem => !!dynDateItem)
60
+ : dynDateData
61
+ ).filter(dynDateItem => dynDateItem.dateTypes.includes(this.subType));
62
+ },
63
+
64
+ curVal0: {
65
+ get () {
66
+ return this.getVal(this.value[this.controlKey][0]);
67
+ },
68
+ set (val) {
69
+ this.$set(this.value, this.controlKey, [this.transformVal(val), this.value[this.controlKey][1] || ""]);
70
+ this.change();
71
+ }
72
+ },
73
+ curVal1: {
74
+ get () {
75
+ return this.getVal(this.value[this.controlKey][1]);
76
+ },
77
+ set (val) {
78
+ this.$set(this.value, this.controlKey, [this.value[this.controlKey][0] || "", this.transformVal(val)]);
79
+ this.change();
80
+ }
81
+ },
82
+ showVal0 () {
83
+ return this.getShowVal(this.curVal0);
84
+ },
85
+ showVal1 () {
86
+ return this.getShowVal(this.curVal1);
87
+ },
88
+ mulShowVal () {
89
+ return this.$isEmptyData(this.curValList[0]) && this.$isEmptyData(this.curValList[1])
90
+ ? this.emptyShowVal
91
+ : `${this.$transformToDateStr(this.curValList[0], "-", this.subType)} - ${this.$transformToDateStr(this.curValList[1], "-", this.subType)}`;
92
+ }
93
+ },
94
+ created () { },
95
+ methods: {
96
+ // 点击快捷日期
97
+ clickDynDate (val, index) {
98
+ this[`curVal${index}`] = val;
99
+ this.changeOpen(false, index);
100
+ },
101
+ // 点击清空
102
+ clickClear (val, index) {
103
+ this[`curVal${index}`] = val;
104
+ // this.changeOpen(false, index);
105
+ },
106
+ // 日期值变化回调
107
+ changeVal (val, index) {
108
+ this[`curVal${index}`] = val;
109
+ this.subType !== "datetime" && this.changeOpen(false, index);
110
+ },
111
+ changeOpen (bool, index) {
112
+ if (!this.disabled) {
113
+ this[`open${index}`] = bool;
114
+ }
115
+ },
116
+
117
+ /* -------- 方法 ------- */
118
+ getVal (val) {
119
+ return this.$isDynDate(val)
120
+ ? val
121
+ : this.$transformToDateObj(val);
122
+ },
123
+ transformVal (val) {
124
+ return this.$isDynDate(val)
125
+ ? val
126
+ : this.$transformToDateStr(val, "-", this.subType);
127
+ },
128
+ getShowVal (val) {
129
+ return this.$isDynDate(val)
130
+ ? (this.dynDateList.find(dynDateItem => dynDateItem._key === val) || { name: `"${val}"动态时间不存在` }).name
131
+ : this.$transformToDateStr(val, "-", this.subType);
132
+ },
133
+
134
+ getShortCuts (index) {
135
+ return this.useDynDate
136
+ ? this.dynDateList
137
+ .filter(dynDateItem =>
138
+ index || index === 0 ? dynDateItem.numbers.includes(index) : true
139
+ )
140
+ .map(dynDateItem => ({
141
+ text: dynDateItem.name,
142
+ onClick: () => {
143
+ this.clickDynDate(dynDateItem._key, index);
144
+ }
145
+ }))
146
+ : [];
147
+ }
148
+ }
149
+ };
@@ -1,111 +1,111 @@
1
- import controlMixin from "./controlMixin.js";
2
- import DshFlatTable from "../../list/DshFlatTable.vue";
3
-
4
- export default {
5
- mixins: [
6
- controlMixin
7
- ],
8
- components: {
9
- DshFlatTable
10
- },
11
- props: {},
12
- data () {
13
- return {};
14
- },
15
- computed: {
16
- selfPropsObj () {
17
- return {
18
- _subForm: [],
19
- _searchList: [], // 作为搜索的字段
20
- _tableAdvSearch: {
21
- logic: "and",
22
- conditions: []
23
- },
24
- ...this.propsObj
25
- };
26
- },
27
- defaultPropsObj () {
28
- return {
29
- ...this.selfPropsObj,
30
- _tableAdvSearch: {
31
- logic: "and",
32
- conditions: []
33
- }
34
- };
35
- },
36
- subForm () {
37
- return this.selfPropsObj._subForm;
38
- },
39
-
40
- searchList () {
41
- return this.selfPropsObj._searchList;
42
- },
43
- searchListMap () {
44
- return this.$arrToMap(this.searchList, "_key");
45
- },
46
- searchListFields () {
47
- return this.searchList.map(searchItem => searchItem._key);
48
- },
49
- tableAdvSearch () {
50
- return this.$transformAdvSearch(this.selfPropsObj._tableAdvSearch, this.allFormList, this.value);
51
- },
52
- dftAdvSearch () {
53
- return {
54
- logic: ["and", "or"].includes(this.tableAdvSearch.logic) ? this.tableAdvSearch.logic : "and",
55
- conditions: this.tableAdvSearch.conditions.filter(conditionItem =>
56
- this.searchListFields.includes(conditionItem.fieldKey)
57
- )
58
- };
59
- },
60
- // 配置的默认筛选值里 隐藏的看不到的筛选条件
61
- hideAdvSearch () {
62
- return {
63
- logic: ["and", "or"].includes(this.tableAdvSearch.logic) ? this.tableAdvSearch.logic : "and",
64
- conditions: this.tableAdvSearch.conditions.filter(conditionItem =>
65
- !this.searchListFields.includes(conditionItem.fieldKey)
66
- )
67
- };
68
- },
69
- // 过滤行数据的 最终的筛选条件
70
- finalTableAdvSearch () {
71
- return {
72
- logic: "and",
73
- conditions: [
74
- this.hideAdvSearch,
75
- this.dftAdvSearch
76
- ]
77
- };
78
- },
79
- isSearching () {
80
- return this.$isAdvSearching(this.finalTableAdvSearch);
81
- },
82
-
83
- curVal () {
84
- return this.value[this.controlKey] || {
85
- list: []
86
- };
87
- },
88
- showVal () {
89
- return `${this.curVal
90
- ? this.curVal.list.filter((row) =>
91
- this.isSearching
92
- ? this.$isAdvRelyAccord(this.finalTableAdvSearch, row)
93
- : true
94
- ).length
95
- : 0
96
- } 行`;
97
- }
98
- },
99
- created () { },
100
- methods: {
101
- // 校验方法 -供外部使用
102
- validate () {
103
- return this.$refs.table.validate();
104
- },
105
-
106
- // 发生变动
107
- change (...params) {
108
- this.$emit("change", ...params);
109
- }
110
- }
111
- };
1
+ import controlMixin from "./controlMixin.js";
2
+ import DshFlatTable from "../../list/DshFlatTable.vue";
3
+
4
+ export default {
5
+ mixins: [
6
+ controlMixin
7
+ ],
8
+ components: {
9
+ DshFlatTable
10
+ },
11
+ props: {},
12
+ data () {
13
+ return {};
14
+ },
15
+ computed: {
16
+ selfPropsObj () {
17
+ return {
18
+ _subForm: [],
19
+ _searchList: [], // 作为搜索的字段
20
+ _tableAdvSearch: {
21
+ logic: "and",
22
+ conditions: []
23
+ },
24
+ ...this.propsObj
25
+ };
26
+ },
27
+ defaultPropsObj () {
28
+ return {
29
+ ...this.selfPropsObj,
30
+ _tableAdvSearch: {
31
+ logic: "and",
32
+ conditions: []
33
+ }
34
+ };
35
+ },
36
+ subForm () {
37
+ return this.selfPropsObj._subForm;
38
+ },
39
+
40
+ searchList () {
41
+ return this.selfPropsObj._searchList;
42
+ },
43
+ searchListMap () {
44
+ return this.$arrToMap(this.searchList, "_key");
45
+ },
46
+ searchListFields () {
47
+ return this.searchList.map(searchItem => searchItem._key);
48
+ },
49
+ tableAdvSearch () {
50
+ return this.$transformAdvSearch(this.selfPropsObj._tableAdvSearch, this.allFormList, this.value);
51
+ },
52
+ dftAdvSearch () {
53
+ return {
54
+ logic: ["and", "or"].includes(this.tableAdvSearch.logic) ? this.tableAdvSearch.logic : "and",
55
+ conditions: this.tableAdvSearch.conditions.filter(conditionItem =>
56
+ this.searchListFields.includes(conditionItem.fieldKey)
57
+ )
58
+ };
59
+ },
60
+ // 配置的默认筛选值里 隐藏的看不到的筛选条件
61
+ hideAdvSearch () {
62
+ return {
63
+ logic: ["and", "or"].includes(this.tableAdvSearch.logic) ? this.tableAdvSearch.logic : "and",
64
+ conditions: this.tableAdvSearch.conditions.filter(conditionItem =>
65
+ !this.searchListFields.includes(conditionItem.fieldKey)
66
+ )
67
+ };
68
+ },
69
+ // 过滤行数据的 最终的筛选条件
70
+ finalTableAdvSearch () {
71
+ return {
72
+ logic: "and",
73
+ conditions: [
74
+ this.hideAdvSearch,
75
+ this.dftAdvSearch
76
+ ]
77
+ };
78
+ },
79
+ isSearching () {
80
+ return this.$isAdvSearching(this.finalTableAdvSearch);
81
+ },
82
+
83
+ curVal () {
84
+ return this.value[this.controlKey] || {
85
+ list: []
86
+ };
87
+ },
88
+ showVal () {
89
+ return `${this.curVal
90
+ ? this.curVal.list.filter((row) =>
91
+ this.isSearching
92
+ ? this.$isAdvRelyAccord(this.finalTableAdvSearch, row)
93
+ : true
94
+ ).length
95
+ : 0
96
+ } 行`;
97
+ }
98
+ },
99
+ created () { },
100
+ methods: {
101
+ // 校验方法 -供外部使用
102
+ validate () {
103
+ return this.$refs.table.validate();
104
+ },
105
+
106
+ // 发生变动
107
+ change (...params) {
108
+ this.$emit("change", ...params);
109
+ }
110
+ }
111
+ };