Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
ripplebb
uni-app
提交
b7feb489
U
uni-app
项目概览
ripplebb
/
uni-app
与 Fork 源项目一致
Fork自
DCloud / uni-app
通知
1
Star
0
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,发现更多精彩内容 >>
提交
b7feb489
编写于
4月 29, 2022
作者:
D
DCloud_LXH
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat(app):
上级
247dceda
变更
5
显示空白变更内容
内联
并排
Showing
5 changed file
with
26 addition
and
12 deletion
+26
-12
lib/apis.js
lib/apis.js
+3
-1
src/platforms/app-plus/service/api/index.js
src/platforms/app-plus/service/api/index.js
+1
-0
src/platforms/app-plus/service/api/plugin/get-launch-options-sync.js
...ms/app-plus/service/api/plugin/get-launch-options-sync.js
+11
-0
src/platforms/app-plus/service/framework/utils.js
src/platforms/app-plus/service/framework/utils.js
+5
-3
src/platforms/mp-weixin/helpers/enhance-system-info.js
src/platforms/mp-weixin/helpers/enhance-system-info.js
+6
-8
未找到文件。
lib/apis.js
浏览文件 @
b7feb489
...
...
@@ -248,7 +248,9 @@ const third = [
'
unPreloadPage
'
,
'
loadSubPackage
'
,
'
sendHostEvent
'
,
'
navigateToMiniProgram
'
'
navigateToMiniProgram
'
,
'
getLaunchOptionsSync
'
,
'
getEnterOptionsSync
'
]
const
ad
=
[
...
...
src/platforms/app-plus/service/api/index.js
浏览文件 @
b7feb489
...
...
@@ -56,6 +56,7 @@ export * from './plugin/on-native-event-receive'
export
*
from
'
./plugin/send-native-event
'
export
*
from
'
./plugin/load-sub-package
'
export
*
from
'
./plugin/sdk
'
export
*
from
'
./plugin/get-launch-options-sync
'
export
*
from
'
./route/navigate-back
'
export
*
from
'
./route/navigate-to
'
...
...
src/platforms/app-plus/service/api/plugin/get-launch-options-sync.js
0 → 100644
浏览文件 @
b7feb489
import
{
getEnterOptions
,
getLaunchOptions
}
from
'
../../framework/utils
'
export
function
getLaunchOptionsSync
()
{
return
getLaunchOptions
()
}
export
function
getEnterOptionsSync
()
{
return
getEnterOptions
()
}
src/platforms/app-plus/service/framework/utils.js
浏览文件 @
b7feb489
...
...
@@ -46,7 +46,9 @@ export function initLaunchOptions ({
extend
(
launchOptions
,
{
path
,
query
:
query
?
parseQuery
(
query
)
:
{},
referrerInfo
:
referrerInfo
||
{}
referrerInfo
:
referrerInfo
||
{},
channel
:
plus
.
runtime
.
channel
,
launcher
:
plus
.
runtime
.
launcher
})
extend
(
enterOptions
,
launchOptions
)
return
launchOptions
...
...
src/platforms/mp-weixin/helpers/enhance-system-info.js
浏览文件 @
b7feb489
...
...
@@ -2,7 +2,7 @@ import { getDeviceBrand } from 'uni-shared'
const
UUID_KEY
=
'
__DC_STAT_UUID
'
let
deviceId
export
function
useDeviceId
(
result
)
{
export
function
useDeviceId
(
result
)
{
deviceId
=
deviceId
||
__GLOBAL__
.
getStorageSync
(
UUID_KEY
)
if
(
!
deviceId
)
{
deviceId
=
Date
.
now
()
+
''
+
Math
.
floor
(
Math
.
random
()
*
1
e7
)
...
...
@@ -14,7 +14,7 @@ export function useDeviceId(result) {
result
.
deviceId
=
deviceId
}
export
function
addSafeAreaInsets
(
result
)
{
export
function
addSafeAreaInsets
(
result
)
{
if
(
result
.
safeArea
)
{
const
safeArea
=
result
.
safeArea
result
.
safeAreaInsets
=
{
...
...
@@ -26,7 +26,7 @@ export function addSafeAreaInsets(result) {
}
}
export
function
populateParameters
(
result
)
{
export
function
populateParameters
(
result
)
{
const
{
brand
,
model
,
system
,
language
,
theme
,
version
,
hostName
,
platform
}
=
result
// osName osVersion
...
...
@@ -75,11 +75,9 @@ export function populateParameters(result) {
// hostName
let
_hostName
=
hostName
// mp-jd
if
(
__PLATFORM__
===
'
mp-weixin
'
)
_hostName
=
(
result
.
host
||
{}).
env
if
(
__PLATFORM__
===
'
mp-baidu
'
||
__PLATFORM__
===
'
mp-kuaishou
'
)
_hostName
=
result
.
host
if
(
__PLATFORM__
===
'
mp-baidu
'
||
__PLATFORM__
===
'
mp-kuaishou
'
)
{
_hostName
=
result
.
host
}
if
(
__PLATFORM__
===
'
mp-qq
'
)
_hostName
=
result
.
AppPlatform
if
(
__PLATFORM__
===
'
mp-toutiao
'
||
__PLATFORM__
===
'
mp-lark
'
)
_hostName
=
result
.
appName
if
(
__PLATFORM__
===
'
mp-toutiao
'
||
__PLATFORM__
===
'
mp-lark
'
)
{
_hostName
=
result
.
appName
}
if
(
__PLATFORM__
===
'
mp-alipay
'
)
_hostName
=
result
.
app
// wx.getAccountInfoSync
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录