mirror of
https://github.com/billz/raspap-webgui.git
synced 2025-12-26 23:26:47 +01:00
Merge pull request #1904 from RaspAP/fix/static-lease-mac
Apply input mask to MAC address field using [0-9a-fA-F] pattern
This commit is contained in:
@@ -606,10 +606,10 @@ $(document).ready(function(){
|
||||
},
|
||||
placeholder: "___.___.___.___"
|
||||
});
|
||||
$('.date').mask('FF:FF:FF:FF:FF:FF', {
|
||||
$('.mac_address').mask('FF:FF:FF:FF:FF:FF', {
|
||||
translation: {
|
||||
"F": {
|
||||
pattern: /[0-9a-z]/, optional: true
|
||||
'F': {
|
||||
pattern: /[0-9a-fA-F]/, optional: false
|
||||
}
|
||||
},
|
||||
placeholder: "__:__:__:__:__:__"
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
|
||||
<div class="row dhcp-static-lease-row js-new-dhcp-static-lease">
|
||||
<div class="col-md-4 col-xs-3">
|
||||
<input type="text" name="mac" value="" placeholder="<?php echo _("MAC address") ?>" class="form-control date" autofocus="autofocus">
|
||||
<input type="text" name="mac" value="" placeholder="<?php echo _("MAC address") ?>" class="form-control mac_address" autofocus="autofocus">
|
||||
</div>
|
||||
<div class="col-md-3 col-xs-3">
|
||||
<input type="text" name="ip" value="" placeholder="<?php echo _("IP address") ?>" class="form-control ip_address" maxlength="15">
|
||||
|
||||
Reference in New Issue
Block a user