Browse Source

更改字段

master
邓宏 2 years ago
parent
commit
fa47f4b94e
  1. 1
      pages/massif/collectList.vue
  2. 6
      pages/purchase/agrProdList.vue
  3. 10
      pages/purchase/specs.vue
  4. 2
      pages/stock/agrWarehouse.vue

1
pages/massif/collectList.vue

@ -63,6 +63,7 @@
<text>{{v.typeOne}}</text> <text>{{v.supplier}}</text>
</view>
</view>
<u-empty v-if="list.length==0" text="为查询到相关信息" width="70%" icon="/static/noData.png"/>
</scroll-view>
</view>
</template>

6
pages/purchase/agrProdList.vue

@ -84,11 +84,11 @@ export default {
list:[],
total:0,
eventChannel:null,
mode:"",
intoPage:"",
}
},
onLoad(options){
this.mode=options.mode||'purchase'
this.intoPage=options.intoPage||'purchase'
this.eventChannel=this.getOpenerEventChannel()
this.search()
},
@ -125,7 +125,7 @@ export default {
},
toAddSepc(e){
uni.navigateTo({
url:`/pages/purchase/specs?goodsId=${e.id}&mode=${this.mode}`,
url:`/pages/purchase/specs?goodsId=${e.id}&intoPage=${this.intoPage}`,
events:{submit: e=>{
uni.navigateBack()
this.eventChannel.emit("submit",e)

10
pages/purchase/specs.vue

@ -182,7 +182,7 @@
<view class="tip" v-if="specStr">库存{{specStr}}</view>
</view>
<view class="card purchase" v-if="mode=='purchase'">
<view class="card purchase" v-if="intoPage=='purchase'">
<view class="title_mast">采购数量</view>
<view class="input">
<input placeholder="请输入采购数量" type="digit" v-model="formData.num"/>
@ -226,11 +226,11 @@ export default{
goodsDetail:{},
eventChannel:null,
mode:"",
intoPage:"",
}
},
async onLoad(options){
this.mode=options.mode
this.intoPage=options.intoPage
this.eventChannel=this.getOpenerEventChannel()
this.eventChannel.on("detail", detail=>{
this.formData.goodsName=detail.goodsName
@ -240,7 +240,7 @@ export default{
})
this.formData.goodsId=options.goodsId
//
if(this.mode=='purchase')this.setGoodsVal()
if(this.intoPage=='purchase')this.setGoodsVal()
},
methods:{
async setGoodsVal(val){
@ -290,7 +290,7 @@ export default{
if(!this.formData.goodsSpecification){
uni.showToast({title:"规格必选!",icon:"none"})
return false
}else if(!this.formData.num>0 && this.mode=="purchase"){
}else if(!this.formData.num>0 && this.intoPage=="purchase"){
uni.showToast({title:"采购数量必填!",icon:"none"})
return false
}

2
pages/stock/agrWarehouse.vue

@ -180,7 +180,7 @@ import request from '@/common/request'
},
toAddAgr(){
uni.navigateTo({
url:"/pages/purchase/agrProdList?mode=stock",
url:"/pages/purchase/agrProdList?intoPage=stock",
events:{submit: e=>{
this.agrDetail=e
this.formData.specId=e.specificationId

Loading…
Cancel
Save