Mercurial > p > roundup > code
comparison roundup/cgi/templating.py @ 2057:d26e577f8a85 maint-0.6
backport from HEAD
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Fri, 27 Feb 2004 00:42:46 +0000 |
| parents | c0961f42d8f3 |
| children | fd4763c6efae |
comparison
equal
deleted
inserted
replaced
| 2055:e99367f7c11a | 2057:d26e577f8a85 |
|---|---|
| 308 # we don't exist | 308 # we don't exist |
| 309 if item == 'id': | 309 if item == 'id': |
| 310 return None | 310 return None |
| 311 | 311 |
| 312 # get the property | 312 # get the property |
| 313 prop = self._props[item] | 313 try: |
| 314 prop = self._props[item] | |
| 315 except KeyError: | |
| 316 raise KeyError, 'No such property "%s" on %s'%(item, self.classname) | |
| 314 | 317 |
| 315 # look up the correct HTMLProperty class | 318 # look up the correct HTMLProperty class |
| 316 form = self._client.form | 319 form = self._client.form |
| 317 for klass, htmlklass in propclasses: | 320 for klass, htmlklass in propclasses: |
| 318 if not isinstance(prop, klass): | 321 if not isinstance(prop, klass): |
