Files
medical-mall/pages/mall/admin/product/reviews/index.uvue
2026-02-06 12:06:33 +08:00

268 lines
8.8 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<view class="product-reply-page">
<!-- 1. 鎼滅储绛涢€?-->
<view class="search-card">
<view class="search-row">
<view class="search-item">
<text class="label">璇勪环鏃堕棿锛?/text>
<view class="mock-date-range">
<text class="emoji">馃搮</text>
<text class="txt">寮€濮嬫棩鏈?- 缁撴潫鏃ユ湡</text>
</view>
</view>
<view class="search-item">
<text class="label">璇勪环鐘舵€侊細</text>
<view class="mock-select"><text>璇烽€夋嫨</text><text class="arrow">鈻?/text></view>
</view>
<view class="search-item">
<text class="label">瀹℃牳鐘舵€侊細</text>
<view class="mock-select"><text>璇烽€夋嫨</text><text class="arrow">鈻?/text></view>
</view>
</view>
<view class="search-row mt-16">
<view class="search-item">
<text class="label">鍟嗗搧淇℃伅锛?/text>
<input class="mock-input" placeholder="璇疯緭鍏ュ晢鍝佷俊鎭? />
</view>
<view class="search-item">
<text class="label">鐢ㄦ埛鍚嶇О锛?/text>
<input class="mock-input" placeholder="璇疯緭鍏? />
</view>
<button class="btn-primary">鏌ヨ</button>
</view>
</view>
<!-- 2. 鎿嶄綔琛?-->
<view class="action-bar">
<button class="btn-primary">娣诲姞鑷瘎</button>
<button class="btn-white">鎵归噺瀹℃牳</button>
</view>
<!-- 3. 鏁版嵁琛ㄦ牸 -->
<view class="list-card">
<view class="table-v5">
<view class="th-row">
<view class="th col-check"><text>鈻?/text></view>
<view class="th col-id"><text>璇勮ID</text></view>
<view class="th col-product"><text>鍟嗗搧淇℃伅</text></view>
<view class="th col-spec"><text>瑙勬牸</text></view>
<view class="th col-user"><text>鐢ㄦ埛鍚嶇О</text></view>
<view class="th col-score"><text>璇勫垎</text></view>
<view class="th col-content"><text>璇勪环鍐呭</text></view>
<view class="th col-reply"><text>鍥炲鍐呭</text></view>
<view class="th col-status"><text>瀹℃牳鐘舵€?/text></view>
<view class="th col-time"><text>璇勪环鏃堕棿</text></view>
<view class="th col-op"><text>鎿嶄綔</text></view>
</view>
<view v-for="item in replyList" :key="item.id" class="tr-row">
<view class="td col-check"><text>鈻?/text></view>
<view class="td col-id"><text>{{ item.id }}</text></view>
<view class="td col-product">
<image class="p-img" :src="item.image" mode="aspectFill" />
<text class="p-name-txt">{{ item.productName }}</text>
</view>
<view class="td col-spec"><text>{{ item.spec }}</text></view>
<view class="td col-user"><text>{{ item.username }}</text></view>
<view class="td col-score"><text>{{ item.score }}</text></view>
<view class="td col-content"><text class="blue-link">{{ item.content }}</text></view>
<view class="td col-reply"><text>{{ item.reply || '鏃? }}</text></view>
<view class="td col-status">
<text class="status-tag" :class="item.status === 1 ? 'pass' : 'wait'">
{{ item.status === 1 ? '閫氳繃' : '寰呭鏍? }}
</text>
</view>
<view class="td col-time"><text>{{ item.time }}</text></view>
<view class="td col-op">
<text class="op-link">閫氳繃</text>
<text class="op-link">椹冲洖</text>
<text class="op-link">鍥炲</text>
<text class="op-link red">鍒犻櫎</text>
</view>
</view>
</view>
<!-- 鍒嗛〉 -->
<view class="pagination-row">
<text class="total">鍏?{{ replyList.length }} 鏉?/text>
<view class="page-ctrl">
<text class="page-btn disabled">{"<"}</text>
<text class="page-num active">1</text>
<text class="page-btn">{">"}</text>
</view>
</view>
</view>
</view>
</template>
<script setup lang="uts">
import { ref } from 'vue'
const replyList = ref([
{
id: 1069,
image: 'https://img1.baidu.com/it/u=254065646,3100346083&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500',
productName: 'UR2024澶忓鏂版濂宠澶嶅彜绾姘涘洿鎰熶竴瀛楄偐鐭T鎭よUWG440060',
spec: 'XL,鍗″叾',
username: 'demo998',
score: 3.5,
content: '22',
reply: '',
status: 0,
time: '2025-02-19 14:56:43'
},
{
id: 1059,
image: 'https://img1.baidu.com/it/u=254065646,3100346083&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500',
productName: 'UR2024澶忓鏂版濂宠澶嶅彜绾姘涘洿鎰熶竴瀛楄偐鐭T鎭よUWG440060',
spec: 'XL,鍗″叾',
username: '浣犲ソ鍛€',
score: 3.5,
content: '鐨?,
reply: '',
status: 0,
time: '2025-01-07 15:35:36'
},
{
id: 980,
image: 'https://img1.baidu.com/it/u=254065646,3100346083&fm=253&fmt=auto&app=138&f=JPEG?w=500&h=500',
productName: 'UR2024澶忓鏂版濂宠澶嶅彜绾姘涘洿鎰熶竴瀛楄偐鐭T鎭よUWG440060',
spec: 'XL,鍗″叾',
username: 'wx209638',
score: 5,
content: '濂?,
reply: '',
status: 1,
time: '2024-09-12 14:20:12'
}
])
</script>
<style scoped lang="scss">
.product-reply-page {
/* padding removed */
}
.search-card {
background: #fff;
padding: 24px;
border-radius: 4px;
margin-bottom: 16px;
}
.search-row {
display: flex;
flex-direction: row;
align-items: center;
gap: 24px;
}
.mt-16 { margin-top: 16px; }
.search-item {
display: flex;
flex-direction: row;
align-items: center;
.label { font-size: 14px; color: #606266; width: 80px; text-align: right; }
}
.mock-date-range {
width: 280px; height: 32px; border: 1px solid #dcdfe6; border-radius: 4px;
display: flex; flex-direction: row; align-items: center; padding: 0 12px; gap: 8px;
.emoji { font-size: 14px; }
.txt { font-size: 13px; color: #c0c4cc; }
}
.mock-select {
width: 160px; height: 32px; border: 1px solid #dcdfe6; border-radius: 4px;
display: flex; flex-direction: row; align-items: center; justify-content: space-between;
padding: 0 12px; font-size: 13px; color: #606266;
.arrow { font-size: 10px; color: #c0c4cc; }
}
.mock-input {
width: 200px; height: 32px; border: 1px solid #dcdfe6; border-radius: 4px; padding: 0 12px; font-size: 13px;
}
.btn-primary { background: #1890ff; color: #fff; height: 32px; padding: 0 16px; border-radius: 4px; font-size: 14px; border: none; }
.btn-white { background: #fff; color: #606266; height: 32px; padding: 0 16px; border-radius: 4px; font-size: 14px; border: 1px solid #dcdfe6; }
.action-bar {
margin-bottom: 16px;
display: flex;
flex-direction: row;
gap: 12px;
}
.list-card {
background: #fff;
border-radius: 4px;
}
.table-v5 { width: 100%; }
.th-row {
display: flex;
flex-direction: row;
background-color: #f8f9fa;
border-bottom: 1px solid #e8e8e8;
}
.th {
padding: 12px 8px; font-size: 13px; font-weight: 500; color: #333;
display: flex; align-items: center; justify-content: center;
}
.tr-row {
display: flex; flex-direction: row; border-bottom: 1px solid #f0f0f0;
&:hover { background-color: #fafafa; }
}
.td {
padding: 12px 8px; font-size: 13px; color: #606266;
display: flex; align-items: center; justify-content: center;
}
.col-check { width: 50px; }
.col-id { width: 80px; }
.col-product { flex: 1.5; justify-content: flex-start; gap: 12px; }
.col-spec { width: 100px; }
.col-user { width: 120px; }
.col-score { width: 80px; }
.col-content { flex: 1; }
.col-reply { flex: 1; }
.col-status { width: 100px; }
.col-time { width: 160px; }
.col-op { width: 180px; }
.p-img { width: 40px; height: 40px; border-radius: 4px; }
.p-name-txt { font-size: 13px; line-height: 1.4; color: #1890ff; }
.blue-link { color: #1890ff; }
.status-tag {
padding: 2px 8px; border-radius: 2px; font-size: 12px;
&.pass { background: rgba(82, 196, 26, 0.1); color: #52c41a; }
&.wait { background: rgba(250, 173, 20, 0.1); color: #faad14; }
}
.op-link { font-size: 13px; color: #1890ff; margin: 0 4px; cursor: pointer; &.red { color: #f5222d; } }
.pagination-row {
padding: 24px; display: flex; flex-direction: row; justify-content: flex-end; align-items: center; gap: 16px;
.total { font-size: 13px; color: #606266; }
}
.page-ctrl {
display: flex; flex-direction: row; gap: 8px;
.page-num, .page-btn {
width: 32px; height: 32px; border: 1px solid #dcdfe6; border-radius: 4px;
display: flex; align-items: center; justify-content: center; font-size: 13px;
&.active { background: #1890ff; color: #fff; }
&.disabled { background: #f5f5f5; color: #ccc; }
}
}
</style>