Changeset 7819 for main/waeup.kofa/trunk/src/waeup/kofa/browser/layout.py
- Timestamp:
- 8 Mar 2012, 22:28:46 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/browser/layout.py
r7811 r7819 33 33 from zope.interface import Interface 34 34 from zope.site.hooks import getSite 35 from waeup.kofa.interfaces import IK OFAObject, IUserAccount35 from waeup.kofa.interfaces import IKofaObject, IUserAccount 36 36 from waeup.kofa.browser.interfaces import ITheme 37 from waeup.kofa.browser.theming import get_all_themes, K OFAThemeBase37 from waeup.kofa.browser.theming import get_all_themes, KofaThemeBase 38 38 from waeup.kofa.students.interfaces import IStudentNavigation 39 39 from waeup.kofa.applicants.interfaces import IApplicant … … 56 56 57 57 def __call__(self, success): 58 action = K OFAAction(self.label, success=success, **self.options)58 action = KofaAction(self.label, success=success, **self.options) 59 59 self.actions.append(action) 60 60 return action 61 61 62 class K OFAAction(Action):62 class KofaAction(Action): 63 63 64 64 def __init__(self, label, style='', **options): 65 super(K OFAAction, self).__init__(label, **options)65 super(KofaAction, self).__init__(label, **options) 66 66 self.style = style 67 67 … … 150 150 return True 151 151 152 class K OFALayout(UtilityView,Layout):152 class KofaLayout(UtilityView,Layout): 153 153 """A megrok.layout.Layout with additional methods. 154 154 """ 155 155 grok.baseclass() 156 156 157 class K OFAForm(UtilityView,Form):157 class KofaForm(UtilityView,Form): 158 158 """A megrok.layout.Form with additional methods. 159 159 """ … … 161 161 162 162 def setUpWidgets(self,ignore_request=False): 163 super(K OFAForm,self).setUpWidgets(ignore_request)163 super(KofaForm,self).setUpWidgets(ignore_request) 164 164 # Width parameters will be overridden by Bootstrap 165 165 # so we have to set the css class … … 171 171 self.widgets['body'].cssClass = 'span9' 172 172 173 class K OFAPage(UtilityView,Page):173 class KofaPage(UtilityView,Page): 174 174 """A megrok.layout page with additional methods. 175 175 """ 176 176 grok.baseclass() 177 177 178 class K OFADisplayFormPage(UtilityView,DisplayForm):178 class KofaDisplayFormPage(UtilityView,DisplayForm): 179 179 """A megrok.layout.DisplayForm with additional methods. 180 180 """ … … 182 182 template = default_waeup_display_template 183 183 184 class K OFAEditFormPage(UtilityView,EditForm):184 class KofaEditFormPage(UtilityView,EditForm): 185 185 """A megrok.layout.EditForm with additional methods. 186 186 """ … … 189 189 190 190 def setUpWidgets(self,ignore_request=False): 191 super(K OFAEditFormPage,self).setUpWidgets(ignore_request)191 super(KofaEditFormPage,self).setUpWidgets(ignore_request) 192 192 for widget in self.widgets: 193 193 if widget.__class__.__name__ == 'TextWidget': … … 207 207 self.widgets['perm_address'].height = 10 208 208 209 class K OFAAddFormPage(UtilityView,AddForm):209 class KofaAddFormPage(UtilityView,AddForm): 210 210 """A megrok.layout.AddForm with additional methods. 211 211 """ … … 213 213 template = default_waeup_edit_template 214 214 215 class SiteLayout(K OFALayout):215 class SiteLayout(KofaLayout): 216 216 """ The general site layout. 217 217 """ 218 grok.context(IK OFAObject)218 grok.context(IKofaObject) 219 219 220 220 #: An instance of the default theme to use for the site layout 221 default_theme = K OFAThemeBase()221 default_theme = KofaThemeBase() 222 222 stafftemp = grok.PageTemplateFile('templates/staffsitelayout.pt') 223 223 studenttemp = grok.PageTemplateFile('templates/studentsitelayout.pt')
Note: See TracChangeset for help on using the changeset viewer.