Skip to content

Fix admin map refresh and admin login security - #47

Open
agrawalmilin9 wants to merge 1 commit into
wncc:mainfrom
agrawalmilin9:fix/admin-map-and-login
Open

agrawalmilin9 wants to merge 1 commit into
wncc:mainfrom
agrawalmilin9:fix/admin-map-and-login

Conversation

@agrawalmilin9

Copy link
Copy Markdown

Description

Follow-up fixes for #29 – Admin web dashboard.

Changes made

  • Prevent the live map from automatically resetting its zoom and position during periodic data refreshes.
  • Add a Fit map button to manually fit all markers into the map view.
  • Restrict admin login to phone numbers configured in ADMIN_PHONES.
  • Prevent unauthorized admin login attempts from creating new user accounts.
  • Return 401 Unauthorized for users without admin access.
  • Add a regression test for failed admin login and normal driver account creation.

Testing

  • Backend tests: 22 passed, 1 skipped
  • Admin production build: Passed
  • git diff --check: Passed
  • Manually verified map zoom stability and the Fit map button.

Related PR

Follow-up to merged PR #29 – Admin web dashboard.

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.

2 participants