Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(2728): gray out the Restart button for jobs that are disabled on the build details page #808

Merged
merged 2 commits into from
Aug 9, 2022

Conversation

yk634
Copy link
Contributor

@yk634 yk634 commented Aug 8, 2022

Context

As per the comment in screwdriver-cd/models#555 (review), it would be preferable to have a UI where disabled jobs cannot be Restarted from the Build Details page.

Objective

Fix the Restart button to be grayed out on the build details page of a disable job.

  • While waiting for model.pipeline.jobs to fetch, isButtonDisabledLoaded is false and the Restart button is grayed out regardless of its state.
    • The time to wait for this fetch does not occur when transitioning from tooltip, but occurs slightly when the build detail page is accessed directly.

References

License

I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.

Copy link
Member

@jithine jithine left a comment

Choose a reason for hiding this comment

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

This is great. Can we extend this to Start button as well ? Can UI determine, if there are no jobs to start then grey it out ? (It's scenario 1 here screwdriver-cd/screwdriver#2749 (comment))

@yk634
Copy link
Contributor Author

yk634 commented Aug 9, 2022

@jithine

This is great. Can we extend this to Start button as well ? Can UI determine, if there are no jobs to start then grey it out ? (It's scenario 1 here screwdriver-cd/screwdriver#2749 (comment))

I certainly think it's a good idea to have the Start button grayed out as well.

However, to gray out the Start button would require a different logic than this PR and would be difficult to extend immediately.

@tkyi tkyi merged commit 83105bd into screwdriver-cd:master Aug 9, 2022
@ibu1224 ibu1224 deleted the yukaneda-patch-1 branch August 9, 2022 23:30
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.

6 participants