Browse Source

1.修改设备档案样式
2.修改设备档案详样式
3.设备档案客户修改为跳转页面
4.设备列表添加删除增加提示框
5.保修列表样式修改
6.保修列表保修详情提交的数据修改

wangzhuo 1 year ago
parent
commit
e90f82eba0

+ 13 - 10
pages/device/EquipmentArchives/EquipmentArchives.vue

@@ -12,15 +12,17 @@
 			</view> -->
 		</view>
 		<view class="listbox">
-			<view class="cardBox" v-for="item in listData" :key="item.id">
+			<view class="cardBox" v-for="item in listData" :key="item.id" @click="Jumpfun(item.id)">
 				<view class="listbox_title">
 					<view class="listbox_titleLeft">
-						<u-icon name="bookmark-fill" color="#215476" size="22"></u-icon>
+						<!-- <u-icon name="bookmark-fill" color="#215476" size="22"></u-icon> -->
+						<view style="width: 10rpx;height: 35rpx;background-color: #fd4b09; margin-right: 8rpx;"></view>
 						<text>{{item.sysNo}}</text>
 					</view>
-					<view class="listbox_titleRight" @click="Jumpfun(item.id)">详情</view>
+					<!-- <view class="listbox_titleRight" @click="Jumpfun(item.id)">详情</view> -->
 				</view>
-				<view class="title" style="margin-left: 40rpx;">{{item.corpName}}</view>
+				<!-- style="margin-left: 40rpx;" -->
+				<view class="title">{{item.corpName}}</view>
 				<view class="countBox">
 					<view class="countBox_Left">
 						<text>设备数量:{{item.equipmentNumber}}</text>
@@ -121,7 +123,7 @@
 		font-size: 30rpx;
 	}
 	.listbox {
-		padding: 30rpx;
+		padding: 20rpx 16rpx;
 		box-sizing: border-box;
 		.cardBox {
 			background: #fff;
@@ -140,12 +142,12 @@
 					display: flex;
 					align-content: center;
 					font-size: 30rpx;
-					color: #215476;
+					// color: #215476;
 					font-weight: 500;
 				}
 				.listbox_titleRight {
 					font-size: 30rpx;
-					color: #215476;
+					// color: #215476;
 				}
 			}
 			.countBox {
@@ -167,8 +169,9 @@
 		}
 	}
 	.title {
-		font-size: 34rpx;
-		color: #215476;
-		font-weight: bold;
+		// font-size: 34rpx;
+		font-size: 32rpx;
+		// color: #215476;
+		// font-weight: bold;
 	}
 </style>

+ 208 - 37
pages/device/FileDetails/FileDetails.vue

@@ -1,25 +1,46 @@
 <template>
 	<view>
 		<view class="filedetails">
-			<view class="cardBox">
-				<view class="filedetails_left">
-					<view>
-						<u--input prefixIcon="account-fill" 
-						prefixIconStyle="fontSize:60rpx;color:#215476" placeholderStyle="fontSize:36rpx;color:#215476" 
+			
+			<view class="cardBox" @click="selectCustomer" style="margin-bottom: 0;  border-bottom: 4rpx solid #f5f5f5; border-radius: 12rpx 12rpx 0 0;">
+			 <!-- @click="pickerShowfun('KH')" -->
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="account" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">客户</text>
+						</view>
+						<u--input
+						 inputAlign="right"
 						disabled disabledColor="#fff" placeholder="客户" border="none"
 							v-model="form.corpName">
 						</u--input>
 					</view>
 				</view>
-				<view class="filedetails_right" @click="pickerShowfun('KH')">
+				<view class="filedetails_right">
 					<u-icon name="arrow-right" color="#101010" size="22"></u-icon>
 				</view>
 			</view>
-			<view class="cardBox">
-				<view class="filedetails_left">
+			
+			<view class="cardBox" style="margin-bottom: 0;  border-bottom: 4rpx solid #f5f5f5; border-radius: 0;">
+				<!-- <view class="filedetails_left">
 					<view>
-						<u--input prefixIcon="account-fill" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						<u--input prefixIcon="account" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
+						placeholder="联系人" border="none"
+							v-model="form.contacts">
+						</u--input>
+					</view>
+				</view>
+				 -->
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="account" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">联系人</text>
+						</view>
+						<u--input inputAlign="right"
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						placeholder="联系人" border="none"
 							v-model="form.contacts">
 						</u--input>
@@ -27,35 +48,64 @@
 				</view>
 			</view>
 			
-			<view class="cardBox">
-				<view class="filedetails_left">
+			<view class="cardBox" style="margin-bottom: 0;  border-bottom: 4rpx solid #f5f5f5; border-radius: 0;">
+				<!-- <view class="filedetails_left">
 					<view>
-						<u--input prefixIcon="phone-fill" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						<u--input prefixIcon="phone" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						 placeholder="电话" border="none"
 							v-model="form.contactsTel">
 						</u--input>
 					</view>
