小程序浮层动作项按钮化并统一按钮样式
自动发布开发环境 Nacos 配置 / publish (push) Successful in 27s

This commit is contained in:
2026-11-07 00:38:22 +08:00
parent a5f050286b
commit 1482bda1fa
31 changed files with 322 additions and 78 deletions
+11 -17
View File
@@ -7,6 +7,7 @@ const { normalizeAvatar } = require('../../utils/profile-card')
const profileCache = require('../../utils/profile-cache')
const employeesApi = require('../../api/employees')
const { showErrorToast, toUserMessage } = require('../../utils/toast')
const { showActionModal } = require('../../utils/action-modal')
function canCreateAppointment() {
const app = getApp()
@@ -287,15 +288,11 @@ Page({
}
if (!summary.noticeEnabled || Number(summary.pendingCount || 0) <= 0) return false
app.globalData.reviewNoticeShown = true
const result = await new Promise(resolve => {
wx.showModal({
title: '有美甲师申请待审核',
content: `当前有 ${summary.pendingCount} 条美甲师加入申请,请在小程序员工页面审核。是否立即处理?`,
cancelText: '稍后处理',
confirmText: '立即审核',
success: resolve,
fail: () => resolve({ confirm: false })
})
const result = await showActionModal(this, {
title: '有美甲师申请待审核',
content: `当前有 ${summary.pendingCount} 条美甲师加入申请,请在小程序员工页面审核。是否立即处理?`,
cancelText: '稍后处理',
confirmText: '立即审核'
})
if (!result.confirm) return false
app.globalData.openEmployeeReview = true
@@ -934,21 +931,18 @@ Page({
wx.navigateTo({ url: `/pages/artist-transfer/index?id=${event.currentTarget.dataset.id}` })
},
quickCancel(event) {
async quickCancel(event) {
const appointment = (this._calendarData && this._calendarData.appointments || []).find(item => String(item.orderItemId) === String(event.currentTarget.dataset.id))
if (!appointment) return
wx.showModal({
const result = await showActionModal(this, {
title: '取消预约',
editable: true,
placeholderText: '可填写取消原因',
content: '',
cancelText: '取消',
confirmText: '确认取消',
success: result => {
if (result.confirm) {
this.updateAppointmentStatus(appointment.orderId, 3, result.content || '')
}
}
confirmType: 'danger'
})
if (result.confirm) this.updateAppointmentStatus(appointment.orderId, 3, result.content || '')
},
async updateAppointmentStatus(orderId, status, cancelReason) {