new-role: Исполнитель ДУРРС #134

Merged
tsygankoviva merged 1 commits from new-role into test 2026-08-31 13:21:20 +03:00
3 changed files with 21 additions and 1 deletions

View File

@ -0,0 +1,15 @@
from alembic import op
revision = "0025"
down_revision = "0024"
branch_labels = None
depends_on = None
def upgrade() -> None:
op.execute("INSERT INTO v3.role(id, code) VALUES (4, 'DURRS')")
def downgrade() -> None:
pass

View File

@ -10,6 +10,7 @@ class UserRoleEnum(int, enum.Enum):
ADMIN = 1 ADMIN = 1
EXECUTOR_DFIP = 2 EXECUTOR_DFIP = 2
EXECUTOR_RF = 3 EXECUTOR_RF = 3
EXECUTOR_DURRS = 4
class Role(Base): class Role(Base):

View File

@ -2,26 +2,30 @@ export const ROLES_ID_NAME = {
1: 'admin', 1: 'admin',
2: 'executor_dfip', 2: 'executor_dfip',
3: 'executor_rf', 3: 'executor_rf',
4: 'executor_durrs'
}; };
export const ROLES_NAME_ID = { admin: 1, executor_dfip: 2, executor_rf: 3 }; export const ROLES_NAME_ID = { admin: 1, executor_dfip: 2, executor_rf: 3, executor_durrs: 4 };
export const ROLES_ID_RUSSIAN_NAME = { export const ROLES_ID_RUSSIAN_NAME = {
1: 'Администратор', 1: 'Администратор',
2: 'Исполнитель ДФИП', 2: 'Исполнитель ДФИП',
3: 'Исполнитель', 3: 'Исполнитель',
4: 'Исполнитель ДУРРС'
}; };
export const ROLES_ID_RUSSIAN_NAME_ARRAY = [ export const ROLES_ID_RUSSIAN_NAME_ARRAY = [
{ id: 1, role: 'Администратор' }, { id: 1, role: 'Администратор' },
{ id: 2, role: 'Исполнитель ДФИП' }, { id: 2, role: 'Исполнитель ДФИП' },
{ id: 3, role: 'Исполнитель' }, { id: 3, role: 'Исполнитель' },
{ id: 4, role: 'Исполнитель ДУРРС' },
]; ];
export const STAGE_ROLE_RUSSIAN_NAME = { export const STAGE_ROLE_RUSSIAN_NAME = {
ADMIN: 'Администратор', ADMIN: 'Администратор',
DFIP: 'Исполнитель ДФИП', DFIP: 'Исполнитель ДФИП',
EXECUTOR_RF: 'Исполнитель', EXECUTOR_RF: 'Исполнитель',
DURRS: 'Исполнитель ДУРРС',
}; };
export const TYPES_CELLS = { numeric: 'число', text: 'текст' }; export const TYPES_CELLS = { numeric: 'число', text: 'текст' };