Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
qianlong66
uni-app
提交
f9515ec7
U
uni-app
项目概览
qianlong66
/
uni-app
与 Fork 源项目一致
Fork自
DCloud / uni-app
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
f9515ec7
编写于
8月 02, 2022
作者:
DCloud-WZF
💬
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
refactor(map): 修改 h5 高德配置 key 与 app 一致
上级
245ade6d
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
19 addition
and
19 deletion
+19
-19
packages/uni-h5-vite/src/plugins/manifestJson.ts
packages/uni-h5-vite/src/plugins/manifestJson.ts
+11
-11
packages/uni-h5-vite/src/plugins/pagesJson.ts
packages/uni-h5-vite/src/plugins/pagesJson.ts
+4
-4
packages/uni-h5/src/helpers/location.ts
packages/uni-h5/src/helpers/location.ts
+4
-4
未找到文件。
packages/uni-h5-vite/src/plugins/manifestJson.ts
浏览文件 @
f9515ec7
...
@@ -59,18 +59,18 @@ export function uniManifestJsonPlugin(): Plugin {
...
@@ -59,18 +59,18 @@ export function uniManifestJsonPlugin(): Plugin {
sdkConfigs
.
maps
.
google
&&
sdkConfigs
.
maps
.
google
&&
sdkConfigs
.
maps
.
google
.
key
sdkConfigs
.
maps
.
google
.
key
const
A
MapKey
=
const
a
MapKey
=
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
.
AMap
&&
sdkConfigs
.
maps
.
AM
ap
.
key
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
.
amap
&&
sdkConfigs
.
maps
.
am
ap
.
key
const
A
MapSecurityJsCode
=
const
a
MapSecurityJsCode
=
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
.
AM
ap
&&
sdkConfigs
.
maps
.
am
ap
&&
sdkConfigs
.
maps
.
AM
ap
.
securityJsCode
sdkConfigs
.
maps
.
am
ap
.
securityJsCode
const
A
MapServiceHost
=
const
a
MapServiceHost
=
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
&&
sdkConfigs
.
maps
.
AM
ap
&&
sdkConfigs
.
maps
.
am
ap
&&
sdkConfigs
.
maps
.
AM
ap
.
serviceHost
sdkConfigs
.
maps
.
am
ap
.
serviceHost
let
locale
:
string
|
null
|
undefined
=
manifest
.
locale
let
locale
:
string
|
null
|
undefined
=
manifest
.
locale
locale
=
locale
&&
locale
.
toUpperCase
()
!==
'
AUTO
'
?
locale
:
''
locale
=
locale
&&
locale
.
toUpperCase
()
!==
'
AUTO
'
?
locale
:
''
...
@@ -105,9 +105,9 @@ export function uniManifestJsonPlugin(): Plugin {
...
@@ -105,9 +105,9 @@ export function uniManifestJsonPlugin(): Plugin {
export const async =
${
JSON
.
stringify
(
async
)}
export const async =
${
JSON
.
stringify
(
async
)}
export const qqMapKey =
${
JSON
.
stringify
(
qqMapKey
)}
export const qqMapKey =
${
JSON
.
stringify
(
qqMapKey
)}
export const googleMapKey =
${
JSON
.
stringify
(
googleMapKey
)}
export const googleMapKey =
${
JSON
.
stringify
(
googleMapKey
)}
export const
AMapKey =
${
JSON
.
stringify
(
A
MapKey
)}
export const
aMapKey =
${
JSON
.
stringify
(
a
MapKey
)}
export const
AMapSecurityJsCode =
${
JSON
.
stringify
(
A
MapSecurityJsCode
)}
export const
aMapSecurityJsCode =
${
JSON
.
stringify
(
a
MapSecurityJsCode
)}
export const
AMapServiceHost =
${
JSON
.
stringify
(
A
MapServiceHost
)}
export const
aMapServiceHost =
${
JSON
.
stringify
(
a
MapServiceHost
)}
export const sdkConfigs =
${
JSON
.
stringify
(
sdkConfigs
)}
export const sdkConfigs =
${
JSON
.
stringify
(
sdkConfigs
)}
export const locale = '
${
locale
}
'
export const locale = '
${
locale
}
'
export const fallbackLocale = '
${
fallbackLocale
}
'
export const fallbackLocale = '
${
fallbackLocale
}
'
...
...
packages/uni-h5-vite/src/plugins/pagesJson.ts
浏览文件 @
f9515ec7
...
@@ -53,7 +53,7 @@ function generatePagesJsonCode(
...
@@ -53,7 +53,7 @@ function generatePagesJsonCode(
return
`
return
`
import { defineAsyncComponent, resolveComponent, createVNode, withCtx, openBlock, createBlock } from 'vue'
import { defineAsyncComponent, resolveComponent, createVNode, withCtx, openBlock, createBlock } from 'vue'
import { PageComponent, AsyncLoadingComponent, AsyncErrorComponent, useI18n, setupWindow, setupPage } from '@dcloudio/uni-h5'
import { PageComponent, AsyncLoadingComponent, AsyncErrorComponent, useI18n, setupWindow, setupPage } from '@dcloudio/uni-h5'
import { appId, appName, appVersion, appVersionCode, debug, networkTimeout, router, async, sdkConfigs, qqMapKey, googleMapKey,
AMapKey, AMapSecurityJsCode, A
MapServiceHost, nvue, locale, fallbackLocale } from './
${
MANIFEST_JSON_JS
}
'
import { appId, appName, appVersion, appVersionCode, debug, networkTimeout, router, async, sdkConfigs, qqMapKey, googleMapKey,
aMapKey, aMapSecurityJsCode, a
MapServiceHost, nvue, locale, fallbackLocale } from './
${
MANIFEST_JSON_JS
}
'
const locales = import.meta.globEager('./locale/*.json')
const locales = import.meta.globEager('./locale/*.json')
${
importLayoutComponentsCode
}
${
importLayoutComponentsCode
}
const extend = Object.assign
const extend = Object.assign
...
@@ -262,9 +262,9 @@ function generateConfig(
...
@@ -262,9 +262,9 @@ function generateConfig(
sdkConfigs,
sdkConfigs,
qqMapKey,
qqMapKey,
googleMapKey,
googleMapKey,
A
MapKey,
a
MapKey,
A
MapSecurityJsCode,
a
MapSecurityJsCode,
A
MapServiceHost,
a
MapServiceHost,
nvue,
nvue,
locale,
locale,
fallbackLocale,
fallbackLocale,
...
...
packages/uni-h5/src/helpers/location.ts
浏览文件 @
f9515ec7
...
@@ -31,12 +31,12 @@ export function getMapInfo() {
...
@@ -31,12 +31,12 @@ export function getMapInfo() {
key
:
__uniConfig
.
googleMapKey
,
key
:
__uniConfig
.
googleMapKey
,
}
}
}
}
if
(
__uniConfig
.
A
MapKey
)
{
if
(
__uniConfig
.
a
MapKey
)
{
return
{
return
{
type
:
MapType
.
AMAP
,
type
:
MapType
.
AMAP
,
key
:
__uniConfig
.
A
MapKey
,
key
:
__uniConfig
.
a
MapKey
,
securityJsCode
:
__uniConfig
.
A
MapSecurityJsCode
,
securityJsCode
:
__uniConfig
.
a
MapSecurityJsCode
,
serviceHost
:
__uniConfig
.
A
MapServiceHost
,
serviceHost
:
__uniConfig
.
a
MapServiceHost
,
}
}
}
}
return
{
return
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录