【功能新增】商城:售后分页查询,支持 userId 过滤
parent
3d56931268
commit
254d1e0322
|
@ -135,7 +135,7 @@
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="订单金额" prop="refundPrice">
|
<el-table-column align="center" label="订单金额" prop="refundPrice" min-width="120">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span>{{ fenToYuan(scope.row.refundPrice) }} 元</span>
|
<span>{{ fenToYuan(scope.row.refundPrice) }} 元</span>
|
||||||
</template>
|
</template>
|
||||||
|
@ -206,6 +206,7 @@ const queryParams = reactive({
|
||||||
way: null,
|
way: null,
|
||||||
type: null
|
type: null
|
||||||
})
|
})
|
||||||
|
|
||||||
/** 查询列表 */
|
/** 查询列表 */
|
||||||
const getList = async () => {
|
const getList = async () => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
|
@ -216,23 +217,26 @@ const getList = async () => {
|
||||||
delete data.status
|
delete data.status
|
||||||
}
|
}
|
||||||
// 执行查询
|
// 执行查询
|
||||||
const res = (await AfterSaleApi.getAfterSalePage(data)) as AfterSaleApi.TradeAfterSaleVO[]
|
const res = await AfterSaleApi.getAfterSalePage(data)
|
||||||
list.value = res.list
|
list.value = res.list as AfterSaleApi.TradeAfterSaleVO[]
|
||||||
total.value = res.total
|
total.value = res.total
|
||||||
} finally {
|
} finally {
|
||||||
loading.value = false
|
loading.value = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 搜索按钮操作 */
|
/** 搜索按钮操作 */
|
||||||
const handleQuery = async () => {
|
const handleQuery = async () => {
|
||||||
queryParams.pageNo = 1
|
queryParams.pageNo = 1
|
||||||
await getList()
|
await getList()
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 重置按钮操作 */
|
/** 重置按钮操作 */
|
||||||
const resetQuery = () => {
|
const resetQuery = () => {
|
||||||
queryFormRef.value?.resetFields()
|
queryFormRef.value?.resetFields()
|
||||||
handleQuery()
|
handleQuery()
|
||||||
}
|
}
|
||||||
|
|
||||||
/** tab 切换 */
|
/** tab 切换 */
|
||||||
const tabClick = async (tab: TabsPaneContext) => {
|
const tabClick = async (tab: TabsPaneContext) => {
|
||||||
queryParams.status = tab.paneName
|
queryParams.status = tab.paneName
|
||||||
|
|
|
@ -133,12 +133,11 @@
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="订单金额" prop="refundPrice">
|
<el-table-column align="center" label="订单金额" prop="refundPrice" min-width="120">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span>{{ fenToYuan(scope.row.refundPrice) }} 元</span>
|
<span>{{ fenToYuan(scope.row.refundPrice) }} 元</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column align="center" label="买家" prop="user.nickname" />
|
|
||||||
<el-table-column align="center" label="申请时间" prop="createTime" width="180">
|
<el-table-column align="center" label="申请时间" prop="createTime" width="180">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span>{{ formatDate(scope.row.createTime) }}</span>
|
<span>{{ formatDate(scope.row.createTime) }}</span>
|
||||||
|
@ -207,6 +206,7 @@ const queryParams = ref({
|
||||||
way: null,
|
way: null,
|
||||||
type: null
|
type: null
|
||||||
})
|
})
|
||||||
|
|
||||||
/** 查询列表 */
|
/** 查询列表 */
|
||||||
const getList = async () => {
|
const getList = async () => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
|
@ -218,24 +218,27 @@ const getList = async () => {
|
||||||
}
|
}
|
||||||
// 执行查询
|
// 执行查询
|
||||||
// TODO @芋艿:接口需要通过userId进行筛选返回值
|
// TODO @芋艿:接口需要通过userId进行筛选返回值
|
||||||
const res = (await AfterSaleApi.getAfterSalePage(data)) as AfterSaleApi.TradeAfterSaleVO[]
|
const res = await AfterSaleApi.getAfterSalePage(data)
|
||||||
list.value = res.list
|
list.value = res.list as AfterSaleApi.TradeAfterSaleVO[]
|
||||||
total.value = res.total
|
total.value = res.total
|
||||||
} finally {
|
} finally {
|
||||||
loading.value = false
|
loading.value = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 搜索按钮操作 */
|
/** 搜索按钮操作 */
|
||||||
const handleQuery = async () => {
|
const handleQuery = async () => {
|
||||||
queryParams.value.pageNo = 1
|
queryParams.value.pageNo = 1
|
||||||
await getList()
|
await getList()
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 重置按钮操作 */
|
/** 重置按钮操作 */
|
||||||
const resetQuery = () => {
|
const resetQuery = () => {
|
||||||
queryFormRef.value?.resetFields()
|
queryFormRef.value?.resetFields()
|
||||||
queryParams.value.userId = userId
|
queryParams.value.userId = userId
|
||||||
handleQuery()
|
handleQuery()
|
||||||
}
|
}
|
||||||
|
|
||||||
/** tab 切换 */
|
/** tab 切换 */
|
||||||
const tabClick = async (tab: TabsPaneContext) => {
|
const tabClick = async (tab: TabsPaneContext) => {
|
||||||
queryParams.value.status = tab.paneName
|
queryParams.value.status = tab.paneName
|
||||||
|
|
Loading…
Reference in New Issue