已合并
web支持复制保险箱 #77335
xiongjun_gitee11创建于 2025年12月4日
web支持复制保险箱 #77335
已合并
xiongjun_gitee11创建于 2025年12月4日
xiongjun_gitee11
xiongjun_gitee11
2025年12月4日

IssueNo:https://gitcode.com/openharmony/arkui_ace_engine/issues/69560
Description: web支持复制保险箱
Sig: SIG_ApplicationFramework
Binary Source: No(涉及则Yes)

请勿修改以下选项内容,仅需保存后点击复选框,或在编辑时将对应项前面的[ ]改为[x]

Do not modify the following option content. Simply save and click the checkbox, or when editing, change [ ] to [x] for the relevant item.

Feature or Bugfix

是否涉及非兼容变更/Whether it involves incompatible changes

TDD自验结果/TDD Self-Verification Results

XTS自验结果/XTS Self-Verification Results

检视意见是否都已闭环/Have all review comments been resolved

是否已执行L0用例

likedislike
Pull Request已成功合入, 合并人@openharmony_ci
(感谢 xiongjun_gitee11 的贡献)
xiongjun_gitee11xiongjun_gitee11
2025年12月4日 关联了issue:[Bug]: web支持复制保险箱
arkui-feature-manager
arkui-feature-manager成员
2025年12月4日 评论:

修改责任田 @arkui_framework_xnode 相关代码, 请根据修改内容联系以下人员检视后评论"pass"后消分:
[FrameworkXnode xiangshouxing] @xiang-shouxing
[FrameworkResource lushi] @lushi871202
[XNode wangchensu] @wangchensu1
[FrameworkXnode wangyang] @wangyang2022
[default group member npisanov] @npisanov
[default group member skrobagleb] @skrobagleb
[Image能力 maxuchu] @huaweimaxuchu

修改责任田 @arkweb-committer-group 相关代码, 请根据修改内容联系以下人员检视后评论"pass"后消分:
[web-交互安全 libing] @libing23232323
[web-渲染 lvjunmao] @LongLie
[web-渲染性能 wudefeng] @defeng2020
[web-事件交互 zhufenghao] @zhufenghao
[web-性能优化 qianliangfang] @qianlf
[web-性能优化 liurongliang] @bc_yx
[web-稳定性&DFX chenshijun] @hjoksky
[web-南向 zhangyinglie] @zhang-yinglie
[web-多媒体 liweiyang] @whuqincheng
[web-网络加载 chenjiadong] @chenjiadong

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
arkui-feature-manager
arkui-feature-manager成员
2025年12月4日 评论:

check type result details
TDD检查/TDD check pass -
检视意见检查/Review Comments Check fail
🔍 点击查看详情/click to show details
检视意见检查(Review Comments Check)
code additions result review comments count(actual/expect)
141 fail 0/3

检视意见数量未达标(详情见上述表格),请联系组内成员积极进行代码检视。

The count of review comments falls short of the target (as detailed in the table above).Please contact your team to actively review your code.

提交信息检查/Commit Message Check pass -
头文件引用计数检查/Header File Check pass -

新开PR检查失败。
Check PR When Open failed.

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:waiting_on_author
xiongjun_gitee11
xiongjun_gitee11
2025年12月4日 评论:

start build

likedislike
openharmony_ci
openharmony_ci成员
2025年12月4日 评论:

感谢提交 Pull Requests!如果您提交的PR已经开发完毕,请评论 "start build" 触发门禁,更多交互操作,请访问OpenHarmony社区支持命令清单。如果需要调整订阅PR、Issue的变更状态,请访问订阅链接。


Thanks for submitting the pull request. If your Pull Request has already been developed, you can leave a "start build" comment to trigger the gated system. For more commands, please visit OpenHarmony Command List. If you need to change the subscription of a Pull Request or Issue, please visit the link.

likedislike
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:dco检查成功
openharmony_ci
openharmony_ci成员
2025年12月4日 评论:

首次触发
门禁构建开始,包含静态检查、代码编译和测试【hap_build-codearts编译, dayu200_xts_static编译, master_inner_build编译, dayu200_xts_acts编译, hap_build编译, dayu200编译, mac-sdk编译, dayu200测试, part_compile编译, arkui_tdd-codearts编译, ohos-sdk编译, arkui_tdd编译, dayu200_xts编译】,预计在60分钟内完成,门禁结果会同步发送到注册邮箱。您可以通过如下链接跟踪门禁进展:http://dcp.openharmony.cn/workbench/cicd/detail/693106f564650f998b649ef4/runlist

likedislike
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:编译成功
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:静态检查成功
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:冒烟测试成功
openharmony_ciopenharmony_ci成员
2025年12月4日 通过测试
openharmony_ci
openharmony_ci成员
2025年12月4日 评论:

