评论需要添加功能,提交订单有问题

This commit is contained in:
bobobobo
2025-12-26 02:15:32 +08:00
parent 1aab94bbc3
commit bb02cb22c0
32 changed files with 2844 additions and 117 deletions

View File

@@ -48,12 +48,26 @@ const showToast = (message, type = 'none', duration = 2000) => {
})
}
// 导出响应式状态和方法
/** 对话框带确认取消按钮 */
const showDialog = (title, content) => {
return new Promise(resolve => {
uni.showModal({
title,
content,
confirmText: '确定',
cancelText: '取消',
success: res => resolve(res.confirm)
})
})
}
/** 导出响应式状态和方法 */
export const useUI = () => {
return {
isLoading: isLoading, // 可用于模板中 v-if="isLoading"
showLoading,
hideLoading,
showToast
showToast,
showDialog
}
}