添加审核状态
This commit is contained in:
@@ -1,8 +1,11 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="car-card-pro">
|
<view class="car-card-pro">
|
||||||
<view class="heard">
|
<view class="heard">
|
||||||
<view class="" @click="handleCardTap">
|
<view class="heard-left" @click="handleCardTap">
|
||||||
编号:{{item.code?item.code:'~'}}
|
<text class="code-text">编号:{{item.code?item.code:'~'}}</text>
|
||||||
|
<view class="status-tag" :class="'status-' + item.status">
|
||||||
|
<text class="status-text">{{ getStatusText(item.status) }}</text>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="ismy">
|
<view v-if="ismy">
|
||||||
<u-icon @click="editfn(item)" name="edit-pen-fill" size="25" />
|
<u-icon @click="editfn(item)" name="edit-pen-fill" size="25" />
|
||||||
@@ -79,6 +82,17 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
// 获取状态文本
|
||||||
|
getStatusText() {
|
||||||
|
return (status) => {
|
||||||
|
const statusMap = {
|
||||||
|
0: '待审核',
|
||||||
|
1: '审核通过',
|
||||||
|
2: '审核拒绝'
|
||||||
|
}
|
||||||
|
return statusMap[status] || '未知'
|
||||||
|
}
|
||||||
|
},
|
||||||
// 计算视频数量
|
// 计算视频数量
|
||||||
videoCount() {
|
videoCount() {
|
||||||
if (!this.item.intro_video) return 0
|
if (!this.item.intro_video) return 0
|
||||||
@@ -295,6 +309,57 @@
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.heard-left {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 10rpx;
|
||||||
|
flex: 1;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.code-text {
|
||||||
|
flex-shrink: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status-tag {
|
||||||
|
padding: 4rpx 12rpx;
|
||||||
|
border-radius: 8rpx;
|
||||||
|
font-size: 20rpx;
|
||||||
|
flex-shrink: 0;
|
||||||
|
|
||||||
|
&.status-0 {
|
||||||
|
background: #FFF7E6;
|
||||||
|
border: 1px solid #FFD591;
|
||||||
|
|
||||||
|
.status-text {
|
||||||
|
color: #FA8C16;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.status-1 {
|
||||||
|
background: #F6FFED;
|
||||||
|
border: 1px solid #B7EB8F;
|
||||||
|
|
||||||
|
.status-text {
|
||||||
|
color: #52C41A;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
&.status-2 {
|
||||||
|
background: #FFF2F0;
|
||||||
|
border: 1px solid #FFCCC7;
|
||||||
|
|
||||||
|
.status-text {
|
||||||
|
color: #F5222D;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.status-text {
|
||||||
|
font-size: 20rpx;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
.car-card-pro {
|
.car-card-pro {
|
||||||
padding-bottom: 6rpx;
|
padding-bottom: 6rpx;
|
||||||
border-radius: 18rpx;
|
border-radius: 18rpx;
|
||||||
|
|||||||
@@ -84,7 +84,7 @@
|
|||||||
// 跳转到我的发布列表
|
// 跳转到我的发布列表
|
||||||
goToMyPublish() {
|
goToMyPublish() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/index/myPublishpro'
|
url: '/pages/index/myPublish'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
goToMyPublishpro() {
|
goToMyPublishpro() {
|
||||||
|
|||||||
@@ -72,10 +72,12 @@
|
|||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
list: [],
|
list: [],
|
||||||
columns: [
|
columns: [
|
||||||
{ label: '全部', id: '' },
|
[
|
||||||
{ label: '正常', id: 1 },
|
{ label: '全部', value: '' },
|
||||||
{ label: '已售出', id: 2 },
|
{ label: '待审核', value: 0 },
|
||||||
{ label: '已归档', id: 3 }
|
{ label: '审核通过', value: 1 },
|
||||||
|
{ label: '审核拒绝', value: 2 }
|
||||||
|
]
|
||||||
],
|
],
|
||||||
options1: [
|
options1: [
|
||||||
{
|
{
|
||||||
@@ -155,7 +157,7 @@
|
|||||||
// 状态筛选
|
// 状态筛选
|
||||||
onstatus(e) {
|
onstatus(e) {
|
||||||
const item = e.value[0]
|
const item = e.value[0]
|
||||||
this.status_id = item.id
|
this.status_id = item.value
|
||||||
this.status_name = item.label
|
this.status_name = item.label
|
||||||
this.show = false
|
this.show = false
|
||||||
this.onSearch()
|
this.onSearch()
|
||||||
|
|||||||
Reference in New Issue
Block a user