def _create_worker_role() -> None: worker_role = RoleModel.get_or_none(name='worker') if worker_role is None: params = { 'name': 'worker', 'description': 'Worker', 'label': 'Worker', 'deleted_at': None, } Factory('Role').save(params)
def _create_admin_role() -> None: admin_role = RoleModel.get_or_none(name='admin') if admin_role is None: params = { 'name': 'admin', 'description': 'Administrator', 'label': 'Admin', 'deleted_at': None, } Factory('Role').save(params)
def _create_team_leader() -> None: team_leader_role = RoleModel.get_or_none(name='team_leader') if team_leader_role is None: params = { 'name': 'team_leader', 'description': 'Team leader', 'label': 'Team leader', 'deleted_at': None, } Factory('Role').save(params)