+				</view> -->
+				
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="account" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">电话</text>
+						</view>
+						<u--input inputAlign="right"
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
+						placeholder="电话" border="none"
+							v-model="form.contactsTel">
+						</u--input>
+					</view>
 				</view>
 			</view>
 			
-			<view class="cardBox">
-				<view class="filedetails_left">
+			<view class="cardBox" style="margin-bottom: 0;  border-bottom: 4rpx solid #f5f5f5; border-radius: 0;">
+				<!-- <view class="filedetails_left">
 					<view>
-						<u--input prefixIcon="map-fill" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						<u--input prefixIcon="home" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						 placeholder="地址" border="none"
 							v-model="form.address">
 						</u--input>
 					</view>
+				</view> -->
+				
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="account" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">地址</text>
+						</view>
+						<u--input inputAlign="right"
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
+						placeholder="地址" border="none"
+							v-model="form.address">
+						</u--input>
+					</view>
 				</view>
+				
 			</view>
 			
-			<view class="cardBox">
-				<view class="filedetails_left">
+			<view class="cardBox" @click="calendarShowfun(1,1)" style="margin-bottom: 0;  border-bottom: 4rpx solid #f5f5f5; border-radius: 0;">
+				<!-- <view class="filedetails_left">
 					<view>
 						<u--input prefixIcon="calendar" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						disabled disabledColor="#fff" placeholder="请选择合同起" border="none"
 							v-model="form.signingDateStart">
 						</u--input>
@@ -63,13 +113,31 @@
 				</view>
 				<view class="filedetails_right" @click="calendarShowfun(1,1)">
 					<u-icon name="arrow-right" color="#101010" size="22"></u-icon>
+				</view> -->
+				
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="calendar" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">合同日期起</text>
+						</view>
+						<u--input
+						 inputAlign="right"
+						disabled disabledColor="#fff" placeholder="合同日期起" border="none"
+							v-model="form.signingDateStart">
+						</u--input>
+					</view>
+				</view>
+				<view class="filedetails_right">
+					<u-icon name="arrow-right" color="#101010" size="22"></u-icon>
 				</view>
+				
 			</view>
-			<view class="cardBox">
-				<view class="filedetails_left">
+			<view class="cardBox" style="border-bottom: 4rpx solid #f5f5f5; border-radius: 0 0 12rpx 12rpx;">
+				<!-- <view class="filedetails_left">
 					<view>
 						<u--input prefixIcon="calendar" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						disabled disabledColor="#fff" placeholder="请选择合同止" border="none"
 							v-model="form.signingDateEnd">
 						</u--input>
@@ -77,6 +145,23 @@
 				</view>
 				<view class="filedetails_right" @click="calendarShowfun(1,2)">
 					<u-icon name="arrow-right" color="#101010" size="22"></u-icon>
+				</view> -->
+				
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;"  @click="calendarShowfun(1,2)">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="calendar" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">合同日期止</text>
+						</view>
+						<u--input
+						 inputAlign="right"
+						disabled disabledColor="#fff" placeholder="合同日期止" border="none"
+							v-model="form.signingDateEnd">
+						</u--input>
+					</view>
+				</view>
+				<view class="filedetails_right">
+					<u-icon name="arrow-right" color="#101010" size="22"></u-icon>
 				</view>
 			</view>
 			
@@ -91,18 +176,39 @@
 					></u-upload>
 			</view>
 			
+			
+			
 			<view class="cardBox">
-				<view class="filedetails_left">
+				<!-- <view class="filedetails_left">
 					<view>
 						<u--input prefixIcon="file-text" 
-						prefixIconStyle="fontSize:50rpx;color:#215476" placeholderStyle="fontSize:34rpx;color:#215476" 
+						prefixIconStyle="fontSize:50rpx;" placeholderStyle="fontSize:34rpx;" 
 						disabled disabledColor="#fff" :placeholder="`设备列表(${form.corpEquipmentArchivesItemList.length})`" border="none">
 						</u--input>
 					</view>
 				</view>
 				<view class="filedetails_right" @click="EquipmentAddition">
 					<u-icon name="list-dot" color="#101010" size="22"></u-icon>
+				</view> -->
+				
+				
+				<view class="filedetails_left" style="width: 100%; margin-right: 20rpx;">
+					<view style="display: flex;align-items: center;">
+						<view class="shebetext" style="display: flex;align-items: center; color: #FD4B09;">
+							<u-icon name="list-dot" color="#FD4B09" size="18"></u-icon>
+							<text style="font-size: 30rpx; margin-left: 10rpx;">设备列表({{form.corpEquipmentArchivesItemList.length}})</text>
+						</view>
+						<!-- <u--input
+						 inputAlign="right"
+						disabled disabledColor="#fff" :placeholder="`设备列表(${form.corpEquipmentArchivesItemList.length})`" border="none">
+						</u--input> -->
+					</view>
 				</view>
