package constants

type UserRole string

const (
	RoleAdmin   UserRole = "admin"
	RoleManager UserRole = "manager"
	RoleCashier UserRole = "cashier"
	RoleWaiter  UserRole = "waiter"
)

func GetAllUserRoles() []UserRole {
	return []UserRole{
		RoleAdmin,
		RoleManager,
		RoleCashier,
		RoleWaiter,
	}
}

func IsValidUserRole(role UserRole) bool {
	for _, validRole := range GetAllUserRoles() {
		if role == validRole {
			return true
		}
	}
	return false
}
