From 976d776e39ec9bb87076fcfa11273af4729f519e Mon Sep 17 00:00:00 2001
From: licp <lichunping@guanfang.com.cn>
Date: 星期一, 01 四月 2024 15:44:43 +0800
Subject: [PATCH] 合并冲突

---
 src/components/do/b1-inspect-order-plan/Inspection.vue |   21 +++++++--------------
 src/components/view/b1-inspect-order-plan.vue          |   17 ++++++++++++-----
 src/util/date.js                                       |    7 ++++++-
 3 files changed, 25 insertions(+), 20 deletions(-)

diff --git a/src/components/do/b1-inspect-order-plan/Inspection.vue b/src/components/do/b1-inspect-order-plan/Inspection.vue
index 7b70bdc..08cde83 100644
--- a/src/components/do/b1-inspect-order-plan/Inspection.vue
+++ b/src/components/do/b1-inspect-order-plan/Inspection.vue
@@ -241,7 +241,7 @@
 				:componentData="componentData" :key="upIndex" />
 		</el-drawer>
     <el-dialog title="妫�楠屽鏍�" :visible.sync="reviewDia" width="400px">
-			<div class="body" style="display: flex;align-items: center;" v-if="reviewDia">
+			<div class="body" style="display: flex;" v-if="reviewDia">
 				<div class="search_label" style="width: 120px;"><span class="required-span">* </span>涓嶉�氳繃鍘熷洜锛�</div>
 				<div class="search_input">
 					<el-input size="small" clearable v-model="noReason" type="textarea" :autosize="{ minRows: 3, maxRows: 5}"></el-input>
@@ -331,7 +331,8 @@
 			id(val) {
 				this.loading = true
 				this.$axios.post(this.$api.insOrderPlan.doInsOrder, {
-					id: val
+					id: val,
+          laboratory: this.sonLaboratory
 				}).then(res => {
 					this.insOrder = res.data.insOrder;
 					this.urgentList.forEach(m => {
@@ -820,16 +821,12 @@
             type:1,
             laboratory:this.sonLaboratory,
             tell:null
-          }, {
-					headers: {
-						'Content-Type': 'application/json'
-					}
           }).then(res => {
             if (res.code === 200 && res.data) {
-              this.reviewLoading = false;
-              this.$message.success("澶嶆牳閫氳繃")
+              this.$message.success("鎿嶄綔鎴愬姛")
               this.$emit('goback')
             }
+            this.reviewLoading = false;
           }).catch(error => {
             console.error(error)
             this.reviewLoading = false;
@@ -847,16 +844,12 @@
             type:0,
             laboratory:this.sonLaboratory,
             tell:this.noReason
-          }, {
-					headers: {
-						'Content-Type': 'application/json'
-					}
           }).then(res => {
             if (res.code === 200 && res.data) {
-              this.reviewLoading = false;
-              this.$message.success("澶嶆牳涓嶉�氳繃")
+              this.$message.success("鎿嶄綔鎴愬姛")
               this.$emit('goback')
             }
+            this.reviewLoading = false;
           }).catch(error => {
             console.error(error)
             this.reviewLoading = false;
diff --git a/src/components/view/b1-inspect-order-plan.vue b/src/components/view/b1-inspect-order-plan.vue
index f344c46..1827d74 100644
--- a/src/components/view/b1-inspect-order-plan.vue
+++ b/src/components/view/b1-inspect-order-plan.vue
@@ -235,13 +235,19 @@
 							id: '',
 							font: '浜ゆ帴',
 							type: 'text',
-							method: 'handleConnect'
+							method: 'handleConnect',
+							disabFun: (row, index) => {
+								return row.userId == null
+							}
 						},
 						{
 							id: '',
 							font: '澶嶆牳',
 							type: 'text',
 							method: 'handleReview',
+							// disabFun: (row, index) => {
+							// 	return row.userId == null || row.insState != 4
+							// }
 						}, {
 							id: '',
 							font: '璁ら',
@@ -300,6 +306,7 @@
         connectVisible:false,
         connectPerson:'',
         loading:false,
+        currentTime: null
 			}
 		},
 		created() {
@@ -307,6 +314,7 @@
 			this.getTypeDicts()
 			this.getInsStateDicts()
       this.getAuthorizedPerson()
+      this.currentTime = getYearAndMonthAndDays()
 		},
 		mounted() {
 			this.entityCopy = this.HaveJson(this.componentData.entity)
@@ -393,10 +401,9 @@
 				row,
 				rowIndex
 			}) {
-				let currentTime = getYearAndMonthAndDays()
-				if (currentTime === row.appointed) {
+				if (this.currentTime === row.appointed) {
 					return 'highlight-warning-row-border'
-				} else if (currentTime > row.appointed) {
+				} else if (this.currentTime > row.appointed) {
 					return 'highlight-danger-row-border'
 				}
 				return ''
@@ -507,9 +514,9 @@
 					if (res.code === 200 && res.data) {
             this.loading = false;
 						this.$message.success("浜ゆ帴鎴愬姛")
-						this.connectVisible = false
 						this.refreshTable()
 					}
+          this.connectVisible = false
 				}).catch(error => {
 					console.error(error)
           this.loading = false;
diff --git a/src/util/date.js b/src/util/date.js
index 867a406..5135a21 100644
--- a/src/util/date.js
+++ b/src/util/date.js
@@ -12,5 +12,10 @@
   }
   year = year + '-'
   let days = date.getDate()
-  return year + month + days
+  if (days < 10) {
+    days = '0' + days + '-'
+  } else {
+    days = days + '-'
+  }
+  return (year + month + days)
 }

--
Gitblit v1.9.3