代码门禁通过
您可以通过如下链接查看门禁报告:http://dcp.openharmony.cn/workbench/cicd/detail/693106f564650f998b649ef4/runlist

静态检查:

# check type result report
1 codeCheck pass >>>

编译测试:
# Device build result test result package
1 ohos-sdk success NA >>>
2 dayu200 success success >>>
3 dayu200_xts success NA >>>
4 hap_build success NA >>>
5 arkui_tdd success NA >>>
6 part_compile success NA >>>
7 dayu200_xts_acts success NA >>>
8 dayu200_xts_static success NA >>>
9 master_inner_build failed(IGNORE)(联合门禁失败) NA >>>
10 hap_build-codearts failed(IGNORE)(skip build) NA >>>
11 mac-sdk success NA >>>
12 arkui_tdd-codearts (IGNORE) NA >>>

likedislike
openharmony_ciopenharmony_ci成员
2025年12月4日 删除了label:waiting_on_author
openharmony_ciopenharmony_ci成员
2025年12月4日 添加了label:waiting_for_review
openharmony_ci
openharmony_ci成员
2025年12月4日 评论:

您好,Committer @zhoutianer @zhanghaibo0 @zhou-chaobo @liyi0309 @Armstrong15 @sunfei2021 @cc520bf @jyj-0306 @uniquexch @jiangdayuan @yangfan229 @lixingchi1 @ZhangYu-Home @zcdqs @caoruihong @piggyguy @carnivore233 @forantar @korobeinikovevgeny @zakalyukinalexander_ac40 @yylong @hwliujinwei @lushi871202 @yan_shuifeng @HeSu6 @shiyu_huang_plus ,请分配检视人员检视该PR,可以通过命令"assign [@someone_id]"分配检视人员,也可以直接评论"assign"分配给自己进行检视。


Hello, Committer @zhoutianer @zhanghaibo0 @zhou-chaobo @liyi0309 @Armstrong15 @sunfei2021 @cc520bf @jyj-0306 @uniquexch @jiangdayuan @yangfan229 @lixingchi1 @ZhangYu-Home @zcdqs @caoruihong @piggyguy @carnivore233 @forantar @korobeinikovevgeny @zakalyukinalexander_ac40 @yylong @hwliujinwei @lushi871202 @yan_shuifeng @HeSu6 @shiyu_huang_plus . Please assign someone to review the PR. You can assign a reviewer by using the command "assign [@someone_id]", or you can comment "assign" to review the PR by yourself.

likedislike
xiongjun_gitee11
xiongjun_gitee11
2025年12月5日 评论:

⚠️ 🤖 AI 代码检视报告 ⚠️

总体评估: NEEDS_ATTENTION

问题统计:

  • 总问题数: 4
  • 严重问题: 0
  • 高危问题: 3

摘要:
代码在实现web复制保险箱功能时存在线程安全和异常安全问题,可能导致数据竞争和资源泄漏。

📊 详细报告
查看完整的审查详情,包括具体的问题描述、建议和代码位置:
🔗 查看详细报告


此评论由 OpenHarmony Insight 代码审查系统自动生成

likedislike
xiongjun_gitee11
xiongjun_gitee112025年12月5日进行代码检视1
frameworks/core/components_ng/pattern/web/web_pattern.cpp
@@ -5732,0 +5758,4 @@
5758+ nodeInfo->SetIsFocus(true);
5759+ pageNodeInfo_.emplace_back(nodeInfo);
5760+ viewDataCommon_ = std::make_shared<ViewDataCommon>();
5761+}
xiongjun_gitee11
xiongjun_gitee112025年12月5日评论:

🤖 AI 代码检视意见

类别: 🛡️ Reliability
严重级别: High
文件: frameworks/core/components_ng/pattern/web/web_pattern.cpp
行号: L5744-L5761

问题描述:
FakePageNodeInfo函数修改了成员变量pageNodeInfo_和viewDataCommon_,但没有使用任何同步机制。在多线程环境下,如果多个线程同时调用RequestAutoFill,可能导致数据竞争和未定义行为。

修复建议:

void WebPattern::FakePageNodeInfo()
{
    std::lock_guard<std::mutex> lock(autoFillMutex_); // 添加互斥锁保护
    auto host = GetHost();
    CHECK_NULL_VOID(host);
    RefPtr<PageNodeInfoWrap> nodeInfo = PageNodeInfoWrap::CreatePageNodeInfoWrap();
    CHECK_NULL_VOID(nodeInfo);
    pageNodeInfo_.clear();
    nodeInfo->SetId(host->GetId());
    // ... 其余代码保持不变
}

