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

16149 add (optional) obj hyperlink to script list table #16271

Merged
merged 5 commits into from
Jun 21, 2024

Conversation

arthanson
Copy link
Collaborator

@arthanson arthanson commented May 23, 2024

Fixes: #16149

  • Fix documentation to refer to obj instead of object
  • Add (optional) obj, url to script table (was only on reports table)
  • hyperlink the obj, url to the respective object when display
  • add the obj to the log message as documentation states and backwards compatability

@arthanson arthanson changed the title 16149 add (optional) obj hyperlink to script list table DRAFT: 16149 add (optional) obj hyperlink to script list table May 23, 2024
@arthanson arthanson changed the title DRAFT: 16149 add (optional) obj hyperlink to script list table 16149 add (optional) obj hyperlink to script list table May 23, 2024
@arthanson arthanson marked this pull request as ready for review May 23, 2024 22:17
@arthanson arthanson requested a review from jeremystretch May 23, 2024 22:17
Copy link
Member

@jeremystretch jeremystretch left a comment

Choose a reason for hiding this comment

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

This does not appear to resolve #16149; I see the same output in the script result before and after the change. Additionally, the table configuration button does not work on the script result view.

@arthanson
Copy link
Collaborator Author

This does not appear to resolve #16149; I see the same output in the script result before and after the change. Additionally, the table configuration button does not work on the script result view.

@jeremystretch I'm not seeing those issues? With the branch I get the configuration button, which you need to do as the object is an optional parameter. If you do add the parameter then you do get a clickable link (second screenshot). Is there a data condition I'm missing that is causing the config screen not to appear on yours?

Monosnap NewBranchScript | NetBox 2024-06-10 11-24-25
Monosnap NewBranchScript | NetBox 2024-06-10 11-24-40

@arthanson arthanson requested a review from jeremystretch June 10, 2024 18:27
@jeremystretch
Copy link
Member

@arthanson looks like the table configuration button is left in a broken state when the script first completes. It's functional on successive reloads. The modal content is likely missing on the first load.

Copy link
Member

@jeremystretch jeremystretch left a comment

Choose a reason for hiding this comment

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

Table configuration button is broken on completion of script execution. Also, we should probably make object a default table column.

@arthanson
Copy link
Collaborator Author

Made object default, the table configuration button wasn't working as the filter list is only included when the script finishes, so made the button dependent on that as well.

@arthanson arthanson requested a review from jeremystretch June 11, 2024 20:00
netbox/extras/scripts.py Outdated Show resolved Hide resolved
netbox/extras/tables/tables.py Outdated Show resolved Hide resolved
@arthanson arthanson requested a review from jeremystretch June 20, 2024 16:17
Copy link
Member

@jeremystretch jeremystretch left a comment

Choose a reason for hiding this comment

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

Thanks @arthanson!

@jeremystretch jeremystretch merged commit 85fd232 into develop Jun 21, 2024
6 checks passed
@jeremystretch jeremystretch deleted the 16149-script-list branch June 21, 2024 14:05
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Custom script logs are missing hyperlinks
2 participants