From b509a23f7a1ad8b3aaaeef75f0b2703a9be4f702 Mon Sep 17 00:00:00 2001 From: Nurmuhammet Allanov Date: Mon, 8 Sep 2025 14:18:22 +0500 Subject: [PATCH] wip --- app/Models/User.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/app/Models/User.php b/app/Models/User.php index 9324689..bcba0dc 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -175,12 +175,20 @@ class User extends Authenticatable return $this->hasRole('operator'); } + /** + * Check if user is a currency maintainer. + */ + public function isCurrencyMaintainer(): bool + { + return $this->hasRole('currency_maintainer'); + } + /** * Is System User */ public function isSystemUser(): bool { - return $this->isAdmin() || $this->isOperator(); + return $this->isAdmin() || $this->isOperator() || $this->isCurrencyMaintainer(); } /**