|
|
|
@ -101,12 +101,14 @@ |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<el-pagination style="margin-top:20px" v-model:current-page="pagination.pageNum" |
|
|
|
v-model:page-size="pagination.pageSize" layout="total, sizes, prev, pager, next, jumper" :total="stats.num" |
|
|
|
@size-change="handlePageSizeChange" @current-change="handleCurrentChange"></el-pagination> |
|
|
|
<div class="pagination"> |
|
|
|
<el-pagination background v-model:current-page="pagination.pageNum" v-model:page-size="pagination.pageSize" |
|
|
|
layout="total, sizes, prev, pager, next, jumper" :total="stats.num" @size-change="handlePageSizeChange" |
|
|
|
@current-change="handleCurrentChange"></el-pagination> |
|
|
|
</div> |
|
|
|
</el-card> |
|
|
|
|
|
|
|
<el-dialog v-model="rejectVisible" title="驳回理由" width="500px"> |
|
|
|
<!-- <el-dialog v-model="rejectDialogVisible" title="驳回理由" width="500px"> |
|
|
|
<el-form> |
|
|
|
<el-form-item label="驳回理由" required> |
|
|
|
<el-input v-model="reason" type="textarea" :rows="4" placeholder="请输入驳回理由" maxlength="200" show-word-limit /> |
|
|
|
@ -114,19 +116,17 @@ |
|
|
|
</el-form> |
|
|
|
<template #footer> |
|
|
|
<span class="dialog-footer"> |
|
|
|
<el-button @click="rejectVisible = false">取消</el-button> |
|
|
|
<el-button @click="rejectDialogVisible = false">取消</el-button> |
|
|
|
<el-button type="primary" @click="handleReject()">确定</el-button> |
|
|
|
</span> |
|
|
|
</template> |
|
|
|
</el-dialog> |
|
|
|
</el-dialog> --> |
|
|
|
|
|
|
|
<ConfirmDialog v-model="rejectDialogVisible" message="驳回该记录!" @confirm="handleReject" @cancel="handleRejectCancel" |
|
|
|
@close="handleRejectClose" /> |
|
|
|
|
|
|
|
<ConfirmDialog |
|
|
|
v-model="approveDialogVisible" |
|
|
|
message="通过该记录!" |
|
|
|
@confirm="handleApproveConfirm" |
|
|
|
@cancel="handleApproveCancel" |
|
|
|
@close="handleApproveClose" |
|
|
|
/> |
|
|
|
<ConfirmDialog v-model="approveDialogVisible" message="通过该记录!" @confirm="handleApproveConfirm" |
|
|
|
@cancel="handleApproveCancel" @close="handleApproveClose" /> |
|
|
|
|
|
|
|
|
|
|
|
</template> |
|
|
|
@ -156,7 +156,7 @@ const activeTimeRange = ref('') |
|
|
|
const sortField = ref('') |
|
|
|
const sortOrder = ref('') |
|
|
|
const checkTab = ref('pending') |
|
|
|
const rejectVisible = ref(false) |
|
|
|
const rejectDialogVisible = ref(false) |
|
|
|
const reason = ref('') |
|
|
|
const rejectRow = ref({ |
|
|
|
id: null |
|
|
|
@ -380,7 +380,7 @@ const handleReject = async () => { |
|
|
|
} |
|
|
|
await API({ url: '/beanAudit/status2', data: params }) |
|
|
|
ElMessage.success('驳回成功') |
|
|
|
rejectVisible.value = false |
|
|
|
rejectDialogVisible.value = false |
|
|
|
await get() |
|
|
|
cancelClicked.value = false |
|
|
|
await getStats() |
|
|
|
@ -389,6 +389,30 @@ const handleReject = async () => { |
|
|
|
ElMessage.error('操作失败') |
|
|
|
} |
|
|
|
} |
|
|
|
// 处理驳回取消操作 |
|
|
|
const handleRejectCancel = () => { |
|
|
|
rejectDialogVisible.value = false |
|
|
|
} |
|
|
|
// 处理驳回关闭操作 |
|
|
|
const handleRejectClose = () => { |
|
|
|
rejectDialogVisible.value = false |
|
|
|
} |
|
|
|
// 这个防抖好像还不能放在定义之前(handleApproveConfirm) |
|
|
|
const throttledHandleApprove = _.throttle(handleApproveConfirm, 5000, { |
|
|
|
trailing: false |
|
|
|
}) |
|
|
|
// 显示驳回对话框 |
|
|
|
const showRejectDialog = (row) => { |
|
|
|
if (!hasbeanWaitReject) { |
|
|
|
ElMessage.error('暂无权限') |
|
|
|
return |
|
|
|
} |
|
|
|
rejectRow.value.id = row.id |
|
|
|
reason.value = '' |
|
|
|
rejectDialogVisible.value = true |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
const getToday = async function () { |
|
|
|
const today = dayjs() |
|
|
|
const startTime = today.startOf('day').format('YYYY-MM-DD HH:mm:ss') |
|
|
|
@ -507,19 +531,7 @@ const format3 = (num) => { |
|
|
|
// 每三位添加逗号 |
|
|
|
return num.toLocaleString('en-US') |
|
|
|
} |
|
|
|
// 这个防抖好像还不能放在定义之前(handleApproveConfirm) |
|
|
|
const throttledHandleApprove = _.throttle(handleApproveConfirm, 5000, { |
|
|
|
trailing: false |
|
|
|
}) |
|
|
|
const showRejectDialog = (row) => { |
|
|
|
if (!hasbeanWaitReject) { |
|
|
|
ElMessage.error('暂无权限') |
|
|
|
return |
|
|
|
} |
|
|
|
rejectRow.value.id = row.id |
|
|
|
reason.value = '' |
|
|
|
rejectVisible.value = true |
|
|
|
} |
|
|
|
|
|
|
|
// 获取地区,修改为级联下拉框 |
|
|
|
const getmarkets = async function () { |
|
|
|
try { |
|
|
|
@ -570,6 +582,11 @@ onMounted(async () => { |
|
|
|
</script> |
|
|
|
|
|
|
|
<style scoped lang="scss"> |
|
|
|
.pagination { |
|
|
|
display: flex; |
|
|
|
margin-top: 1vh; |
|
|
|
} |
|
|
|
|
|
|
|
/* 搜索的卡片样式 */ |
|
|
|
.card1 { |
|
|
|
background: #F3FAFE; |
|
|
|
|