Нужно создать фирму, соответствующую подразделению верхнего уровня. Сопоставить ей подписантов.
Создать view где id_firm = 4
Пользователь работающий под ролью ROLE_QQQ_UK получит во все приказы подписантов фирмы с id_firm = 4.
CREATE view [ROLE_QQQ_UK].[pr_config]
(id_firm, Boss_Auto_Card, Boss_PD_Auto_Card, Boss_ChB_Auto_Card, Current_Access,
Boss_Work_Auto_Card, Boss_Prof_Auto_Card, Boss_name_app, Boss_PD_name_app, Boss_ChB_name_app,
Boss_Work_name_app, Boss_Prof_name_app, Boss_PRM_Auto_Card, Boss_PRM_name_app, Boss_HRM_Auto_Card, Boss_HRM_name_app, Boss_MIS_Auto_Card, Boss_MIS_name_app)
as
select
1 as Current_Access, Boss_Auto_Card, Boss_PD_Auto_Card, Boss_ChB_Auto_Card, 4,
Boss_Work_Auto_Card, Boss_Prof_Auto_Card, Boss_name_app, Boss_PD_name_app, Boss_ChB_name_app,
Boss_Work_name_app, Boss_Prof_name_app, Boss_PRM_Auto_Card, Boss_PRM_name_app, Boss_HRM_Auto_Card, Boss_HRM_name_app, Boss_MIS_Auto_Card, Boss_MIS_name_app
from dbo.pr_config where id_firm = 4
|