fix(partner): hide map pick coords from UI

Keep lat/lng in form state for submit; remove pending coords panel and toasts.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-07-29 13:04:41 +08:00
parent f396cb1fef
commit 507a21a318
3 changed files with 25 additions and 58 deletions
@@ -13,8 +13,6 @@ import { resolveRegionBinding } from '../lib/china-region';
import { checkStorePhoneAvailable } from '../lib/storePhone';
import { formatStoreCoords } from '../lib/storeLocate';
import { fetchPartnerCities, type OpenCityOption } from '../lib/upload';
import { usePartnerSession } from '../contexts/PartnerSessionContext';
@@ -669,11 +667,12 @@ export default function StoreCreatePage() {
</button>
<span className="label-md text-muted">
{formatStoreCoords(form.latitude, form.longitude)
? `坐标:${formatStoreCoords(form.latitude, form.longitude)}`
: '未选点(可地图选点)'}
{form.latitude.trim() && form.longitude.trim() ? '已选点' : '未选点'}
</span>
</div>
{/* 经纬度仅内存/提交用,界面不展示 */}
<input type="hidden" name="latitude" value={form.latitude} readOnly />
<input type="hidden" name="longitude" value={form.longitude} readOnly />
</div>
@@ -1137,9 +1136,7 @@ export default function StoreCreatePage() {
longitude: String(loc.longitude),
...(loc.address && !form.address.trim() ? { address: loc.address } : {}),
});
toastSuccess(
`已选点 ${loc.latitude.toFixed(6)}, ${loc.longitude.toFixed(6)}${loc.name ? `${loc.name}` : ''}`,
);
toastSuccess(loc.name ? `已选定:${loc.name}` : '位置已选定');
}}
/>