Skip to content

Admit a sales manager to the admin panel only with a sales employee - #1080

Merged
KrzysztofPajak merged 1 commit into
developfrom
fix/sales-manager-admin-access
Nov 22, 2026
Merged

KrzysztofPajak merged 1 commit into
developfrom
fix/sales-manager-admin-access

Conversation

@KrzysztofPajak

Copy link
Copy Markdown
Member

A sales manager works on the customers and orders of their own sales employee. The admin panel now admits a sales manager only when a sales employee is assigned to their account, the same way it already turns away vendors and store managers.

The customer edit screen already requires a sales employee for the Sales manager group, so accounts created there are unaffected. The rule covers accounts set up any other way.

Changes

  • AuthorizeAdminAttribute: a sales manager without a sales employee is sent to the admin login, like a vendor or a store manager.

Tests

  • AuthorizeAdminAttributeTests (new): staff are admitted, a sales manager with a sales employee is admitted, a sales manager without one is sent to the login, a customer without the panel permission is sent to the login.
  • Grand.Web.Common.Tests (771) and Grand.Web.Admin.Tests (2097) pass.

Copilot AI balanced review requested due to automatic review settings November 22, 2026 06:06

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@KrzysztofPajak
KrzysztofPajak merged commit c32f934 into develop Nov 22, 2026
9 checks passed
@KrzysztofPajak
KrzysztofPajak deleted the fix/sales-manager-admin-access branch November 22, 2026 10:46
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