|
|
@@ -180,7 +180,19 @@
|
|
|
@click="singleBatch"
|
|
|
v-if="
|
|
|
item.currentTaskDiagram &&
|
|
|
- item.currentTaskDiagram.isFirstTask == 1
|
|
|
+ item.currentTaskDiagram.isFirstTask == 1 &&
|
|
|
+ clientEnvironmentId != 3
|
|
|
+ "
|
|
|
+ >确认</view
|
|
|
+ >
|
|
|
+
|
|
|
+ <view
|
|
|
+ class="unit-btn"
|
|
|
+ @click="singleBatchTg"
|
|
|
+ v-if="
|
|
|
+ item.currentTaskDiagram &&
|
|
|
+ item.currentTaskDiagram.isFirstTask == 1 &&
|
|
|
+ clientEnvironmentId == 3
|
|
|
"
|
|
|
>确认</view
|
|
|
>
|
|
|
@@ -224,7 +236,10 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { createInProductBatch } from "@/api/pda/jobBooking.js";
|
|
|
+import {
|
|
|
+ createInProductBatch,
|
|
|
+ createInProductBatchTG,
|
|
|
+} from "@/api/pda/jobBooking.js";
|
|
|
// import checkboxTable from '../componentsTable/checkbox/checkbox.vue'
|
|
|
import batchProductJobBom from "./batchProductJobBom.vue";
|
|
|
import semiProductJobBomPL from "./semiProductJobBomPL.vue";
|
|
|
@@ -477,6 +492,41 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
|
|
|
+ singleBatchTg() {
|
|
|
+ if (!this.item.workReportInfo.formedNum)
|
|
|
+ return uni.showToast({
|
|
|
+ icon: "none",
|
|
|
+ title: "请输入合格品数",
|
|
|
+ });
|
|
|
+ if (
|
|
|
+ this.notFormedList[0].notFormedNum == "" ||
|
|
|
+ this.notFormedList[0].notFormedNum == null
|
|
|
+ )
|
|
|
+ return uni.showToast({
|
|
|
+ icon: "none",
|
|
|
+ title: "请输入不合格品数",
|
|
|
+ });
|
|
|
+
|
|
|
+ const req = {
|
|
|
+ formedNum: this.item.workReportInfo.formedNum,
|
|
|
+ notFormedNum: this.notFormedList[0].notFormedNum,
|
|
|
+ taskId: this.item.workReportInfo.taskId,
|
|
|
+ workOrderId: this.item.workReportInfo.workOrderId,
|
|
|
+ };
|
|
|
+
|
|
|
+ createInProductBatchTG(req).then((res) => {
|
|
|
+ if (res && res.length) {
|
|
|
+ this.forValue = res[0];
|
|
|
+
|
|
|
+ res.map((v) => {
|
|
|
+ v.selected = true;
|
|
|
+ });
|
|
|
+ this.tableData = res;
|
|
|
+ this.item.product = res;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
/**
|
|
|
* 更新批次号
|
|
|
*
|