コード例 #1
0
class PrivateTitleFields(widgets.WidgetsList):
    import operator
    preferred_distributor = widgets.TextField()
    title_id = widgets.HiddenField()
    all_sections = [(l.id, l.sectionName) for l in list(Section.select())]
    all_sections.sort(key=operator.itemgetter(1))
    sections = widgets.CheckBoxList(options=all_sections, field_class='inline')
コード例 #2
0
 def sections(self):
     return dict(authorswidget=AuthorsWidget(),titlelistwidget=TitleListWidget(),sections=Section.select("1=1",orderBy="section_name"),the_sections=False)
コード例 #3
0
 def sections(self):
     return dict(authorswidget=AuthorsWidget(),
                 titlelistwidget=TitleListWidget(),
                 sections=Section.select("1=1", orderBy="section_name"),
                 the_sections=False)