并在类中添加成员:mutable std::mutex autoFillMutex_;


此评论由 OpenHarmony Insight Review Lite 自动生成

likedislike
xiongjun_gitee11xiongjun_gitee11
2025年12月5日 解决了最后一个问题
xiongjun_gitee11
xiongjun_gitee112025年12月5日进行代码检视1
adapter/ohos/entrance/ace_container.cpp
@@ -1735,2 +1734,3 @@
1734+ [viewDataWrap, node, autoFillType = autoFillType_, triggerType = triggerType_]() {
17351735 if (node) {
1736- node->NotifyFillRequestSuccess(viewDataWrap, nullptr, autoFillType);
1736+ node->NotifyFillRequestSuccess(viewDataWrap, nullptr, autoFillType, triggerType);
xiongjun_gitee11
xiongjun_gitee112025年12月5日评论:

将触发类型通知到frame_node

likedislike
xiongjun_gitee11
xiongjun_gitee112025年12月5日进行代码检视1
frameworks/core/components/web/resource/web_delegate.cpp
@@ -7300,3 +7308,4 @@
73007308 auto romMessage = std::make_shared<OHOS::NWeb::WebViewValue>(NWebRomValue::Type::NONE);
73017309 romMessage->SetType(NWebRomValue::Type::STRING);
73027310 romMessage->SetString(jsonStr);
7311+ delegate->nweb_->FillAutofillDataFromTriggerType(romMessage, type);
xiongjun_gitee11
xiongjun_gitee112025年12月5日评论:

将触发类型通知到内核,以便内核可以区分当前触发来源是什么

likedislike
xiongjun_gitee11
xiongjun_gitee11
2025年12月5日 评论:

self check

likedislike
arkui-feature-manager
arkui-feature-manager成员
2025年12月5日 评论:
check type result details
提交信息检查/Commit Message Check pass -
TDD检查/TDD check pass -
检视意见检查/Review Comments Check pass -
头文件引用计数检查/Header File Check pass -

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
zhufenghao
zhufenghao成员2025年12月5日进行代码检视1
frameworks/core/components_ng/pattern/web/web_pattern.cpp
@@ -5729,0 +5792,4 @@
5792+ CHECK_NULL_VOID(pageNode);
5793+ auto pagePattern = pageNode->GetPattern<PagePattern>();
5794+ CHECK_NULL_VOID(pagePattern);
5795+ pagePattern->SetIsModalCovered(true);
zhufenghao
zhufenghao2025年12月5日评论:

回调的实际作用

likedislike
zhufenghaozhufenghao成员
2025年12月6日 解决了最后一个问题
zhufenghao
zhufenghao成员
2025年12月6日 评论:

pass

likedislike
arkui-feature-manager
arkui-feature-manager成员
2025年12月6日 评论:

@arkweb-committer-group 加分已记录。

若本次加分失败,请您在所有管控项通过后,评论"self check"可恢复加分,无需再找CodeOwner进行加分。

If the current review fails, you can restore the review by commenting 'self check' once all check items are passed. No further action from the CodeOwner is required.

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
Aarkweb-committer-group成员
2025年12月6日 通过审查
arkui-feature-manager
arkui-feature-manager成员
2025年12月6日 评论:
check type result details
提交信息检查/Commit Message Check pass -
TDD检查/TDD check pass -
检视意见检查/Review Comments Check pass -
头文件引用计数检查/Header File Check pass -

@zhufenghao 已评审通过, 责任田 @arkweb-committer-group 已加分, 满足合入条件后请联系Commiter审核加分

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
wangyang2022
wangyang2022成员
2025年12月8日 评论:

pass

likedislike
arkui-feature-manager
arkui-feature-manager成员
2025年12月8日 评论:

@arkui_framework_xnode 加分已记录。

若本次加分失败,请您在所有管控项通过后,评论"self check"可恢复加分,无需再找CodeOwner进行加分。

If the current review fails, you can restore the review by commenting 'self check' once all check items are passed. No further action from the CodeOwner is required.

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
Aarkui_framework_xnode成员
2025年12月8日 通过审查
arkui-feature-manager
arkui-feature-manager成员
2025年12月8日 评论:
check type result details
提交信息检查/Commit Message Check pass -
TDD检查/TDD check pass -
检视意见检查/Review Comments Check pass -
头文件引用计数检查/Header File Check pass -
多线程映射检查/Multi-Thread Mapping Check pass -

@wangyang2022 已评审通过, 责任田 @arkui_framework_xnode 已加分, 满足合入条件后请联系Commiter审核加分

您可通过评论"list commands"来查询命令列表。
You can leave a "list commands" comment to get commands list.

likedislike
ZhangYu-HomeZhangYu-Home成员
2025年12月8日 通过审查
openharmony_ci
openharmony_ci成员
2025年12月8日 评论:

验证结果已超过12小时,之前验证结果无效,自动重新触发构建,请关注最新验证结果

likedislike
openharmony_ci
openharmony_ci成员
2025年12月8日 评论:

start build

likedislike
openharmony_ciopenharmony_ci成员
2025年12月8日 删除了label:静态检查成功
openharmony_ciopenharmony_ci成员
2025年12月8日 删除了label:编译成功
openharmony_ciopenharmony_ci成员
2025年12月8日 删除了label:冒烟测试成功
openharmony_ci
openharmony_ci成员
2025年12月8日 评论:

本地或库上代码有更新,全量重新构建,重置所有关联PR的验证状态
门禁构建开始,包含静态检查、代码编译和测试【dayu200_xts_static编译, master_inner_build编译, ohos-sdk编译, part_compile编译, arkui_tdd-codearts编译, hap_build-codearts编译, dayu200编译, dayu200_xts_acts编译, dayu200_xts编译, arkui_tdd编译, mac-sdk编译, dayu200测试, hap_build编译】,预计在60分钟内完成,门禁结果会同步发送到注册邮箱。您可以通过如下链接跟踪门禁进展:http://dcp.openharmony.cn/workbench/cicd/detail/69362fd664650f998b25d859/runlist

likedislike
openharmony_ciopenharmony_ci成员
2025年12月8日 添加了label:编译成功
openharmony_ciopenharmony_ci成员
2025年12月8日 添加了label:静态检查成功
openharmony_ciopenharmony_ci成员
2025年12月8日 添加了label:冒烟测试成功
openharmony_ciopenharmony_ci成员
2025年12月8日 通过测试
openharmony_ci
openharmony_ci成员
2025年12月8日 评论:

代码门禁通过
您可以通过如下链接查看门禁报告:http://dcp.openharmony.cn/workbench/cicd/detail/69362fd664650f998b25d859/runlist

静态检查:

# check type result report
1 codeCheck pass >>>

编译测试:
# Device build result test result package
1 ohos-sdk success NA >>>
2 dayu200 success success >>>
3 dayu200_xts success NA >>>
4 hap_build success NA >>>
5 arkui_tdd success NA >>>
6 part_compile success NA >>>
7 dayu200_xts_acts success NA >>>
8 dayu200_xts_static success NA >>>
9 master_inner_build failed(IGNORE)(联合门禁失败) NA >>>
10 hap_build-codearts failed(IGNORE)(skip build) NA >>>
11 mac-sdk success NA >>>
12 arkui_tdd-codearts success(IGNORE) NA >>>

likedislike
openharmony_ci
openharmony_ci成员
2025年12月8日 评论:

您好,Committer @zhoutianer @zhanghaibo0 @zhou-chaobo @liyi0309 @Armstrong15 @sunfei2021 @cc520bf @jyj-0306 @uniquexch @jiangdayuan @yangfan229 @lixingchi1 @ZhangYu-Home @zcdqs @caoruihong @piggyguy @carnivore233 @fenglinbailu @forantar @korobeinikovevgeny @zakalyukinalexander_ac40 @yylong @hwliujinwei @lushi871202 @yan_shuifeng @HeSu6 @shiyu_huang_plus ,请分配检视人员检视该PR,可以通过命令"assign [@someone_id]"分配检视人员,也可以直接评论"assign"分配给自己进行检视。


Hello, Committer @zhoutianer @zhanghaibo0 @zhou-chaobo @liyi0309 @Armstrong15 @sunfei2021 @cc520bf @jyj-0306 @uniquexch @jiangdayuan @yangfan229 @lixingchi1 @ZhangYu-Home @zcdqs @caoruihong @piggyguy @carnivore233 @fenglinbailu @forantar @korobeinikovevgeny @zakalyukinalexander_ac40 @yylong @hwliujinwei @lushi871202 @yan_shuifeng @HeSu6 @shiyu_huang_plus . Please assign someone to review the PR. You can assign a reviewer by using the command "assign [@someone_id]", or you can comment "assign" to review the PR by yourself.

likedislike
openharmony_ciopenharmony_ci成员
2025年12月8日 关闭了关联的issue
openharmony_ciopenharmony_ci成员
2025年12月8日 合入了pull request,合并节点 SHA:9db166b2aa02b8fca0307c71ca4ed9cafa02bf32
openharmony_ciopenharmony_ci成员
2025年12月8日 删除了label:waiting_for_review
openharmony_ciopenharmony_ci成员
2025年12月8日 添加了label:merged