diff --git a/common/util.js b/common/util.js
index b5c59e3..df1039b 100644
--- a/common/util.js
+++ b/common/util.js
@@ -169,8 +169,8 @@ function openHomeView() {
})
}
-//退出登陆
-function logout() {
+//退出登陆-清空缓存数据
+function loginOut() {
//清除token
uni.removeStorageSync('token')
//清除用户信息
@@ -185,7 +185,7 @@ function logout() {
module.exports = {
- logout,
+ loginOut,
openHomeView,
formatTime,
formatDateTime,
diff --git a/pages/student/my/set_up.vue b/pages/student/my/set_up.vue
index b98a620..f247c33 100644
--- a/pages/student/my/set_up.vue
+++ b/pages/student/my/set_up.vue
@@ -7,7 +7,7 @@
清空缓存
- 退出账号
+ 退出账号
@@ -20,6 +20,11 @@
}
},
methods: {
+ //退出登陆
+ loginOut(){
+ this.$util.loginOut()
+ },
+
privacy_agreement(type){
uni.navigateTo({
url: '/pages/common/privacy_agreement?type='+type
diff --git a/pages/student/my/update_pass.vue b/pages/student/my/update_pass.vue
index 05bd181..411e6a9 100644
--- a/pages/student/my/update_pass.vue
+++ b/pages/student/my/update_pass.vue
@@ -75,7 +75,7 @@
old_password: this.old_password,
}).then(res => {
if (res.code == 1) {
- this.$util.logout();
+ this.$util.loginOut();
} else {
uni.showToast({
title: res.msg,