User roles
The system supports three distinct user roles, each with specific permissions and access levels.Manager role
Managers have full access to all system features and administrative functions. Access privileges:- Full point-of-sale operations
- Complete inventory management
- Employee management and permissions
- Business settings configuration
- Financial reports and analytics
- Transaction history and auditing
- System configuration and preferences
- Voiding transactions
- Applying manager-level discounts
- Database backup and restore
/manager) which provides access to all system modules.
Login.tsx:115-118
Cashier role
Cashiers have access to core point-of-sale functions needed for daily transaction processing. Access privileges:- Point-of-sale transaction processing
- Product scanning and manual entry
- Payment processing (cash, card, etc.)
- Receipt printing
- Basic customer information
- Limited transaction history (own transactions)
- Shift reports (own shift only)
- Cannot void transactions without manager approval
- Cannot apply discounts above set threshold
- Cannot access employee management
- Cannot modify system settings
- Cannot view financial reports
- Cannot manage inventory
/manager) with restricted permissions enforced at the feature level.
Login.tsx:119-121
While cashiers navigate to the same dashboard as managers, the UI dynamically shows or hides features based on the user’s role and permissions.
Inventory role
Inventory staff have specialized access for managing stock and product information. Access privileges:- Inventory tracking and updates
- Stock receiving and adjustments
- Product information management
- Low stock alerts and reporting
- Supplier management
- Product categories and organization
- Barcode generation and printing
- Cannot process sales transactions
- Cannot access financial reports
- Cannot manage employees
- Cannot modify system settings
- Limited access to transaction history
Login.tsx:122-124
Role assignment
Roles are assigned to employees in the database and stored in theEmployee table.
Role field structure
Employee roles are determined by:Rolefield - Explicitly set role (“Manager”, “Cashier”, or “Inventory”)IsManagerflag - Legacy field for backward compatibility
Login.tsx:100
Role verification on login
The system validates that users select their assigned role during login:AuthController.cs:95-120
Permission levels
Permissions are enforced at multiple levels throughout the application.Backend API authorization
API endpoints check user roles before processing sensitive operations. The user’s role is included in the session data and validated for each request.Frontend UI controls
The frontend dynamically shows or hides features based on the current user’s role:Manager approval workflows
Certain operations require manager PIN validation even when initiated by other roles:AuthController.cs:158-185
- Transaction voids and refunds
- Large discounts or price overrides
- Cash drawer openings outside of sales
- Inventory adjustments above threshold
- Employee permission changes
Session-based role enforcement
User roles are stored in the session and validated throughout the user’s session:Login.tsx:104-111
- User’s assigned role
- Manager status flag
- Employee identification
- Authentication timestamp
Roles cannot be changed during an active session. To switch roles, users must log out and log back in.
Role selection interface
The login screen presents all three roles, but users must select their assigned role:Login.tsx:155-179
- Makes role selection explicit and visible
- Prevents accidental role confusion
- Creates an audit trail of role selection attempts
- Provides clear feedback on role assignment errors
Managing employee roles
Managers can assign and modify employee roles through the employee management interface.Best practices for role assignment
Principle of least privilege:- Assign the minimum role necessary for job functions
- Avoid giving everyone Manager access
- Regularly review role assignments
- Separate duties between roles to prevent conflicts of interest
- Don’t allow employees to manage their own permissions
- Use multiple managers for checks and balances
- Train employees on their role’s capabilities and limitations
- Document role responsibilities in employee onboarding
- Review audit logs for role-based access patterns
Next steps
Authentication
Learn about PIN-based authentication
Audit logging
Track role-based activity and access