From ce9371b9a8f3b8bff52efedff9cace87bd6496d1 Mon Sep 17 00:00:00 2001 From: lihuilin Date: Sat, 5 Jul 2025 17:18:50 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=80=E6=AC=BE=E5=AE=A1=E6=A0=B8=E4=BA=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 4 ++-- src/views/audit/refundAudit.vue | 20 +++++++++++++++----- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/.env.development b/.env.development index 23ae9e8..e3a60cd 100644 --- a/.env.development +++ b/.env.development @@ -1,6 +1,6 @@ -VITE_API_BASE='https://hwjb.homilychart.com/admin/' +# VITE_API_BASE='https://hwjb.homilychart.com/admin/' # VITE_API_BASE='https://hwjb.homilychart.com/gold_htms_dev' -# VITE_API_BASE='http://192.168.8.242:8081/' +VITE_API_BASE='http://192.168.8.242:8081/' # VITE_API_BASE='http://18.143.76.3:10704/' # VITE_API_BASE='http://192.168.9.28:8081/' # VITE_API_BASE='http://192.168.8.94:8081/' diff --git a/src/views/audit/refundAudit.vue b/src/views/audit/refundAudit.vue index 7dd0538..4fefde0 100644 --- a/src/views/audit/refundAudit.vue +++ b/src/views/audit/refundAudit.vue @@ -229,7 +229,7 @@ const handleSortChange = (column) => { } else if (column.prop === 'permanentGold') { sortField.value = 'permanent_gold' } else if (column.prop === 'freeGold') { - sortField.value = 'free_gold' + sortField.value = 'freeGold' }else if (column.prop === 'taskGold') { sortField.value = 'task_gold' }else if (column.prop === 'createTime') { @@ -294,6 +294,7 @@ const get = async function (val) { console.log('看看传给后端的参数:', params) const res = await API({ url: '/audit/selectRefund', data: params }) tableData.value = res.list || [] + tableData.value.aduitName = pagination.value.total = res.total || 0 console.log('查全部的total', pagination.value.total, res.total) } catch (error) { @@ -305,11 +306,12 @@ const handleApprove = async (row) => { try { const params = { orderCode: row.orderCode, - auditId: row.auditId, + auditId: adminInfo.value.id, action: 1,// action的1是通过,2是驳回 rejectReason: '' } await API({ url: '/audit/audit', data: params })// 试一下能不能发 + console.log('=============',params) ElMessage.success('审核通过成功') get() getStats() @@ -319,7 +321,15 @@ const handleApprove = async (row) => { ElMessage.error('操作失败') } } - +const getAdminData = async function () { + try { + const result = await API({ url: '/admin/userinfo', data: {} }) + adminInfo.value = result + console.log('用户信息', adminInfo.value) + } catch (error) { + console.log('请求失败', error) + } +} // 处理驳回操作 const handleReject = async () => { if (!rejectReason.value.trim()) { @@ -329,7 +339,7 @@ const handleReject = async () => { try { const params = { orderCode: scopeValue.value.orderCode, - auditId: scopeValue.value.auditId, + auditId: adminInfo.value.id, action: 2, rejectReason: rejectReason.value } @@ -486,7 +496,7 @@ const adminReject = async function () { } onMounted(async () => { - //await getAdminInfo()// 用户信息要挂吗 + await getAdminData() getRefundGoods() getmarkets() await get()