Skip to content

Commit

Permalink
Use a list for css classes col property, to be consistant with django…
Browse files Browse the repository at this point in the history
… way of doing it
  • Loading branch information
yohanboniface committed Apr 5, 2012
1 parent 1b15d67 commit 822d78b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions admin_tabs/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,17 @@ class AdminCol(object):
"""
One column in the admin pages.
"""
def __init__(self, fieldsets, name=None, css_id=None, css_class=None):
def __init__(self, fieldsets, name=None, css_id=None, css_classes=None):
"""
`css_classes`: list of css classes
"""
self.name = name
self._fieldsets = {} # names of fieldsets for now (real Fieldsets should be better)
for idx, fieldset in enumerate(fieldsets):
self.add_fieldset(fieldset, idx)
self.css_id = css_id
self.css_class = css_class
self.css_classes = css_classes

def add_fieldset(self, fieldset, position=None):
if not position:
position = len(self)
Expand Down

0 comments on commit 822d78b

Please sign in to comment.