Merge pull request #3595 from LinuxSuRen/fix-pipe-input-admin
Fix that devops admin users cannot approve a Pipeline input
This commit is contained in:
@@ -209,4 +209,6 @@ const (
|
||||
VerbGet = "get"
|
||||
// VerbWatch represents the verb of watching a resource
|
||||
VerbWatch = "watch"
|
||||
// VerbDelete represents the verb of deleting a resource
|
||||
VerbDelete = "delete"
|
||||
)
|
||||
|
||||
@@ -307,8 +307,9 @@ func (h *ProjectPipelineHandler) approvableCheck(nodes []clientDevOps.NodesDetai
|
||||
if userInfo, ok = request.UserFrom(pipe.Context); ok {
|
||||
createAuth := authorizer.AttributesRecord{
|
||||
User: userInfo,
|
||||
Verb: authorizer.VerbCreate,
|
||||
Verb: authorizer.VerbDelete,
|
||||
Workspace: pipe.Workspace,
|
||||
DevOps: pipe.ProjectName,
|
||||
Resource: "devopsprojects",
|
||||
ResourceRequest: true,
|
||||
ResourceScope: request.DevOpsScope,
|
||||
|
||||
Reference in New Issue
Block a user