View Issue Details

IDProjectCategoryView StatusLast Update
2077RackTablesdefaultpublic2023-03-25 23:14
Reporteraprudente Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
Status newResolutionopen 
Product Version0.22.0 
Summary2077: Change color or image of the rack - add logo organization
DescriptionHi,
could you help me understand how I can change the background color or the image of the racks in the "Rackspace" page
then how to insert a logo instead of the name of the organization
thank you and congratulations for the excellent work.
TagsNo tags attached.
Attached Files
image.png (19,346 bytes)   
image.png (19,346 bytes)   

Activities

infrastation

infrastation

2023-03-25 23:14

administrator   ~0004479

There are two independent places that define rack colours. One is in "wwwroot/css/pi.css":
.state_F   { background-color: #8fbfbf; }
.state_A   { background-color: #bfbfbf; }
.state_U   { background-color: #bf8f8f; }
.state_T   { background-color: #408080; }
.state_Th  { background-color: #80ffff; }
.state_Tw  { background-color: #804040; }
.state_Thw { background-color: #ff8080; }

The above defines HTML colours. But the colour you want to modify is one of the PNG image colours, which are defined in "wwwroot/inc/solutions.php", function "printRackThumbImage()":
        $color = array
        (
                'F' => colorFromHex ($img, '8fbfbf'),
                'A' => colorFromHex ($img, 'bfbfbf'),
                'U' => colorFromHex ($img, 'bf8f8f'),
                'T' => colorFromHex ($img, '408080'),
                'Th' => colorFromHex ($img, '80ffff'),
                'Tw' => colorFromHex ($img, '804040'),
                'Thw' => colorFromHex ($img, 'ff8080'),
                'black' => colorFromHex ($img, '000000'),
        );

As you can see, the former is a subset of the latter, so in theory it might be better to have one definition in code and to generate the other in CSS. But in the current implementation it is two different sets, so you need to remember to keep the two in sync if you decide to make changes.

Issue History

Date Modified Username Field Change
2023-03-25 17:39 aprudente New Issue
2023-03-25 17:39 aprudente File Added: image.png
2023-03-25 23:14 infrastation Note Added: 0004479