库存物资赋码生成
This commit is contained in:
parent
0de37e701d
commit
dd0c463b29
@ -245,10 +245,13 @@ export default {
|
|||||||
this.loading = true;
|
this.loading = true;
|
||||||
listWmstock(this.queryParams).then(response => {
|
listWmstock(this.queryParams).then(response => {
|
||||||
if(response.rows){
|
if(response.rows){
|
||||||
if(this.warehouseCode.indexOf('VIR') == -1){
|
debugger;
|
||||||
|
if(this.warehouseCode != null && this.warehouseCode != undefined && this.warehouseCode.indexOf('VIR') >0 ){
|
||||||
|
this.wmstockList = response.rows;
|
||||||
|
}else {
|
||||||
//如果不是查询线边库的物资,则在查询结果中过滤掉线边库的数据
|
//如果不是查询线边库的物资,则在查询结果中过滤掉线边库的数据
|
||||||
this.wmstockList = response.rows.filter((el) =>{
|
this.wmstockList = response.rows.filter((el) =>{
|
||||||
return el.warehouseCode.indexOf('VIR') == -1;
|
return el.warehouseCode.indexOf('VIR') == -1;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
this.total = response.total;
|
this.total = response.total;
|
||||||
|
@ -272,7 +272,22 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
|
<!-- 库存 -->
|
||||||
|
<el-row v-else-if="form.barcodeType=='STOCK'">
|
||||||
|
<el-col :span="8">
|
||||||
|
<el-form-item label="物资编码" prop="bussinessCode">
|
||||||
|
<el-input v-model="form.bussinessCode" placeholder="请选择库存记录" >
|
||||||
|
<el-button slot="append" icon="el-icon-search" @click="handleMaterialStockSelect"></el-button>
|
||||||
|
</el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<StockSelect ref="stockSelect" @onSelected="onMaterialStockSelected"> </StockSelect>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="16">
|
||||||
|
<el-form-item label="物资信息" prop="bussinessName">
|
||||||
|
<el-input v-model="form.bussinessName" readonly="readonly" ></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
<!--根据不同的条码类型展示不同的业务内容选择 end-->
|
<!--根据不同的条码类型展示不同的业务内容选择 end-->
|
||||||
<el-row>
|
<el-row>
|
||||||
@ -316,6 +331,7 @@ import ItemSelect from "@/components/itemSelect/single.vue";
|
|||||||
import VendorSelect from "@/components/vendorSelect/single.vue";
|
import VendorSelect from "@/components/vendorSelect/single.vue";
|
||||||
import PackageSelectSingle from "@/components/package/single.vue";
|
import PackageSelectSingle from "@/components/package/single.vue";
|
||||||
import WorkstationSelect from "@/components/workstationSelect/simpletableSingle.vue"
|
import WorkstationSelect from "@/components/workstationSelect/simpletableSingle.vue"
|
||||||
|
import StockSelect from "@/components/stockSelect/single.vue"
|
||||||
import Barcodeconfig from "./config.vue"
|
import Barcodeconfig from "./config.vue"
|
||||||
import BarcodeBatchPrint from "./batchprint.vue"
|
import BarcodeBatchPrint from "./batchprint.vue"
|
||||||
import {getTreeList} from "@/api/mes/wm/warehouse"
|
import {getTreeList} from "@/api/mes/wm/warehouse"
|
||||||
@ -323,7 +339,7 @@ export default {
|
|||||||
name: "Barcode",
|
name: "Barcode",
|
||||||
dicts: ['mes_barcode_type','mes_barcode_formart','sys_yes_no'],
|
dicts: ['mes_barcode_type','mes_barcode_formart','sys_yes_no'],
|
||||||
components: {
|
components: {
|
||||||
ItemSelect,VendorSelect,PackageSelectSingle,Barcodeconfig,WorkstationSelect,BarcodeBatchPrint
|
ItemSelect,VendorSelect,PackageSelectSingle,Barcodeconfig,WorkstationSelect,StockSelect,BarcodeBatchPrint
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -578,6 +594,22 @@ export default {
|
|||||||
this.form.barcodeContent= "".concat(this.form.barcodeType,'-',this.form.bussinessCode);
|
this.form.barcodeContent= "".concat(this.form.barcodeType,'-',this.form.bussinessCode);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
/**
|
||||||
|
* 选择库存
|
||||||
|
*/
|
||||||
|
handleMaterialStockSelect(){
|
||||||
|
this.$refs.stockSelect.showFlag = true;
|
||||||
|
},
|
||||||
|
|
||||||
|
/**库存选择返回 */
|
||||||
|
onMaterialStockSelected(obj){
|
||||||
|
if(obj != undefined && obj != null){
|
||||||
|
this.form.bussinessId = obj.materialStockId;
|
||||||
|
this.form.bussinessCode = obj.itemCode;
|
||||||
|
this.form.bussinessName = "".concat(obj.itemName,'|',obj.specification,'|',obj.vendorName,'|',obj.batchCode);
|
||||||
|
this.form.barcodeContent= "".concat(this.form.barcodeType,'-',this.form.bussinessId);
|
||||||
|
}
|
||||||
|
},
|
||||||
handleConfig(){
|
handleConfig(){
|
||||||
this.$refs.barcodeconfig.showFlag = true;
|
this.$refs.barcodeconfig.showFlag = true;
|
||||||
},
|
},
|
||||||
|
Loading…
Reference in New Issue
Block a user