diff --git a/frontend/index.html b/frontend/index.html
index 4ba3980..e17b7ae 100644
--- a/frontend/index.html
+++ b/frontend/index.html
@@ -4,7 +4,7 @@
-
甲辰收藏 v1.2.15
+ 甲辰收藏 v1.2.16
diff --git a/frontend/src/pages/Info.jsx b/frontend/src/pages/Info.jsx
index 2cde493..a93782d 100644
--- a/frontend/src/pages/Info.jsx
+++ b/frontend/src/pages/Info.jsx
@@ -10,7 +10,7 @@ export default function Info() {
const [formData, setFormData] = useState({
edition: '龙钞', type: '标百', isGraded: true, category: '成交', source: '直播', title: ''
})
- const [content, setContent] = useState('')
+ // content使用原生DOM
useEffect(() => {
if (activeTab === 'manage') fetchMyList()
@@ -43,14 +43,14 @@ export default function Info() {
const token = localStorage.getItem('token')
const res = await fetch(`${API_BASE}/api/information/`, {
method: 'POST', headers: { 'Authorization': `Bearer ${token}`, 'Content-Type': 'application/json' },
- body: JSON.stringify({ title: formData.title, content: content, info_type: formData.category === '成交' ? 'deal' : 'seek' })
+ body: JSON.stringify({ title: formData.title, content: document.getElementById('publishContent')?.value || '', info_type: formData.category === '成交' ? 'deal' : 'seek' })
})
const data = await res.json()
if (data.id || data.code === 0) {
alert('发布成功!')
setShowPublish(false)
setFormData({ edition: '龙钞', type: '标百', isGraded: true, category: '成交', source: '直播', title: '' })
- setContent('')
+ const el = document.getElementById('publishContent'); if(el) el.value = ''
fetchMyList()
} else { alert(data.message || '发布失败') }
} catch (e) { alert('发布失败: ' + e.message) }
@@ -184,7 +184,7 @@ export default function Info() {