MA 跨域解析网关 · 同一码三屏统一解析}>
+
+ setMaCode(e.target.value)} onPressEnter={doResolve} />
+
+
+
+ {res && (
+
+
+
+ {res.resolved ? 解析成功 : 未解析/未登记}
+
+
+ {res.in_circulation ? 流通中 : {res.status || '不可用'}}
+
+ {res.title || '-'}
+ {res.issuer || '-'}
+
+
+ {p?.valid ? (
+
+ 国家码 {p.country_code}
+ 行业 {p.industry_node}
+ 机构 {p.org_node}
+ 类目 {p.category}
+ {p.year} 年
+ 序列 {p.sequence}
+ {p.episode > 0 && 第 {p.episode} 集}
+
+ ) : 结构非法}
+
+ {res.message}
+
+
+ )}
+
+ )
+}
+
+// ============ 扫码验真(B.2)============
+function ScanVerifyPanel() {
+ const [maCode, setMaCode] = useState('')
+ const [res, setRes] = useState(null)
+ const [loading, setLoading] = useState(false)
+
+ async function doScan() {
+ if (!maCode) return message.warning('请输入/扫描 MA 码')
+ setLoading(true)
+ const r = await api.scanVerify(maCode.trim())
+ setLoading(false)
+ if (r.ok) setRes(r.data.data)
+ else { setRes(null); message.error(r.data.message || '验真失败') }
+ }
+
+ let status = 'info', title = '请扫码验真'
+ if (res) {
+ if (res.authentic && res.compliant) { status = 'success'; title = '正版内容 · 合规流通' }
+ else if (res.authentic && !res.compliant) { status = 'warning'; title = '真码 · 但不合规(已下架/未流通)' }
+ else { status = 'error'; title = '验真失败 · 疑似盗版/伪造' }
+ }
+
+ return (
+