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

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

@@ -84,6 +84,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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>
<a-col :md="6" :sm="24"> <a-col :md="6" :sm="24">
<a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol"> <a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input> <a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input>
@@ -165,9 +172,9 @@
<script> <script>
import BillDetail from '../bill/dialog/BillDetail' import BillDetail from '../bill/dialog/BillDetail'
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectSup, findBillDetailByNumber, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectSup, findBillDetailByNumber, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -208,6 +215,7 @@
supList: [], supList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
operNumberTotalStr: '0', operNumberTotalStr: '0',
allPriceTotalStr: '0', allPriceTotalStr: '0',
tabKey: "1", tabKey: "1",
@@ -251,6 +259,7 @@
this.getDepotData() this.getDepotData()
this.initSupplier() this.initSupplier()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -316,6 +325,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);
}
}
})
},
myHandleDetail(record) { myHandleDetail(record) {
findBillDetailByNumber({ number: record.number }).then((res) => { findBillDetailByNumber({ number: record.number }).then((res) => {
if (res && res.code === 200) { if (res && res.code === 200) {

View File

@@ -71,6 +71,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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> </template>
</a-row> </a-row>
</a-form> </a-form>
@@ -141,9 +148,9 @@
</template> </template>
<script> <script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getNowFormatYear, getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util' import { getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectSup, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectSup, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -179,6 +186,7 @@
supList: [], supList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
realityPriceTotal: '', realityPriceTotal: '',
tabKey: "1", tabKey: "1",
pageName: 'buyInReport', pageName: 'buyInReport',
@@ -217,6 +225,7 @@
this.initSupplier() this.initSupplier()
this.getDepotData() this.getDepotData()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -283,6 +292,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() { searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){ if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!') this.$message.warning('请选择单据日期!')

View File

@@ -85,6 +85,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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>
<a-col :md="6" :sm="24"> <a-col :md="6" :sm="24">
<a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol"> <a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input> <a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input>
@@ -166,9 +173,9 @@
<script> <script>
import BillDetail from '../bill/dialog/BillDetail' import BillDetail from '../bill/dialog/BillDetail'
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectOrgan, findBillDetailByNumber, getUserList, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectOrgan, findBillDetailByNumber, getUserList, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser } from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -210,6 +217,7 @@
depotList: [], depotList: [],
userList: [], userList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
operNumberTotalStr: '0', operNumberTotalStr: '0',
allPriceTotalStr: '0', allPriceTotalStr: '0',
tabKey: "1", tabKey: "1",
@@ -258,6 +266,7 @@
this.initSupplier() this.initSupplier()
this.initUser() this.initUser()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -330,6 +339,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);
}
}
})
},
myHandleDetail(record) { myHandleDetail(record) {
findBillDetailByNumber({ number: record.number }).then((res) => { findBillDetailByNumber({ number: record.number }).then((res) => {
if (res && res.code === 200) { if (res && res.code === 200) {

View File

@@ -70,6 +70,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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> </template>
</a-row> </a-row>
</a-form> </a-form>
@@ -140,9 +147,9 @@
</template> </template>
<script> <script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' 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 JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -179,6 +186,7 @@
organList: [], organList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
numSumTotalStr: '0', numSumTotalStr: '0',
priceSumTotalStr: '0', priceSumTotalStr: '0',
tabKey: "1", tabKey: "1",
@@ -214,6 +222,7 @@
this.getDepotData() this.getDepotData()
this.initSupplier() this.initSupplier()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { 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() { searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){ if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!') this.$message.warning('请选择单据日期!')

View File

@@ -234,7 +234,7 @@
}, },
created() { created() {
this.getDepotData() this.getDepotData()
this.loadTreeData() this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -266,7 +266,7 @@
return '' return ''
} }
}, },
loadTreeData(){ loadCategoryTreeData(){
let that = this; let that = this;
let params = {}; let params = {};
params.id=''; params.id='';

View File

@@ -85,6 +85,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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>
<a-col :md="6" :sm="24"> <a-col :md="6" :sm="24">
<a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol"> <a-form-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input> <a-input placeholder="请输入备注" v-model="queryParam.remark"></a-input>
@@ -166,9 +173,9 @@
<script> <script>
import BillDetail from '../bill/dialog/BillDetail' import BillDetail from '../bill/dialog/BillDetail'
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectOrgan, findBillDetailByNumber, getUserList, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectOrgan, findBillDetailByNumber, getUserList, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -210,6 +217,7 @@
depotList: [], depotList: [],
userList: [], userList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
operNumberTotalStr: '0', operNumberTotalStr: '0',
allPriceTotalStr: '0', allPriceTotalStr: '0',
tabKey: "1", tabKey: "1",
@@ -258,6 +266,7 @@
this.initSupplier() this.initSupplier()
this.initUser() this.initUser()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -330,6 +339,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);
}
}
})
},
myHandleDetail(record) { myHandleDetail(record) {
findBillDetailByNumber({ number: record.number }).then((res) => { findBillDetailByNumber({ number: record.number }).then((res) => {
if (res && res.code === 200) { if (res && res.code === 200) {

View File

@@ -70,6 +70,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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> </template>
</a-row> </a-row>
</a-form> </a-form>
@@ -140,9 +147,9 @@
</template> </template>
<script> <script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getFormatDate, getNowFormatYear, getPrevMonthFormatDate } from '@/utils/util' import { getFormatDate, getPrevMonthFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' 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 JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -179,6 +186,7 @@
organList: [], organList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
numSumTotalStr: '0', numSumTotalStr: '0',
priceSumTotalStr: '0', priceSumTotalStr: '0',
tabKey: "1", tabKey: "1",
@@ -214,6 +222,7 @@
this.getDepotData() this.getDepotData()
this.initSupplier() this.initSupplier()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { 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() { searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){ if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!') this.$message.warning('请选择单据日期!')

View File

@@ -71,6 +71,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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> </template>
</a-row> </a-row>
</a-form> </a-form>
@@ -141,9 +148,9 @@
</template> </template>
<script> <script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getNowFormatYear, getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util' import { getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectRetail, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectRetail, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -170,6 +177,7 @@
organId: undefined, organId: undefined,
depotId: undefined, depotId: undefined,
organizationId: undefined, organizationId: undefined,
categoryId: undefined,
mpList: getMpListShort(Vue.ls.get('materialPropertyList')), mpList: getMpListShort(Vue.ls.get('materialPropertyList')),
}, },
ipagination:{ ipagination:{
@@ -180,6 +188,7 @@
retailList: [], retailList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
realityPriceTotal: '', realityPriceTotal: '',
tabKey: "1", tabKey: "1",
pageName: 'retailOutReport', pageName: 'retailOutReport',
@@ -218,12 +227,11 @@
this.initRetail() this.initRetail()
this.getDepotData() this.getDepotData()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
moment, moment,
create(){
},
getQueryParams() { getQueryParams() {
let param = Object.assign({}, this.queryParam, this.isorter); let param = Object.assign({}, this.queryParam, this.isorter);
param.monthTime = this.queryParam.monthTime; param.monthTime = this.queryParam.monthTime;
@@ -286,6 +294,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() { searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){ if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!') this.$message.warning('请选择单据日期!')

View File

@@ -71,6 +71,13 @@
</a-tree-select> </a-tree-select>
</a-form-item> </a-form-item>
</a-col> </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> </template>
</a-row> </a-row>
</a-form> </a-form>
@@ -141,9 +148,9 @@
</template> </template>
<script> <script>
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import { getNowFormatYear, getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util' import { getMpListShort, getPrevMonthFormatDate, getFormatDate } from '@/utils/util'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import {findBySelectCus, getAllOrganizationTreeByUser} from '@/api/api' import {findBySelectCus, queryMaterialCategoryTreeList, getAllOrganizationTreeByUser} from '@/api/api'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import moment from 'moment' import moment from 'moment'
import Vue from 'vue' import Vue from 'vue'
@@ -179,6 +186,7 @@
cusList: [], cusList: [],
depotList: [], depotList: [],
orgaTree: [], orgaTree: [],
categoryTree:[],
realityPriceTotal: '', realityPriceTotal: '',
tabKey: "1", tabKey: "1",
pageName: 'saleOutReport', pageName: 'saleOutReport',
@@ -217,6 +225,7 @@
this.initCustomer() this.initCustomer()
this.getDepotData() this.getDepotData()
this.loadAllOrgaData() this.loadAllOrgaData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -285,6 +294,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() { searchQuery() {
if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){ if(this.queryParam.beginTime == '' || this.queryParam.endTime == ''){
this.$message.warning('请选择单据日期!') this.$message.warning('请选择单据日期!')

View File

@@ -25,6 +25,13 @@
<a-input placeholder="请输入条码名称助记码规格型号等信息" v-model="queryParam.materialParam"></a-input> <a-input placeholder="请输入条码名称助记码规格型号等信息" v-model="queryParam.materialParam"></a-input>
</a-form-item> </a-form-item>
</a-col> </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>
<a-col :md="6" :sm="24"> <a-col :md="6" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery">查询</a-button> <a-button type="primary" @click="searchQuery">查询</a-button>
@@ -103,6 +110,7 @@
import { JeecgListMixin } from '@/mixins/JeecgListMixin' import { JeecgListMixin } from '@/mixins/JeecgListMixin'
import JEllipsis from '@/components/jeecg/JEllipsis' import JEllipsis from '@/components/jeecg/JEllipsis'
import {getAction} from '@/api/manage' import {getAction} from '@/api/manage'
import { queryMaterialCategoryTreeList } from '@/api/api'
import { getMpListShort } from "@/utils/util" import { getMpListShort } from "@/utils/util"
import Vue from 'vue' import Vue from 'vue'
export default { export default {
@@ -131,6 +139,7 @@
pageSizeOptions: ['11', '21', '31', '101', '201'] pageSizeOptions: ['11', '21', '31', '101', '201']
}, },
depotList: [], depotList: [],
categoryTree:[],
tabKey: "1", tabKey: "1",
pageName: 'stockWarningReport', pageName: 'stockWarningReport',
// 默认索引 // 默认索引
@@ -167,6 +176,7 @@
}, },
created () { created () {
this.getDepotData() this.getDepotData()
this.loadCategoryTreeData()
this.initColumnsSetting() this.initColumnsSetting()
}, },
methods: { methods: {
@@ -186,6 +196,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);
}
}
})
},
exportExcel() { exportExcel() {
let list = [] let list = []
let head = '仓库,条码,名称,规格,型号,颜色,品牌,制造商,扩展信息,单位,库存,最低安全库存,最高安全库存,建议入库量,建议出库量' let head = '仓库,条码,名称,规格,型号,颜色,品牌,制造商,扩展信息,单位,库存,最低安全库存,最高安全库存,建议入库量,建议出库量'