fix(wechat): 协议挂起请求仅在离开页面时结算并集中映射错误文案
自动发布开发环境 Nacos 配置 / publish (push) Successful in 18s

This commit is contained in:
2026-11-05 10:51:40 +08:00
parent 3f825682fb
commit 942718b8d9
20 changed files with 141 additions and 70 deletions
@@ -1,5 +1,6 @@
const employeesApi = require('../../api/employees')
const { chooseImageFilePath, uploadObjectFile } = require('../../utils/upload')
const { showErrorToast } = require('../../utils/toast')
const EMPLOYEE_COLORS = ['#7BA7C7', '#8FB89A', '#A894C7', '#D7A86E', '#D98DA5', '#79A6A3', '#B9A16B', '#9BA9C8']
@@ -66,7 +67,7 @@ Page({
'form.avatarUrl': filePath
})
} catch (error) {
wx.showToast({ title: error.message || '头像上传失败', icon: 'none' })
showErrorToast(error, '头像上传失败')
} finally {
this.setData({ avatarUploading: false })
}
@@ -122,7 +123,7 @@ Page({
}
await this.offerPendingAssociation()
} catch (error) {
wx.showToast({ title: error.message || '新增失败', icon: 'none' })
showErrorToast(error, '新增失败')
} finally {
this.setData({ creating: false })
}
@@ -207,7 +208,7 @@ Page({
this.setData({ associationSheetVisible: false, onboardingVisible: true })
wx.showToast({ title: '已预关联申请', icon: 'success' })
} catch (error) {
wx.showToast({ title: error.message || '关联失败,请重新选择', icon: 'none' })
showErrorToast(error, '关联失败,请重新选择')
this.setData({ associationSelectedId: '' })
} finally {
this.setData({ associationLoading: false })