Browse Source

去除投料计划单号选择

master
lijuncheng 4 months ago
parent
commit
93546cd250
  1. 67
      src/pages/foam/input.vue
  2. 109
      src/pages/plastics/input.vue

67
src/pages/foam/input.vue

@ -2,40 +2,11 @@
<view class="page-wraper" @touchstart="touchScreen">
<view class="page-header flex"
style="font-size: 32rpx; padding-left: 10rpx; padding-top: 10rpx; flex-direction: column;">
<!-- <view class="flex u-col-center space-between">
<view class="" style="font-size: 35rpx;">
计划单号 : {{planNumber}}
<text v-if="planName!=''">({{planName}})</text>
</view>
<view class="">
<button type="primary" size="mini" @click="showPlanSelect">选择单号</button>
</view>
</view> -->
<!-- <view class="" style="width: 100%;background-color: gray;height: 2rpx; margin-top: 10rpx;" /> -->
</view>
<view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll">
<view style="padding-bottom: 80rpx;width: 100%;">
<view class="uni-flex uni-column " style="margin: 10rpx;">
<!-- <view class="" style="font-size: 35rpx;">
计划单号
</view> -->
<uni-section title="计划单号" subTitle="选择计划单号" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
<view class="" style="width: 75%; ">
<uni-easyinput disabled style="margin-left: 10rpx; margin-right: 10rpx;" trim="all"
v-model="planNumber"></uni-easyinput>
</view>
<view class="uni-flex" style="width: 25%; align-items: center;">
<button type="primary" size="mini" @click="showPlanSelect">单号</button>
</view>
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="原料名称" subTitle="输入或者选择原料名称" subTitleFontSize="26rpx" titleFontSize="35rpx"
@ -81,7 +52,6 @@
</view>
</view>
<selectClickList ref="selectPopup" title="选择计划单号" @select="selectPlan"></selectClickList>
<selectClickList ref="selectPopupMaterial" title="选择原料" @select="selectMaterial"></selectClickList>
</view>
@ -99,7 +69,6 @@
</script>
<script>
import {
getFoamPlaneNumberList,
getMaterialLists,
foamInputSubmit
} from '@/api/request2.js';
@ -120,7 +89,6 @@
data() {
return {
dateTime: "",
planNumber: "",
materialName: "",
materialCode: "",
materialQty: "",
@ -159,10 +127,6 @@
}
},
submit() {
if (this.planNumber == "") {
this.showMessage("请选择计划单号")
return
}
if (this.materialName == "") {
this.showMessage("请输入原料名称")
return
@ -176,7 +140,6 @@
mask: true
})
var param = {
planNumber: this.planNumber,
materialName: this.materialName,
materialCode: this.materialCode,
materialQty: this.materialQty,
@ -200,40 +163,10 @@
})
},
resetData() {
this.planNumber = "";
this.materialName = ""
this.materialQty = "";
this.materialCode = ""
},
showPlanSelect() {
uni.showLoading({
title: "加载中",
mask: true
})
getFoamPlaneNumberList().then(res => {
uni.hideLoading()
if(res.Result.length>0){
var list = [];
list = res.Result;
list.forEach(res => {
res.label = res.PLAN_NO;
res.value = res.SHIFT_CODE
})
this.$refs.selectPopup.openScanPopup(list)
}else {
this.showMessage("原料列表为0")
}
}).catch(error => {
uni.hideLoading()
this.showMessage(error)
})
},
selectPlan(data) {
this.planNumber = data.label
console.log(data)
},
showMaterialSelect() {
uni.showLoading({

109
src/pages/plastics/input.vue

@ -2,36 +2,12 @@
<view class="page-wraper" @touchstart="touchScreen">
<view class="page-header flex"
style="font-size: 32rpx; padding-left: 10rpx; padding-top: 10rpx; flex-direction: column;">
<!-- <view class="flex u-col-center space-between">
<view class="" style="font-size: 35rpx;">
生产计划 : {{planNumber}}
<text v-if="planName!=''">({{planName}})</text>
</view>
<view class="">
<button type="primary" size="mini" @click="showPlanSelect">选择单号</button>
</view>
</view> -->
<!-- <view class="" style="width: 100%;background-color: gray;height: 2rpx; margin-top: 10rpx;" /> -->
</view>
<view class="page-main">
<scroll-view scroll-y="true" class="page-main-scroll">
<view style="padding-bottom: 80rpx;width: 100%;">
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="1.生产计划" subTitle="选择生产计划" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
<view class="" style="width: 75%;">
<uni-easyinput disabled trim="all" v-model="planNumber"></uni-easyinput>
</view>
<view class="uni-flex" style="width: 25%; align-items: center;">
<button type="primary" size="mini" @click="showPlanSelect">选择</button>
</view>
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="2.料筒号" subTitle="扫描料筒号" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="1.料筒号" subTitle="扫描料筒号" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
@ -43,7 +19,7 @@
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="3.零件号" subTitle="扫描零件号" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="2.零件号" subTitle="扫描零件号" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
@ -52,7 +28,7 @@
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="4.批次号" subTitle="扫描批次号" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="3.批次号" subTitle="扫描批次号" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
@ -61,7 +37,7 @@
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="5.参考号" subTitle="扫描参考号" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="4.参考号" subTitle="扫描参考号" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
@ -70,7 +46,7 @@
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="6.供应商编码" subTitle="扫描供应商编码" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="5.供应商编码" subTitle="扫描供应商编码" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
@ -79,7 +55,7 @@
</view>
</view>
<view class="uni-flex uni-column " style="margin: 10rpx;">
<uni-section title="7.重量" subTitle="输入重量" subTitleFontSize="26rpx" titleFontSize="35rpx"
<uni-section title="6.重量" subTitle="输入重量" subTitleFontSize="26rpx" titleFontSize="35rpx"
type="line">
</uni-section>
<view class="uni-flex space-between">
@ -102,7 +78,6 @@
</view>
</view>
</view>
<selectClickList ref="selectPopup" title="选择计划单号" @select="selectPlan" ></selectClickList>
</view>
@ -110,7 +85,6 @@
<script>
import {
getPlasticsPlaneNumberList,
getMaterialLists,
plasticsInputSubmit,
getBucketCode,
@ -135,7 +109,6 @@
data() {
return {
dateTime: "",
planNumber: "",
dataList: [],
userForm: {
names: [],
@ -189,7 +162,7 @@
this.itemCode = ""
this.itemCheckCode = ""
if (data == undefined || data == "") {
this.showMessage("2.料筒号", "输入料筒号")
this.showMessage("1.料筒号", "输入料筒号")
this.$refs.inputBucketCode.focused = true
return;
}
@ -204,11 +177,11 @@
this.itemCode = ""
this.bucketCheckCode = ""
this.$refs.inputBucketCode.focused = true
this.showMessage("2.料筒号", "请先扫描料筒号")
this.showMessage("1.料筒号", "请先扫描料筒号")
return;
}
if (data == undefined || data == "") {
this.showMessage("3.零件号", "输入零件号")
this.showMessage("2.零件号", "输入零件号")
this.$refs.inputItemCode.focused = true
return;
}
@ -223,7 +196,7 @@
this.itemCode = ""
this.itemCheckCode = "";
this.$refs.inputItemCode.focused = true
this.showMessage("3.零件号", "零件号【" + data + "】无效," + error)
this.showMessage("2.零件号", "零件号【" + data + "】无效," + error)
// this.showMessage("3.",error)
})
@ -231,87 +204,81 @@
onConfirmBatchCode(data) {
if (data == undefined || data == "") {
this.showMessage("4.批次", "输入批次号位空")
this.showMessage("3.批次", "输入批次号位空")
return;
}
this.$refs.inputReferenceCode.focused = true
},
onConfirmReferenceCode(data) {
if (data == undefined || data == "") {
this.showMessage("4.批次", "输入参考号位空")
this.showMessage("3.批次", "输入参考号位空")
return;
}
this.$refs.inputSupplierCode.focused = true
},
onConfirmSupplierCode(data) {
if (data == undefined || data == "") {
this.showMessage("6.供应商编码", "输入供应商编码位空")
this.showMessage("5.供应商编码", "输入供应商编码位空")
return;
}
this.$refs.inputWeight.focused = true
},
onConfirmWeight(data) {
if (data == undefined || data == "") {
this.showMessage("7.数量", "输入数量为空")
this.showMessage("6.数量", "输入数量为空")
return;
}
},
submit() {
if (this.planNumber == "") {
this.showMessage("1.生产计划", "请选择生产计划")
return
}
if (this.bucketCode == "") {
this.bucketCode = ""
this.bucketCheckCode ==""
this.showMessage("2.料筒号", "请扫描料筒号")
this.showMessage("1.料筒号", "请扫描料筒号")
return
}
if (this.bucketCheckCode == "") {
this.showMessage("2.料筒号", "请按回车校验料筒号")
this.showMessage("1.料筒号", "请按回车校验料筒号")
return
}
if (this.itemCode == "") {
this.itemCode = ""
this.itemCheckCode = ""
this.showMessage("3.零件号", "请扫描零件号")
this.showMessage("2.零件号", "请扫描零件号")
return
}
if (this.itemCheckCode == "") {
this.showMessage("3.零件号", "请按回车校验零件号")
this.showMessage("2.零件号", "请按回车校验零件号")
return
}
if (this.batchCode == "") {
this.showMessage("4.批次号", "请扫描批次号")
this.showMessage("3.批次号", "请扫描批次号")
return
}
if (this.referenceCode == "") {
this.showMessage("5.参考号", "请扫描参考号")
this.showMessage("4.参考号", "请扫描参考号")
return
}
if (this.supplierCode == "") {
this.showMessage("6.供应商编码", "请扫描供应商")
this.showMessage("5.供应商编码", "请扫描供应商")
return
}
if (this.weight == "") {
this.showMessage("7.数量", "请输入重量")
this.showMessage("6.数量", "请输入重量")
return
}
if (this.weight == 0) {
this.showMessage("7.数量", "输入重量必须大于0")
this.showMessage("6.数量", "输入重量必须大于0")
return
}
var param = {
planNumber: this.planNumber,
bucketCode: this.bucketCheckCode,
itemCode: this.itemCheckCode,
batchCode: this.batchCode,
@ -360,7 +327,6 @@
})
},
resetData() {
this.planNumber = ""
this.bucketCheckCode = ""
this.bucketCode = ""
this.itemCheckCode = ""
@ -370,35 +336,6 @@
this.supplierCode = ""
this.weight = ""
},
showPlanSelect() {
uni.showLoading({
title: "加载中",
mask: true
})
getPlasticsPlaneNumberList().then(res => {
uni.hideLoading()
if(res.Result.length>0){
var list = [];
list = res.Result;
list.forEach(res => {
res.label = res.PLAN_NO;
res.value = res.SHIFT_CODE
})
this.$refs.selectPopup.openScanPopup(list)
}else {
this.showMessage("原料列表为0")
}
}).catch(error => {
uni.hideLoading()
this.showMessage("",error)
})
},
selectPlan(data) {
this.planNumber = data.label
console.log(data)
},
onConfirm(data) {
console.log(data.detail.value)

Loading…
Cancel
Save