Hi Erik,Thank you for sharing, I might see about trying this with the version we have installed. Would be interesting to see if the code for these pages have changed to try this.
Thanks Joe On 9/7/2010 3:46 AM, Erik Weber wrote:
On Tue, Sep 7, 2010 at 2:25 AM, Joseph Hardeman<jwhardeman@xxxxxxxxx> wrote:Hi Guys, I was curious, is there an easy way to change the color of a device placed in a rack? I was thinking about doing some color coding depending on the type of device in a rack.I did something like that once (to view 'reserved' space with a different color, red in this case). It's an ugly hack, and doesn't give any UI because we do all the tampering in the database. What I did (as far as I can recall), this is for 0.14.12 so file locations may have changed: * Changed some code (index.php, render_image.php, render_rack_thumb.php atleast) to add another statecode, thus "foreach (array ('F', 'A', 'U', 'T', 'Th', 'Tw', 'Thw') as $statecode)" became "foreach (array ('F', 'A', 'U', 'T', 'Th', 'Tw', 'Thw', 'R') as $statecode)" Notice the new statecode, 'R' for reserved. * Added a row to Config-table; varname: color_R varvalue: ff0000 vartype: string emptyok: no is_hidden: yes description: Reserved Atoms 1 row in set (0.01 sec) To actually change color on object, change it's state in RackSpace to 'R' or whatever value you gave your new color. I might have forgotten something, and it does lack GUI functions (we populate racktables from our CMDB, not by hand).