+				<view class="filedetails_right" @click="EquipmentAddConfirm = true">
+					<u-icon name="file-text" color="#101010" size="22"></u-icon>
+				</view>
+				
+				
 			</view>
 			
 			<view class="cardBox" v-for="(item,index) in form.corpEquipmentArchivesItemList" :key="item.id" 
@@ -112,12 +218,12 @@
 						<view class="listbox_titleXh">
 							设备{{index+1}}
 						</view>
-						<view class="listbox_titleDe" @click="DeleteDevicefun(item,index)">删除</view>
+						<view class="listbox_titleDe" @click="DeleteWindow(item,index)">删除</view>
 					</view>
 					<view class="inputbox" @click="pickerShowfun('CP',index)">
 						<!-- <view class="shebetext">设备名称:</view> -->
 						<u--input
-							prefixIconStyle="fontSize:60rpx;color:#215476"
+							prefixIconStyle="fontSize:60rpx;"
 							placeholderStyle="fontSize:30rpx;" 
 							disabled disabledColor="#fff" placeholder="请选择设备名称" border="bottom"
 							v-model="item.cname" >
@@ -129,7 +235,7 @@
 					<view class="inputbox">
 						<!-- <view class="shebetext">设备编号:</view> -->
 						<u--input
-							prefixIconStyle="fontSize:60rpx;color:#215476"
+							prefixIconStyle="fontSize:60rpx;"
 							placeholderStyle="fontSize:30rpx;"
 							 disabledColor="#fff" placeholder="请输入设备编号" border="bottom"
 							v-model="item.code">
@@ -144,7 +250,7 @@
 					<view class="inputbox" @click="calendarShowfun(2,1,index)">
 						<!-- <view class="shebetext">出厂日期:</view> -->
 						<u--input
-							prefixIconStyle="fontSize:60rpx;color:#215476"
+							prefixIconStyle="fontSize:60rpx;"
 							placeholderStyle="fontSize:30rpx;"
 							disabled disabledColor="#fff" placeholder="请选择出厂日期" border="bottom"
 							v-model="item.exitDate">
@@ -156,7 +262,7 @@
 					<view class="inputbox" @click="calendarShowfun(2,2,index)">
 						<!-- <view class="shebetext">保养日期:</view> -->
 						<u--input
-							prefixIconStyle="fontSize:60rpx;color:#215476"
+							prefixIconStyle="fontSize:60rpx;"
 							placeholderStyle="fontSize:30rpx;"
 							disabled disabledColor="#fff" placeholder="请选择保养日期" border="bottom"
 							v-model="item.maintenanceDate">
@@ -256,11 +362,27 @@
 		 @confirm="calendarConfirm" @close="calendarClose"></u-calendar>
 		<!-- 提示 -->
 		<u-toast ref="uToast"></u-toast>
+		
+		<!-- 添加设备弹框 -->
+		<u-modal :show="EquipmentAddConfirm" title="提示" showCancelButton @confirm="EquipmentAddition"
+			@cancel="EquipmentAddConfirm = false">
+			<view class="slot-content">
+				<rich-text nodes="确定要添加新设备吗?"></rich-text>
+			</view>
+		</u-modal>
+		
+		<!-- 删除弹框 -->
+		<u-modal :show="EquipmentDeleteConfirm" title="提示" showCancelButton @confirm="DeleteDevicefun"
+			@cancel="EquipmentDeleteConfirm = false">
+			<view class="slot-content">
+				<rich-text nodes="确定要删除该设备吗?"></rich-text>
+			</view>
+		</u-modal>
 	</view>
 </template>
 
 <script>
-	import { corpequipmentarchivesDetail,corpequipmentarchivesSubmit,goodsdescDescList } from '@/api/device/index.js'
+	import { corpequipmentarchivesDetail,corpequipmentarchivesSubmit,goodsdescDescList,corpequipmentarchivesitemRemove } from '@/api/device/index.js'
 	import { corpsDescList } from '@/api/views/sale/index.js'
 	import { queryDetail } from '@/api/views/customer/index.js'
 	import http from '@/http/api.js'
@@ -271,6 +393,13 @@
 	export default {
 		data() {
 			return {
+				// 弹框
+				// 设备添加
+				EquipmentAddConfirm: false,
+				// 设备删除
+				EquipmentDeleteConfirm: false,
+				EquipmentDeleteRow:{},
+				EquipmentDeleteIndex: -1,
 				// 传递过来的id
 				id:null,
 				// 绑定的数据
@@ -386,6 +515,26 @@
 					}
 				})
 			},
