You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
SCASS_project/profile/profile.js

25 lines
554 B

Page({
data: {
avatarUrl: '/image/化工专家.png', // 默认头像
},
viewLogs: function() {
wx.navigateTo({
url: '/pages/userview/usereview',
});
},
logout: function() {
wx.showModal({
title: '退出登录',
content: '你确定要退出登录吗?',
success: (res) => {
if (res.confirm) {
wx.clearStorage(); // 清除本地存储的用户数据
wx.redirectTo({
url: '/pages/login/login' // 跳转到登录页面
});
}
}
});
}
});