|
|
@ -93,7 +93,8 @@ import request from '@/common/request' |
|
|
|
return{ |
|
|
|
fields:{ |
|
|
|
specName:{label:"规格", disabled:true, agr:true}, |
|
|
|
number:{label:"入库数量", type:"digit",suffix:"袋", tip:""}, |
|
|
|
warning:{label:"预计值",type:"digit",suffix:"",agr:true}, |
|
|
|
number:{label:"入库数量", type:"digit",suffix:"", tip:""}, |
|
|
|
inOutBatchNo:{label:"入库批次号",agr:true, btnText:"生成", btnFun:()=>this.formData.inOutBatchNo=`RK${new Date().format('yyyyMMdd')}${new Date().getTime()}`}, |
|
|
|
warehouseId:{label:"选择仓库", type:"select",columns:[],value:[],agr:true}, |
|
|
|
inOutType:{label:"入库类型",type:"select",columns:[],value:[]}, |
|
|
@ -104,6 +105,7 @@ import request from '@/common/request' |
|
|
|
formData:{ |
|
|
|
enterpriseId: this.$store.getters['userInfo'].companyId, |
|
|
|
specName:"", |
|
|
|
warning:"", |
|
|
|
specId:"", |
|
|
|
number:"", |
|
|
|
warehouseId:"", |
|
|
@ -117,6 +119,7 @@ import request from '@/common/request' |
|
|
|
}, |
|
|
|
rules:{ |
|
|
|
number:{required:true,type:"number", message:"入库数量必填!"}, |
|
|
|
warning:{required:true,type:"number", message:"入库数量必填!"}, |
|
|
|
inOutBatchNo:{required:true, message:"入库批次号必填!"}, |
|
|
|
warehouseId:{required:true, message:"仓库必选!"}, |
|
|
|
inOutType:{required:true, message:"入库类型必选!"}, |
|
|
@ -139,6 +142,7 @@ import request from '@/common/request' |
|
|
|
watch:{ |
|
|
|
specs(n){ |
|
|
|
this.fields.number.suffix=n.specs[2] |
|
|
|
this.fields.warning.suffix=n.specs[2] |
|
|
|
if(n.num>0 && n.specs[0]){ |
|
|
|
this.fields.number.tip=`共计:${parseFloat(n.num)*parseFloat(n.specs[0])}${n.specs[1]}` |
|
|
|
}else{ |
|
|
@ -180,6 +184,7 @@ import request from '@/common/request' |
|
|
|
}) |
|
|
|
} |
|
|
|
}, |
|
|
|
//添加农资 |
|
|
|
toAddAgr(){ |
|
|
|
uni.navigateTo({ |
|
|
|
url:"/pages/purchase/agrProdList?intoPage=stock", |
|
|
|