+			// 跳转选择用户
+			selectCustomer() {
+				console.log("跳转");
+				this.$u.route('/pages/views/salesSlip/selectCustomer', {
+					corpType: 'KH'
+				});
+			},
+			// 选中用户赋值
+			otherFun(user) {
+				console.log(user);
+				
+				queryDetail({id:user.id}).then(res=>{
+					this.$set(this.form,'address',res.data.corpsAddrList[0].detailedAddress)
+					this.form.corpId = user.id
+					this.form.corpName = res.data.cname
+					this.form.contacts = res.data.attn
+					this.form.contactsTel = res.data.tel
+				})
+				
+			},
 			// 设备新增
 			EquipmentAddition(){
 				this.form.corpEquipmentArchivesItemList.push({
@@ -408,6 +557,8 @@
 					maintenanceSecond:'',
 					filesList:[],
 				})
+				
+				this.EquipmentAddConfirm = false
 			},
 			// 弹窗的开启
 			pickerShowfun(type,index){
@@ -442,7 +593,7 @@
 					})
 				}else if (this.pickerType.type == 'CP'){
 					this.form.corpEquipmentArchivesItemList[this.pickerType.index].cname = val.value[0].cname
-					this.form.corpEquipmentArchivesItemList[this.pickerType.index].code = val.value[0].code
+					// this.form.corpEquipmentArchivesItemList[this.pickerType.index].code = val.value[0].code
 					this.form.corpEquipmentArchivesItemList[this.pickerType.index].brand = val.value[0].brand
 					this.form.corpEquipmentArchivesItemList[this.pickerType.index].brandId = val.value[0].brandId
 					this.form.corpEquipmentArchivesItemList[this.pickerType.index].specs = val.value[0].specs
@@ -500,14 +651,32 @@
 					this.form = res.data
 				})
 			},
+			
+			// 删除弹窗
+			DeleteWindow(row, index) {
+				this.EquipmentDeleteRow = row;
+				this.EquipmentDeleteIndex = index;
+				this.EquipmentDeleteConfirm = true;
+			},
+			
 			// 删除设备
