Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 新增功能订阅消息 #451

Merged

Conversation

wangzhenhuiOne
Copy link

这个 PR 做了什么? (简要描述所做更改)

这个 PR 是什么类型? (至少选择一个)

  • 新功能(Feature)

这个 PR 涉及以下平台:

  • 鸿蒙(harmony)

// @ts-ignore
native.requestSubscribeMessage(options).then((res) => {
if (res.errMsg === 'requestSubscribeMessage:ok') {
options.success?.(res)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里建议用公共接口返回处理

if (res.errMsg === 'requestSubscribeMessage:ok') {
options.success?.(res)
} else {
options.fail?.(res)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同上

} else {
options.fail?.(res)
}
options.complete?.(res)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同上

})
} catch (res) {
options.fail?.(res)
options.complete?.(res)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同上

Copy link

@szzwk szzwk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@szzwk szzwk merged commit a7dae4e into handsomeliuyang:release-3.6.8-app Dec 4, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants