|
@@ -58,7 +58,17 @@
|
|
|
<p>This operation will remove your samba user account from the system</p>
|
|
|
<button class="ui red button" onclick="removeUser(event)">Disable</button>
|
|
|
</div>
|
|
|
-
|
|
|
+ <div id="notSupported" style="display: none;">
|
|
|
+ <br>
|
|
|
+ <div class="ui header">
|
|
|
+ <i class="red remove icon"></i>
|
|
|
+ <div class="content">
|
|
|
+ Platform Not Supported
|
|
|
+ <div class="sub header">Are you using Windows?</div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <p>This setting interface is disabled automatically on not supported platforms.</p>
|
|
|
+ </div>
|
|
|
<br><br>
|
|
|
<script>
|
|
|
//Do not allow window resize
|
|
@@ -71,17 +81,25 @@
|
|
|
|
|
|
//Get the account status
|
|
|
$.get("./getStatus?username=" + username, function(data){
|
|
|
- if (data == true){
|
|
|
- $("#acstatus").text("Enabled");
|
|
|
- $("#acstatus").attr("class","success");
|
|
|
+ if (data.error !== undefined){
|
|
|
+ //Not supported platforms
|
|
|
$("#enableAccount").hide();
|
|
|
- $("#disableAccount").show();
|
|
|
- } else{
|
|
|
- $("#acstatus").text("Disabled");
|
|
|
- $("#acstatus").attr("class","failed");
|
|
|
- $("#enableAccount").show();
|
|
|
$("#disableAccount").hide();
|
|
|
+ $("#notSupported").show();
|
|
|
+ }else{
|
|
|
+ if (data == true){
|
|
|
+ $("#acstatus").text("Enabled");
|
|
|
+ $("#acstatus").attr("class","success");
|
|
|
+ $("#enableAccount").hide();
|
|
|
+ $("#disableAccount").show();
|
|
|
+ } else{
|
|
|
+ $("#acstatus").text("Disabled");
|
|
|
+ $("#acstatus").attr("class","failed");
|
|
|
+ $("#enableAccount").show();
|
|
|
+ $("#disableAccount").hide();
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
});
|
|
|
});
|
|
|
|