Merge branch 'dev' into test
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -1,19 +1,80 @@
|
|||||||
<!-- eslint-disable vue/no-v-html -->
|
<!-- eslint-disable vue/no-v-html -->
|
||||||
<template>
|
<template>
|
||||||
<CommonPage show-footer :title="$route.title">
|
<CommonPage show-footer :title="$route.title">
|
||||||
|
<!-- {{ queryParams }} -->
|
||||||
<n-grid class="mb-10" x-gap="12">
|
<n-grid class="mb-10" x-gap="12">
|
||||||
<n-gi span="12" mt-10 flex items-center>
|
<n-gi span="12" mt-10 flex items-center>
|
||||||
<span w-100>筛选条件:</span>
|
<span w-100>筛选条件:</span>
|
||||||
<n-input-group>
|
<n-input-group>
|
||||||
<n-select
|
<n-select
|
||||||
v-model:value="queryParams.selectKey"
|
v-model:value="queryParams.selectKey"
|
||||||
:style="{ width: '20%' }"
|
:style="{ width: '25%' }"
|
||||||
:options="selectOptions"
|
:options="selectOptions"
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
/>
|
/>
|
||||||
<n-input v-model:value="queryParams.word" :style="{ width: '30%' }" />
|
<n-input v-model:value="queryParams.word" :style="{ width: '50%' }" />
|
||||||
</n-input-group>
|
</n-input-group>
|
||||||
</n-gi>
|
</n-gi>
|
||||||
|
<n-gi :span="24" mt-10>
|
||||||
|
<div>
|
||||||
|
<span>审核状态:</span>
|
||||||
|
<n-radio-group v-model:value="queryParams.status">
|
||||||
|
<n-radio-button
|
||||||
|
v-for="song in [
|
||||||
|
{
|
||||||
|
label: '待审',
|
||||||
|
value: 0,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '已审核',
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '拒绝',
|
||||||
|
value: 2,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '待审核',
|
||||||
|
value: 3,
|
||||||
|
},
|
||||||
|
]"
|
||||||
|
:key="song.value"
|
||||||
|
:value="song.value"
|
||||||
|
:label="song.label"
|
||||||
|
/>
|
||||||
|
</n-radio-group>
|
||||||
|
</div>
|
||||||
|
</n-gi>
|
||||||
|
<n-gi :span="24" mt-10>
|
||||||
|
<div>
|
||||||
|
<span>商品类型:</span>
|
||||||
|
<n-radio-group v-model:value="queryParams.type">
|
||||||
|
<n-radio-button
|
||||||
|
v-for="song in [
|
||||||
|
{
|
||||||
|
label: '普通商品',
|
||||||
|
value: 0,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '活动商品',
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '积分商品',
|
||||||
|
value: 2,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
label: '摇球商品',
|
||||||
|
value: 3,
|
||||||
|
},
|
||||||
|
]"
|
||||||
|
:key="song.value"
|
||||||
|
:value="song.value"
|
||||||
|
:label="song.label"
|
||||||
|
/>
|
||||||
|
</n-radio-group>
|
||||||
|
</div>
|
||||||
|
</n-gi>
|
||||||
<n-gi span="24" mt-10 flex items-center>
|
<n-gi span="24" mt-10 flex items-center>
|
||||||
<n-button type="primary" @click="getList">查询</n-button>
|
<n-button type="primary" @click="getList">查询</n-button>
|
||||||
<n-button ml-10 @click="clear">重置</n-button>
|
<n-button ml-10 @click="clear">重置</n-button>
|
||||||
@@ -212,11 +273,17 @@ const selectOptions = ref([
|
|||||||
label: '商品名称',
|
label: '商品名称',
|
||||||
value: 0,
|
value: 0,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
label: '商家bid',
|
||||||
|
value: 1,
|
||||||
|
},
|
||||||
])
|
])
|
||||||
|
|
||||||
const queryParams = ref({
|
const queryParams = ref({
|
||||||
selectKey: 0,
|
selectKey: 0,
|
||||||
word: '',
|
word: '',
|
||||||
|
type: '',
|
||||||
|
status: '',
|
||||||
checkedRowKeysRef: [],
|
checkedRowKeysRef: [],
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -508,10 +575,17 @@ onMounted(() => {
|
|||||||
const getList = async () => {
|
const getList = async () => {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
try {
|
try {
|
||||||
|
const query_data = {
|
||||||
|
status: queryParams.value.status,
|
||||||
|
type: queryParams.value.type,
|
||||||
|
}
|
||||||
|
|
||||||
|
query_data[queryParams.value.selectKey === 0 ? 'name' : 'bid'] = queryParams.value.word
|
||||||
|
|
||||||
const res = await api.getHotlist({
|
const res = await api.getHotlist({
|
||||||
pageNum: pagination.value.page,
|
pageNum: pagination.value.page,
|
||||||
pageSize: pagination.value.pageSize,
|
pageSize: pagination.value.pageSize,
|
||||||
name: queryParams.value.word,
|
...query_data,
|
||||||
})
|
})
|
||||||
data.value = res.data.data.sort((a, b) => b.status - a.status) || []
|
data.value = res.data.data.sort((a, b) => b.status - a.status) || []
|
||||||
pagination.value.itemCount = res.data.total
|
pagination.value.itemCount = res.data.total
|
||||||
@@ -526,7 +600,13 @@ const clear = () => {
|
|||||||
isDzModel.value = false
|
isDzModel.value = false
|
||||||
notesVal.value = ''
|
notesVal.value = ''
|
||||||
nowRow.value = {}
|
nowRow.value = {}
|
||||||
queryParams.value.word = ''
|
queryParams.value = {
|
||||||
|
selectKey: 0,
|
||||||
|
word: '',
|
||||||
|
type: '',
|
||||||
|
status: '',
|
||||||
|
checkedRowKeysRef: [],
|
||||||
|
}
|
||||||
getList()
|
getList()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user