Changeset 7819 for main/waeup.kofa/trunk/src/waeup/kofa/hostels
- Timestamp:
- 8 Mar 2012, 22:28:46 (13 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa/hostels
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/hostels/browser.py
r7811 r7819 23 23 from zope.component import getUtility 24 24 from waeup.kofa.browser import ( 25 K OFAEditFormPage, KOFAAddFormPage, KOFADisplayFormPage,25 KofaEditFormPage, KofaAddFormPage, KofaDisplayFormPage, 26 26 NullValidator) 27 27 from waeup.kofa.browser.breadcrumbs import Breadcrumb … … 32 32 ManageActionButton, PrimaryNavTab) 33 33 from waeup.kofa.browser.layout import jsaction, action 34 from waeup.kofa.interfaces import IK OFAObject, IKOFAUtils34 from waeup.kofa.interfaces import IKofaObject, IKofaUtils 35 35 from waeup.kofa.interfaces import MessageFactory as _ 36 36 from waeup.kofa.hostels.vocabularies import NOT_OCCUPIED … … 61 61 """ 62 62 63 grok.context(IK OFAObject)63 grok.context(IKofaObject) 64 64 grok.order(5) 65 65 grok.require('waeup.viewHostels') … … 96 96 mapping = {'a':co[1], 'b':co[2], 'c':co[3]}) 97 97 98 class HostelsContainerPage(K OFADisplayFormPage):98 class HostelsContainerPage(KofaDisplayFormPage): 99 99 """The standard view for hostels containers. 100 100 """ … … 113 113 text = _('Manage accommodation section') 114 114 115 class HostelsContainerManagePage(K OFADisplayFormPage):115 class HostelsContainerManagePage(KofaDisplayFormPage): 116 116 """The manage page for hostel containers. 117 117 """ … … 148 148 return 149 149 150 class HostelAddFormPage(K OFAAddFormPage):150 class HostelAddFormPage(KofaAddFormPage): 151 151 """Add-form to add a hostel. 152 152 """ … … 175 175 return 176 176 177 class HostelDisplayFormPage(K OFADisplayFormPage):177 class HostelDisplayFormPage(KofaDisplayFormPage): 178 178 """ Page to display hostel data 179 179 """ … … 196 196 target = 'manage' 197 197 198 class HostelManageFormPage(K OFAEditFormPage):198 class HostelManageFormPage(KofaEditFormPage): 199 199 """ View to edit hostel data 200 200 """ … … 261 261 switched = [] # for log file 262 262 switched_translated = [] # for flash message 263 portal_language = getUtility(IK OFAUtils).PORTAL_LANGUAGE263 portal_language = getUtility(IKofaUtils).PORTAL_LANGUAGE 264 264 preferred_language = self.request.cookies.get( 265 265 'kofa.language', portal_language) … … 306 306 return 307 307 308 class BedManageFormPage(K OFAEditFormPage):308 class BedManageFormPage(KofaEditFormPage): 309 309 """ View to edit bed data 310 310 """ -
main/waeup.kofa/trunk/src/waeup/kofa/hostels/interfaces.py
r7811 r7819 18 18 from zope.interface import invariant, Invalid 19 19 from zope import schema 20 from waeup.kofa.interfaces import IK OFAObject20 from waeup.kofa.interfaces import IKofaObject 21 21 from waeup.kofa.interfaces import MessageFactory as _ 22 22 from waeup.kofa.hostels.vocabularies import ( 23 23 bed_letters, blocks, special_handling, StudentSource) 24 24 25 class IHostelsContainer(IK OFAObject):25 class IHostelsContainer(IKofaObject): 26 26 """A container for all kind of hostel objects. 27 27 28 28 """ 29 29 30 class IHostel(IK OFAObject):30 class IHostel(IKofaObject): 31 31 """A base representation of hostels. 32 32 … … 146 146 raise Invalid(_('Bed categories overlap.')) 147 147 148 class IBed(IK OFAObject):148 class IBed(IKofaObject): 149 149 """A base representation of beds. 150 150 -
main/waeup.kofa/trunk/src/waeup/kofa/hostels/vocabularies.py
r7811 r7819 22 22 from zope.catalog.interfaces import ICatalog 23 23 from zc.sourcefactory.contextual import BasicContextualSourceFactory 24 from waeup.kofa.interfaces import SimpleK OFAVocabulary24 from waeup.kofa.interfaces import SimpleKofaVocabulary 25 25 from waeup.kofa.interfaces import MessageFactory as _ 26 26 … … 54 54 return "%s - %s" % (value, self.acco_students(context)[value]) 55 55 56 bed_letters = SimpleK OFAVocabulary(56 bed_letters = SimpleKofaVocabulary( 57 57 (_('Bed A'),'A'), 58 58 (_('Bed B'),'B'), … … 66 66 ) 67 67 68 blocks = SimpleK OFAVocabulary(68 blocks = SimpleKofaVocabulary( 69 69 (_('Block A'),'A'), 70 70 (_('Block B'),'B'), … … 84 84 ) 85 85 86 special_handling = SimpleK OFAVocabulary(86 special_handling = SimpleKofaVocabulary( 87 87 (_('Regular Hostel'),'regular'), 88 88 (_('Blocked Hostel'),'blocked'),
Note: See TracChangeset for help on using the changeset viewer.