|
@@ -51,9 +51,10 @@
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6" :sm="24">
|
|
<a-col :md="6" :sm="24">
|
|
<a-form-item label="库存情况">
|
|
<a-form-item label="库存情况">
|
|
- <a-select placeholder="请选择库存情况" id="inventoryQueryList-zeroQtyFlag" allowClear v-model="queryParam.zeroQtyFlag">
|
|
|
|
|
|
+ <!-- <a-select placeholder="请选择库存情况" id="inventoryQueryList-zeroQtyFlag" allowClear v-model="queryParam.zeroQtyFlag">
|
|
<a-select-option v-for="item in zeroQtyData" :key="item.id" :value="item.id">{{ item.name }}</a-select-option>
|
|
<a-select-option v-for="item in zeroQtyData" :key="item.id" :value="item.id">{{ item.name }}</a-select-option>
|
|
- </a-select>
|
|
|
|
|
|
+ </a-select> -->
|
|
|
|
+ <a-checkbox v-model="queryParam.zeroQtyFlag" id="inventoryQueryList-zeroQtyFlag">只查看有库存</a-checkbox>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
</template>
|
|
</template>
|
|
@@ -142,7 +143,7 @@ export default {
|
|
productTypeSn1: '', // 产品分类1
|
|
productTypeSn1: '', // 产品分类1
|
|
productTypeSn2: '', // 产品分类2
|
|
productTypeSn2: '', // 产品分类2
|
|
productTypeSn3: '', // 产品分类3
|
|
productTypeSn3: '', // 产品分类3
|
|
- zeroQtyFlag: undefined // 库存数量是否为0
|
|
|
|
|
|
+ zeroQtyFlag: false // 库存情况
|
|
},
|
|
},
|
|
productType: [],
|
|
productType: [],
|
|
exportLoading: false, // 导出loading
|
|
exportLoading: false, // 导出loading
|
|
@@ -166,7 +167,13 @@ export default {
|
|
parameter.sortField = 'currentStockCost'
|
|
parameter.sortField = 'currentStockCost'
|
|
parameter.sortAlias = 'stock'
|
|
parameter.sortAlias = 'stock'
|
|
}
|
|
}
|
|
- return stockList(Object.assign(parameter, this.queryParam)).then(res => {
|
|
|
|
|
|
+ const params = Object.assign(parameter, this.queryParam)
|
|
|
|
+ if (params.zeroQtyFlag) {
|
|
|
|
+ params.zeroQtyFlag = '0'
|
|
|
|
+ } else {
|
|
|
|
+ params.zeroQtyFlag = ''
|
|
|
|
+ }
|
|
|
|
+ return stockList(params).then(res => {
|
|
const data = res.data
|
|
const data = res.data
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
@@ -175,7 +182,7 @@ export default {
|
|
this.disabled = false
|
|
this.disabled = false
|
|
this.spinning = false
|
|
this.spinning = false
|
|
// 总计
|
|
// 总计
|
|
- this.getTotal(Object.assign(parameter, this.queryParam))
|
|
|
|
|
|
+ this.getTotal(params)
|
|
// 产品分类
|
|
// 产品分类
|
|
if (this.productTypeList.length == 0) {
|
|
if (this.productTypeList.length == 0) {
|
|
this.getProductType()
|
|
this.getProductType()
|
|
@@ -220,7 +227,7 @@ export default {
|
|
this.queryParam.productCode = ''
|
|
this.queryParam.productCode = ''
|
|
this.queryParam.productOrigCode = ''
|
|
this.queryParam.productOrigCode = ''
|
|
this.queryParam.productName = ''
|
|
this.queryParam.productName = ''
|
|
- this.queryParam.zeroQtyFlag = undefined
|
|
|
|
|
|
+ this.queryParam.zeroQtyFlag = false
|
|
this.productType = []
|
|
this.productType = []
|
|
this.$refs.table.refresh(true)
|
|
this.$refs.table.refresh(true)
|
|
},
|
|
},
|