fix(index.vue): 修改toast提示方法,统一使用toast.show

This commit is contained in:
feige996 2025-06-06 21:59:06 +08:00
parent 6362129e34
commit 4e7dd994b4

View File

@ -162,7 +162,7 @@ const handlePassword = () => {
//
const handleInform = () => {
// uni.navigateTo({ url: `/pages/mine/inform/index` })
toast.success('功能开发中')
toast.show('功能开发中')
}
//
const handleAppUpdate = () => {
@ -173,9 +173,9 @@ const handleAppUpdate = () => {
//
// console.log(res.hasUpdate)
if (res.hasUpdate) {
toast.success('检测到新版本,正在下载中...')
toast.show('检测到新版本,正在下载中...')
} else {
toast.success('已是最新版本')
toast.show('已是最新版本')
}
})
updateManager.onUpdateReady(function (res) {
@ -198,7 +198,7 @@ const handleAppUpdate = () => {
// #endif
// #ifndef MP
toast.success('功能开发中')
toast.show('功能开发中')
// #endif
}
//
@ -217,7 +217,7 @@ const handleClearCache = () => {
uni.clearStorageSync()
//
useUserStore().logout()
toast.success('清除缓存成功')
toast.show('清除缓存成功')
} catch (err) {
console.error('清除缓存失败:', err)
toast.error('清除缓存失败')
@ -237,7 +237,7 @@ const handleLogout = () => {
useUserStore().logout()
hasLogin.value = false
// 退
toast.success('退出登录成功')
toast.show('退出登录成功')
// #ifdef MP-WEIXIN
//
// uni.reLaunch({ url: '/pages/index/index' })