doway-coms 2.11.85 → 2.11.87

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": "doway-coms",
3
- "version": "2.11.85",
3
+ "version": "2.11.87",
4
4
  "description": "doway组件库",
5
5
  "author": "dowaysoft",
6
6
  "main": "packages/index.js",
@@ -610,6 +610,48 @@
610
610
  <a-button @click="filterConfirm(scope.column)">确认</a-button>
611
611
  </div>
612
612
  </template>
613
+ <template #select_remote_filter="scope">
614
+ <div class="interceptor-filter-class">
615
+ <a-checkbox-group
616
+ v-model="scope.column.filters[0].data.displayValues"
617
+ @keyup.enter.native="filterConfirm(scope.column)"
618
+ >
619
+ <a-input
620
+ placeholder="请输入搜索内容"
621
+ @change="displayValueSearchTextChange(scope.column)"
622
+ v-model="scope.column.filters[0].data.displayValueSearchText"
623
+ :addon-before="
624
+ '已选' + scope.column.filters[0].data.displayValues.length
625
+ "
626
+ />
627
+ <div style="max-height: 200px; overflow-y: scroll">
628
+ <div
629
+ style="text-align: left"
630
+ v-for="loopSource in scope.column.params.dataSource"
631
+ :key="loopSource.value"
632
+ >
633
+ <a-checkbox
634
+ v-show="
635
+ loopSource.caption.indexOf(
636
+ scope.column.filters[0].data.displayValueSearchText
637
+ ) > -1
638
+ "
639
+ :value="loopSource.value"
640
+ style="margin: 5px 0"
641
+ >{{ loopSource.caption }}
642
+ </a-checkbox>
643
+ </div>
644
+ </div>
645
+ </a-checkbox-group>
646
+ <br />
647
+ <a-button
648
+ @click="saveFilterTable(scope.column)"
649
+ v-if="moduleCode && dataCode"
650
+ >默认配置</a-button
651
+ >
652
+ <a-button @click="filterConfirm(scope.column)">确认</a-button>
653
+ </div>
654
+ </template>
613
655
  <template #multiSelect_filter="scope">
614
656
  <div class="interceptor-filter-class">
615
657
  <a-checkbox-group
@@ -820,7 +862,7 @@ import BasePagination from '../../BasePagination/index'
820
862
  import exportCmp from './exportCmp.vue'
821
863
  import BasePulldown from '../../BasePulldown/index'
822
864
  import BaseGridAdjust from '../../BaseGridAdjust/index'
823
- import { saveUserModuleDataFieldApi, userResetApi, saveUserModuleDataPageSizeApi } from '../../utils/api'
865
+ import { saveUserModuleDataFieldApi, userResetApi, saveUserModuleDataPageSizeApi,commonOperationSearchDataApi } from '../../utils/api'
824
866
  import { gridDefaultValueDisplay } from '../../utils/filters'
825
867
  import SeqSetting from './SeqSetting'
826
868
  import request from '../../utils/request'
