diff --git a/zh-cn/application-dev/reference/apis/js-apis-app-form-formHost.md b/zh-cn/application-dev/reference/apis/js-apis-app-form-formHost.md index 225ac2a3ffe90306ffbfdc7210db5ae6af5615eb..a6b51e58d7380fc2278b6a4e9473c002e88afd0e 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-app-form-formHost.md +++ b/zh-cn/application-dev/reference/apis/js-apis-app-form-formHost.md @@ -2158,9 +2158,11 @@ import formHost from '@ohos.app.form.formHost'; let formId = '12400633174999288'; try { - formHost.acquireFormData(formId, (error) => { + formHost.acquireFormData(formId, (error, data) => { if (error) { console.error(`error, code: ${error.code}, message: ${error.message}`); + } else { + console.log('formHost acquireFormData, data: ${JSON.stringify(data)}'); } }); } catch(error) { @@ -2188,7 +2190,7 @@ acquireFormData(formId: string): Promise<{[key: string]: Object}>; | 类型 | 说明 | | ------------------- | ------------------------- | -| Promise<void> | 无返回结果的Promise对象。 | +| Promise<{[key: string]: Object}>| 以Promise方式返回接口运行结果及分享数据。 | **错误码:** @@ -2206,8 +2208,8 @@ import formHost from '@ohos.app.form.formHost'; let formId = '12400633174999288'; try { - formHost.acquireFormData(formId).then(() => { - console.log('formHost acquireFormData success'); + formHost.acquireFormData(formId).then((data) => { + console.log('formHost acquireFormData success' + data); }).catch((error) => { console.error(`error, code: ${error.code}, message: ${error.message}`); }); diff --git a/zh-cn/application-dev/reference/apis/js-apis-wantAgent.md b/zh-cn/application-dev/reference/apis/js-apis-wantAgent.md index f98e2664deb717f3bf90510f12d41cf9d9133b3f..811d23feb1fec6e0ac79038dc9082c28246581e4 100644 --- a/zh-cn/application-dev/reference/apis/js-apis-wantAgent.md +++ b/zh-cn/application-dev/reference/apis/js-apis-wantAgent.md @@ -354,7 +354,7 @@ getBundleName(agent: WantAgent): Promise\ **系统能力**:SystemCapability.Ability.AbilityRuntime.Core -**参数:** +**参数:** | 参数名 | 类型 | 必填 | 说明 | | ----- | --------- | ---- | ------------- |