Przeglądaj źródła

Merge branch 'master' of http://110.41.163.243:9980/kd-aiot/aiot-app

ysy 1 rok temu
rodzic
commit
4ea26deaaf

+ 25 - 3
api/myTicket/index.js

@@ -1,4 +1,8 @@
-import { postJ, post, get } from '@/utils/request'
+import {
+	postJ,
+	post,
+	get
+} from '@/utils/request'
 import Vue from 'vue'
 
 // 我的工单列表(巡点检,保养,量具送检)
@@ -9,6 +13,14 @@ export async function getWorkOrderList(params) {
 	}
 	return Promise.reject(new Error(data.message))
 }
+// 协助工单
+export async function getAssistList(params) {
+	const data = await postJ(Vue.prototype.apiUrl + `/eam/PdaWorkOrder/assistList`, params)
+	if (data.code == 0) {
+		return data.data
+	}
+	return Promise.reject(new Error(data.message))
+}
 
 // 设备列表(巡点检,保养,量具送检)
 export async function getDeviceList(params) {
@@ -41,7 +53,9 @@ export async function mattersChecked(params) {
 export async function listOrganizations(id) {
 	console.log(Vue.prototype.apiUrl)
 	console.log('id-----------------------------', id)
-	const data = await get(Vue.prototype.apiUrl + `/main/group/getGroupTree`, { parentId: id })
+	const data = await get(Vue.prototype.apiUrl + `/main/group/getGroupTree`, {
+		parentId: id
+	})
 	console.log(data)
 	if (data.code == 0) {
 		return data.data
@@ -93,6 +107,14 @@ export async function workOrderRotate(params) {
 	}
 	return Promise.reject(new Error(data.message))
 }
+//
+export async function addAssists(params) {
+	const data = await get(Vue.prototype.apiUrl + `/eam/workordermaintenance/addAssists`, params)
+	if (data.code == 0) {
+		return data.data
+	}
+	return Promise.reject(new Error(data.message))
+}
 
 // 我的工单统计
 export async function statistics(params) {
@@ -121,4 +143,4 @@ export async function deviceListQrCode(params) {
 		return data.data
 	}
 	return Promise.reject(new Error(data.message))
-}
+}

+ 36 - 27
api/repair/index.js

@@ -5,6 +5,15 @@ import {
 } from '@/utils/request'
 import Vue from 'vue'
 
+
+export async function loseReport(data) {
+	const res = await postJ(Vue.prototype.apiUrl + '/eam/workordermaintenance/loseReport', data);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
+}
+
 // 通过工单查询详情
 export async function getWorkOrderDetail(code) {
 	const res = await get(Vue.prototype.apiUrl + '/eam/workorder/getWorkOrderDetail/' + code)
@@ -97,7 +106,7 @@ export async function getProductList(data) {
 }
 // 通过台账id获取出库物品详情
 export async function getHierarchyList(params) {
-	const res = await get(Vue.prototype.apiUrl +`/wms/outintwo/getHierarchyList`, {
+	const res = await get(Vue.prototype.apiUrl + `/wms/outintwo/getHierarchyList`, {
 		params
 	});
 	if (res.data.code == 0) {
@@ -106,7 +115,7 @@ export async function getHierarchyList(params) {
 	return Promise.reject(new Error(res.data.message));
 }
 export async function getHierarchyFifo(data) {
-	const res = await postJ(Vue.prototype.apiUrl +'/wms/outintwo/getHierarchyFifo', data);
+	const res = await postJ(Vue.prototype.apiUrl + '/wms/outintwo/getHierarchyFifo', data);
 	if (res.data.code == 0) {
 		return res.data.data;
 	}
@@ -167,40 +176,40 @@ export async function getByFixCode(data) {
 }
 
 // // 详情列表
-export async function getSparePartsApply (id) {
-  const res = await get(Vue.prototype.apiUrl +`/eam/spare_parts_apply/details/${id}`);
-  if (res.code == 0) {
-    return res.data;
-  }
-  return Promise.reject(new Error(res.message));
+export async function getSparePartsApply(id) {
+	const res = await get(Vue.prototype.apiUrl + `/eam/spare_parts_apply/details/${id}`);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
 }
 
 // // 详情
-export async function detailsId (id) {
-  const res = await get(Vue.prototype.apiUrl +`/eam/spare_parts_apply/detailsId/${id}`);
-  if (res.code == 0) {
-    return res.data;
-  }
-  return Promise.reject(new Error(res.message));
+export async function detailsId(id) {
+	const res = await get(Vue.prototype.apiUrl + `/eam/spare_parts_apply/detailsId/${id}`);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
 }
 /**
  * 列表
  */
-export async function getList (data) {
-  const res = await postJ(Vue.prototype.apiUrl +'/eam/spare_parts_apply/page', data);
-  if (res.code == 0) {
-    return res.data;
-  }
-  return Promise.reject(new Error(res.message));
+export async function getList(data) {
+	const res = await postJ(Vue.prototype.apiUrl + '/eam/spare_parts_apply/page', data);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
 }
 
 // 详情
 export async function getWordOrderDetail(workOrderId) {
-  const res = await get(
-    Vue.prototype.apiUrl +`/eam/workordermaintenance/maintenanceDetail/${workOrderId}`
-  );
-  if (res.code == 0) {
-    return res.data;
-  }
-  return Promise.reject(new Error(res.message));
+	const res = await get(
+		Vue.prototype.apiUrl + `/eam/workordermaintenance/maintenanceDetail/${workOrderId}`
+	);
+	if (res.code == 0) {
+		return res.data;
+	}
+	return Promise.reject(new Error(res.message));
 }

+ 91 - 42
components/Assign.vue

@@ -8,32 +8,51 @@
 					<text class="btn confirm" @tap="submit">确定</text>
 				</view>
 				<view class="select-wrapper">
+					<view class="col userInp" v-if="fromValue=='Transfer'">
+						<text class="label">类型:</text>
+						<!-- multiple -->
+						<zxz-uni-data-select :localdata="[{text:'执行人',value:1},{text:'辅助人',value:2}]" v-model="Usertype"
+							@change="changeUserType"></zxz-uni-data-select>
+					</view>
+					<!-- fromValue  Transfer  -->
 					<view class="col deptInp">
 						<text class="label">部门:</text>
 						<!-- <input type="text" disabled :value="formData.executorDeptName" placeholder="请选择" /> -->
-						<text class="input_text" @click="openPicker">{{ formData.executorDeptName ? formData.executorDeptName : '请选择' }}</text>
+						<text class="input_text"
+							@click="openPicker">{{ formData.executorDeptName ? formData.executorDeptName : '请选择' }}</text>
 					</view>
 
 					<view class="col userInp">
 						<text class="label">接收人:</text>
 						<!-- multiple -->
-						<zxz-uni-data-select :localdata="userList" v-model="formData.executorId" @change="handleUserChange"></zxz-uni-data-select>
+						<zxz-uni-data-select :localdata="userList" v-model="formData.executorId"
+							@change="handleUserChange" :multiple="Usertype==2"></zxz-uni-data-select>
 					</view>
 
-					<view class="col userInp">
+					<!-- <view class="col userInp">
 						<text class="label">转派原因:</text>
 						<textarea v-model="formData.reassignExplain" cols="20" rows="5"></textarea>
-					</view>
+					</view> -->
 				</view>
 			</view>
 		</u-popup>
-		<ba-tree-picker ref="treePicker" :multiple="false" @select-change="confirm" title="选择部门" :localdata="listData" valueKey="id" textKey="name" childrenKey="children" />
+		<ba-tree-picker ref="treePicker" :multiple="false" @select-change="confirm" title="选择部门" :localdata="listData"
+			valueKey="id" textKey="name" childrenKey="children" />
 	</view>
 </template>
 
 <script>
-	import { listOrganizations, getUserPage, workOrderRotate } from '@/api/myTicket/index.js'
-	import { post, get, postJ } from '@/utils/api.js'
+	import {
+		listOrganizations,
+		getUserPage,
+		workOrderRotate,
+		addAssists
+	} from '@/api/myTicket/index.js'
+	import {
+		post,
+		get,
+		postJ
+	} from '@/utils/api.js'
 	import baTreePicker from '@/components/ba-tree-picker/ba-tree-picker.vue'
 	export default {
 		components: {
@@ -54,7 +73,9 @@
 				},
 
 				selectList: [],
-				newArr: []
+				newArr: [],
+				Usertype: '',
+				fromValue: ''
 			}
 		},
 		created() {
@@ -62,25 +83,34 @@
 		},
 		methods: {
 			//工单id
-			open(id) {
-				console.log(id)
+			open(id, val) {
+				console.log(id, val)
+				this.fromValue = val
 				this.formData.workOrderId = id
 				this.popShow = true
 			},
 			openPicker() {
 				this.$refs.treePicker._show()
 			},
-
+			changeUserType() {
+				this.formData.executorId = ''
+				this.formData.executorName = ''
+			},
 			deWeight(arr4) {
 				var obj = {}
-				arr4 = arr4.reduce(function (a, b) {
+				arr4 = arr4.reduce(function(a, b) {
 					obj[b.userId] ? '' : (obj[b.userId] = true && a.push(b))
 					return a
 				}, [])
 				return arr4
 			},
 			handleUserChange(obj) {
-				this.formData.executorName = obj.text
+				if (this.Usertype == 1) {
+					this.formData.executorName = obj.name
+				} else {
+					this.formData.executorId = this.formData.executorId.toString()
+				}
+
 
 				// const obj = this.userList.find(i => i.value === id)
 				// this.formData.executorName = (obj && obj.text) || ''
@@ -104,13 +134,13 @@
 					})
 					return
 				}
-				if (!this.formData.reassignExplain) {
-					uni.showToast({
-						icon: 'error',
-						title: '请输入转派原因'
-					})
-					return
-				}
+				// if (!this.formData.reassignExplain) {
+				// 	uni.showToast({
+				// 		icon: 'error',
+				// 		title: '请输入转派原因'
+				// 	})
+				// 	return
+				// }
 
 				// let param = {
 				// 	executorDeptName: this.formData.executorDeptName,
@@ -124,22 +154,41 @@
 					acceptUserId: this.formData.executorId,
 					workOrderId: this.formData.workOrderId
 				}
-				console.log(param)
-				workOrderRotate(param).then(() => {
-					this.close()
-					const _this = this
-					uni.showModal({
-						title: `此工单已转派成功`,
-						content: '',
-						confirmText: '确认',
-						showCancel: false, // 是否显示取消按钮,默认为 true
-						success: function (res) {
-							if (res.confirm) {
-								_this.$emit('success', _this.formData)
+				console.log(param, 'param')
+				if (this.Usertype == 1) {
+					workOrderRotate(param).then(() => {
+						this.close()
+						const _this = this
+						uni.showModal({
+							title: `此工单已转派成功`,
+							content: '',
+							confirmText: '确认',
+							showCancel: false, // 是否显示取消按钮,默认为 true
+							success: function(res) {
+								if (res.confirm) {
+									_this.$emit('success', _this.formData)
+								}
 							}
-						}
+						})
 					})
-				})
+				} else {
+					addAssists(param).then(() => {
+						this.close()
+						const _this = this
+						uni.showModal({
+							title: `此工单已转派成功`,
+							content: '',
+							confirmText: '确认',
+							showCancel: false, // 是否显示取消按钮,默认为 true
+							success: function(res) {
+								if (res.confirm) {
+									_this.$emit('success', _this.formData)
+								}
+							}
+						})
+					})
+				}
+
 
 				// postJ(this.apiUrl + '/workOrder/anewSendOrders', [param]).then(res => {
 				// 	if (res?.success) {
@@ -189,7 +238,11 @@
 				// })
 			},
 			getUser(deptCode) {
-				getUserPage({ pageNum: 1, size: -1, groupId: deptCode }).then(data => {
+				getUserPage({
+					pageNum: 1,
+					size: -1,
+					groupId: deptCode
+				}).then(data => {
 					this.userList = data.list.map(item => {
 						item.text = item.name
 						item.value = item.id
@@ -227,16 +280,11 @@
 			text-align: center;
 			background-color: $j-primary-border-green;
 			font-weight: bold;
+			padding: 0 20rpx;
 			position: relative;
 			font-size: 32rpx;
 			color: #fff;
 
-			// .btn-box {
-			//   position: absolute;
-			//   top: 50%;
-			//   right: 10rpx;
-			//   transform: translateY(-50%);
-			// }
 			.btn {
 				width: 80rpx;
 				height: 32rpx;
@@ -245,6 +293,7 @@
 				border: 1px solid #fff;
 				text-align: center;
 				line-height: 30rpx;
+				margin: 0;
 			}
 		}
 
@@ -316,4 +365,4 @@
 			}
 		}
 	}
-</style>
+</style>

+ 22 - 1
pages/maintenanceWorkorder/components/maintain_course.vue

@@ -48,11 +48,26 @@
 						</view>
 					</view>
 					<view class="list-xs" v-else-if="item.type == 'WORK_REPORT'">
+						<view class="list-xs-item">
+							<view class="label">报工人</view>
+							<view class="value">
+								{{logs[item.id] ?  logs[item.id].content.rawUserName:'' }}
+							</view>
+						</view>
+						<view class="list-xs-item">
+							<view class="label">辅助人</view>
+							<view class="value">
+								{{logs[item.id].content.assists ?logs[item.id].content.assists.map((item) => item.name).toString():''}}
+							</view>
+						</view>
+
 						<view class="list-xs-item">
 							<view class="label">处理说明</view>
 							<view class="value">
 								{{ logs[item.id] ? logs[item.id].content.reason : '' }}
 							</view>
+						</view>
+						<view class="list-xs-item">
 							<view class="label">附件</view>
 							<view class="value">
 								<fileMain type="view" v-model="logs[item.id].content.attachments"></fileMain>
@@ -260,6 +275,7 @@
 			console.log(this.logs)
 			this.logsKeys = Object.keys(this.logs)
 			this.lastStepName = this.logsKeys[0]
+			console.log(this.repairInfoLogList, 'repairInfoLogList')
 		},
 		methods: {
 			close() {
@@ -313,7 +329,7 @@
 
 			.label {
 				font-size: 28rpx;
-				width: 120rpx;
+				width: 20%;
 				text-align: right;
 				margin-right: 20rpx;
 			}
@@ -321,6 +337,11 @@
 			.value {
 				font-size: 28rpx;
 
+				white-space: nowrap;
+				overflow: hidden;
+				text-overflow: ellipsis;
+				max-width: 70%;
+
 				&.bj {
 					padding: 10rpx 0;
 					color: #4f7f00;

+ 275 - 0
pages/maintenanceWorkorder/components/unfinishedApplication.vue

@@ -0,0 +1,275 @@
+<template>
+	<view class="assign-container">
+		<u-popup :show="popShow" @close="close">
+			<view class="select-container">
+				<view class="title">
+					<text class="btn cancel" @tap="close">取消</text>
+					非完成报工
+					<text class="btn confirm" @tap="submit">确定</text>
+				</view>
+				<view class="select-wrapper">
+					<view class="col deptInp">
+						<text class="label">部门:</text>
+						<text class="input_text"
+							@click="openPicker">{{ formData.executorDeptName ? formData.executorDeptName : '请选择' }}</text>
+					</view>
+
+					<view class="col userInp">
+						<text class="label">接收人:</text>
+						<zxz-uni-data-select :localdata="userList" v-model="formData.executorId"
+							@change="handleUserChange"></zxz-uni-data-select>
+					</view>
+					<view class="col">
+						<view class="label">处理说明:</view>
+						<textarea class="textarea" v-model="formData.repairReportExplain"></textarea>
+					</view>
+					<view class="col">
+						<view class="label">附件:</view>
+						<fileMain v-model="formData.attachments"></fileMain>
+					</view>
+				</view>
+			</view>
+		</u-popup>
+		<ba-tree-picker ref="treePicker" :multiple="false" @select-change="confirm" title="选择部门" :localdata="listData"
+			valueKey="id" textKey="name" childrenKey="children" />
+	</view>
+</template>
+
+<script>
+	import {
+		listOrganizations,
+		getUserPage,
+		workOrderRotate
+	} from '@/api/myTicket/index.js'
+	import {
+		post,
+		get,
+		postJ
+	} from '@/utils/api.js'
+	import baTreePicker from '@/components/ba-tree-picker/ba-tree-picker.vue'
+	import fileMain from "@/pages/doc/index.vue"
+	import {
+		loseReport
+	} from '@/api/repair'
+
+	export default {
+		components: {
+			baTreePicker,
+			fileMain
+		},
+		props: {
+		},
+		data() {
+			return {
+				popShow: false,
+				deptPickerShow: false,
+				listData: [],
+				userList: [],
+				formData: {
+					executorDeptName: '',
+					executorName: '',
+					executorId: '',
+					repairReportExplain: '',
+					attachments: []
+				},
+
+				selectList: [],
+				newArr: [],
+				sid: ''
+			}
+		},
+		created() {
+			this.getDept()
+		},
+		methods: {
+			open(id) {
+				this.sid = id;
+				console.log(id)
+				this.popShow = true
+			},
+			openPicker() {
+				this.$refs.treePicker._show()
+			},
+
+			deWeight(arr4) {
+				var obj = {}
+				arr4 = arr4.reduce(function(a, b) {
+					obj[b.userId] ? '' : (obj[b.userId] = true && a.push(b))
+					return a
+				}, [])
+				return arr4
+			},
+			handleUserChange(obj) {
+				this.formData.executorName = obj.text
+
+				// const obj = this.userList.find(i => i.value === id)
+				// this.formData.executorName = (obj && obj.text) || ''
+			},
+			close() {
+				this.formData = {
+					executorDeptName: '',
+					executorName: '',
+					executorId: '',
+					repairReportExplain: '',
+					attachments: []
+				}
+				this.popShow = false
+			},
+
+			submit() {
+				if (!this.formData.executorId) {
+					uni.showToast({
+						icon: 'error',
+						title: '请选择接收人'
+					})
+					return
+				}
+
+				let params = {
+					workOrderId: this.sid,
+					acceptUserId: this.formData.executorId,
+					reason: this.formData.repairReportExplain,
+					attachments: this.formData.attachments,
+				}
+				loseReport(params).then(() => {
+					uni.showToast({
+						title: '非报工成功',
+						icon: 'success',
+						duration: 2000
+					})
+					this.popShow = false;
+				})
+			},
+			confirm(data, name) {
+				console.log(data)
+				console.log(name)
+				this.formData.executorDeptName = name
+				this.formData.executorDeptCode = data[0]
+
+				this.formData.executorName = ''
+				this.formData.executorId = ''
+				this.getUser(data[0])
+			},
+			getDept() {
+				listOrganizations(1).then(data => {
+					console.log('listOrganizations-----------------------')
+					console.log(data)
+					this.listData = data
+				})
+			},
+			getUser(deptCode) {
+				getUserPage({
+					pageNum: 1,
+					size: -1,
+					groupId: deptCode
+				}).then(data => {
+					this.userList = data.list.map(item => {
+						item.text = item.name
+						item.value = item.id
+						return item
+					})
+				})
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.select-container {
+		min-height: 60vh;
+
+		.title {
+			display: flex;
+			justify-content: space-between;
+			align-items: center;
+			height: 100rpx;
+			line-height: 100rpx;
+			text-align: center;
+			background-color: $j-primary-border-green;
+			font-weight: bold;
+			padding: 0 20rpx;
+			position: relative;
+			font-size: 32rpx;
+			color: #fff;
+
+			.btn {
+				width: 80rpx;
+				height: 32rpx;
+				display: inline-block;
+				font-size: 32rpx;
+				border: 1px solid #fff;
+				text-align: center;
+				line-height: 30rpx;
+				margin: 0;
+			}
+		}
+
+		.select-wrapper {
+			.col {
+				display: flex;
+				// min-height: 0rpx;
+				margin-top: 22rpx;
+				align-items: center;
+				padding-right: 14rpx;
+
+				.label {
+					display: inline-block;
+					width: 200rpx;
+					text-align: right;
+				}
+
+				.input_text {
+					flex: 1;
+					height: 66rpx;
+					line-height: 66rpx;
+					padding: 0rpx 16rpx;
+					box-sizing: border-box;
+					font-size: 28rpx;
+					border: 1px solid #eceeec;
+					border-radius: 8rpx;
+				}
+
+				input {
+					flex: 1;
+					border: 1rpx solid #e5e5e5;
+					height: 66rpx;
+					border-radius: 8rpx;
+					font-size: 28rpx;
+					padding: 0rpx 16rpx;
+					color: #6a6a6a;
+				}
+
+				textarea {
+					border: 1rpx solid #e5e5e5;
+					flex: 1;
+					height: 100rpx;
+				}
+
+				.tab_box {
+					display: flex;
+					flex-direction: row;
+					flex-wrap: wrap;
+					width: 520rpx;
+
+					.tab {
+						display: flex;
+						flex-direction: row;
+
+						border: 2rpx solid #d9ecff;
+						background-color: #f4f4f5;
+						border-color: #e9e9eb;
+						color: #909399;
+						margin-left: 8rpx;
+						margin-bottom: 8rpx;
+						padding: 2rpx 8rpx;
+						font-size: 28rpx;
+					}
+
+					.icon {
+						margin-left: 6rpx;
+					}
+				}
+			}
+		}
+	}
+</style>

+ 23 - 7
pages/maintenanceWorkorder/detail/detail.vue

@@ -66,7 +66,7 @@
 					{{ timeInterval(worksheetInfo.acceptTime, worksheetInfo.finishTime) }}
 				</view>
 
-				<view class="zxpg-wrap" v-if="orderType == 1 && repairInfo.repairUserId == userId">
+				<view class="zxpg-wrap" v-if="orderType == 1 && repairInfo.repairUserId == userId && ParentIndex !=4">
 					<template v-if="repairInfo.orderStatus == 0">
 						<!-- <view class="zx-btn btns" @click="handleExecute">开始执行</view> -->
 						<view class="zp-btn btns" @click="handlbpbj">申请备品备件</view>
@@ -77,6 +77,7 @@
 					<template v-else-if="repairInfo.orderStatus == 2">
 						<view class="zp-btn btns" @click="handlbpbj">申请备品备件</view>
 						<view class="zx-btn btns" @click="handlbg">报工</view>
+						<view class="zx-btn btns" style="margin-top: 20rpx;" @click="handlNobg">非完成报工</view>
 						<!-- <view class="zp-btn btns" @click="handlbpbj" v-if="!worksheetInfo.applyOrder">
 							申请备品备件
 						</view>
@@ -96,7 +97,7 @@
 					</div> -->
 				</view>
 				<view class="zxpg-wrap"
-					v-if="orderType == 1 && repairInfo.orderStatus == 3 && repairInfo.requestUserId == userId">
+					v-if="orderType == 1 && repairInfo.orderStatus == 3 && repairInfo.requestUserId == userId && ParentIndex !=4">
 					<view class="zx-btn btns" @click="searchShow = true">验收</view>
 				</view>
 
@@ -321,6 +322,7 @@
 		<!-- <Approval v-if="isApproval && worksheetInfo.status && worksheetInfo.status.code == 5" :devOpsType="1" :planType="3" :myHandleId="myHandleId" :id="worksheetInfo.workOrderId" /> -->
 		<HistoryRepairDetail ref="HistoryRepairDetail" @close="close"></HistoryRepairDetail>
 		<Notice v-if="noticeShow" :id="worksheetInfo.id" :repairInfo="repairInfo" @agree="agree"></Notice>
+		<unfinishedApplication ref="unfinishedA"></unfinishedApplication>
 	</view>
 </template>
 
@@ -332,6 +334,7 @@
 	import StepItem from '@/components/Step/StepItem.vue'
 	import Assign from '@/components/Assign.vue'
 	import fold from '../components/fold.vue'
+	import unfinishedApplication from '../components/unfinishedApplication.vue'
 	import HistoryRepairDetail from '../components/historyRepairDetail.vue'
 	import PopSparePart from '../components/PopSparePart.vue'
 	import pickCard from '../components/pickCard.vue'
@@ -363,7 +366,8 @@
 			Notice,
 			HistoryRepairDetail,
 			SearchPopup,
-			pickCard
+			pickCard,
+			unfinishedApplication
 		},
 		computed: {
 			// 是否为自己的工单
@@ -443,7 +447,8 @@
 				noticeShow: false,
 
 				workOrderType: {},
-				planRepair: {}
+				planRepair: {},
+				ParentIndex: 0,
 			}
 		},
 		onLoad(options) {
@@ -453,6 +458,8 @@
 			this.workOrderCode = options.code
 			this.planId = options.planId
 			this.orderType = options.orderType
+			this.ParentIndex = options.ParentIndex
+			console.log(this.ParentIndex, '协助工单')
 			let userInfo = uni.getStorageSync('userInfo')
 			// 当前登录人id
 			this.userId = userInfo.userId
@@ -484,6 +491,11 @@
 					this.getInfo()
 				})
 			},
+			back() {
+				uni.navigateBack({
+					delta: 1
+				})
+			},
 			close() {
 				this.popupShow = false
 			},
@@ -499,6 +511,7 @@
 					size: 999
 				}).then(data => {
 					this.repairHistoryList = data.list
+					console.log(this.repairHistoryList, '\this.repairHistoryList')
 				})
 			},
 			// 获取设备信息
@@ -570,7 +583,7 @@
 					.category.modelType
 				let data = JSON.parse(JSON.stringify(this.worksheetInfo));
 				data['deviceList'] = [this.equipmentInfo];
-				data['pageType']='add'
+				data['pageType'] = 'add'
 				uni.navigateTo({
 					url: `/pages/maintenanceWorkorder/sparepart/sparepart?data=${JSON.stringify(data)}`
 				})
@@ -587,7 +600,10 @@
 					url: `/pages/maintenanceWorkorder/submitted_ministry/submitted_ministry?workOrderCode=${this.repairInfo.code}&code=${this.workOrderCode}&id=${this.id}&deviceName=${this.repairInfo.deviceName}`
 				})
 			},
-
+			// 跳转非完成报工
+			handlNobg() {
+				this.$refs.unfinishedA.open(this.worksheetInfo.id)
+			},
 			// 保修须知
 			handleNotice() {
 				this.noticeShow = true
@@ -614,7 +630,7 @@
 			// 转派
 			handlZp() {
 				let id = this.worksheetInfo.id
-				this.$refs.Assign.open(id)
+				this.$refs.Assign.open(id, 'Transfer')
 			},
 			// 详情
 			handDetail(data) {

+ 5 - 2
pages/maintenanceWorkorder/order/OrderTask.vue

@@ -61,7 +61,10 @@
 			list: {
 				type: Array,
 				default: () => []
-			}
+			},
+			ParentIndex: {
+				type: [String, Number]
+			},
 		},
 		data() {
 			return {
@@ -84,7 +87,7 @@
 		methods: {
 			goDetail(item) {
 				uni.navigateTo({
-					url: `/pages/maintenanceWorkorder/detail/detail?id=${item.id}&planId=${item.planId}&code=${item.code}&&orderType=1`
+					url: `/pages/maintenanceWorkorder/detail/detail?id=${item.id}&planId=${item.planId}&code=${item.code}&&orderType=1&ParentIndex=${this.ParentIndex}`
 				})
 			},
 			isClass() {

+ 32 - 3
pages/maintenanceWorkorder/order/order.vue

@@ -22,13 +22,14 @@
 			</view>
 		</view>
 		<OrderTask v-for="(item, index) in tabList" :key="index" v-show="index === pickTabIndex" :list="item.list"
-			:type="tabList.value"></OrderTask>
+			:type="tabList.value" :ParentIndex="pickTabIndex"></OrderTask>
 	</view>
 </template>
 
 <script>
 	import {
-		getWorkOrderList
+		getWorkOrderList,
+		getAssistList
 	} from '@/api/myTicket'
 	import OrderTask from './OrderTask.vue'
 	import {
@@ -65,6 +66,12 @@
 						label: '已验收',
 						list: [],
 						number: 0
+					},
+					{
+						value: 5,
+						label: '协助工单',
+						list: [],
+						number: 0
 					}
 				],
 				pickTabIndex: 0,
@@ -120,6 +127,7 @@
 				}).then(res => {
 					this.tabList[3].number = res.count
 				})
+				// /eam/PdaWorkOrder/assistList
 			},
 			getCount() {
 				statistics().then(data => {
@@ -187,7 +195,28 @@
 			},
 			changeChartsTab(index) {
 				this.pickTabIndex = index
-				this.getFirstList()
+				if (index == 4) {
+					this.getAList()
+				} else {
+					this.getFirstList()
+				}
+			},
+			async getAList() {
+				uni.showLoading({
+					title: '数据加载中'
+				})
+				getAssistList({
+						type: 3,
+						pageNum: page,
+						size
+					}).then(res => {
+						this.tabList[this.pickTabIndex].list = res.list
+						isEnd = this.tabList[this.pickTabIndex].list >= res.count
+						uni.hideLoading()
+					})
+					.catch(() => {
+						uni.hideLoading()
+					})
 			}
 		}
 	}