-			DeleteDevicefun(row,index){
+			DeleteDevicefun(){
+				
+				var row = this.EquipmentDeleteRow
+				var index = this.EquipmentDeleteIndex
+				
+
+				
 				if (row.id) {
 					this.form.corpEquipmentArchivesItemList.splice(index,1)
 					this.corpequipmentarchivesitemRemovefun(row.id)
 				}else {
 					this.form.corpEquipmentArchivesItemList.splice(index,1)
 				}
+				
+				this.EquipmentDeleteRow = null;
+				this.EquipmentDeleteIndex = -1;
+				this.EquipmentDeleteConfirm = false;
 			},
 			// 删除接口
 			corpequipmentarchivesitemRemovefun(id){
@@ -688,7 +857,7 @@
 		background: #fff;
 		border-radius: 12rpx;
 		width: 100%;
-		padding: 30rpx;
+		padding: 20rpx 30rpx;
 		box-sizing: border-box;
 		display: flex;
 		align-content: center;
@@ -708,9 +877,11 @@
 		z-index: 99;
 		.savebutton {
 			border-radius: 30rpx;
-			color: #3f7cef;
+			// color: #3f7cef;
+			color: #FD4B09;
 			font-size: 34rpx;
-			border: 2rpx solid #3f7cef;
+			// border: 2rpx solid #3f7cef;
+			border: 2rpx solid #FD4B09;
 			padding: 15rpx 40rpx;
 			font-weight: 500;
 		}

+ 224 - 86
pages/device/RepairDetails/RepairDetails.vue

@@ -1,118 +1,133 @@
 <template>
 	<view>
-		<view class="repairdetails">
-			<view class="cardBox">
-				<!-- <view class="text">客户名称:</view> -->
-				<u-input v-model="form.corpName" disabled disabledColor="#fff"
-				border="none" placeholder="请输入客户名称" ></u-input>
+		<!-- 状态 -->
+		<view class="label" v-if="(form.status == 2 || form.status == 3 || form.status == 4) && userInfoRoleName.indexOf('admin') == -1">
+			<view class="tab" ref="wx" :style="{'color':wxStyle}" @click="tab('wx')">
+				<text>报修单</text>
 			</view>
+			<view class="tab" ref="gz" :style="{'color':gzStyle}" @click="tab('gz')">
+				<text>工作单</text>
+			</view>
+		</view>
+		
+		<view class="repairdetails" v-if="form.status == 1">
 			
 			<view class="cardBox">
-				<!-- <view class="text">客户描述:</view> -->
-				<u--textarea v-model="form.corpDescribe" placeholder="请输入客户描述"
-				 disabled border="none" >
-				</u--textarea>
+				<!-- <view class="text">设备信息:</view> -->
+				<u-input v-model="form.deviceName" disabledColor="#fff" disabled
+				border="none" placeholder="请选择设备信息" >
+					<template slot="suffix">
+						<u-icon name="scan" color="#bbb" size="32"></u-icon>
+					</template>
+				</u-input>
 			</view>
 			
 			<view class="cardBox">
-				<!-- <view class="text">电话:</view> -->
-				<u-input v-model="form.corpTel" disabled disabledColor="#fff"
-				border="none" placeholder="请输入电话" ></u-input>
+				<!-- <view class="text">客户名称:</view> -->
+				<u-input v-model="form.corpName" disabled disabledColor="#fff"
+				border="none" placeholder="客户名称" ></u-input>
 			</view>
 			
 			<view class="cardBox">
 				<!-- <view class="text">地址:</view> -->
 				<u-input v-model="form.deviceAddress" disabledColor="#fff" disabled
-				 border="none" placeholder="请输入地址" ></u-input>
+				 border="none" placeholder="设备地址" ></u-input>
 			</view>
 			
 			<view class="cardBox">
+				<!-- <view class="text">故障描述:</view> -->
+				<u--textarea v-model="form.faultDescribe" placeholder="故障描述" disabled
+					border="none" >
+				</u--textarea>
+			</view>
+			
+						
+			<view class="kapian">
+				<!-- <view style="font-size: 30rpx;color: #999;margin-left: 10rpx;">添加图片</view> -->
+				<view style="margin-top: 20rpx;">
+					<u-upload
+						:fileList="form.maintenanceFiles"
+						 :disabled="form.status != 3"
+						@afterRead="afterRead"
+						@delete="deletePic"
+						name="1"
+						multiple
+						:maxCount="10"
+					></u-upload>
+				</view>
+			</view>
+			
+		</view>
+		
+		
+		
+		<view class="repairdetails" v-if="wxStyle != ''">
+			
+			<view class="cardBox">
 				<!-- <view class="text">设备信息:</view> -->
 				<u-input v-model="form.deviceName" disabledColor="#fff" disabled
 				border="none" placeholder="请选择设备信息" >
-<!-- 					<template slot="suffix">
+					<template slot="suffix">
 						<u-icon name="scan" color="#bbb" size="32"></u-icon>
-					</template> -->
+					</template>
 				</u-input>
 			</view>
 			
 			<view class="cardBox">
-				<!-- <view class="text">设备描述:</view> -->
-				<u--textarea v-model="form.deviceDescribe" placeholder="请输入设备描述" disabled
-					border="none" >
-				</u--textarea>
+				<!-- <view class="text">客户名称:</view> -->
+				<u-input v-model="form.corpName" disabled disabledColor="#fff"
+				border="none" placeholder="客户名称" ></u-input>
+			</view>
+			
+			<view class="cardBox">
+				<!-- <view class="text">地址:</view> -->
+				<u-input v-model="form.deviceAddress" disabledColor="#fff" disabled
+				 border="none" placeholder="设备地址" ></u-input>
 			</view>
 			
 			<view class="cardBox">
 				<!-- <view class="text">故障描述:</view> -->
-				<u--textarea v-model="form.faultDescribe" placeholder="请输入故障描述" disabled
+				<u--textarea v-model="form.faultDescribe" placeholder="故障描述" disabled
 					border="none" >
 				</u--textarea>
 			</view>
 			
-			<view class="cardBox">
-				<!-- <view class="text">维修工:</view> -->
-				<u-input v-model="form.maintenanceWorkerName" disabledColor="#fff" disabled
-				border="none" placeholder="请选择维修工">
-					<template slot="suffix" v-if="form.status == 1 && userInfoRoleName.indexOf('admin') != -1">
-						<u-icon @click="pickerShowfun" name="arrow-right" color="#bbb" size="24"></u-icon>
-					</template>
-				</u-input>
+						
+			<view class="kapian">
+				<!-- <view style="font-size: 30rpx;color: #999;margin-left: 10rpx;">添加图片</view> -->
+				<view style="margin-top: 20rpx;">
+					<u-upload
+						:fileList="form.maintenanceFiles"
+						 :disabled="form.status != 3"
+						@afterRead="afterRead"
+						@delete="deletePic"
+						name="1"
+						multiple
+						:maxCount="10"
+					></u-upload>
+				</view>
 			</view>
 			
-			<view class="cardBox">
-				<!-- <view class="text">维修工电话:</view> -->
-				<u-input v-model="form.maintenanceWorkerTel" disabledColor="#fff" :disabled="form.status != 1"
-				border="none" placeholder="请输入维修工电话" ></u-input>
-			</view>
+		</view>
+		
+		
+		<view class="repairdetails" v-if="gzStyle != ''">
 			
 			<view class="cardBox">
-				<u-input v-model="form.repairReportDate" disabledColor="#fff" disabled
-				border="none" placeholder="请选择维修日期">
+				<!-- <view class="text">设备信息:</view> -->
+				<u-input v-model="form.deviceName" disabledColor="#fff" disabled
+				border="none" placeholder="请选择设备信息" >
+					<template slot="suffix">
+						<u-icon name="scan" color="#bbb" size="32"></u-icon>
+					</template>
 				</u-input>
 			</view>
 			
-			
-			<view class="kapian" >
-				<view class="wxtitleflex">
-					<view class="wxtitle">维修费用</view>
-					<view v-if="form.status == 3 && type != 'XQ'" class="addwx" @click="wxaddfun">添加</view>
-				</view>
+			<view class="cardBox">
+				<u--textarea v-model="form.repairDescription" placeholder="维修描述" border="none" :disabled="form.status != 3" >
+				</u--textarea>
 			</view>
 			
-			<view >
-				<view class="kapian" v-for="(item,index) in form.maintenanceFees" :key="item.id">
-					<view class="WXflex">
-						<view class="xuhao">序号:{{index + 1}}</view>
-						<view class="wxscfun" v-if="form.status == 3" @click="maintenanceDe(item,index)">删除</view>
-					</view>
-					<view class="wxbox">
-						<!-- <view class="text">维修项目:</view> -->
-						<u-input v-model="item.costName" disabledColor="#fff" :disabled="form.status != 3"
-						border="none" placeholder="请输入维修项目" ></u-input>
-					</view>
-					
-					<view class="wxbox">
-						<!-- <view class="text">金额:</view> -->
-						<u-input v-model="item.amount" disabledColor="#fff" :disabled="form.status != 3"
-						border="none" placeholder="请输入金额" ></u-input>
-					</view>
-					
-			<!-- 		<view class="wxbox">
-						<view class="text">结算金额:</view>
-						<u-input v-model="item.settlementAmount" disabledColor="#fff" disabled
-						border="none" placeholder="请输入结算金额" ></u-input>
-					</view> -->
-					
-					<view class="wxbox">
-						<!-- <view class="text">备注:</view> -->
-						<u--textarea v-model="item.remarks" placeholder="请输入备注" :disabled="form.status != 3"
-							border="none" >
-						</u--textarea>
-					</view>
-				</view>
-			</view>
-						
 			<view class="kapian">
 				<!-- <view style="font-size: 30rpx;color: #999;margin-left: 10rpx;">添加图片</view> -->
 				<view style="margin-top: 20rpx;">
@@ -128,24 +143,66 @@
 				</view>
 			</view>
 			
+			<view >
+				<view class="kapian" v-for="(item,index) in form.maintenanceFees" :key="item.id">
+					<view class="WXflex">
+						<view class="wxscfun" v-if="form.status == 3" @click="maintenanceDe(item,index)">删除</view>
+					</view>
+					<view class="repairProject">
+						<view class="wxbox">
+							<u-input v-model="item.costName" disabledColor="#fff" :disabled="form.status != 3"
+							border="none" placeholder="添加项目" ></u-input>
+						</view>
+						
+						<view class="wxbox">
+							<u-input v-model="item.amount" disabledColor="#fff" :disabled="form.status != 3"
+							border="none" inputAlign="right" @input="moneyInput" placeholder="金额" >
+							<u--text
+								text="元"
+								slot="suffix"
+								margin="0 3px 0 0"
+								type="tips"
+								></u--text>
+							</u-input>
+						</view>
+					</view>
+				</view>
+			</view>
+			
+			
+			<view class="kapian" >
+				<view class="wxtitleflex">
+					<view class="wxtitle">添加费用</view>
+					<view v-if="form.status == 3 && type != 'XQ'" class="addwx" @click="wxaddfun">添加</view>
+				</view>
+			</view>
 		</view>
 		
 		
-		
+
+			  
+			
+			
 		
 		<u-gap height="60"></u-gap>
 		
 		<view class="bottombox" v-if="type != 'XQ'">
-			<view class="bottombox_name">{{form.maintenanceWorkerName}}</view>
+			<view class="bottombox_name" v-if="form.status != 3 && form.status != 1">
+				<text>{{form.maintenanceWorkerName}}</text>
+			</view>
+			<view class="bottombox_name" @click="pickerShowfun" v-if="form.status == 1 && userInfoRoleName.indexOf('admin') != -1">
+				<text>{{form.maintenanceWorkerName == null || form.maintenanceWorkerName == '' ? '请选择维修工' : form.maintenanceWorkerName}}</text>
+			</view>
+			<view v-if="form.status == 3" style="color: #FD4B09;">维修费:{{form.maintenanceAmount}}元</view>
 			<view class="bottombox_right">
 				<view class="buttonClass"
 				 v-if="form.status == 1 && userInfoRoleName.indexOf('admin') != -1" 
-				 @click="maintenanceDispatchingWorkersfun">派工</view>
+				 @click="maintenanceDispatchingWorkersfun">确认派工</view>
 				<view class="buttonClass" 
 					v-if="form.status == 2 && userInfoRoleName.indexOf('admin') != -1"
 				 @click="maintenanceRevokeDispatchingWorkersfun">撤销派工</view>
 				<view class="buttonClass" v-if="form.status == 2 && userInfoRoleName.indexOf('维修工') != -1" @click="receivingOrdersfun">确认接单</view>
-				<view class="buttonClass" v-if="form.status == 3" @click="Confirmexpenses">提交费用</view>
+				<view class="buttonClass" v-if="form.status == 3" @click="Confirmexpenses">确认费用</view>
 				<view class="buttonClass" v-if="form.status == 4" @click="Confirmexpenses">确认结算</view>
 			</view>
 		</view>
@@ -175,6 +232,13 @@
 		data() {
 			return {
 				id:null,
+				wxStyle: '',
+				gzStyle: '',
+				range: [
+				          { value: 0, text: "篮球" },
+				          { value: 1, text: "足球" },
+				          { value: 2, text: "游泳" },
+				        ],
 				form:{
 					maintenanceFees:[
 						{
@@ -202,10 +266,35 @@
 			this.userInfoRoleName = uni.getStorageSync('userInfo').role_name.split(',')
 			this.maintenanceDetailfun()
 		},
+		onShow() {
+			
+		},
 		methods: {
+			moneyInput() {
+				var money = 0
+				
+				for (let fees of this.form.maintenanceFees) {
+					money += Number(fees.amount)
+				}
+				
+				this.form.maintenanceAmount = money;
+			},
+			tab(type) {
+				if(type == "wx") {
+					this.wxStyle = "#fd4b09"
+					this.gzStyle = ""
+					// this.form.status = 2
+					
+				} else if (type == "gz") {
+					this.gzStyle = "#fd4b09"
+					this.wxStyle = ""
+					// this.form.status = 3
+				}
+			},
 			// 设备删除
 			maintenanceDe(row,index){
 				this.form.maintenanceFees.splice(index,1)
+				this.moneyInput()
 			},
 			// 撤销派工
 			maintenanceRevokeDispatchingWorkersfun(){
@@ -227,11 +316,11 @@
 			// 派工
 			maintenanceDispatchingWorkersfun(){
 				if (!this.form.maintenanceWorkerId) {
-					return this.$refs.uToast.show({type: 'warning',message: '请添加维修工'})
-				}
-				if (!this.form.maintenanceWorkerTel) {
-					return this.$refs.uToast.show({type: 'warning',message: '请输入维修工电话'})
+					return this.$refs.uToast.show({type: 'warning',message: '请选择维修工'})
 				}
+				// if (!this.form.maintenanceWorkerTel) {
+				// 	return this.$refs.uToast.show({type: 'warning',message: '请输入维修工电话'})
+				// }
 				maintenanceDispatchingWorkers(this.form).then(res=>{
 					if (res.code == 200) {
 						this.$refs.uToast.show({
@@ -266,6 +355,7 @@
 				this.form.maintenanceWorkerName = e.value[0].name
 				this.form.maintenanceWorkerTel = e.value[0].phone
 				this.pickerShow = false
+				
 			},
 			// 维修工弹窗取消
 			pickerShowCancel() {
@@ -348,6 +438,19 @@
 			maintenanceDetailfun(){
 				maintenanceDetail({id:this.id}).then(res=>{
 					this.form = res.data
+					
+					if (this.form.status == 3) {
+						this.gzStyle = "#fd4b09"
+						this.wxStyle = ""
+					} else if (this.form.status == 2) {
+						console.log(this.form.status);
+						this.wxStyle = "#fd4b09"
+						this.gzStyle = ""
+					} else if (this.form.status == 1) {
+						userList({roleAlias:'维修工'}).then(res=>{
+							this.wxUserList = [res.data]
+						})
+					}
 					// if (this.type == 'JD') {
 					// 	this.form.maintenanceFees.push({
 					// 		id:null,
@@ -422,6 +525,35 @@
 </script>
 
 <style lang="scss" scoped>
+	
+	.label {
+		left: 0rpx;
+		top: 190rpx;
+		width: 100%;
+		height: 114rpx;
+		line-height: 40rpx;
+		background-color: rgba(255, 255, 255, 1);
+		text-align: center;
+		
+		display: flex;
+		
+		align-items: center;
+
+		
+		.tab {
+			width: 50%;
+			display: flex;
+			color: #c4c4c4;
+			
+			align-items: center;
+			justify-content: center;
+			font-size: 40rpx;
+			text-align: left;
+			font-family: PingFangSC-semiBold;
+			
+		}
+	}
+	
 	.repairdetails {
 		padding: 20rpx;
 		box-sizing: border-box;
@@ -449,6 +581,11 @@
 		padding: 30rpx;
 		box-sizing: border-box;
 		margin-bottom: 20rpx;
+		
+		.repairProject {
+			display: flex;
+		}
+		
 		.wxtitleflex {
 			display: flex;
 			align-items: center;
@@ -509,12 +646,13 @@
 		.bottombox_right {
 			display: flex;
 			.buttonClass {
-				background: #2d4a6a;
-				padding: 10rpx 30rpx;
+				// background: #2d4a6a;
+				background: #FD4B09;
+				padding: 10rpx 60rpx;
 				border-radius: 30rpx;
 				color: #fff;
-				font-weight: bold;
-				margin: 0 10rpx;
+				// font-weight: bold;
+				// margin: 0 10rpx;
 			}
 		}
 	}

+ 37 - 9
pages/device/RepairReportList/RepairReportList.vue

@@ -7,10 +7,20 @@
 			</view>
 		</view> -->
 		
-		<view class="cardBox" v-for="(item,index) in Datalist" :key="index">
+		<view class="cardBox" v-for="(item,index) in Datalist" :key="index" @click="cardBoxClick(item)">
 			<view class="cardBox_top">
-				<u-icon name="bookmark-fill" size="24"></u-icon>
-				<view class="text">{{item.sysNo}}</view>
+				<!-- <u-icon name="bookmark-fill" size="24"></u-icon> -->
+				<view class="cardBox_top">
+					<view style="width: 10rpx;height: 35rpx;background-color: #fd4b09; margin-right: 8rpx;"></view>
+					<view class="text">{{item.sysNo}}</view>
+				</view>
+				<view>
+					<text v-if="item.status == 1" style="color: #3c9cff; font-size: 28rpx">待派工</text>
+					<text v-if="item.status == 2" style="color: #fd4b09; font-size: 28rpx">待接单</text>
+					<text v-if="item.status == 3" style="color: rgba(222, 36, 18, 1); font-size: 28rpx">待提交</text>
+					<text v-if="item.status == 4" style="color:  rgba(233, 157, 66, 1); font-size: 28rpx">待结算</text>
+					<text v-if="item.status == 5" style="color: rgba(129, 179, 55, 1); font-size: 28rpx">已完工</text>
+				</view>
 			</view>
 			<view class="title">{{item.deviceName}}</view>
 			<view class="text">
@@ -31,12 +41,12 @@
 			</view>
 			
 			<view class="positioningButton">
-				<view class="Buttonjd" v-if="item.status == 1 && userInfoRoleName.indexOf('admin') != -1" @click="Jumpfun(item.id,'PG')">派工</view>
+				<!-- <view class="Buttonjd" v-if="item.status == 1 && userInfoRoleName.indexOf('admin') != -1" @click="Jumpfun(item.id,'PG')">派工</view>
 				<view class="Buttonjd" v-if="item.status == 2 && userInfoRoleName.indexOf('admin') != -1" @click="Jumpfun(item.id,'QXPG')">撤销派工</view>
 				<view class="Buttonjd" v-if="item.status == 2 && userInfoRoleName.indexOf('维修工') != -1" @click="Jumpfun(item.id,'JD')">接单</view>
 				<view class="Buttonjd" v-if="item.status == 3 && userInfoRoleName.indexOf('admin') == -1" @click="Jumpfun(item.id,'FY')">提交费用</view>
-				<view class="Buttonjd" v-if="item.status == 4 && userInfoRoleName.indexOf('admin') == -1" @click="Jumpfun(item.id,'FY')">确认结算</view>
-				<view class="Buttonxq" @click="Jumpfun(item.id,'XQ')">详情</view>
+				<view class="Buttonjd" v-if="item.status == 4 && userInfoRoleName.indexOf('admin') == -1" @click="Jumpfun(item.id,'FY')">确认结算</view> -->
+				<!-- <view class="Buttonxq" @click="Jumpfun(item.id,'XQ')">详情</view> -->
 			</view>
 			
 		</view>
@@ -105,6 +115,19 @@
 			}
 		},
 		methods: {
+			cardBoxClick(item) {
+				if (item.status == 1 && this.userInfoRoleName.indexOf('admin') != -1) {
+					this.Jumpfun(item.id,'PG');
+				} else if (item.status == 2 && this.userInfoRoleName.indexOf('admin') != -1) {
+					this.Jumpfun(item.id,'QXPG')
+				} else if (item.status == 2 && this.userInfoRoleName.indexOf('维修工') != -1) {
+					this.Jumpfun(item.id,'JD')
+				} else if (item.status == 3 && this.userInfoRoleName.indexOf('admin') == -1) {
+					this.Jumpfun(item.id,'FY')
+				} else if (item.status == 4 && this.userInfoRoleName.indexOf('admin') == -1) {
+					this.Jumpfun(item.id,'FY')
+				}
+			},
 			tbafun(type){
 				console.log(type);
 				this.page.status = type.id
@@ -136,6 +159,9 @@
 	.cardBox_top {
 		display: flex;
 		align-items: center;
+		
+		display: flex;
+		justify-content: space-between;
 	}
 	.positioningButton {
 		position: absolute;
@@ -181,8 +207,9 @@
 		position: relative;
 	}
 	.title {
-		font-size: 38rpx;
-		color: #215476;
+		font-size: 32rpx;
+		// color: #215476;
+		color: #fd4b09;
 		font-weight: 500;
 		margin: 15rpx 0;
 		margin-left: 20rpx;
@@ -192,7 +219,8 @@
 		text-overflow: ellipsis;
 	}
 	.text {
-		font-size: 30rpx;
+		// font-size: 30rpx;
+		font-size: 24rpx;
 		margin: 10rpx 0;
 		display: flex;
 		align-items: center;

+ 2 - 0
pages/views/salesSlip/selectCustomer.vue

@@ -92,6 +92,8 @@
 				})
 			},
 			choice(item1, index1) {
+				console.log("item1");
+				console.log(item1);
 				this.form = item1
 				this.show = true
 			},