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

Extend reports to perform post-run actions #1631

Closed
cslingerland opened this issue Oct 20, 2017 · 3 comments
Closed

Extend reports to perform post-run actions #1631

cslingerland opened this issue Oct 20, 2017 · 3 comments
Labels
type: feature Introduction of new functionality to the application

Comments

@cslingerland
Copy link

Issue type

[x ] Feature request
[ ] Bug report
[ ] Documentation

Environment

  • Python version:
  • NetBox version:

Description

Would it be possible to setup some form of emailing of reports, or an indication that a report was run? This would be good so that management doesn't have to go into Netbox and parse out what they're looking for, and then run the report. I don't think the database would need to be touched unless you wanted to track emails sent.

@jeremystretch
Copy link
Member

There will likely be many things people want to do after running a report: sending an email, writing a log, calling a webhook, etc. These are all possible now by overriding the run() method, but it would be more convenient to add a post_run() method which report authors can more easily extend.

Related, here's an example showing how to send email in Django. The configured list of administrators is available at django.conf.settings.ADMINS.

@jeremystretch jeremystretch changed the title Report Emails Extend reports to perform post-run actions Oct 23, 2017
@jeremystretch jeremystretch added the type: feature Introduction of new functionality to the application label Oct 23, 2017
@lampwins
Copy link
Contributor

Given there there is consensus that #81 will rely on Django signals, would it also be prudent is put in the effort here to fire signals on report completion?

@jeremystretch
Copy link
Member

@lampwins I'll defer the signals work until we have a chance to take a look at the whole project and go through adding signals everywhere they need to be, for both #81 and #1127.

@lock lock bot locked as resolved and limited conversation to collaborators Jan 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: feature Introduction of new functionality to the application
Projects
None yet
Development

No branches or pull requests

3 participants