guoyujia 7 hónapja
szülő
commit
90c904e556

+ 16 - 0
api/business/drawing.js

@@ -35,6 +35,14 @@ export function getTechnologicalProcess(id) {
 		method: 'GET'
 	})
 }
+export function getLotTechnologicalProcess(data) {
+	return req.request({
+		url: '/business/technologicalProcess/getLotTechnologicalProcess',
+		// header: reqHeader,
+		method: 'GET',
+		data:data
+	})
+}
 /**
  * 获取工艺工序
  * @param id
@@ -54,4 +62,12 @@ export function getDeptProcess(data) {
 		method: 'GET',
 		data: data
 	})
+}
+export function getDeptLotProcess(data) {
+	return req.request({
+		url: '/business/drawing/listLotProcess',
+		// header: reqHeader,
+		method: 'GET',
+		data: data
+	})
 }

+ 21 - 0
api/business/sortDaywork.js

@@ -19,6 +19,27 @@ export function getInspectionList(data) {
 		data: data
 	})
 }
+export function selectInstructionList(data) {
+	return req.request({
+		url: '/business/sortDaywork/selectInstructionList',
+		method: 'POST',
+		data: data
+	})
+}
+export function getInstructionInfo(data) {
+	return req.request({
+		url: '/business/sortDaywork/getInstructionList',
+		method: 'POST',
+		data: data
+	})
+}
+export function getStandardList(data) {
+	return req.request({
+		url: '/business/sortDaywork/getStandardList',
+		method: 'Get',
+		data: data
+	})
+}
 
 export function saveConsult(data) {
 	return req.request({

+ 1 - 1
components/dialog-end-work/dialog-end-work.vue

@@ -23,7 +23,7 @@
 
 			<view class="list-title uni-row">
 				<text class="label">当前序是否完成</text><text>否</text>
-				<switch class="switch" @change="switchChange" color="rgba(255,85,85,1)" />
+				<switch class="switch" @change="switchChange" color="rgba(103, 195, 55, 1.0)" />
 				<text>是</text>
 			</view>
 			<view v-if="showCarrierList && !store.isPreProcess" class="confirmCarrier">

+ 1 - 1
components/dialog-lotReporting/dialog-lotReporting.vue

@@ -53,7 +53,7 @@
 			</view>
 			<view v-if="!isWx" class="item-info uni-row" style="margin-top: 12rpx;">
 				<text class="label" style="width: 250rpx;"  >下序是否包装</text><text style="margin-left: 24rpx;" class="label right">否</text>
-				<switch class="switch" @change="switchChange" :checked="normalStatus" style="transform: scale(0.8);align-items: center;font-size:32rpx ;" color="rgba(255,85,85,1)" />
+				<switch class="switch" @change="switchChange" :checked="normalStatus" style="transform: scale(0.8);align-items: center;font-size:32rpx ;" color="rgba(103, 195, 55, 1.0)" />
 				<text class=" label right">是</text>
 			</view>
 		</view>

+ 6 - 0
pages.json

@@ -117,6 +117,12 @@
 				"navigationBarTitleText": "检查项选择"
 			}
 		},
+		{
+			"path": "pages/sorting/specialOptions",
+			"style": {
+				"navigationBarTitleText": "检查项选择"
+			}
+		},
 		{
 			"path": "pages/sorting/storageRetrieval",
 			"style": {

+ 5 - 3
pages/batchReporting/index.vue

@@ -15,7 +15,7 @@
 			<!-- <div class="list-title uni-row"> -->
 			<text class="label">是否正常批次</text>
 			<text>{{ normalStatus ? '是' : '否' }}</text>
-			<switch class="switch" :checked="normalStatus" @change="switchChange" color="rgba(255,85,85,1)" />
+			<switch class="switch" :checked="normalStatus" @change="switchChange" color="rgba(103, 195, 55, 1.0)" />
 			<!-- <text>{{ }}</text> -->
 			<!-- </div> -->
 			<!-- 	<text class="label">是否正常批次</text><text>是</text>
@@ -75,8 +75,10 @@
 				</view>
 				<view class="item-info uni-row">
 					<text class="label">当前工序</text>
-					<text
-						class="label right">{{ item.currentProcess ? item.prevProcess && item['currentProcess'].processAlias == item['prevProcess'].processAlias ? '-' : item['currentProcess'].processAlias : '-'}}</text>
+					<!-- <text
+						class="label right">{{ item.currentProcess ? item.prevProcess && item['currentProcess'].processAlias == item['prevProcess'].processAlias ? '-' : item['currentProcess'].processAlias : '-'}}</text> -->
+						<text
+							class="label right">{{ item.currentProcess ? item['currentProcess'].processAlias : '-'}}</text>
 				</view>
 				<view class="item-info uni-row">
 					<text class="label">下道工序</text>

+ 19 - 16
pages/deliveryExamine/form.vue

@@ -277,23 +277,26 @@
 			}
 		}
 	} 
-	function handleDrawingMenu(){
-		  // 对 technologicalProcessDetailId 进行URL编码
-		  var encodedId = encodeURIComponent(processInspecion.value.lot.productId);
-		  var enTechnologicalProcessId = encodeURIComponent(processInspecion.value.lot.technologicalProcessId);
-		  var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
-		  var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
-		  var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
-		  // 构建查询参数字符串
-		  var queryParam = `param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
-		
-		  // 使用模板字符串构建完整的URL
-		  var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
-		
-		  // 导航到指定页面
-		  uni.navigateTo({
+	function handleDrawingMenu() {
+		// 对 technologicalProcessDetailId 进行URL编码
+		var encodedId = encodeURIComponent(processInspecion.value.lot.productId);
+		var enTechnologicalProcessId = encodeURIComponent(processInspecion.value.lot.technologicalProcessId);
+		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
+		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
+		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
+		// 构建查询参数字符串
+		var queryParam =
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
+
+		// 使用模板字符串构建完整的URL
+		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
+
+		// 导航到指定页面
+		uni.navigateTo({
 			url: navigateUrl
-		  });
+		});
 	}
 
 	//查询咨询列表

+ 6 - 4
pages/deliveryInspection/form.vue

@@ -134,7 +134,7 @@
 					<text class="label">是否移交仪器室</text><text>&nbsp;否</text>
 					<!-- <switch class="switch" @change="switchChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
-					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(255,85,85,1)"
+					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(103, 195, 55, 1.0)"
 						:size="18" style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -147,7 +147,7 @@
 						@change="switchAllCheckChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
 					<zero-switch v-model="isAllChecked" :disabled="!showTransfer || processInspecion.flag"
-						@change="switchAllCheckChange" active-color="rgba(255,85,85,1)" :size="18"
+						@change="switchAllCheckChange" active-color="rgba(103, 195, 55, 1.0)" :size="18"
 						style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -412,16 +412,18 @@
 		selectedPhotos.value.splice(index, 1)
 	}
 
-	function handleDrawingMenu() {
+function handleDrawingMenu() {
 		// 对 technologicalProcessDetailId 进行URL编码
 		var encodedId = encodeURIComponent(processInspecion.value.lot.productId);
 		var enTechnologicalProcessId = encodeURIComponent(processInspecion.value.lot.technologicalProcessId);
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
 
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;

+ 59 - 2
pages/drawingMenu/index.vue

@@ -39,7 +39,9 @@
 	import {
 		getDrawingList,
 		getTechnologicalProcess,
-		getDeptProcess
+		getDeptProcess,
+		getLotTechnologicalProcess,
+		getDeptLotProcess
 	} from '@/api/business/drawing.js'
 	import {
 		ref
@@ -56,6 +58,8 @@
 	const productId = ref("")
 	const product = ref({})
 	const lotCode = ref("")
+	const isWasteRecycling = ref("")
+	const isAmend = ref("")
 	const selectedProcessList = ref([]);
 	const curSelectedProcessCode = ref("");
 	const processAlias = ref("")
@@ -67,6 +71,8 @@
 		processCode.value = options.param3
 		curSelectedProcessCode.value = processCode.value
 		processAlias.value = decodeURIComponent(options.param5)
+		isWasteRecycling.value = options.param6
+		isAmend.value = options.param7
 		init();
 
 	})
@@ -92,9 +98,60 @@
 			curSelectedProcessCode.value = processCode.value
 		})
 	}
+	function getLotProcesses(data) {
+		console.log(data)
+		getDeptLotProcess(data).then(res => {
+			selectedProcessList.value = res.data.map(v => ({
+				text: v.processAlias,
+				value: v.processCode
+			}))
+			// selectedProcessList.value.push({
+			// 	text: '分选-直径Φ13.04(杠杆千',
+			// 	value: '30492'
+			// })
+			if (!selectedProcessList.value.some(v => v.value == processCode.value)) {
+				selectedProcessList.value.push({
+					text: processAlias.value,
+					value: processCode.value
+				})
+			}
+			curSelectedProcessCode.value = processCode.value
+		})
+	}
 
 	function init() {
 		console.log(product.value)
+		if(isWasteRecycling.value == 1 || isAmend.value == 1){
+			console.log("7777")
+			getLotTechnologicalProcess({id:technologicalProcessId.value}).then(response => {
+				console.log(response, 1123)
+				if (response.code == 200) {
+					product.value = response.data
+					product.value.lotCode = lotCode.value
+					product.value.processAlias = processAlias.value
+					getLotProcesses({
+						productVersion: product.value.technologyVersion,
+						deptId: store.curDeptDetails.deptId,
+						productId: productId.value,
+						technologicalProcessId:technologicalProcessId.value
+					})
+					getDrawingList({
+						productVersion: product.value.technologyVersion,
+						processCode: processCode.value,
+						productId: productId.value
+					}).then(res => {
+						if (res.code == 200) {
+							drawingList.value = res.data
+							// product.value = drawingList.value[0].product
+							// product.value.technologyVersion = drawingList.value[0].technologyVersion
+							// product.value.processAlias = drawingList.value[0].processAlias
+							// product.value.lotCode = lotCode.value
+			
+						}
+					})
+				}
+			})
+		}else{
 		getTechnologicalProcess(technologicalProcessId.value).then(response => {
 			console.log(response, 1123)
 			if (response.code == 200) {
@@ -122,7 +179,7 @@
 				})
 			}
 		})
-
+}
 	}
 
 

+ 4 - 2
pages/factoryInspection/form.vue

@@ -121,7 +121,7 @@
 					<!-- <switch :checked="isAllChecked" class="switch" :disabled="!showTransfer || processInspecion.flag"
 						@change="switchAllCheckChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
-					<zero-switch v-model="isAllChecked" @change="switchAllCheckChange" active-color="rgba(255,85,85,1)"
+					<zero-switch v-model="isAllChecked" @change="switchAllCheckChange" active-color="rgba(103, 195, 55, 1.0)"
 						:size="18" style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -368,9 +368,11 @@
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
 
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;

+ 5 - 3
pages/firstInspection/form.vue

@@ -128,7 +128,7 @@
 					<text class="label">是否移交仪器室</text><text>&nbsp;否</text>
 					<!-- <switch class="switch" @change="switchChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
-					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(255,85,85,1)"
+					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(103, 195, 55, 1.0)"
 						:size="18" style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -141,7 +141,7 @@
 						@change="switchAllCheckChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
 					<zero-switch v-model="isAllChecked" :disabled="!showTransfer || processInspecion.flag"
-						@change="switchAllCheckChange" active-color="rgba(255,85,85,1)" :size="18"
+						@change="switchAllCheckChange" active-color="rgba(103, 195, 55, 1.0)" :size="18"
 						style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -439,9 +439,11 @@
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
 
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;

+ 3 - 1
pages/firstInspection/instrumentRoomForm.vue

@@ -375,9 +375,11 @@
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
 
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;

+ 19 - 16
pages/inspectionDetails/form.vue

@@ -256,23 +256,26 @@
 			}
 		}
 	} 
-	function handleDrawingMenu(){
-		  // 对 technologicalProcessDetailId 进行URL编码
-		  var encodedId = encodeURIComponent(processInspecion.value.lot.productId);
-		  var enTechnologicalProcessId = encodeURIComponent(processInspecion.value.lot.technologicalProcessId);
-		  var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
-		  var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
-		  var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
-		  // 构建查询参数字符串
-		  var queryParam = `param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
-		
-		  // 使用模板字符串构建完整的URL
-		  var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
-		
-		  // 导航到指定页面
-		  uni.navigateTo({
+	function handleDrawingMenu() {
+		// 对 technologicalProcessDetailId 进行URL编码
+		var encodedId = encodeURIComponent(processInspecion.value.lot.productId);
+		var enTechnologicalProcessId = encodeURIComponent(processInspecion.value.lot.technologicalProcessId);
+		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
+		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
+		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
+		// 构建查询参数字符串
+		var queryParam =
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
+	
+		// 使用模板字符串构建完整的URL
+		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
+	
+		// 导航到指定页面
+		uni.navigateTo({
 			url: navigateUrl
-		  });
+		});
 	}
 
 	//查询咨询列表

+ 5 - 3
pages/instrumentRoomInspection/form.vue

@@ -356,13 +356,15 @@
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
-
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
+	
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
-
+	
 		// 导航到指定页面
 		uni.navigateTo({
 			url: navigateUrl

+ 7 - 5
pages/onSiteInspection/form.vue

@@ -125,7 +125,7 @@
 					<text class="label">是否移交仪器室</text><text>&nbsp;否</text>
 					<!-- <switch class="switch" @change="switchChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
-					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(255,85,85,1)"
+					<zero-switch v-model="processInspecion.flag" @change="switchChange" active-color="rgba(103, 195, 55, 1.0)"
 						:size="18" style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -138,7 +138,7 @@
 						@change="switchAllCheckChange" style="transform:scale(0.7);margin-top: -16rpx;"
 						color="rgba(255,85,85,1)" /> -->
 					<zero-switch v-model="isAllChecked" :disabled="!showTransfer || processInspecion.flag"
-						@change="switchAllCheckChange" active-color="rgba(255,85,85,1)" :size="18"
+						@change="switchAllCheckChange" active-color="rgba(103, 195, 55, 1.0)" :size="18"
 						style="transform:scale(0.9);margin-top: -9rpx;"></zero-switch>
 					<text>是</text>
 				</view>
@@ -449,13 +449,15 @@
 		var enprocessCode = encodeURIComponent(processInspecion.value.lot.processCode);
 		var encodeCode = encodeURIComponent(processInspecion.value.lot.lotCode);
 		var enProcessAlias = encodeURIComponent(processInspecion.value.lot.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(processInspecion.value.lot.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(processInspecion.value.lot.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
-
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
+	
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;
-
+	
 		// 导航到指定页面
 		uni.navigateTo({
 			url: navigateUrl

+ 1 - 1
pages/outsourcedInspection/form.vue

@@ -180,7 +180,7 @@
 				<view v-if="showTransfer" class="list-title uni-row" style="margin-top: 16rpx;">
 					<text class="label">是否移交仪器室</text><text>&nbsp;否</text>
 					<switch class="switch" @change="switchChange" style="transform:scale(0.7);margin-top: -16rpx;"
-						color="rgba(255,85,85,1)" />
+						color="rgba(103, 195, 55, 1.0)" />
 					<text>是</text>
 				</view>
 				<view v-else class="list-title uni-row" style="margin-top: 16rpx;">

+ 3 - 1
pages/processInspectionReceive/form.vue

@@ -1053,9 +1053,11 @@
 		var enprocessCode = encodeURIComponent(data.processCodeLabel);
 		var encodeCode = encodeURIComponent(data.lotCode);
 		var enProcessAlias = encodeURIComponent(data.processAlias);
+		var enIsWasteRecycling = encodeURIComponent(data.isWasteRecycling);
+		var enIsAmend = encodeURIComponent(data.isAmend);
 		// 构建查询参数字符串
 		var queryParam =
-			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}`;
+			`param1=${encodedId}&param2=${encodeCode}&param3=${enprocessCode}&param4=${enTechnologicalProcessId}&param5=${enProcessAlias}&param6=${enIsWasteRecycling}&param7=${enIsAmend}`;
 
 		// 使用模板字符串构建完整的URL
 		var navigateUrl = `/pages/drawingMenu/index?${queryParam}`;

+ 1 - 1
pages/sortBatchReporting/index.vue

@@ -12,7 +12,7 @@
 		<view class="list-title uni-row">
 			<text class="label">是否正常批次</text>
 			<text>{{ normalStatus ? '是' : '否' }}</text>
-			<switch class="switch" :checked="normalStatus" @change="switchChange" color="rgba(255,85,85,1)" />
+			<switch class="switch" :checked="normalStatus" @change="switchChange" color="rgba(103, 195, 55, 1.0)" />
 		</view>
 		<view class="scroll-container" style="padding-bottom: 150rpx;">
 			<view v-if="listData.length == 0" style="color: #999;margin: 50% auto;">

+ 45 - 10
pages/sorting/form.vue

@@ -163,7 +163,8 @@
 		getSortingDayworkItem,
 		saveConsult,
 		finish,
-		update
+		update,
+		selectInstructionList
 	} from '@/api/business/sortDaywork.js'
 	import {
 		getTakeStockPeriod
@@ -215,6 +216,7 @@
 	})
 	onShow(() => {
 		uni.$off('addInfoEvent');
+		uni.$off('addUnfitInfoEvent')
 	})
 	onMounted(() => {
 		const instance = getCurrentInstance().proxy
@@ -306,16 +308,19 @@ uni.navigateTo({
 	}
 	const addUnfitInfo = (data) => {
 		console.log(data)
-		if (data.index > unfitInfos.value.length) {
-			const info = {
-				inspectionInstructionId: data.id,
-				title: data.title,
-				standard: data.standard,
-				checkStandard: data.standard,
-				type: data.type,
+		if (data&& data.length >0) {
+			for (var i = 0; i < data.length; i++) {
+				const info = {
+				inspectionInstructionId: data[i].id,
+				title: data[i].title,
+				standard: data[i].standard,
+				checkStandard: data[i].standard,
+				type: data[i].type,
 				reason: ''
 			}
 			unfitInfos.value.push(info)
+			}
+			
 		}
 	}
 	function dele(ite,index) {
@@ -371,7 +376,26 @@ uni.navigateTo({
 		uni.$once('addUnfitInfoEvent', (data) => {
 			addUnfitInfo(data)
 		})
-		// console.log(dayworkItem.value)
+		console.log(getHasInstruction())
+		if(!getHasInstruction()){
+			uni.navigateTo({
+				url: "/pages/sorting/specialOptions",
+				success: (res) => {
+					// 通过eventChannel向被打开页面传送数据
+					res.eventChannel.emit('acceptDataFromOpenerPage', {
+						data: dayworkItem.value,
+						query: {
+							productId: dayworkItem.value.daywork.productId,
+							processId: dayworkItem.value.process.id,
+							// technologyVersion: dayworkItem.value.technologicalProcessDetail.technologyVersion
+							technologyVersion: dayworkItem.value.technologyVersion
+						},
+						index: unfitInfos.value.length
+					})
+				}
+			})
+		}else{
+			console.log(dayworkItem.value)
 		uni.navigateTo({
 			url: "/pages/sorting/options",
 			success: (res) => {
@@ -380,7 +404,7 @@ uni.navigateTo({
 					data: dayworkItem.value,
 					query: {
 						productId: dayworkItem.value.daywork.productId,
-						processId: dayworkItem.value.process.id,
+						processCode: dayworkItem.value.process.processCode,
 						// technologyVersion: dayworkItem.value.technologicalProcessDetail.technologyVersion
 						technologyVersion: dayworkItem.value.technologyVersion
 					},
@@ -388,6 +412,17 @@ uni.navigateTo({
 				})
 			}
 		})
+		}
+	}
+	function getHasInstruction(){
+				const res = selectInstructionList({
+					technologicalProcessId: dayworkItem.value.technologicalProcessId,
+					processCode: dayworkItem.value.processCode,
+					lotId: dayworkItem.value.lotId
+				}).then(res=> {
+				return res.data
+			})
+			return res
 	}
 	// 删除不合格信息
 	const handleDelUnfit = (index) => {

+ 143 - 170
pages/sorting/options.vue

@@ -1,37 +1,38 @@
 <template>
-	<view class="page-container uni-column">
-		<view class="option-container uni-column">
-			<!-- tab-bar -->
-			<view class="tab-bars uni-row">
-				<view :class="currentTabName === 1 ? 'active' : ''" @click.stop="handleTabBarClick(1)">
-					<text>检查指导书</text>
-					<view class="line"></view>
+	<view class="page-container" style="position: absolute;left: 0;right: 0;top: 0;bottom: 0">
+				<view class="option-container uni-column" style="display: flex;">
+					<!-- tab-bar -->
+					<view class="tab-bars uni-row">
+						<!-- 				<view :class="currentTabName === 1 ? 'active' : ''" @click.stop="handleTabBarClick(1)">
+							<text>检查指导书</text>
+							<view class="line"></view>
+						</view> -->
+						<view :class="currentTabName === 2 ? 'active' : ''">
+							<text>分选标准</text>
+							<view class="line"></view>
+						</view>
+					</view>
+					<!-- 搜索框 -->
+					<view class="search-container uni-row">
+						<input type="text" v-model="keywords" placeholder="请输入关键字" />
+						<view class="btn" @click="handleSearch()">搜索</view>
+					</view>
 				</view>
-				<view :class="currentTabName === 2 ? 'active' : ''" @click.stop="handleTabBarClick(2)">
-					<text>分选标准</text>
-					<view class="line"></view>
+				<view  class="uni-row" style="background-color:#ffffff;height: 75%;padding-bottom: 12px;">
+					<view style="width: 100%;height: 100%;overflow: auto;">
+						<view v-if="dataList&& dataList.length == 0" style="align-items: center;margin-top: 30px">暂无分选标准数据</view>
+						<view v-else v-for="(item, index) in dataList" :key="index" :class="{'option-item':true,'selectedOptions':isSelectedOptions(item)}" @click="itemClick(item)">
+							<view class="uni-row">
+								<view class="value">{{ item.standard }}</view>
+								<uni-icons v-if="selection.includes(item)" class="arrow-right" type="checkmarkempty" size="24" />
+							</view>
+						</view>
+					</view>
 				</view>
-			</view>
-			<!-- 搜索框 -->
-			<view class="search-container uni-row">
-				<input type="text" v-model="keywords" placeholder="请输入关键字" />
-				<view class="btn" @click="handleSearch()">搜索</view>
-			</view>
-			<!-- 选项 -->
-			<view class="option-item" v-for="(item, index) in optionList" :key="index"
-				@click="handleOptionChecked(item)">
-				<view class="uni-row">
-					<view class="label">检查项</view>
-					<view class="value">{{ item.title }}</view>
+				<view class="bottom uni-row">
+					<button class="start-batch-btn" type="primary" :disabled="selection.length ==0" @click="handleAdd">添加</button>
 				</view>
-				<view class="uni-row">
-					<view class="label">检查标准</view>
-					<view class="value">{{ item.standard }}</view>
-				</view>
-				<uni-icons class="arrow-right" type="right" size="24" />
-			</view>
-		</view>
-	</view>
+</view>
 </template>
 
 <script setup>
@@ -49,18 +50,19 @@
 		onShow
 	} from '@dcloudio/uni-app'
 	import {
-		getInspectionList
+		 getInstructionInfo
 	} from '@/api/business/sortDaywork.js'
+	import {
+		store
+	} from '@/store/index.js'
 
-	const currentTabName = ref(1)
+	const currentTabName = ref(2)
 	const keywords = ref('')
-	const optionList = ref([])
-	// 检查指导书
-	const optionList1 = ref([])
-	// 分选标准
-	const optionList2 = ref([])
-	const dayworkItem = ref({})
-	const index = ref(0)
+	const dataList = ref([])
+	const originalList = ref([])
+	const selection = ref([])
+	const dayworkItem = ref(null)
+
 	onMounted(() => {
 		const instance = getCurrentInstance().proxy
 		const eventChannel = instance.getOpenerEventChannel();
@@ -69,157 +71,103 @@
 			// console.log('acceptDataFromOpenerPage', data)
 			// 传入当前报工信息 通过当前报工的产品和工序获取检查指导书和分选标准
 			if (data && data.data) {
+				selection.value = []
 				dayworkItem.value = data.data
 				console.log(dayworkItem.value)
-				index.value = data.index
 				loadInspection({
 					technologicalProcessId: dayworkItem.value.technologicalProcessId,
-					processId: dayworkItem.value.processId,
+					processCode: dayworkItem.value.process.processCode,
 					lotId: dayworkItem.value.lotId
 				})
 			}
 		})
 	})
+		const loadInspection = (data) => {
+			uni.showLoading({
+				title: '加载中'
+			});
+			// console.log(data)
+			getInstructionInfo(data).then(res => {
+				console.log(res)
+				if (res.code === 200) {
+					dataList.value = res.data
+					originalList.value = res.data
+					uni.hideLoading();
+					// console.log(optionList1.value, res.data.instructions)
+					// console.log(optionList2.value, res.data.standards)
+				} else {
+					uni.showToast({
+						icon: 'none',
+						title: '分选标准获取失败'
+					})
+					uni.hideLoading();
+				}
+			})
+		}
+	function isSelectedOptions(item) {
+		return selection.value.includes(item);
+	}
+
+	function cateClick(item) {
+		selectionCategory.value = item
+		console.log(item)
+		console.log(categoryList.value)
+		let index = categoryList.value.findIndex(v=>v.id == item.id)
+		console.log(index)
+		currentData.value = index
+		if(categoryList.value[index].instructionList && categoryList.value[index].instructionList.length>0){
+		dataList.value = categoryList.value[index].instructionList
+		originalList.value = categoryList.value[index].instructionList
+		}else{
+			dataList.value = []
+		}
+		
+	}
+
+	function itemClick(item) {
+		const buttonIndex = selection.value.findIndex(selectedItem => selectedItem === item);
+		if (buttonIndex > -1) {
+			selection.value.splice(buttonIndex, 1); // 取消选中
+		} else {
+			selection.value.push(item); // 选中
+		}
+	}
 
 	function handleSearch() {
-		console.log(dayworkItem.value)
-		let data = {
-			technologicalProcessId: dayworkItem.value.technologicalProcessId,
-			processId: dayworkItem.value.processId,
-			keywords: keywords.value,
-			lotId: dayworkItem.value.lotId
+		if(keywords.value == ""){
+			dataList.value = originalList.value
+		}else{
+			dataList.value = originalList.value.filter(item=>item.standard.includes(keywords.value))
 		}
-		getInspectionList(data).then(res => {
-			console.log(res)
-			if (res.code === 200) {
-				optionList1.value = res.data.instructions
-				optionList2.value = res.data.standards
-				if (currentTabName.value == 1) {
-					optionList.value = optionList1.value
-				} else {
-					optionList.value = optionList2.value
-				}
-			} else {
-				uni.showToast({
-					icon: 'none',
-					title: '分选标准和检查指导项获取失败'
-				})
-			}
-		})
+		
 
 	}
 	// 页面生命周期函数
 	onLoad(() => {
-		// optionList1.value = [
-		// 	{
-		// 		title: '001 台阶径',
-		// 		standard: '角偏 < 0.05'
-		// 	},
-		// 	{
-		// 		title: '002 台阶径',
-		// 		standard: '角偏 < 0.04'
-		// 	}
-		// ]
-
-		// optionList2.value = [
-		// 	{
-		// 		title: '划痕',
-		// 		standard: '划痕描述'
-		// 	},
-		// 	{
-		// 		title: '划伤',
-		// 		standard: '划伤描述'
-		// 	}
-		// ]
 
-		// optionList.value = optionList1.value
 	})
 
-	const loadInspection = (data) => {
-		// console.log(data)
-		getInspectionList(data).then(res => {
-			console.log(res)
-			if (res.code === 200) {
-				optionList1.value = res.data.instructions
-				optionList2.value = res.data.standards
-				//handleTabBarClick(currentTabName.value)
-				currentTabName.value = 1
-				optionList.value = optionList1.value
-				// console.log(optionList1.value, res.data.instructions)
-				// console.log(optionList2.value, res.data.standards)
-			} else {
-				uni.showToast({
-					icon: 'none',
-					title: '分选标准和检查指导项获取失败'
-				})
-			}
-		})
-	}
 
 	// tabbar切换
-	const handleTabBarClick = (val) => {
-		switch (val) {
-			case 1:
-				keywords.value = ''
-				var data = {
-					technologicalProcessId: dayworkItem.value.technologicalProcessId,
-					processId: dayworkItem.value.processId,
-					lotId: dayworkItem.value.lotId
-				}
-				getInspectionList(data).then(res => {
-					console.log(res)
-					if (res.code === 200) {
-						optionList1.value = res.data.instructions
-						optionList2.value = res.data.standards
-						optionList.value = optionList1.value
-					} else {
-						uni.showToast({
-							icon: 'none',
-							title: '检查指导项获取失败'
-						})
-					}
-				})
-				break
-			case 2:
-				keywords.value = ''
-				var data = {
-					technologicalProcessId: dayworkItem.value.technologicalProcessId,
-					processId: dayworkItem.value.processId,
-					lotId: dayworkItem.value.lotId
-				}
-				getInspectionList(data).then(res => {
-					console.log(res)
-					if (res.code === 200) {
-						optionList1.value = res.data.instructions
-						optionList2.value = res.data.standards
-						optionList.value = optionList2.value
-					} else {
-						uni.showToast({
-							icon: 'none',
-							title: '分选标准获取失败'
-						})
-					}
-				})
-		}
-		currentTabName.value = val
-		console.log(optionList.value)
-	}
 
-	const handleOptionChecked = (data) => {
-		uni.$emit('addUnfitInfoEvent', {
-			id: data.id,
-			title: data.title,
-			standard: data.standard,
-			type: data.type,
-			index: index.value + 1
-		})
+
+	function handleAdd(){
+		console.log(selection.value)
+		uni.$emit('addUnfitInfoEvent', 
+			selection.value
+			
+		)
 		uni.navigateBack()
 	}
 </script>
 
 <style lang="scss">
+	.selected {
+		border-left: 5px solid #c0c4fc;
+		font-weight: 700;
+		/* 选中之后样式 */
+	}
 	.page-container {
-		height: 100%;
 		background-color: #ececec;
 		font-size: 28rpx;
 		padding: 24rpx;
@@ -227,6 +175,7 @@
 	}
 
 	.option-container {
+		height: 10%;
 		background-color: #ffffff;
 		padding: 24rpx;
 		border-radius: 12rpx;
@@ -277,34 +226,58 @@
 			color: #ffffff;
 		}
 	}
