Skip to content

Conversation

@utkaka
Copy link
Contributor

@utkaka utkaka commented Sep 29, 2025

Restore permissions from v6:

  • Forbid create teamspace
  • Forbid create drive
  • Forbid create funnel
  • Forbid create vacancy
  • Forbid create project

Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
@huly-github-staging
Copy link

Connected to Huly®: UBERF-13804

Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
@utkaka utkaka changed the title Qfix plugin permissions Backport plugin permissions in the workspace Sep 29, 2025
@utkaka utkaka marked this pull request as ready for review September 29, 2025 09:29
@utkaka utkaka requested review from Copilot and lexiv0re September 29, 2025 09:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR restores permission-based restrictions from v6 by implementing a comprehensive permissions system to forbid creation of certain workspace entities. It introduces workspace-level permissions that prevent users from creating projects, teamspaces, drives, funnels, and vacancies.

  • Implements workspace-scoped permission checking in the middleware
  • Adds new "forbid" permissions for create operations on major entity types
  • Updates UI components to use a unified HeaderButton with permission-aware actions

Reviewed Changes

Copilot reviewed 85 out of 87 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
server/middleware/src/spacePermissions.ts Refactors permission checking to support workspace permissions with forbid logic
plugins/*/src/index.ts Adds permission definitions and string constants for forbid create permissions
models/*/src/permissions.ts Defines workspace-level forbid permissions for entity creation
plugins/*-resources/src/components/*Header.svelte Replaces custom button implementations with unified HeaderButton component
packages/ui/src/components/HeaderButton.svelte New unified header button component with permission checking
tests/sanity/tests/**/*.ts Updates test selectors from generic IDs to specific string constants

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@utkaka utkaka merged commit 764d963 into develop Sep 30, 2025
15 checks passed
@BykhovDenis BykhovDenis deleted the qfix-plugin-permissions branch October 22, 2025 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants