Skip to content

perf(DeliveryJobs): 优化页面转跳逻辑#1062

Merged
MistEO merged 4 commits intomainfrom
refactor/delivery-jobs-navigation
Mar 7, 2026
Merged

perf(DeliveryJobs): 优化页面转跳逻辑#1062
MistEO merged 4 commits intomainfrom
refactor/delivery-jobs-navigation

Conversation

@he0119
Copy link
Contributor

@he0119 he0119 commented Mar 7, 2026

  1. 每个地区运送委托开始时先进入对应地区建设页面,检查仓储节点是否解锁
  2. 进入对应仓储节点后,循环检查任务和货物
  3. 当货物打包后,需要重新回到对应仓储节点转交任务
  4. 当任务转交后,会直接回到之前的仓储节点,所以不需要额外转跳
  5. 当所有任务都完成转交则返回地区建设页面并回到主循环

Summary by Sourcery

优化 DeliveryJobs 流水线在区域、仓库节点和任务转移步骤之间的导航流程。

改进内容:

  • 优化 DeliveryJobs 流水线定义(包括 EnterDepotNodePackCargoTransferJob 以及各区域特定流程),以简化页面跳转和任务交接顺序。
  • 更新通用的 Region 和 Text 流水线资源,使其与新的配送任务导航逻辑保持一致。
  • 新增五菱区域配送流水线,并调整现有的区域特定配送配置(包括 ValleyIV)。
  • 使测试用的 schema 定义与更新后的流水线资源结构保持一致。

测试:

  • 更新 DeliveryJobs 区域测试(包括 ADB 变体),以反映新的导航流程和区域配置变更。
Original summary in English

Summary by Sourcery

Optimize the DeliveryJobs pipeline navigation flow between region, depot node, and job transfer steps.

Enhancements:

  • Refine DeliveryJobs pipeline definitions (including EnterDepotNode, PackCargo, TransferJob, and region-specific flows) to streamline page transitions and task handoff sequencing.
  • Update common Region and Text pipeline resources to align with the new delivery job navigation logic.
  • Introduce a new Wuling region delivery pipeline and adjust existing region-specific delivery configurations, including ValleyIV.
  • Align test schema definitions with the updated pipeline resource structure.

Tests:

  • Update DeliveryJobs region tests (including ADB variants) to reflect the new navigation flow and region configuration changes.

由 Sourcery 生成的总结

优化 DeliveryJobs 在区域、仓库节点和任务流转步骤之间的导航流程,减少多余的页面跳转。

新功能:

  • 添加新的五菱区域配送流水线配置。

增强与改进:

  • 优化 DeliveryJobs 的流水线定义(包括仓库入场、货物打包、任务流转以及仓库节点流程),以精简页面导航和任务排序。
  • 更新通用的 Region 和 Text 流水线资源,使其与修订后的配送任务导航逻辑保持一致。
  • 调整现有的 ValleyIV 区域配送配置及相关仓库节点行为。
  • 更新测试用的 schema 定义,使其匹配新的流水线资源结构。

测试:

  • 更新 DeliveryJobs 区域和 pack-cargo 测试(包括 ADB 变体),以反映新的导航流程和区域配置。
Original summary in English

Summary by Sourcery

Optimize the DeliveryJobs navigation flow between regions, depot nodes, and job transfer steps to reduce redundant page transitions.

New Features:

  • Add a new Wuling region delivery pipeline configuration.

Enhancements:

  • Refine DeliveryJobs pipeline definitions (including depot entry, cargo packing, job transfer, and depot node flows) to streamline page navigation and task sequencing.
  • Update common Region and Text pipeline resources to align with the revised delivery job navigation logic.
  • Adjust existing region-specific delivery configuration for ValleyIV and related depot-node behavior.
  • Update test schema definitions to match the new pipeline resource structure.

Tests:

  • Update DeliveryJobs region and pack-cargo tests, including ADB variants, to reflect the new navigation flow and region configurations.

he0119 added 4 commits March 7, 2026 12:49
1. 每个地区运送委托开始时先进入对应地区建设页面,检查仓储节点是否解锁
2. 进入对应仓储节点后,循环检查任务和货物
3. 当货物打包后,在最后需要重新回到仓储节点转交任务,这里利用锚点设置
4. 当所有任务都完成转交则返回地区建设页面并回到主循环
这个节点会在确认仓储节点界面稳定后结束
@he0119 he0119 marked this pull request as ready for review March 7, 2026 06:14
Copilot AI review requested due to automatic review settings March 7, 2026 06:14
Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - 我在这里给出了一些整体性的反馈:

  • 新增的 Wuling 区域流水线和调整后的 ValleyIV 区域流水线在结构上看起来很相似;可以考虑把任何共享的导航逻辑或仓库(depot)处理步骤抽取成可复用的公共流水线片段,以避免代码重复,并让未来对各区域的调整变得更简单。
  • 当前的导航假设(例如在完成 TransferJob 后自动返回到上一个仓库节点)已经成为流程的核心部分;也许值得在流水线定义中把这些假设编码为显式、具名的状态或标志位,从而让行为更加清晰,并在未来 UI 流程发生变化时降低出现细微问题的风险。
