未验证 提交 5ce00b0c 编写于 作者: O openharmony_ci 提交者: Gitee

!5932 修复getTopAbility问题

Merge pull request !5932 from jerry/master
...@@ -494,8 +494,8 @@ export default function StartAbilityForResult() { ...@@ -494,8 +494,8 @@ export default function StartAbilityForResult() {
}).catch((error) => { }).catch((error) => {
console.error(' getTopAbility error: ' + JSON.stringify(error)); console.error(' getTopAbility error: ' + JSON.stringify(error));
}); });
console.log(" checkAbilityInfo deviceId : " + details1.ability.deviceId); console.log(" checkAbilityInfo deviceId : " + details1.deviceId);
DeviceId = details1.ability.deviceId; DeviceId = details1.deviceId;
await Utils.sleep(500); await Utils.sleep(500);
var str = { var str = {
'want': { 'want': {
...@@ -536,8 +536,8 @@ export default function StartAbilityForResult() { ...@@ -536,8 +536,8 @@ export default function StartAbilityForResult() {
}).catch((error) => { }).catch((error) => {
console.error(' getTopAbility error: ' + JSON.stringify(error)); console.error(' getTopAbility error: ' + JSON.stringify(error));
}); });
console.log(" checkAbilityInfo deviceId : " + details1.ability.deviceId); console.log(" checkAbilityInfo deviceId : " + details1.deviceId);
DeviceId = details1.ability.deviceId; DeviceId = details1.deviceId;
await Utils.sleep(1000); await Utils.sleep(1000);
var str = { var str = {
'want': { 'want': {
......
...@@ -201,8 +201,8 @@ export default function StartAbilityForResult(abilityContext) { ...@@ -201,8 +201,8 @@ export default function StartAbilityForResult(abilityContext) {
}).catch((error) => { }).catch((error) => {
console.error(' getTopAbility error: ' + JSON.stringify(error)); console.error(' getTopAbility error: ' + JSON.stringify(error));
}); });
console.log(" checkAbilityInfo deviceId : " + details1.ability.deviceId); console.log(" checkAbilityInfo deviceId : " + details1.deviceId);
DeviceId = details1.ability.deviceId; DeviceId = details1.deviceId;
setTimeout(async () => { setTimeout(async () => {
var str = { var str = {
"deviceId": DeviceId, "deviceId": DeviceId,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册