Skip to content

Fixes #39533 - "View task" disabled when job is running - #1044

Closed
MariaAga wants to merge 2 commits into
theforeman:masterfrom
MariaAga:view-task-perms
Closed

Fixes #39533 - "View task" disabled when job is running#1044
MariaAga wants to merge 2 commits into
theforeman:masterfrom
MariaAga:view-task-perms

Conversation

@MariaAga

Copy link
Copy Markdown
Member

include_permissions wasnt present in every api call when job is running, causing the view task button to be disabled as it didnt have permissions data.
Also just removed the usage of include_permissions api requests for permissions, as all permissions are loaded to the foreman metadata.

@kmalyjur
kmalyjur self-requested a review July 21, 2026 10:27

@kmalyjur kmalyjur left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Works as it should.

In webpack/JobInvocationDetail/__tests__/TemplateInvocation.test.js, lines 198-202 (permissions) are now unused and could be deleted.

In webpack/JobInvocationDetail/__tests__/fixtures.js, the export const mockPermissionsData seems to be unused, too.

@MariaAga

Copy link
Copy Markdown
Member Author

Thanks! removed it, js tests are passing locally

@kmalyjur

kmalyjur commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

@MariaAga Thank you. Additionally, I see that when I have a user with only one permission view_job_invocations, on master the "View task" button is disabled, but on this branch it's enabled. I think that it's not intended, right?

@MariaAga

Copy link
Copy Markdown
Member Author

I cant reproduce this issue anymore so closing. Couldnt see anything that would have fixed it recently, so not sure if my env just had issues.

@MariaAga MariaAga closed this Jul 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants