Révision bbd1f783
Ajouté par Phil Davis il y a plus de 9 ans
usr/local/www/firewall_aliases_edit.php | ||
---|---|---|
7 | 7 |
Copyright (C) 2010 Jim Pingle |
8 | 8 |
All rights reserved. |
9 | 9 |
|
10 |
originially part of m0n0wall (http://m0n0.ch/wall)
|
|
10 |
originally part of m0n0wall (http://m0n0.ch/wall) |
|
11 | 11 |
Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>. |
12 | 12 |
All rights reserved. |
13 | 13 |
|
... | ... | |
476 | 476 |
} |
477 | 477 |
EOD; |
478 | 478 |
|
479 |
$network_str = gettext("Network"); |
|
479 |
$network_str = gettext("Network or FQDN");
|
|
480 | 480 |
$networks_str = gettext("Network(s)"); |
481 | 481 |
$cidr_str = gettext("CIDR"); |
482 | 482 |
$description_str = gettext("Description"); |
483 | 483 |
$hosts_str = gettext("Host(s)"); |
484 |
$ip_str = gettext("IP"); |
|
484 |
$ip_str = gettext("IP or FQDN");
|
|
485 | 485 |
$ports_str = gettext("Port(s)"); |
486 | 486 |
$port_str = gettext("Port"); |
487 | 487 |
$url_str = gettext("URL (IPs)"); |
... | ... | |
513 | 513 |
document.getElementById ("onecolumn").firstChild.data = "{$network_str}"; |
514 | 514 |
document.getElementById ("twocolumn").firstChild.data = "{$cidr_str}"; |
515 | 515 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
516 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
516 | 517 |
document.getElementById ("itemhelp").firstChild.data = "{$networks_help}"; |
517 | 518 |
document.getElementById ("addrowbutton").style.display = 'block'; |
518 | 519 |
} else if(selected == '{$hosts_str}') { |
... | ... | |
520 | 521 |
document.getElementById ("onecolumn").firstChild.data = "{$ip_str}"; |
521 | 522 |
document.getElementById ("twocolumn").firstChild.data = ""; |
522 | 523 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
524 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
523 | 525 |
document.getElementById ("itemhelp").firstChild.data = "{$hosts_help}"; |
524 | 526 |
document.getElementById ("addrowbutton").style.display = 'block'; |
525 | 527 |
} else if(selected == '{$ports_str}') { |
... | ... | |
527 | 529 |
document.getElementById ("onecolumn").firstChild.data = "{$port_str}"; |
528 | 530 |
document.getElementById ("twocolumn").firstChild.data = ""; |
529 | 531 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
532 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
530 | 533 |
document.getElementById ("itemhelp").firstChild.data = "{$ports_help}"; |
531 | 534 |
document.getElementById ("addrowbutton").style.display = 'block'; |
532 | 535 |
} else if(selected == '{$url_str}') { |
... | ... | |
534 | 537 |
document.getElementById ("onecolumn").firstChild.data = "{$url_str}"; |
535 | 538 |
document.getElementById ("twocolumn").firstChild.data = ""; |
536 | 539 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
540 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
537 | 541 |
document.getElementById ("itemhelp").firstChild.data = "{$url_help}"; |
538 | 542 |
document.getElementById ("addrowbutton").style.display = 'block'; |
539 | 543 |
} else if(selected == '{$url_ports_str}') { |
... | ... | |
541 | 545 |
document.getElementById ("onecolumn").firstChild.data = "{$url_ports_str}"; |
542 | 546 |
document.getElementById ("twocolumn").firstChild.data = ""; |
543 | 547 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
548 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
544 | 549 |
document.getElementById ("itemhelp").firstChild.data = "{$url_ports_help}"; |
545 | 550 |
document.getElementById ("addrowbutton").style.display = 'block'; |
546 | 551 |
} else if(selected == '{$openvpn_user_str}') { |
... | ... | |
548 | 553 |
document.getElementById ("onecolumn").firstChild.data = "{$openvpn_str}"; |
549 | 554 |
document.getElementById ("twocolumn").firstChild.data = "{$openvpn_freq}"; |
550 | 555 |
document.getElementById ("threecolumn").firstChild.data = "{$description_str}"; |
556 |
document.getElementById ("threecolumn").style.display = 'block'; |
|
551 | 557 |
document.getElementById ("itemhelp").firstChild.data = "{$openvpn_help}"; |
552 | 558 |
document.getElementById ("addrowbutton").style.display = 'block'; |
553 | 559 |
} else if(selected == '{$urltable_str}') { |
Formats disponibles : Unified diff
firewall_aliases_edit UI text changes
If type URL Table then the heading "Description" on the 3rd column gets suppressed (I am not really sure why that is, since the description data entry box still appears - I guess someone intended that the data entry box itself also be suppressed, since URL Table takes just a single line entry, the overall description of the alias should be enough - no need for a per-line description.)
In any case, if the user then selects some other Alias Type, the "Description" heading on the 3rd column is not re-enabled.
This change fixes that.
I also implemented what is suggested in Redmine #3893 - making the 1st column heading say "IP or FQDN", "Network or FQDN". IMHO that looks fine on the UI and cannot do any harm. (and yes, the longer explanatory text already tells the user that an FQDN is allowed in these cases.)