From d18a0c9fe708dcf58253b54ef2938b5e864b24df Mon Sep 17 00:00:00 2001
From: zuoxiao <zuoxiao>
Date: 星期一, 28 四月 2025 14:39:30 +0800
Subject: [PATCH] 优化水摄入页面的确认弹窗逻辑,调整showConfirm状态的设置位置,并移除不必要的代码注释,提升代码可读性和维护性。
---
pages/createIrrigation/createIrrigation.js | 23 +++++++++++++++++++----
1 files changed, 19 insertions(+), 4 deletions(-)
diff --git a/pages/createIrrigation/createIrrigation.js b/pages/createIrrigation/createIrrigation.js
index 6915e8f..14c2a4c 100644
--- a/pages/createIrrigation/createIrrigation.js
+++ b/pages/createIrrigation/createIrrigation.js
@@ -303,10 +303,25 @@
* 璺宠浆鍒拌疆鐏岀粍璇︽儏椤�
*/
navigateToGroupDetail: function (e) {
- const {
- groupIndex
- } = e.currentTarget.dataset;
- // TODO: 瀹炵幇璺宠浆閫昏緫
+ const { groupIndex } = e.currentTarget.dataset;
+ const group = this.data.selectedProject.groups[groupIndex];
+
+ // 鏋勫缓URL鍙傛暟
+ const params = {
+ projectName: this.data.selectedProject.name,
+ groupName: group.name,
+ groupId: group.id
+ };
+
+ // 鏋勫缓URL鏌ヨ瀛楃涓�
+ const queryString = Object.keys(params)
+ .map(key => `${key}=${encodeURIComponent(params[key])}`)
+ .join('&');
+
+ // 璺宠浆鍒拌疆鐏岀粍璇︽儏椤�
+ wx.navigateTo({
+ url: `/pages/groupDetail/groupDetail?${queryString}`
+ });
},
/**
--
Gitblit v1.8.0