给报表里面增加商品类别的查询条件

This commit is contained in:
jishenghua
2025-01-14 00:19:58 +08:00
parent edcada7d16
commit 9566071e91
10 changed files with 227 additions and 20 deletions

View File

@@ -70,6 +70,13 @@
</a-tree-select>
</a-form-item>
</a-col>
<a-col :md="6" :sm="24">
<a-form-item label="商品类别" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-tree-select style="width:100%" :dropdownStyle="{maxHeight:'200px',overflow:'auto'}" allow-clear
:treeData="categoryTree" v-model="queryParam.categoryId" placeholder="请选择商品类别">
</a-tree-select>
</a-form-item>
</a-col>
</template>
</a-row>
</a-form>
@@ -140,9 +147,9 @@
</template>
<script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util'
import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage'
import {findBySelectOrgan, getAllOrganizationTreeByUser} from '@/api/api'
import {findBySelectOrgan, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment'
import Vue from 'vue'
@@ -179,6 +186,7 @@
organList: [],
depotList: [],
orgaTree: [],
categoryTree:[],
numSumTotalStr: '0',
priceSumTotalStr: '0',
tabKey: "1",
@@ -214,6 +222,7 @@
this.getDepotData()
this.initSupplier()
this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting()
},
methods: {
@@ -279,6 +288,20 @@
}
})
},
loadCategoryTreeData(){
let that = this;
let params = {};
params.id='';
queryMaterialCategoryTreeList(params).then((res)=>{
if(res){
that.categoryTree = [];
for (let i = 0; i < res.length; i++) {
let temp = res[i];
that.categoryTree.push(temp);
}
}
})
},
searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!')