From 4369a89256808fe681b140a8adc9719a45df3c09 Mon Sep 17 00:00:00 2001 From: fengwei Date: Wed, 21 Jun 2023 17:35:37 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BA=94=E7=94=A8=E7=AE=A1=E7=90=86=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E5=8F=98=E6=9B=B4=EF=BC=8C=E6=B7=BB=E5=8A=A0=E8=AE=BF?= =?UTF-8?q?=E9=97=AE=E6=9D=83=E9=99=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: fengwei --- .../ets/model/appManagementImpl/AppManagementModel.ts | 3 ++- product/phone/src/main/module.json5 | 8 ++++++-- product/phone/src/main/resources/base/element/string.json | 4 ++++ .../phone/src/main/resources/en_US/element/string.json | 5 ++++- .../phone/src/main/resources/phone/element/string.json | 4 ++++ .../phone/src/main/resources/zh_CN/element/string.json | 4 ++++ 6 files changed, 24 insertions(+), 4 deletions(-) diff --git a/product/phone/src/main/ets/model/appManagementImpl/AppManagementModel.ts b/product/phone/src/main/ets/model/appManagementImpl/AppManagementModel.ts index b8a7f1b1..d50593cd 100644 --- a/product/phone/src/main/ets/model/appManagementImpl/AppManagementModel.ts +++ b/product/phone/src/main/ets/model/appManagementImpl/AppManagementModel.ts @@ -17,6 +17,7 @@ import LogUtil from '../../../../../../../common/utils/src/main/ets/default/base import Bundle from '@ohos.bundle'; import appManager from '@ohos.application.appManager' import osAccount from '@ohos.account.osAccount'; +import bundleManager from '@ohos.bundle.bundleManager' import ConfigData from '../../../../../../../common/utils/src/main/ets/default/baseUtil/ConfigData'; import { LogAll } from '../../../../../../../common/utils/src/main/ets/default/baseUtil/LogDecorator'; @@ -58,7 +59,7 @@ export class AppManagementModel extends BaseModel { */ setAppManagementListener() { this.mBundleInfoList = []; - Bundle.getAllBundleInfo(IS_INCLUDE_ABILITY_INFO) + bundleManager.getAllBundleInfo(bundleManager.BundleFlag.GET_BUNDLE_INFO_WITH_APPLICATION) .then((data) => { LogUtil.info('settings AppManagementModel setAppManagementListener getBundleInfos() start '); LogUtil.info('settings AppManagementModel data.length: ' + data.length + ' data: ' + JSON.stringify(data)); diff --git a/product/phone/src/main/module.json5 b/product/phone/src/main/module.json5 index 64533b7e..eb288133 100644 --- a/product/phone/src/main/module.json5 +++ b/product/phone/src/main/module.json5 @@ -188,11 +188,15 @@ { "name": "ohos.permission.MODIFY_AUDIO_SETTINGS", "reason": "$string:MODIFY_AUDIO_SETTINGS" - }, { + }, + { "name": "ohos.permission.ENTERPRISE_SET_DATETIME", "reason": "$string:ENTERPRISE_SET_DATETIME" }, - + { + "name": "ohos.permission.GET_INSTALLED_BUNDLE_LIST", + "reason": "$string:GET_INSTALLED_BUNDLE_LIST" + } ] } } \ No newline at end of file diff --git a/product/phone/src/main/resources/base/element/string.json b/product/phone/src/main/resources/base/element/string.json index 061a827f..a7dfb2bf 100644 --- a/product/phone/src/main/resources/base/element/string.json +++ b/product/phone/src/main/resources/base/element/string.json @@ -1263,6 +1263,10 @@ { "name": "assessmentIntroduction", "value": "OpenHarmony兼容性测评是由OpenHarmony社区面向设备厂商提供的测评服务,以保障OpenHarmony生态设备的应用兼容性、分布式兼容性和基础用户体验,实现OpenHarmony设备和应用生态统一。\n\n\n\n通过OpenHarmony兼容性测评的设备,由OpenHarmony项目群工作委员会授予OpenHarmony生态产品兼容性证书,并授权使用Powered By OpenHarmony兼容性标识。\n\n\n\n 您可以访问openHarmony.cn官网兼容性专区获取更多信息。" + }, + { + "name": "GET_INSTALLED_BUNDLE_LIST", + "value":"获取应用列表信息" } ] } \ No newline at end of file diff --git a/product/phone/src/main/resources/en_US/element/string.json b/product/phone/src/main/resources/en_US/element/string.json index 02a0b7d5..2f878e95 100644 --- a/product/phone/src/main/resources/en_US/element/string.json +++ b/product/phone/src/main/resources/en_US/element/string.json @@ -1259,7 +1259,10 @@ { "name": "assessmentIntroduction", "value": "OpenHarmony兼容性测评是由OpenHarmony社区面向设备厂商提供的测评服务,以保障OpenHarmony生态设备的应用兼容性、分布式兼容性和基础用户体验,实现OpenHarmony设备和应用生态统一。\n\n\n\n通过OpenHarmony兼容性测评的设备,由OpenHarmony项目群工作委员会授予OpenHarmony生态产品兼容性证书,并授权使用Powered By OpenHarmony兼容性标识。\n\n\n\n 您可以访问openHarmony.cn官网兼容性专区获取更多信息。" - + }, + { + "name": "GET_INSTALLED_BUNDLE_LIST", + "value":"Get installed bundle list" } ] } \ No newline at end of file diff --git a/product/phone/src/main/resources/phone/element/string.json b/product/phone/src/main/resources/phone/element/string.json index e75a879f..dab7a1d9 100644 --- a/product/phone/src/main/resources/phone/element/string.json +++ b/product/phone/src/main/resources/phone/element/string.json @@ -1263,6 +1263,10 @@ { "name": "assessmentIntroduction", "value": "OpenHarmony兼容性测评是由OpenHarmony社区面向设备厂商提供的测评服务,以保障OpenHarmony生态设备的应用兼容性、分布式兼容性和基础用户体验,实现OpenHarmony设备和应用生态统一。\n\n\n\n通过OpenHarmony兼容性测评的设备,由OpenHarmony项目群工作委员会授予OpenHarmony生态产品兼容性证书,并授权使用Powered By OpenHarmony兼容性标识。\n\n\n\n 您可以访问openHarmony.cn官网兼容性专区获取更多信息。" + }, + { + "name": "GET_INSTALLED_BUNDLE_LIST", + "value":"获取应用列表信息" } ] } \ No newline at end of file diff --git a/product/phone/src/main/resources/zh_CN/element/string.json b/product/phone/src/main/resources/zh_CN/element/string.json index bfb3e0de..769e152c 100644 --- a/product/phone/src/main/resources/zh_CN/element/string.json +++ b/product/phone/src/main/resources/zh_CN/element/string.json @@ -1263,6 +1263,10 @@ { "name": "assessmentIntroduction", "value": "OpenHarmony兼容性测评是由OpenHarmony社区面向设备厂商提供的测评服务,以保障OpenHarmony生态设备的应用兼容性、分布式兼容性和基础用户体验,实现OpenHarmony设备和应用生态统一。\n\n\n\n通过OpenHarmony兼容性测评的设备,由OpenHarmony项目群工作委员会授予OpenHarmony生态产品兼容性证书,并授权使用Powered By OpenHarmony兼容性标识。\n\n\n\n 您可以访问openHarmony.cn官网兼容性专区获取更多信息。" + }, + { + "name": "GET_INSTALLED_BUNDLE_LIST", + "value":"获取应用列表信息" } ] } \ No newline at end of file