Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
django-basetheme-bootstrap
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Bryan BRANCOTTE
django-basetheme-bootstrap
Commits
b1837f8c
Commit
b1837f8c
authored
5 years ago
by
Bryan BRANCOTTE
Browse files
Options
Downloads
Patches
Plain Diff
use preferences_groups order when available
parent
1dcc2d01
No related branches found
No related tags found
No related merge requests found
Pipeline
#26547
passed
5 years ago
Stage: test
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
basetheme_bootstrap/user_preferences.py
+7
-1
7 additions, 1 deletion
basetheme_bootstrap/user_preferences.py
setup.py
+1
-1
1 addition, 1 deletion
setup.py
with
8 additions
and
2 deletions
basetheme_bootstrap/user_preferences.py
+
7
−
1
View file @
b1837f8c
...
...
@@ -99,13 +99,19 @@ class UserPreferencesAbstractModel(models.Model):
@classmethod
def
get_allowed_fields
(
cls
):
if
cls
.
preferences_groups
is
not
None
:
for
group
,
fields
in
cls
.
preferences_groups
.
items
():
for
f
in
fields
:
yield
f
return
for
field_name
in
[
f
.
name
for
f
in
cls
.
_meta
.
get_fields
()]:
if
field_name
==
"
id
"
or
field_name
==
"
pk
"
or
field_name
==
"
user
"
:
continue
yield
field_name
@classmethod
@property
def
preferences_groups
(
self
):
def
preferences_groups
(
cls
):
return
None
@property
...
...
This diff is collapsed.
Click to expand it.
setup.py
+
1
−
1
View file @
b1837f8c
...
...
@@ -7,7 +7,7 @@ readme = open('README.rst').read()
setup
(
name
=
'
django-basetheme-bootstrap
'
,
version
=
'
0.2.2
8
'
,
version
=
'
0.2.2
9
'
,
description
=
'
Django Basetheme Bootstrap
'
,
long_description
=
readme
,
author
=
'
Bryan Brancotte
'
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment