From 73de6a1f851f98cda52b6a45ffc374bcbdecc28e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=94=B2=E8=BE=B0=E7=94=9F=E4=BA=A7?= Date: Sat, 11 Apr 2026 21:34:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=88=90=E4=BA=A4=E8=A1=8C?= =?UTF-8?q?=E6=83=85=E5=88=97=E8=A1=A8=E5=B1=95=E7=A4=BA=E6=A0=BC=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/pages/News.jsx | 36 ++++++++++++++++++++++++------------ 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/frontend/src/pages/News.jsx b/frontend/src/pages/News.jsx index f5bb3c8..6c7b2ac 100644 --- a/frontend/src/pages/News.jsx +++ b/frontend/src/pages/News.jsx @@ -647,22 +647,23 @@ export default function News() { {infoList.map(item => { // 成交行情 tab - 按维度汇总展示 if (activeTab === 'deal') { - // 从content中解析各个字段 const content = item.content || '' const categoryMatch = content.match(/分类:\s*(.+?)(?:\n|$)/) const packagingMatch = content.match(/包装:\s*(.+?)(?:\n|$)/) const platformMatch = content.match(/平台:\s*(.+?)(?:\n|$)/) const sellerMatch = content.match(/出售者:\s*(.+?)(?:\n|$)/) const dateMatch = content.match(/日期:\s*(.+?)(?:\n|$)/) + const gradeMatch = content.match(/评级:\s*(.+?)(?:\n|$)/) const category = categoryMatch ? categoryMatch[1].trim() : item.category || '-' const packaging = packagingMatch ? packagingMatch[1].trim() : item.packaging || '-' const platform = platformMatch ? platformMatch[1].trim() : '-' const seller = sellerMatch ? sellerMatch[1].trim() : '-' const dealDate = dateMatch ? dateMatch[1].trim() : item.deal_date || '-' + const grade = gradeMatch ? gradeMatch[1].trim() : '' + const gradingCompany = item.grading_company || '' - // 从冠字号判断版本(龙钞J0,马钞J1,蛇钞J3等) - const serial = item.title?.split('-')[0] || '' + const serial = (item.title || '').split('-')[0] || '' let version = '其他' if (serial.startsWith('J0')) version = '龙钞' else if (serial.startsWith('J1')) version = '马钞' @@ -670,20 +671,31 @@ export default function News() { return (
+ {/* 第一行:冠字号 | 版别 | 包装 | 分数 + 价格 */}
-
{(item.title || '').split('-')[0]}
+
+ {serial} + | + {version} + | + {packaging} + | + {grade} +
¥{item.deal_price?.toLocaleString()}
-
- {version} - {packaging} - {category} - {platform} + {/* 第二行:编码 | 分类 | 评级机构 | 平台 | 日期 */} +
+ {item.deal_no} + | + {category} + | + {gradingCompany && {gradingCompany}} + | + {platform} + | {dealDate}
- {seller && seller !== '-' && ( -
出售者: {seller}
- )}
) }