Changeset 12508 for main/ikobacustom.pcn
- Timestamp:
- 22 Jan 2015, 19:50:49 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/ikobacustom.pcn/trunk/src/ikobacustom/pcn/customers/interfaces.py
r12501 r12508 19 19 from zope import schema 20 20 from datetime import datetime 21 from zc.sourcefactory.basic import BasicSourceFactory 21 22 from waeup.ikoba.interfaces import IIkobaObject 22 23 from waeup.ikoba.customers.interfaces import ( … … 34 35 return range(curr_year - 2, curr_year + 5) 35 36 37 class PracticeSource(BasicSourceFactory): 38 """A source for categories of practice. 39 """ 40 def getValues(self): 41 return [ 42 'academic', 43 'administrative', 44 'distribution', 45 'importation', 46 'manufacturing', 47 'retail and dispensing', 48 'wholesale', 49 ] 50 51 36 52 class IPCNCustomer(ICustomer): 37 53 """Representation of a customer. … … 110 126 ) 111 127 112 category_practice = schema.TextLine( 113 title = _(u'Category of Practice'), 114 description = _(u'academic, retail and dispensing, hospital, administrative, wholesale, importation, manufacturing, etc.'), 115 required = False, 128 categories_practice = schema.List( 129 title = _(u'Categories of Practice'), 130 value_type = schema.Choice(source=PracticeSource()), 131 required = False, 132 default = [], 116 133 ) 117 134 … … 129 146 130 147 class IRONContractOfficialUse(IIkobaObject): 131 """Interface for editing RO P data by customers.148 """Interface for editing RON official use data. 132 149 133 150 """ … … 173 190 ) 174 191 175 category_practice = schema.TextLine( 176 title = _(u'Category of Practice'), 177 description = _(u'retail and dispensing, wholesale, importation, manufacturing, distribution etc.'), 178 required = False, 192 categories_practice = schema.List( 193 title = _(u'Categories of Practice'), 194 value_type = schema.Choice(source=PracticeSource()), 195 required = False, 196 default = [], 179 197 ) 180 198 181 199 premises_certificate = schema.TextLine( 182 200 title = _(u'Last Premises Certificate'), 183 description= _('If an old premises .state the last premises certificate number issued with date.'),201 description= _('If an old premises, state the last premises certificate number issued with date.'), 184 202 required = False, 185 203 ) … … 232 250 233 251 class IROPContractOfficialUse(IIkobaObject): 234 """Interface for editing ROP data by customers.252 """Interface for editing ROP official use data. 235 253 236 254 """
Note: See TracChangeset for help on using the changeset viewer.