Commit Graph

6 Commits

Author SHA1 Message Date
7db81c0e68 Return the created location from CreateTenantLocation so its locationid is available immediately
The store/branch QR code the app scans is just {tenantid, locationid} JSON, but the
onboarding response previously discarded the DB-assigned locationid, so the frontend
had no way to render a store's QR right after onboarding without a separate lookup.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-23 11:08:57 +05:30
Suriya
5bd1f52d41 Stop forcing new store outlets and their logins to InActive
CreateTenantLocation hardcoded the new location and its auto-spawned
manager login to InActive regardless of what the caller sent (the
frontend already sends Active). AppLogin checks account status before
checking whether a password is set, so a new store's login could
never reach the password-setup screen — permanently stuck on
"Inactive Account. Contact admin."

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-21 18:01:15 +05:30
Suriya
e48fb4cf57 Fix tenant onboarding creating admin users with configid=0
CreateTenantUser copied the tenant form's fields onto the new
app_users row via copier.Copy, but the onboarding form never sends a
configid, so it defaulted to 0. AppLogin's GetUserByAuthname always
queries configid=1 for the web login, so any tenant onboarded through
this path was permanently unable to log in by email ("Email not
found") no matter what was typed. Set it explicitly, same as roleid.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-21 17:13:58 +05:30
Suriya
7e9b3f98ba stores login fix 2026-07-09 18:03:44 +05:30
abe2cb997b stock request table created 2026-07-04 17:49:54 +05:30
Gokul
0d42ac84e1 initial commit 2026-05-25 11:52:26 +05:30