-
 	.option-item {
 		position: relative;
 		margin-top: 24rpx;
 		padding-bottom: 8rpx;
 		border-bottom: 1px solid #BBBBBB;
-
+		margin-left: 24rpx;
+		
 		.uni-row {
 			padding-bottom: 16rpx;
-
+			
 			.label {
 				width: 144rpx;
 			}
-
 			.value {
 				flex: 1;
 			}
 		}
-
 		.uni-row:first-child {
 			font-size: 32rpx;
-			font-weight: 700;
-		}
 
+		}
 		.arrow-right {
 			position: absolute;
-			top: 24rpx;
 			right: 24rpx;
 		}
 	}
+	.uniui-checkmarkempty[data-v-d31e1c47]:before {
+	    color: #1684FC;
+	}
+	.selectedOptions {
+		color: #1684FC;
+	}
+	.bottom {
+		height: 10%;
+		position: fixed;
+		right: 0;
+		bottom: 0;
+		left: 0;
+		height: 100rpx;
+		border-top: 1px solid #999999;
+		padding: 16rpx 32rpx;
+		align-items: center;
+		background-color: #fff;
+		justify-content: space-evenly;
+	
+		.start-batch-btn {
+			flex: 1;
+			height: 80rpx;
+			line-height: 80rpx;
+			border-radius: 8rpx;
+			color: #FFFFFF;
+			font-size: 28rpx;
+		}
+	}
 </style>