]> git.ipfire.org Git - people/teissler/ipfire-2.x.git/commitdiff
Firewall: fixed colors of target column when using standard networks
authorAlexander Marx <amarx@ipfire.org>
Sun, 10 Nov 2013 08:28:02 +0000 (09:28 +0100)
committerMichael Tremer <michael.tremer@ipfire.org>
Tue, 12 Nov 2013 23:29:21 +0000 (00:29 +0100)
When using RED, OpenVPN-Dyn or IPsec RW as target, the column was not
colored.

html/cgi-bin/firewall.cgi

index 3e4e3b0eb7df694e3f86adb1d5a4f8c30b938fbe..80989ce58662ddbca0950f79f26daba2e91b8a0a 100755 (executable)
@@ -1376,6 +1376,12 @@ sub getcolor
                }elsif ($val eq 'IPFire' ){
                        $tdcolor="style='background-color: $Header::colourred;color:white;'";
                        return;
+               }elsif ($val eq 'OpenVPN-Dyn' ){
+                       $tdcolor="style='background-color: $Header::colourovpn;color:white;'";
+                       return;
+               }elsif ($val eq 'IPsec RW' ){
+                       $tdcolor="style='background-color: $Header::colourvpn;color:white;'";
+                       return;
                }elsif($val =~ /^(.*?)\/(.*?)$/){
                        my ($sip,$scidr) = split ("/",$val);
                        if ( &General::IpInSubnet($sip,$netsettings{'ORANGE_ADDRESS'},$netsettings{'ORANGE_NETMASK'})){
@@ -2600,7 +2606,7 @@ END
                        if ($$hash{$key}[5] eq 'std_net_tgt' || $$hash{$key}[5] eq 'ipfire'  || $$hash{$key}[6] eq 'RED1' || $$hash{$key}[6] eq 'GREEN' || $$hash{$key}[6] eq 'ORANGE' || $$hash{$key}[6] eq 'BLUE' ){
                                if ($$hash{$key}[6] eq 'RED1'){
                                        print "$ipfireiface $Lang::tr{'red1'}";
-                               }elsif ($$hash{$key}[6] eq 'GREEN' || $$hash{$key}[6] eq 'ORANGE' || $$hash{$key}[6] eq 'BLUE'|| $$hash{$key}[6] eq 'ALL')
+                               }elsif ($$hash{$key}[6] eq 'GREEN' || $$hash{$key}[6] eq 'ORANGE' || $$hash{$key}[6] eq 'BLUE'|| $$hash{$key}[6] eq 'ALL' || $$hash{$key}[6] eq 'RED')
                                {
                                        print "$ipfireiface ".&get_name($$hash{$key}[6]);
                                }else{