mirror of
https://github.com/RaspAP/raspap-webgui.git
synced 2024-11-22 07:30:23 +00:00
Remove valid RASPI_5GHZ_ISO_ALPHA2 country, set hwModeDisabled
This commit is contained in:
parent
e16c69c446
commit
5e802e8a0b
2 changed files with 3 additions and 13 deletions
|
@ -881,12 +881,12 @@ function getCountryCodes($locale = 'en', $flag = true) {
|
|||
if (count($parts) >= 2) {
|
||||
$countryCode = $parts[0];
|
||||
if ($flag) {
|
||||
$countryFlag = $parts[3] . ' ';
|
||||
$countryName = $parts[4];
|
||||
$countryFlag = $parts[3];
|
||||
$countryName = $parts[4] .' ';
|
||||
} else {
|
||||
$countryName = $parts[3];
|
||||
}
|
||||
$countryData[$countryCode] = $countryFlag .$countryName;
|
||||
$countryData[$countryCode] = $countryName.$countryFlag;
|
||||
}
|
||||
}
|
||||
return $countryData;
|
||||
|
|
|
@ -117,7 +117,6 @@ function DisplayHostAPDConfig()
|
|||
}
|
||||
}
|
||||
|
||||
$countries_5Ghz_max48ch = RASPI_5GHZ_ISO_ALPHA2;
|
||||
$selectedHwMode = $arrConfig['hw_mode'];
|
||||
if (isset($arrConfig['ieee80211n'])) {
|
||||
if (strval($arrConfig['ieee80211n']) === '1') {
|
||||
|
@ -134,14 +133,6 @@ function DisplayHostAPDConfig()
|
|||
$selectedHwMode = 'w';
|
||||
}
|
||||
}
|
||||
if (!in_array($arrConfig['country_code'], $countries_5Ghz_max48ch)) {
|
||||
$hwModeDisabled = 'ac';
|
||||
if ($selectedHwMode === $hwModeDisabled) {
|
||||
unset($selectedHwMode);
|
||||
}
|
||||
} else {
|
||||
$hwModeDisabled = null;
|
||||
}
|
||||
|
||||
echo renderTemplate(
|
||||
"hostapd", compact(
|
||||
|
@ -160,7 +151,6 @@ function DisplayHostAPDConfig()
|
|||
"arrHostapdConf",
|
||||
"operatingSystem",
|
||||
"selectedHwMode",
|
||||
"hwModeDisabled",
|
||||
"countryCodes"
|
||||
)
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue