| | |
| | | <template> |
| | | <view> |
| | | <u-modal |
| | | v-model="show" |
| | | ref="uModal" |
| | | title="" |
| | | :show-cancel-button="true" |
| | | @confirm="confirm" |
| | | @cancel="cancel" |
| | | :async-close="true" |
| | | :loading="loading" |
| | | > |
| | | <u-modal v-model="show" ref="uModal" title="" :show-cancel-button="true" @confirm="confirm" @cancel="cancel" |
| | | :async-close="true"> |
| | | <view class="packing-registration-param"> |
| | | <scroll-view |
| | | scroll-y="true" |
| | | style=" |
| | | <scroll-view scroll-y="true" style=" |
| | | height: 100%; |
| | | transform: translateZ(0); |
| | | -webkit-font-smoothing: antialiased; |
| | | " |
| | | > |
| | | "> |
| | | <view class="packing-registration-param-view"> |
| | | <view class="packing-registration-param-item param-extra"> |
| | | <view class="packing-registration-param-item-left"> |
| | |
| | | <u-input class="item-one item-two" v-model="form.outBatchNo" /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | | <!-- <view class="packing-registration-param-item param-extra"> |
| | | <view class="packing-registration-param-item-left"> |
| | | <text class="item-one">投料批次</text> |
| | | </view> |
| | |
| | | disabled |
| | | /> |
| | | </view> |
| | | </view> |
| | | </view> --> |
| | | <view class="packing-registration-param-item param-extra"> |
| | | <view class="packing-registration-param-item-left"> |
| | | <text class="item-one">长度</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.overallLength" |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.overallLength" /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | |
| | | <text class="item-one">库位</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.proposedLocation" |
| | | disabled |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.proposedLocation" disabled /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | |
| | | <text class="item-one">净重</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.netWeight" |
| | | disabled |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.netWeight" disabled /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | | <!-- <view class="packing-registration-param-item param-extra"> |
| | | <view class="packing-registration-param-item-left"> |
| | | <text class="item-one">废料</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input class="item-one item-two" v-model="form.waste" /> |
| | | </view> |
| | | </view> |
| | | </view> --> |
| | | <view class="packing-registration-param-item param-extra"> |
| | | <view class="packing-registration-param-item-left"> |
| | | <text class="item-one">工序</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.name" |
| | | disabled |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.name" disabled /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | |
| | | <text class="item-one">成品外径测量值</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.outerDiameter" |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.outerDiameter" /> |
| | | </view> |
| | | </view> |
| | | <view class="packing-registration-param-item param-extra"> |
| | |
| | | <text class="item-one item-two">生产速度</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="form.productionSpeed" |
| | | /> |
| | | <u-input class="item-one item-two" v-model="form.productionSpeed" /> |
| | | </view> |
| | | </view> |
| | | </view> |
| | | </scroll-view> |
| | | </view> |
| | | </u-modal> |
| | | <u-modal |
| | | v-model="showModal" |
| | | title="" |
| | | :show-cancel-button="true" |
| | | :show-confirm-button="true" |
| | | @confirm="confirmTl" |
| | | @cancel="cancelTl" |
| | | > |
| | | <u-modal v-model="showModal" title="" :show-cancel-button="true" :show-confirm-button="true" |
| | | @confirm="confirmTl" @cancel="cancelTl"> |
| | | <view class="packing-registration-param"> |
| | | <view class="packing-registration-param-view"> |
| | | <view class="packing-registration-param-item param-extra"> |
| | |
| | | <text class="item-one">数量</text> |
| | | </view> |
| | | <view class="packing-registration-param-item-right"> |
| | | <u-input |
| | | class="item-one item-two" |
| | | v-model="detailedList.suppliedQuantity" |
| | | /> |
| | | <u-input class="item-one item-two" v-model="detailedList.suppliedQuantity" /> |
| | | </view> |
| | | </view> |
| | | </view> |
| | |
| | | form: {}, |
| | | ifsBatchNo: [], |
| | | productInputList: [], |
| | | loading: false, |
| | | // loading: false, |
| | | }; |
| | | }, |
| | | watch: { |
| | |
| | | }, |
| | | methods: { |
| | | confirm() { |
| | | if (this.loading) return; |
| | | // if (this.loading) return; |
| | | // if (!this.form.outerDiameter) { |
| | | // this.$u.toast("请输入成品外径测量值"); |
| | | // this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | |
| | | this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | | return; |
| | | } |
| | | if (!this.form.waste) { |
| | | this.$u.toast("请输入废料"); |
| | | this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | | return; |
| | | } |
| | | if (this.form.productInputList.length == 0) { |
| | | this.$u.toast("投料批次不能为空,请扫码投料"); |
| | | this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | | return; |
| | | } |
| | | this.operationTaskList.operationTaskId = this.operationTaskList.id; |
| | | this.form.operationTaskId = this.operationTaskList.id; |
| | | this.form.status = this.operationTaskList.status; |
| | | this.form.Persons = this.operationTaskList.Persons; |
| | | this.form.productStaffIds = this.operationTaskList.productStaffIds; |
| | | this.form.productStaffs = this.operationTaskList.productStaffs; |
| | | this.form.dutyRecordId = this.dutyId; |
| | | this.operationTaskList.productOutputList = []; // 创建一个空数组 |
| | | this.operationTaskList.productOutputList.push(this.form); // 向数组中添加元素 |
| | | console.log("this.operationTaskList", this.operationTaskList); |
| | | this.loading = true; |
| | | this.$u.api.workReporting |
| | | .submitPDA(this.operationTaskList) |
| | | .then((res) => { |
| | | this.$emit("update",this.operationTaskList); |
| | | this.$refs.uModal.cancel(); |
| | | }) |
| | | .finally(() => { |
| | | this.loading = false; |
| | | // if (!this.form.waste) { |
| | | // this.$u.toast("请输入废料"); |
| | | // this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | | // return; |
| | | // } |
| | | // if (this.form.productInputList.length == 0) { |
| | | // this.$u.toast("投料批次不能为空,请扫码投料"); |
| | | // this.$refs.uModal.clearLoading(); // 清除加载状态 |
| | | // return; |
| | | // } |
| | | // this.operationTaskList.operationTaskId = this.operationTaskList.id; |
| | | // this.form.operationTaskId = this.operationTaskList.id; |
| | | // this.form.status = this.operationTaskList.status; |
| | | // this.form.Persons = this.operationTaskList.Persons; |
| | | // this.form.productStaffIds = this.operationTaskList.productStaffIds; |
| | | // this.form.productStaffs = this.operationTaskList.productStaffs; |
| | | // this.form.dutyRecordId = this.dutyId; |
| | | // this.operationTaskList.productOutputList = []; // 创建一个空数组 |
| | | // this.operationTaskList.productOutputList.push(this.form); // 向数组中添加元素 |
| | | // console.log("this.operationTaskList", this.operationTaskList); |
| | | // this.loading = true; |
| | | // this.$u.api.workReporting |
| | | // .submitPDA(this.operationTaskList) |
| | | // .then((res) => { |
| | | // this.$emit("update",this.operationTaskList); |
| | | // this.$refs.uModal.cancel(); |
| | | // }) |
| | | // .finally(() => { |
| | | // this.loading = false; |
| | | // this.$refs.uModal.clearLoading(); |
| | | // }); |
| | | this.$emit("update", this.form); |
| | | this.$refs.uModal.clearLoading(); |
| | | }); |
| | | this.$refs.uModal.cancel(); |
| | | }, |
| | | cancel() { |
| | | this.show = false; |
| | |
| | | ::v-deep .u-input__input { |
| | | text-align: right !important; |
| | | } |
| | | |
| | | @import "../index.scss"; |
| | | </style> |