> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
**Goal:** Redirect successful low-price submissions to `confirmOrder` and route pending-follow-up list items to the low-price create-order flow.
**Architecture:** Remove the low-price-only branch from `SubmitContext.doSubmit` and use the same post-submit navigation statement as the business-assistant reference project. Restore the reference list template's status-based target so `status == 1` uses the existing `jump` create-order pathway while other statuses remain on details.
**Tech Stack:** JavaScript ES modules, WeChat Mini Program page/router APIs, Node.js built-in test runner, npm work-order test scripts.
## Global Constraints
- Preserve draft-save navigation and error handling.
- Preserve `wx.$util.refreshPageData()` and the correction-order `isErrorOrder` marker.
- Pass the API response data unchanged to `confirmOrder`.
- Do not modify request payload construction, approval rules, scene defaults, or list filtering.
- Preserve the existing list `jump` access checks and pass the complete list item to the create-order route.
- Work inline because the current repository contains related uncommitted create-order changes and delegation was not requested.
---
### Task 1: Align low-price submit success navigation with the reference project
-[]**Step 2: Run the focused test and verify RED**
Run:
```powershell
node --test --test-name-pattern "redirects a low-price order to confirmOrder after approval" tabWorkOrder/pages/createOrder/tests/lowPriceSubmitFlow.integration.test.mjs
```
Expected: FAIL because `redirectTarget` is empty and the current implementation calls list back-navigation.
-[]**Step 3: Apply the minimal production change**
Remove the import from `./services/lowPriceSubmitNavigation.helpers.js`. Replace the low-price branch in the successful non-draft path with the shared statement:
```js
wx.$util.refreshPageData()
if(isErrorOrder)resData.isErrorOrder=true
wx.$router.redirectTo('confirmOrder',resData)
```
-[]**Step 4: Run the focused test and verify GREEN**
Run the command from Step 2. Expected: PASS with one selected test and no failures.
Expected: all non-live tests pass, live tests remain explicitly skipped, work-order closure reports `status: ok`, and the diff check reports no whitespace errors.
-[]**Step 7: Review scope without staging unrelated changes**
Do not commit the dirty integration or production files automatically because they contain earlier confirmed create-order fixes that predate this navigation change.
---
### Task 2: Route pending-follow-up list items to create order
Make a successfully submitted low-price order continue to the same confirmation page as the business-assistant reference project instead of returning to the pending-order list.
Align two low-price-order navigation points with the business-assistant reference project:
- A successfully submitted order continues to the confirmation page instead of returning to the pending-order list.
- A pending-follow-up list item (`status == 1`) opens the low-price create-order flow instead of the detail page.
## Root Cause
## Root Cause
`regional-assistant` added a low-price-only success branch in `SubmitContext.doSubmit`. That branch updates or opens the low-price list after `createWithPay` succeeds. The reference project has no such branch: every successful non-draft submission redirects to `confirmOrder` with the API response data.
`regional-assistant` added a low-price-only success branch in `SubmitContext.doSubmit`. That branch updates or opens the low-price list after `createWithPay` succeeds. The reference project has no such branch: every successful non-draft submission redirects to `confirmOrder` with the API response data.
The migrated low-price list also hard-codes every card's `data-name` to `orderDetail`. The reference template routes `status == 1` to `createOrder`, so the hard-coded target incorrectly sends pending-follow-up records to details.
## Design
## Design
- Preserve draft-save navigation and error handling.
- Preserve draft-save navigation and error handling.
...
@@ -15,13 +20,17 @@ Make a successfully submitted low-price order continue to the same confirmation
...
@@ -15,13 +20,17 @@ Make a successfully submitted low-price order continue to the same confirmation
- For every successful non-draft submission, including low-price orders, call `wx.$router.redirectTo('confirmOrder', resData)`.
- For every successful non-draft submission, including low-price orders, call `wx.$router.redirectTo('confirmOrder', resData)`.
- Remove the now-unused low-price-list navigation import, helper module, and helper tests.
- Remove the now-unused low-price-list navigation import, helper module, and helper tests.
- Update the low-price submit integration test to assert one API call, no list back-navigation, and a `confirmOrder` redirect carrying the returned order data.
- Update the low-price submit integration test to assert one API call, no list back-navigation, and a `confirmOrder` redirect carrying the returned order data.
- Change the low-price list card target to `createOrder` when `li.status == 1`; keep `orderDetail` for other states.
- Continue using the existing `jump` method so its access checks and complete list item parameters remain intact.
- Add a list-template regression assertion for the pending-follow-up route mapping.
## Verification
## Verification
- First run the updated low-price submit test against the current implementation and verify it fails because the route remains empty and list back-navigation occurs.
- First run the updated low-price submit test against the current implementation and verify it fails because the route remains empty and list back-navigation occurs.
- Apply the production change and verify the focused test passes.
- Apply the production change and verify the focused test passes.
- Run the list-page test before and after the template change to prove that a pending-follow-up item no longer targets `orderDetail`.
- Run the complete create-order and work-order regression suites plus `git diff --check`.
- Run the complete create-order and work-order regression suites plus `git diff --check`.
## Scope
## Scope
This change does not alter request payloads, approval rules, scene defaults, list filtering, draft-save behavior, or API response handling.
This change does not alter request payloads, approval rules, scene defaults, list filtering, draft-save behavior, API response handling, or non-pending list-item routing.