Adds support for conditionally disabling VM creation.
authorPeter Iannucci <iannucci@mit.edu>
Tue, 5 Oct 2010 00:55:13 +0000 (20:55 -0400)
committerPeter Iannucci <iannucci@mit.edu>
Tue, 5 Oct 2010 00:55:13 +0000 (20:55 -0400)
code/main.py
code/templates/list.mako
debian/changelog

index f2ee6d1..f754ca0 100755 (executable)
@@ -459,7 +459,8 @@ def getListDict(username, state):
              defaults=defaults,
              machines=machines,
              has_vnc=has_vnc,
-             installing=installing)
+             installing=installing,
+             disable_creation=True)
     return d
 
 def getHostname(nic):
index d71792a..3d0c50c 100644 (file)
@@ -81,7 +81,15 @@ ${self.fn.cdromList(defaults.cdrom, "$('cd_or_auto_cd').checked = true;$('autoin
        </tr>
        ${self.fn.errorRow('owner', err)}
       </table>
-      <input type="submit" class="button" value="Create it!"/><br />
+      <input type="submit" class="button" value="Create it!" \
+% if disable_creation:
+ disabled="disabled" \
+% endif
+/> \
+% if disable_creation:
+&nbsp;<span style="color:red;">VM creation is currently disabled due to lack of disk space.</span> \
+%endif
+<br />
       Windows notes: ${self.fn.helppopup('Windows')}
     </form>
 % endif
index e416f92..4e22229 100644 (file)
@@ -1,3 +1,9 @@
+invirt-web (0.1.9) unstable; urgency=low
+
+  * Adds support for disabling (conditionally) VM creation in list.mako, main.py
+
+ -- Peter A. Iannucci <iannucci@mit.edu>  Mon, 04 Oct 2010 20:54:10 -0400
+
 invirt-web (0.1.8) lucid; urgency=low
 
   [ Andrew M. Farrell ]