mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-03-01 10:31:47 +00:00
Update chkstatic/chkdhcp radio btns classes
This commit is contained in:
parent
87f95ab9f9
commit
9a1d362d30
@ -242,15 +242,15 @@ function loadInterfaceDHCPSelect() {
|
|||||||
$('#txtmetric').val(jsonData.Metric);
|
$('#txtmetric').val(jsonData.Metric);
|
||||||
|
|
||||||
if (jsonData.StaticIP !== null && jsonData.StaticIP !== '' && !jsonData.FallbackEnabled) {
|
if (jsonData.StaticIP !== null && jsonData.StaticIP !== '' && !jsonData.FallbackEnabled) {
|
||||||
$('#chkstatic').closest('.btn').button('toggle');
|
$('#chkstatic').prop('checked', true);
|
||||||
$('#chkstatic').closest('.btn').button('toggle').blur();
|
$('#chkstatic').closest('.btn').addClass('active').removeClass('btn-light');
|
||||||
$('#chkstatic').blur();
|
$('#chkdhcp').closest('.btn').removeClass('active').addClass('btn-light');
|
||||||
$('#chkfallback').prop('disabled', true);
|
$('#chkfallback').prop('disabled', true);
|
||||||
$('#dhcp-iface').removeAttr('disabled');
|
$('#dhcp-iface').removeAttr('disabled');
|
||||||
} else {
|
} else {
|
||||||
$('#chkdhcp').closest('.btn').button('toggle');
|
$('#chkdhcp').prop('checked', true);
|
||||||
$('#chkdhcp').closest('.btn').button('toggle').blur();
|
$('#chkdhcp').closest('.btn').addClass('active').removeClass('btn-light');
|
||||||
$('#chkdhcp').blur();
|
$('#chkstatic').closest('.btn').removeClass('active').addClass('btn-light');
|
||||||
$('#chkfallback').prop('disabled', false);
|
$('#chkfallback').prop('disabled', false);
|
||||||
}
|
}
|
||||||
if (jsonData.FallbackEnabled || $('#chkdhcp').is(':checked')) {
|
if (jsonData.FallbackEnabled || $('#chkdhcp').is(':checked')) {
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
<h5 class="mt-1"><?php echo _("Adapter IP Address Settings"); ?></h5>
|
<h5 class="mt-1"><?php echo _("Adapter IP Address Settings"); ?></h5>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="mb-3 col-md-6">
|
<div class="mb-3 col-md-6">
|
||||||
<div class="btn-group" data-bs-toggle="buttons">
|
<div class="btn-group" role="group" data-bs-toggle="buttons">
|
||||||
<label class="btn btn-light active" checked onclick="setDHCPToggles(false)">
|
<label class="btn btn-light active" checked onclick="setDHCPToggles(false)">
|
||||||
<input type="radio" name="adapter-ip" id="chkdhcp" autocomplete="off"> DHCP
|
<input type="radio" name="adapter-ip" id="chkdhcp" autocomplete="off"> DHCP
|
||||||
</label>
|
</label>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user