-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Migrate application settings to model #313
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
Conversation
…file, change format for severity presentation
@patriknordlen thank you so much for doing this! Will clone and review shortly. |
@patriknordlen just wanted to provide an update. Will be able to clone and review on Wednesday |
Cool! Don't sweat it :) |
Hi @patriknordlen thank you again for working on this! July 5th load the systems settings fixture `python manage.py loaddata system_settings.json' I'm happy to merge as is though and due the documentation if that is confusing / you don't want to :) |
Thanks for the review @devGregA! I'll go make the documentation changes tomorrow and submit, so let's do the merge after that. :) |
@devGregA documentation added - please have a look. |
dojo/templates/dojo/view_eng.html
Outdated
<span class="text-error"> | ||
{% else %}<span>{% endif %}{{ finding.severity }}</span></td> | ||
<td> | ||
<span class="label severity severity-{{ finding.severity|safe }}"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@patriknordlen last question I promise 😂 , would you please explain this change? I understand the nav / label changes but I'm not sure why we're marking the severity as safe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haha, that's ok! 😄
That's a good catch, it's from my initial misunderstanding of what the safe function did 🙄
I'll change that and go through any other uses of |safe in my commits to make sure they're actually needed!
There, done! |
@patriknordlen merged :) |
This PR addresses (or at least attempts to address :) ) #215.
It adds the model "System_Settings" for keeping system settings in the database, along with views and forms to change them in the web UI.
Also changes have been made to all components using these settings so that they refer to the settings from the model rather than settings.py.
Settings that have been added to the model and migrated in the application are:
Settings that are missing from this PR that were part of the original issue:
Caveats:
There's, uh, also a couple of additional commits related to look and feel + bug fixes:
I'm used to straight and honest PR feedback so don't hold back - I'm new at contributing to this project and I'm sure I've gotten a thing or two wrong.