diff --git a/VERSION b/VERSION index 85de19b..b54183a 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.2.100 +1.2.101 \ No newline at end of file diff --git a/backend/app/routers/information.py b/backend/app/routers/information.py index fc65d26..5a8c00f 100644 --- a/backend/app/routers/information.py +++ b/backend/app/routers/information.py @@ -76,6 +76,8 @@ class InformationResponse(BaseModel): collection_number: Optional[str] = None # 匹配数量(我的藏品中满足条件的数量) matched_count: Optional[int] = 0 + # 网络匹配数量(coolbot_data数据库中满足条件的数量) + network_matched_count: Optional[int] = 0 class Config: from_attributes = True @@ -115,6 +117,11 @@ def get_information_list( if item.info_type == 'seek' and item.expect_number and current_user: matched_count = match_collections_count(db, current_user.f99_90_id, item.expect_number) + # 计算网络匹配数量(coolbot_data数据库) + network_matched_count = 0 + if item.info_type == 'seek' and item.expect_number: + network_matched_count = match_collections_count_from_coolbot(item.expect_number) + result.append(InformationResponse( id=item.id, user_id=item.user_id, @@ -144,6 +151,7 @@ def get_information_list( collection_version=item.collection.f02_11_version if item.collection else None, collection_number=item.collection.f02_10_prefix_serial if item.collection else None, matched_count=matched_count, + network_matched_count=network_matched_count, )) return result diff --git a/frontend/src/config/version.js b/frontend/src/config/version.js index 4810618..49e32ca 100644 --- a/frontend/src/config/version.js +++ b/frontend/src/config/version.js @@ -1 +1 @@ -VERSION=1.2.100 +export const APP_VERSION = '1.2.101' diff --git a/frontend/src/pages/Add.jsx b/frontend/src/pages/Add.jsx index 09a9208..22406f2 100644 --- a/frontend/src/pages/Add.jsx +++ b/frontend/src/pages/Add.jsx @@ -75,6 +75,7 @@ export default function Add() { // 行情录入表单 const [dealForm, setDealForm] = useState({ serial: '', + serialDigits: ['','','','','','','','','',''], // 冠字号10位分别存储 category: '', packaging: '标十', price: '', @@ -730,9 +731,100 @@ export default function Add() {