Changeset 2424 for package_branches/invirt-web/cherrypy/code/main.py
- Timestamp:
- Aug 10, 2009, 12:41:46 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
package_branches/invirt-web/cherrypy/code/main.py
r2423 r2424 148 148 149 149 def parseCreate(self, fields): 150 kws = dict([(kw, fields.get(kw)) for kw in 'name description owner memory disksize vmtype cdrom autoinstall'.split() ])150 kws = dict([(kw, fields.get(kw)) for kw in 'name description owner memory disksize vmtype cdrom autoinstall'.split() if fields.get(kw)]) 151 151 validate = validation.Validate(cherrypy.request.login, cherrypy.request.state, strict=True, **kws) 152 152 return dict(contact=cherrypy.request.login, name=validate.name, description=validate.description, memory=validate.memory, … … 375 375 on = {} 376 376 has_vnc = {} 377 installing = {} 377 378 xmlist = state.xmlist 378 379 checkpoint.checkpoint('Got uptimes') 379 can_clone = 'ice3' not in state.xmlist_raw380 380 for m in machines: 381 381 if m not in xmlist: … … 390 390 else: 391 391 has_vnc[m] = "ParaVM" 392 if xmlist[m].get('autoinstall'): 393 installing[m] = True 394 else: 395 installing[m] = False 392 396 max_memory = validation.maxMemory(username, state) 393 397 max_disk = validation.maxDisk(username) … … 407 411 machines=machines, 408 412 has_vnc=has_vnc, 409 can_clone=can_clone)413 installing=installing) 410 414 return d 411 415
Note: See TracChangeset
for help on using the changeset viewer.