base implementation of user setting

This commit is contained in:
Matthias 2021-07-22 23:50:09 +02:00
parent 3f6c7df7a8
commit 5f2bef7ee1
2 changed files with 12 additions and 4 deletions

View File

@ -762,10 +762,10 @@ class InvenTreeUserSetting(BaseInvenTreeSetting):
""" """
GLOBAL_SETTINGS = { GLOBAL_SETTINGS = {
'PART_ASSEMBLY': { 'HOMEPAGE_PART_STARRED': {
'name': _('Assembly'), 'name': _('Show starred parts'),
'description': _('Parts can be assembled from other components by default'), 'description': _('Show starred parts on the homepage'),
'default': False, 'default': True,
'validator': bool, 'validator': bool,
}, },
} }

View File

@ -63,5 +63,13 @@
</form> </form>
</div> </div>
<h4>{% trans "User Settings" %}</h4>
<table class='table table-striped table-condensed'>
{% include "InvenTree/settings/header.html" %}
<tbody>
{% include "InvenTree/settings/setting.html" with key="HOMEPAGE_PART_STARRED" user_setting=True %}
</tbody>
</table>
{% endblock %} {% endblock %}