@@ -2220,7 +2262,13 @@ export default {
2220
2262
  // }
2221
2263
  colParams['le'] = originCol.le
2222
2264
  colParams['controlType'] = originCol.controlType
2223
- colParams['filterControlType'] = colParams['controlType']
2265
+ if(originCol.filterControlType){
2266
+ colParams['filterControlType'] = originCol.filterControlType
2267
+ colParams['filterLinkData'] = originCol.filterLinkData
2268
+ colParams['dataSource'] = []
2269
+ }else{
2270
+ colParams['filterControlType'] = colParams['controlType']
2271
+ }
2224
2272
  colParams['edit'] = false
2225
2273
  colParams['thousandDigit'] = originCol.thousandDigit
2226
2274
  if (originCol.editStates) {
@@ -3784,7 +3832,8 @@ export default {
3784
3832
  if (
3785
3833
  colInfo.params.controlType === controlType.multiSelect ||
3786
3834
  colInfo.params.controlType === controlType.select ||
3787
- colInfo.params.controlType === controlType.checkbox
3835
+ colInfo.params.controlType === controlType.checkbox ||
3836
+ colInfo.params.filterControlType === 'select_remote'
3788
3837
  ) {
3789
3838
  colInfo.filters[0].data.bindingValues.push(XEUtils.clone(item,true))
3790
3839
  this.$set(
@@ -3855,7 +3904,7 @@ export default {
3855
3904
  }
3856
3905
  } else if (
3857
3906
  column.params.controlType === controlType.select ||
3858
- column.params.controlType === controlType.multiSelect
3907
+ column.params.controlType === controlType.multiSelect
3859
3908
  ) {
3860
3909
  // 下拉
3861
3910
  data.push(item)
@@ -3915,7 +3964,8 @@ export default {
3915
3964
  if (
3916
3965
  loopColInfo.params.controlType === controlType.select ||
3917
3966
  loopColInfo.params.controlType === controlType.multiSelect ||
3918
- loopColInfo.params.controlType === controlType.checkbox
3967
+ loopColInfo.params.controlType === controlType.checkbox ||
3968
+ loopColInfo.params.filterControlType === 'select_remote'
3919
3969
  ) {
3920
3970
  colFilterExpression.expressions.push({
3921
3971
  field: loopColInfo.field,
@@ -4021,7 +4071,39 @@ export default {
4021
4071
 
4022
4072
  this.toolBarConfig.enabled = this.filterExpression.length > 0
4023
4073
  },
4024
- filterVisible({ column, visible }) {
4074
+ async filterVisible({ column, visible }) {
4075
+
4076
+ if(visible && column.params && column.params.filterControlType==='select_remote' && column.params.filterLoaded!==true){
4077
+ //已经加载过数据
4078
+ let postData = {
4079
+ moduleCode: this.moduleCode,
4080
+ dataCodes: [
4081
+ {
4082
+ dataCode: column.params.filterLinkData,
4083
+ searchParam: {
4084
+ begin:1,
4085
+ size: 0,
4086
+ sorts: [],
4087
+ expression: {
4088
+ expressions: [],
4089
+ operator: 'and'
4090
+ }
4091
+ }
4092
+ }
4093
+ ]
4094
+ }
4095
+ try {
4096
+ let res = await commonOperationSearchDataApi(postData)
4097
+ column.params['dataSource'] = res.content[column.params.filterLinkData].rows
4098
+ column.params['filterLoaded'] = true
4099
+ }catch(err){
4100
+ console.debug(err)
4101
+ return
4102
+ }finally{
4103
+ }
4104
+ }
4105
+
4106
+
4025
4107
  // 筛选前关闭所有展开行
4026
4108
  this.closeAllExpand()
4027
4109
  //重新设置绑定值
@@ -4192,7 +4274,8 @@ export default {
4192
4274
  })
4193
4275
  } else if (
4194
4276
  info.column.params.controlType === controlType.select ||
4195
- info.column.params.controlType === controlType.multiSelect
4277
+ info.column.params.controlType === controlType.multiSelect ||
4278
+ info.column.params.filterControlType === 'select_remote'
4196
4279
  ) {
4197
4280
  // 下拉
4198
4281
  returnOperator = '包含'
@@ -4231,7 +4314,8 @@ export default {
4231
4314
  if (
4232
4315
  colInfo.params.controlType === controlType.select ||
4233
4316
  colInfo.params.controlType === controlType.multiSelect ||
4234
- colInfo.params.controlType === controlType.checkbox
4317
+ colInfo.params.controlType === controlType.checkbox ||
4318
+ colInfo.params.filterControlType === 'select_remote'
4235
4319
  ) {
4236
4320
  // 复选清空筛选初始数据过滤
4237
4321
  if (!item.value) {
@@ -126,3 +126,10 @@ export function userResetApi(data) {
126
126
  params: data
127
127
  })
128
128
  }
129
+ export function commonOperationSearchDataApi(data) {
130
+ return request({
131
+ url: store.getters.baseUrl + '/searchData',
132
+ method: 'post',
133
+ data: data
134
+ })
135
+ }
@@ -93,6 +93,7 @@ export function successMsg(msg, desc){
93
93
  title: msgObj.title,
94
94
  content: msgObj.content,
95
95
  width: msgObj.width? msgObj.width : 416,
96
+ zIndex:1000000,
96
97
  onOk() {
97
98
  resolve(true)
98
99
  },