From 8fc8838a441ae3d3b1616f4fc003b16292978b54 Mon Sep 17 00:00:00 2001
From: 付延余 <f-yanyu@outlook.com>
Date: 星期一, 19 十二月 2022 11:19:45 +0800
Subject: [PATCH] 注册,登录,主页,日计划的修改

---
 pages/my-todo/my-todo.vue |   50 +++++++++++++++++++++++++++++++++-----------------
 1 files changed, 33 insertions(+), 17 deletions(-)

diff --git a/pages/my-todo/my-todo.vue b/pages/my-todo/my-todo.vue
index 0f57734..c58cdf1 100644
--- a/pages/my-todo/my-todo.vue
+++ b/pages/my-todo/my-todo.vue
@@ -81,7 +81,7 @@
           <view class="bottom-container">
             <!-- 寰呭姙鎸夐挳 -->
             <view class="bottom-content__item">
-              <view @click="theFormDataClick(item.tableId)" v-if="item.procDefId == 'WAY_BILL:4:87504'">
+              <view @click="theFormDataClick(item.tableId)" v-if="item.processName == '鍙戣繍閫氱煡鍗�'">
                 <image src="@/static/home/jindu.png" mode=""></image>
                 <view>鐢宠璇︽儏</view>
               </view>
@@ -89,7 +89,7 @@
                 <image src="@/static/home/tongguo.png" mode=""></image>
                 <view>閫氳繃</view>
               </view>
-              <view @click="rejectModalShow = true">
+              <view @click="rejectClick(item)">
                 <image src="@/static/home/bohui.png" mode=""></image>
                 <view>椹冲洖</view>
               </view>
@@ -192,6 +192,7 @@
 <script>
 import popupMenu from '@/components/common/popup-menu/popup-menu.vue';
 import combinationCard from '@/components/common/combination-card/combination-card.vue';
+import { callWithErrorHandling } from "vue";
 
 export default {
   data() {
@@ -422,6 +423,7 @@
     },
     // 閫氳繃
     adopClick(v) {
+			console.log('閫氳繃',v);
       this.adoptModalShow = true;
       this.adoptForm.ids = v.id;
       this.modalType = 0;
@@ -436,47 +438,61 @@
     // 閫氳繃妯℃�佹
     adoptModalConfirm() {
       this.adoptModalShow = false;
-      this.checkBoxValue.forEach(item => {
-        this.adoptDataBox.push(item.slice(0, 6))
-      })
-      this.adoptForm.ids = this.adoptDataBox.toString();
-      this.$reqPost('passAll', this.adoptForm, 'form').then(res => {
+			if(this.checkBoxValue.length >= 1){
+				this.checkBoxValue.forEach(item => {
+				  this.adoptDataBox.push(item.slice(0, 6))
+				})
+				this.adoptForm.ids = this.adoptDataBox.toString();
+			}
+      this.$reqPost('passAll', this.adoptForm).then(res => {
         console.log('鏄惁杩樺師', this.adoptForm.ids, this.rejectForm.procInstIds);
         if (res.code == 0) {
           this.$u.toast('鎿嶄綔鎴愬姛!');
         } else {
           this.$u.toast('娣诲姞澶辫触!!');
         }
+				// 鍒濆鍖�
+				this.checkBoxValue = []
+				this.adoptForm.ids = '';
+				this.adoptForm.comment = '';
         this.init();
       });
     },
     adoptModalCancel() {
       this.adoptModalShow = false;
     },
+		// 椹冲洖鐐瑰嚮
+		rejectClick(v) {
+		  this.modalType = 1;
+		  this.rejectModalShow = true;
+		  this.rejectForm.procInstIds = v.procInstId;
+		},
     // 椹冲洖妯℃�佹
     rejectModalConfirm() {
       this.rejectModalShow = false;
-      this.checkBoxValue.forEach(item => {
-        this.rejectDataBox.push(item.slice(6, 12))
-      })
-      this.rejectForm.procInstIds = this.rejectDataBox.toString();
-      this.$reqPost('backAll', this.rejectForm, 'form').then(res => {
+			if(this.checkBoxValue.length >= 1){
+				this.checkBoxValue.forEach(item => {
+				  this.rejectDataBox.push(item.slice(6, 12))
+				})
+				this.rejectForm.procInstIds = this.rejectDataBox.toString();
+			}
+      this.$reqPost('backAll', this.rejectForm).then(res => {
         if (res.code == 0) {
           this.$u.toast('鎿嶄綔鎴愬姛锛�');
         } else {
           this.$u.toast('鎿嶄綔澶辫触锛侊紒锛�');
         }
+				// 鍒濆鍖�
+				this.rejectForm.procInstIds = '';
+				this.rejectForm.comment = '';
+				this.checkBoxValue = []
         this.init();
       });
     },
     rejectModalCancel() {
       this.rejectModalShow = false;
     },
-    rejectClick(v) {
-      this.modalType = 1;
-      this.rejectModalShow = true;
-      this.rejectForm.procInstIds = v.procInstId;
-    },
+    
     batchRejectClick() {
       if (this.checkBoxValue.length != 0) {
         this.rejectModalShow = true;

--
Gitblit v1.9.1