Browse Source

涂装上线计划申请

pda_nev
李俊城 11 months ago
parent
commit
3bc073a1d6
  1. 58
      fe/PDA/pages/request/injectionPlanRequest.vue

58
fe/PDA/pages/request/injectionPlanRequest.vue

@ -21,11 +21,26 @@
<view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll">
<view class="uni-flex uni-row" style="flex-wrap: wrap; margin: 10rpx;">
<view class="uni-flex uni-row" style="flex-wrap: wrap; margin: 5rpx;">
<view class="uni-flex" style=" width: 50%; justify-content: center; margin-top: 40rpx; "
v-for="(item, index) in showList" :key="index">
<uni-tag style="width: 100%; margin-left: 20rpx;" :inverted="!item.checked" :circle="false"
:text="item.code+'\n'+item.desc1" type="primary" @click="setContainerModel(item)" />
<view class="uni-flex" style="flex-direction: column; margin-left: 10rpx; border-radius: 10rpx; border: 0.5px solid #000;padding: 5rpx;">
<view class="" style="">
<uni-tag :customStyle="customStyle" style="width: 100%;white-space: normal;" :inverted="!item.checked" :circle="false"
:text="item.code+'\n'+item.desc1" type="primary" @click="setContainerModel(item)" />
</view>
<view style="display: flex; flex-direction: row; align-items: center; width: 100%;">
<view class="" style="font-size: 32rpx;">
收容数
</view>
<com-number-box :ref="'comNumberBox_'+index" v-model="item.stdPackQty"
:max="999999" :min="0" style=''
@change="qtyChanged($event,item,index)">
</com-number-box>
</view>
</view>
</view>
</view>
@ -67,12 +82,14 @@
import comJobTopInfo from '@/mycomponents/comjob/comJobTopInfo.vue'
import comMessage from '@/mycomponents/common/comMessage.vue'
import winCollapseLocation from '@/mycomponents/wincom/winCollapseLocation.vue'
import comNumberBox from '@/mycomponents/common/comNumberBox.vue';
export default {
components: {
winEmptyView,
comJobTopInfo,
comMessage,
winCollapseLocation
winCollapseLocation,
comNumberBox
},
data() {
return {
@ -83,7 +100,10 @@
loadingType: "nomore",
showList: [],
toLocationInfo: null,
tabIndex:0
tabIndex:0,
customStyle:"white-space: normal;word-break:break-all"
};
},
filters: {
@ -142,6 +162,10 @@
this.showMessage("获取["+categoryName+"]信息失败,请在字典中维护")
}else {
this.showList = res;
this.showList.forEach(item=>{
item.defaultStdPackQty=item.stdPackQty
item.checked =false
})
}
}).catch(error => {
@ -175,10 +199,13 @@
})
},
setContainerModel(item) {
item.checked=!item.checked
this.showList.forEach(res => {
res.checked = false
if(res.code!=item.code){
res.checked = false
}
})
item.checked = true;
this.$forceUpdate()
},
@ -194,7 +221,8 @@
this.current=0
this.showList= []
this.toLocationInfo = null,
this.tabIndex = 0
this.tabIndex = 0 ;
this.$refs.comCollapseLocation.clearLocation();
},
submit(item) {
@ -230,7 +258,7 @@
itemDesc1: checked[0].desc1,
itemDesc2: checked[0].desc2,
uom: checked[0].basicUom,
qty: 1,
qty: checked[0].stdPackQty,
stdPackQty: checked[0].stdPackQty,
toLocationCode: this.toLocationInfo.code,
toLocationArea: this.toLocationInfo.areaCode,
@ -239,7 +267,7 @@
toWarehouseCode: localStorage.warehouseCode,
positionCode: "",
recommendType: "SEMI",
boxQty: 1
boxQty: checked[0].stdPackQty
}
params.details.push(item)
console.log("测试", JSON.stringify(params));
@ -266,7 +294,15 @@
}
this.tabIndex = index;
this.getCategoryList(this.tabs[index])
}
},
qtyChanged(value, item, index) {
if (value <= 0) {
item.qty = item.defaultHandleQty
this.$refs['comNumberBox_' + index][0].setValue(item.qty);
this.showMessage('数量不能小于或等于0')
return;
}
},
}
};
</script>

Loading…
Cancel
Save