From cf511deeef3632573a19bfd66035c1d8f4af9045 Mon Sep 17 00:00:00 2001 From: mll Date: Sat, 14 Mar 2026 23:46:24 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=9A=E9=80=89(in)=20multiple=E5=92=8C?= =?UTF-8?q?=E6=9C=88=E4=BB=BD=E8=A1=A8=E5=A4=B4=E6=8C=89data=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E8=BF=94=E5=9B=9E=E5=AD=97=E6=AE=B5=E8=BF=87=E6=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../LowDesign/src/LowReport/index.vue | 29 ++++++++----------- 1 file changed, 12 insertions(+), 17 deletions(-) diff --git a/src/components/LowDesign/src/LowReport/index.vue b/src/components/LowDesign/src/LowReport/index.vue index 4fc1e23..48cd85f 100644 --- a/src/components/LowDesign/src/LowReport/index.vue +++ b/src/components/LowDesign/src/LowReport/index.vue @@ -296,7 +296,7 @@ const initTable = async () => { config.dicData=[{label:'1月',value:'1'},{label:'2月',value:'2'},{label:'3月',value:'3'},{label:'4月',value:'4'},{label:'5月',value:'5'},{label:'6月',value:'6'},{label:'7月',value:'7'},{label:'8月',value:'8'},{label:'9月',value:'9'},{label:'10月',value:'10'},{label:'11月',value:'11'},{label:'12月',value:'12'}] } } - if(['货品名称','货品名称','剂型','剂型名称','客户名称','客户','业务员'].includes(item.fieldName)&&config.search){ + if(['货品名称','货品','剂型','产品','产品名称','剂型名称','客户名称','客户','业务员'].includes(item.fieldName)&&config.search){ config.dataType= 'string' config.dictType= 'defaultTable' config.dicUrl= `/lideeyunji/report-data/list/${item.fieldName.includes('客户') ?'khxx':(item.fieldName.includes('业务员')?'ywyxx': 'hpmx')}` @@ -306,7 +306,7 @@ const initTable = async () => { pageNo:1 } config.filterable= true - config.multiple= true + config.collapseTags=true config.dicFormatter= (res) => { //请求数据格式化 const arr=[...new Set(res.records.map(item=>item[config.prop]))] @@ -314,6 +314,10 @@ const initTable = async () => { } config.searchType='select' } + + const moreIn="MORE_IN".includes(item.queryMode) + config.searchType=moreIn?'select':config.searchType + config.multiple=moreIn if(!!item.isAmount){ index==0?amountFieds.value.fistField=config.prop:'' @@ -598,21 +602,12 @@ const getTableData = async (isLoading = true) => { }) } - tableData.value = processedData - // amountFieds.value={ - // 'thissaqty_s':{ - // prop:'thissaqty', - // }, - // "monthsaqty_s":{ - // prop:'monthsaqty', - //}, - //'lastsaqty_s':{ - // prop:'lastsaqty' - //} - //} - //tableData.value[0]['thissaqty_s']=6083195687 - // tableData.value[0]['monthsaqty_s']=972705058 - // tableData.value[0]['lastsaqty_s']=6075936725 + tableData.value = processedData + Object.values(tableOption.value.column).forEach( item=>{ + item.hide=item.children?.every(child=>tableData.value[0]&&(tableData.value[0][child.prop]===undefined)) + item.hide? hideColumns.value.push(item.prop):'' + }) + let keys=Object.keys(amountFieds.value) if(!!keys.length&&!!tableData.value.length){