Skip to content

fix: [DHCP Settings] back button incorrectly navigates to Menu instead of previous page #749

Description

@PeterJhongLinksys

Description

On the DHCP Settings page, tapping the back button navigates to the Menu page instead of returning to the previous page (Local Network). This is an unexpected navigation behavior since users always enter the DHCP Settings page from the Local Network page.

Root Cause

The uspDhcpDetail route is defined as a top-level sibling route under the dashboard shell (lib/route/route_usp_dashboard.dart:72), rather than as a child route of uspAdvancedSettings. Since go_router cannot resolve a parent route to pop back to, the backFallback in UspDhcpDetailView (lib/page/dhcp/views/usp_dhcp_detail_view.dart:38) directs users to RouteNamed.uspMenu.

Entry Points

Users navigate to the DHCP Settings page from:

  • lib/page/local_network/views/usp_local_network_view.dart:330 — "DHCP Settings" link in Local Network view
  • lib/page/local_network/cards/usp_dhcp_reservations_card.dart:36 — DHCP reservations card

Both use context.goNamed(RouteNamed.uspDhcpDetail).

Expected Behavior

Tapping the back button on the DHCP Settings page should return the user to the Local Network page (or the page they navigated from).

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions