Hide Specialty sidebar group for desk specialists.
Deploy Ladill Care / deploy (push) Successful in 2m34s

Single-desk specialists already reach their workspace via dashboard cards; the Specialty → Dentistry nav group was redundant. GPs and multi-module roles keep the section.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-07-18 22:29:30 +00:00
co-authored by Cursor
parent c8a7115e49
commit 244bb8fba6
3 changed files with 71 additions and 10 deletions
@@ -180,6 +180,32 @@ class SpecialtyModuleService
return $out;
}
/**
* Whether the sidebar should show the Specialty nav group.
*
* Desk specialists only receive their own matching module(s), so a
* Specialty Dentistry (etc.) group is redundant they use dashboard
* cards / direct routes instead. GPs, nurses, and other multi-module
* roles keep the group for referral and cross-module access.
*/
public function shouldShowSpecialtyNav(Organization $organization, ?Member $member): bool
{
if (! $member) {
return false;
}
$modules = $this->enabledModulesForMember($organization, $member);
if ($modules === []) {
return false;
}
if ($this->isDeskSpecialist($organization, $member)) {
return false;
}
return true;
}
/**
* @return 'general'|'limited'|'restricted'
*/