Author: jfthomps
Date: Wed Jun 1 14:46:14 2016
New Revision: 1746472
URL: http://svn.apache.org/viewvc?rev=1746472&view=rev
Log:
VCL-946 - add image revision to manage computers page
utils.php: modified getComputers: added ir.revision AS imagerevision to query
computers.php:
-modified fieldWidth: added case for imagerevision (also added cases for
procnumber and ram to decrease the amount of space those columns took up)
-modified fieldDisplayName: added case for imagerevision
Modified:
vcl/trunk/web/.ht-inc/computer.php
vcl/trunk/web/.ht-inc/utils.php
Modified: vcl/trunk/web/.ht-inc/computer.php
URL:
http://svn.apache.org/viewvc/vcl/trunk/web/.ht-inc/computer.php?rev=1746472&r1=1746471&r2=1746472&view=diff
==============================================================================
--- vcl/trunk/web/.ht-inc/computer.php (original)
+++ vcl/trunk/web/.ht-inc/computer.php Wed Jun 1 14:46:14 2016
@@ -94,6 +94,13 @@ class Computer extends Resource {
case 'eth1macaddress':
$w = 8.5;
break;
+ case 'procnumber':
+ $w = 3.5;
+ break;
+ case 'imagerevision':
+ case 'ram':
+ $w = 4.5;
+ break;
case 'vmhost':
case 'nathost':
$w = 8;
@@ -139,6 +146,8 @@ class Computer extends Resource {
switch($field) {
case 'currentimg':
return 'Current Image';
+ case 'imagerevision':
+ return 'Image Revision';
case 'nextimg':
return 'Next Image';
case 'ram':
Modified: vcl/trunk/web/.ht-inc/utils.php
URL:
http://svn.apache.org/viewvc/vcl/trunk/web/.ht-inc/utils.php?rev=1746472&r1=1746471&r2=1746472&view=diff
==============================================================================
--- vcl/trunk/web/.ht-inc/utils.php (original)
+++ vcl/trunk/web/.ht-inc/utils.php Wed Jun 1 14:46:14 2016
@@ -8238,6 +8238,7 @@ function getComputers($sort=0, $included
. "cur.prettyname AS currentimg, "
. "c.currentimageid AS currentimgid, "
. "c.imagerevisionid, "
+ . "ir.revision AS imagerevision, "
. "next.prettyname AS nextimg, "
. "c.nextimageid AS nextimgid, "
. "c.RAM AS ram, "
@@ -8284,6 +8285,7 @@ function getComputers($sort=0, $included
. "LEFT JOIN nathostcomputermap nm ON (nm.computerid = c.id) "
. "LEFT JOIN nathost nh ON (nm.nathostid = nh.id) "
. "LEFT JOIN nathost nh2 ON (r.id = nh2.resourceid) "
+ . "LEFT JOIN imagerevision ir ON (c.imagerevisionid = ir.id) "
. "WHERE c.stateid = st.id AND "
. "c.platformid = p.id AND "
. "c.scheduleid = sc.id AND "