给 AI 代理的提示
Please address the comments from this code review:

## Overall Comments
- The new Wuling and adjusted ValleyIV region pipelines sound structurally similar; consider extracting any shared navigation or depot-handling steps into reusable common pipeline fragments to avoid duplication and keep future region tweaks simpler.
- The navigation assumptions (e.g., auto-return to the previous depot node after TransferJob) are now core to the flow; it may be worth encoding these as explicit, named states or flags in the pipeline definitions to make the behavior clearer and reduce the risk of subtle breakage if the UI flow changes later.

Sourcery 对开源项目是免费的——如果你觉得我们的评审有帮助,欢迎分享 ✨
帮我变得更有用!请在每条评论上点 👍 或 👎,我会根据你的反馈改进后续的评审。
Original comment in English

Hey - I've left some high level feedback:

  • The new Wuling and adjusted ValleyIV region pipelines sound structurally similar; consider extracting any shared navigation or depot-handling steps into reusable common pipeline fragments to avoid duplication and keep future region tweaks simpler.
  • The navigation assumptions (e.g., auto-return to the previous depot node after TransferJob) are now core to the flow; it may be worth encoding these as explicit, named states or flags in the pipeline definitions to make the behavior clearer and reduce the risk of subtle breakage if the UI flow changes later.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The new Wuling and adjusted ValleyIV region pipelines sound structurally similar; consider extracting any shared navigation or depot-handling steps into reusable common pipeline fragments to avoid duplication and keep future region tweaks simpler.
- The navigation assumptions (e.g., auto-return to the previous depot node after TransferJob) are now core to the flow; it may be worth encoding these as explicit, named states or flags in the pipeline definitions to make the behavior clearer and reduce the risk of subtle breakage if the UI flow changes later.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

该 PR 旨在优化 DeliveryJobs(自动转交运送委托) 在“地区建设 ↔ 仓储节点 ↔ 任务/货物流程”之间的导航与循环结构,使装箱后能回到对应仓储节点继续转交,并减少不必要的页面跳转与分支节点依赖。

Changes:

  • 重构 Valley IV / 武陵 两个地区的 DeliveryJobs 主循环与仓储节点识别节点,并新增 Wuling.json 地区流水线。
  • 调整装箱(PackCargo)与转交(TransferJob)流程的收尾逻辑,引入“回到仓储节点”的统一回跳节点。
  • 清理/迁移 Common 里的部分可复用 OCR 节点,并同步更新相关 tests 与 schema 文案。

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tools/schema/test.schema.json 更新测试 schema 文案示例节点名
tests/DeliveryJobs/test_region.json 更新地区/仓储节点命中节点名为 DeliveryJobs 专用节点
tests/DeliveryJobs/test_region_adb.json 同上(ADB 变体)
tests/DeliveryJobs/test_pack_cargo.json 更新装箱流程测试用例命中节点与回跳节点
tests/DeliveryJobs/test_pack_cargo_adb.json 同上(ADB 变体)
assets/resource_fast/pipeline/DeliveryJobs/Wuling.json 新增武陵地区循环与仓储节点/货物入口节点
assets/resource_fast/pipeline/DeliveryJobs/ValleyIV.json 重构四号谷地循环、仓储节点识别、货物入口节点
assets/resource_fast/pipeline/DeliveryJobs/TransferJob.json 更新转交流程说明并等待回到仓储界面
assets/resource_fast/pipeline/DeliveryJobs/PackCargo.json 装箱完成后改为回到仓储节点(通过锚点跳转)
assets/resource_fast/pipeline/DeliveryJobs/EnterDepotNode.json 调整进入仓储节点与返回地区建设的通用节点
assets/resource_fast/pipeline/DeliveryJobs.json 调整地区任务入口逻辑,接入新的地区循环节点
assets/resource_fast/pipeline/Common/Text.json 移除部分仓储节点 OCR 文本节点(迁移到 DeliveryJobs 地区文件)
assets/resource_fast/pipeline/Common/Region.json 移除地区专用的本地仓储节点识别节点(迁移到 DeliveryJobs 地区文件)

@MistEO MistEO merged commit db717f6 into main Mar 7, 2026
21 checks passed
@MistEO MistEO deleted the refactor/delivery-jobs-navigation branch March 7, 2026 06:25
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