juci-wireless: adapt wireless to use option hidden
authorSukru Senli <sukru.senli@inteno.se>
Mon, 12 Mar 2018 17:16:07 +0000 (18:16 +0100)
committerSukru Senli <sukru.senli@inteno.se>
Mon, 12 Mar 2018 17:16:07 +0000 (18:16 +0100)
plugins/juci-wireless/po/sv.po
plugins/juci-wireless/src/pages/wireless-wps.js
plugins/juci-wireless/src/widgets/uci.wireless.interface.html
plugins/juci-wireless/src/widgets/uci.wireless.interface.js
plugins/juci-wireless/src/wireless.js

index fb68398..134a3bd 100644 (file)
@@ -204,7 +204,7 @@ msgstr "Interface"
 msgid "wifi-iface.up"
 msgstr "På"
 
-msgid "wifi-iface.closed"
+msgid "wifi-iface.hidden"
 msgstr "Öppet nätverk"
 
 msgid "wifi-iface.disabled"
index facc371..a04b122 100644 (file)
@@ -52,7 +52,7 @@ JUCI.app
        $scope.progress = 0;
        
        $scope.wpsUnlocked = function(interface){
-               return ["none", "psk2", "mixed-psk"].indexOf(interface.encryption.value) !== -1 && interface.closed.value === false;
+               return ["none", "psk2", "mixed-psk"].indexOf(interface.encryption.value) !== -1 && interface.hidden.value === false;
        }
        
        $wireless.getInterfaces().done(function(ifaces){
index 14f8610..110d281 100644 (file)
@@ -8,7 +8,7 @@
                        <juci-warning value="ssidwarning"></juci-warning>
                </juci-config-line>
                <juci-config-line title="{{'Broadcast SSID'|translate}}">
-                       <switch name="enabled" ng-model="interface.closed.value" on-change="onShowSSIDToggle()" class="green" inverted></switch>
+                       <switch name="enabled" ng-model="interface.hidden.value" on-change="onShowSSIDToggle()" class="green" inverted></switch>
                </juci-config-line>
                <juci-config-line title="{{'AP Isolation'|translate}}">
                        <switch name="enabled" ng-model="interface.isolate.value" class="green"></switch>
index bd7cba9..4f22f0b 100644 (file)
@@ -97,13 +97,13 @@ JUCI.app
                $scope.onSSIDChanged();
        });
 
-       $scope.$watch("interface.closed.value", function(value, oldvalue){
+       $scope.$watch("interface.hidden.value", function(value, oldvalue){
                if(!$scope.interface) return;
                if(value && value != oldvalue){
                        var text = $tr(gettext("If you disable SSID broadcasting, WPS function will be disabled as well. You will need to enable it manually later. Are you sure you want to continue?"));
                        if($scope.interface.wps_pbc.value && !confirm(text)){
                                setTimeout(function(){
-                                       $scope.interface.closed.value = oldvalue;
+                                       $scope.interface.hidden.value = oldvalue;
                                        $scope.$apply();
                                },0);
                        } else {
index 5c961fc..901072a 100644 (file)
@@ -286,7 +286,7 @@ JUCI.app.run(function($network, $wireless, $uci){
                "wps_pbc":                      { dvalue: false, type: Boolean },
                "wmf_bss_enable":       { dvalue: false, type: Boolean },
                "bss_max":                      { dvalue: 32, type: Number, validator: UCI.validators.NumberLimitValidator(0, 128) },
-               "closed":                       { dvalue: false, type: Boolean },
+               "hidden":                       { dvalue: false, type: Boolean },
                "isolate":                      { dvalue: false, type: Boolean },
                "disabled":                     { dvalue: false, type: Boolean },
                "macfilter":                    { dvalue: 0, type: Number },