提交 44c06470 编写于 作者: Y yangzk

IssueNo: #I59MK9

Description: fix acquireFormState sample
Sig: SIG_ApplicationFramework
Feature or Bugfix: Bugfix
Binary Source: No
Signed-off-by: Nyangzk <yangzhongkai@huawei.com>
Change-Id: Ie12ec719ba0d3fdeb570730edee0f06b2d3dbe30
上级 b9a2e0cf
......@@ -819,9 +819,14 @@ SystemCapability.Ability.Form
```js
var want = {
"deviceId": "",
"bundleName": "com.extreme.test",
"abilityName": "com.extreme.test.MainAbility"
"deviceId": "",
"bundleName": "ohos.samples.FormApplication",
"abilityName": "FormAbility",
"parameters": {
"ohos.extra.param.key.module_name": "entry",
"ohos.extra.param.key.form_name": "widget",
"ohos.extra.param.key.form_dimension": 2
}
};
formHost.acquireFormState(want, (error, data) => {
if (error.code) {
......@@ -858,9 +863,14 @@ SystemCapability.Ability.Form
```js
var want = {
"deviceId": "",
"bundleName": "com.extreme.test",
"abilityName": "com.extreme.test.MainAbility"
"deviceId": "",
"bundleName": "ohos.samples.FormApplication",
"abilityName": "FormAbility",
"parameters": {
"ohos.extra.param.key.module_name": "entry",
"ohos.extra.param.key.form_name": "widget",
"ohos.extra.param.key.form_dimension": 2
}
};
formHost.acquireFormState(want).then((data) => {
console.log('formHost acquireFormState, data:' + JSON.stringify(data));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册