From 5cfd98e57bcd99c0c97888236e6f683efe4741cc Mon Sep 17 00:00:00 2001
From: 罗广辉 <guanghui.luo@foxmail.com>
Date: Thu, 06 Nov 2025 17:36:53 +0800
Subject: [PATCH] feat: 跳登录的时候关闭其他页面

---
 src/subPackages/userDetail/password/index.vue |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/subPackages/userDetail/password/index.vue b/src/subPackages/userDetail/password/index.vue
index 2f9543e..ea627e3 100644
--- a/src/subPackages/userDetail/password/index.vue
+++ b/src/subPackages/userDetail/password/index.vue
@@ -13,7 +13,7 @@
 					<div class="rowTitle">新密码</div>
 					<u-input input-align="right" v-model="passwordForm.newPassword" placeholder="请输入"
 						class="input-item" />
-				
+
 				</div>
 				<div class="orderRow">
 					<div class="rowTitle">确认密码</div>
@@ -53,7 +53,7 @@
 	const validatePasswordNoChinese = (password) => {
 	  const chineseRegex = /[\u4e00-\u9fa5]/;
 	  if (chineseRegex.test(password)) {
-	  
+
 		uni.showToast({
 			title: '密码不能包含中文字符',
 			icon: 'none',
@@ -66,7 +66,7 @@
 	// 校验密码复杂度(长度≥6位,包含字母和数字)
 	const validatePasswordStrength = (password) => {
 	  if (password.length < 6) {
-	 
+
 		uni.showToast({
 			title: '密码长度不能少于6位',
 			icon: 'none',
@@ -95,7 +95,7 @@
 	const submit = () => {
 // 原始密码校验
     if (!passwordForm.value.oldPassword) {
-   
+
 	  uni.showToast({
 	  	title: '请输入原始密码',
 	  	icon: 'none',
@@ -107,7 +107,7 @@
     if (!validatePasswordNoChinese(passwordForm.value.newPassword)) return;
     // 新密码校验
     if (!passwordForm.value.newPassword) {
- 
+
 	  uni.showToast({
 	  	title: '请输入新密码',
 	  	icon: 'none',
@@ -125,7 +125,7 @@
 	  });
       return;
     }
-   
+
     // 复杂度校验
     if (!validatePasswordStrength(passwordForm.value.newPassword)) return;
 		updatePassword(md5(passwordForm.value.oldPassword),
@@ -139,7 +139,7 @@
 				});
 				clearForm();
 				userStore.setUserInfo(null)
-				uni.redirectTo({
+				uni.reLaunch({
 					url: '/pages/login/index'
 				})
 
@@ -186,7 +186,7 @@
 		height: 96rpx;
 		border-bottom: 2rpx solid #f5f5f5;
 		color: #7b7b7b;
-		
+
 
 			.rowTitle {
 				font-family: Source Han Sans CN, Source Han Sans CN;
@@ -219,9 +219,9 @@
 	.u-button:first-child{
 		margin-right: 30rpx;
 	}
-	
+
 	.custom-style {
 		width: 276rpx;
 		height: 76rpx;
 	}
-</style>
\ No newline at end of file
+</style>

--
Gitblit v1.9.3