From 1e171523831b7d9a7d6732233fbb2c156b4d450c Mon Sep 17 00:00:00 2001 From: TimSpan Date: Fri, 15 Nov 2024 17:24:33 +0800 Subject: [PATCH] .. --- policeManagement/.env.development | 2 +- policeManagement/src/views/query/index.tsx | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/policeManagement/.env.development b/policeManagement/.env.development index 8ecf877..7252cf2 100644 --- a/policeManagement/.env.development +++ b/policeManagement/.env.development @@ -15,7 +15,7 @@ VITE_APP_RSA_PUBLIC_KEY=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDJps/EXxxSpEM1Ix4R # 高德 VITE_APP_GAODE_KEY=ca549d915cb38803582ca7e85c5f972c VITE_APP_GAODE_VERSION=2.0 -VITE_APP_SECURITY_JS_CODE=432125a0f8d8cad2dac38b77d6f6728f +VITE_APP_SECURITY_JS_CODE=f464462874676b3f1469780a62e5b921 # VITE_APP_GAODE_KEY=f379a3f860a68d7438526275d6a94b05 # VITE_APP_GAODE_VERSION=2.0 diff --git a/policeManagement/src/views/query/index.tsx b/policeManagement/src/views/query/index.tsx index 26fa0d4..1207abf 100644 --- a/policeManagement/src/views/query/index.tsx +++ b/policeManagement/src/views/query/index.tsx @@ -24,7 +24,7 @@ const saveOrUpdateEnterprisesUnit = (params: _FormType, callback: Function) => { const _mapRef = ref>(null) const _formParams = ref<_FormType>({ ...params }) - let city = '' + let city = '全国' const initMarker = (map: AMap.Map) => { //添加maker点 设置point const maker = new AMap.Marker({ @@ -62,11 +62,13 @@ const saveOrUpdateEnterprisesUnit = (params: _FormType, callback: Function) => { //@ts-ignore const auto = new AMap.AutoComplete({ city: city, - input: 'tipinput', + // input: 'tipinput', citylimit: true, }) auto.search(val, (status, result) => { + console.log('🚀 ~ auto.search ~ status, result:', status, result) if (status === 'complete') { + // 生成组件需要数据 autoAddress.value = result.tips?.map((e) => { return { value: e.name,