This commit is contained in:
@@ -4,6 +4,7 @@ const planningApi = require('../../api/planning')
|
||||
const { buildProfileCard } = require('../../utils/profile-card')
|
||||
const profileCache = require('../../utils/profile-cache')
|
||||
const authApi = require('../../api/auth')
|
||||
const { showErrorToast } = require('../../utils/toast')
|
||||
|
||||
function resolveRoleText(type) {
|
||||
const role = Number(type)
|
||||
@@ -62,7 +63,7 @@ Page({
|
||||
}
|
||||
})
|
||||
} catch (error) {
|
||||
wx.showToast({ title: error.message || '今日概览加载失败', icon: 'none' })
|
||||
showErrorToast(error, '今日概览加载失败')
|
||||
} finally {
|
||||
this.setData({ overviewLoading: false })
|
||||
}
|
||||
@@ -113,7 +114,7 @@ Page({
|
||||
const profile = await profileCache.getProfile()
|
||||
this.syncProfileToSession(profile)
|
||||
} catch (error) {
|
||||
wx.showToast({ title: error.message || '个人信息加载失败', icon: 'none' })
|
||||
showErrorToast(error, '个人信息加载失败')
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user