mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-10 07:34:06 -08:00
jQuery script to toggle the disabled state of auto_increment_prefix (#3292)
* Toggles the disabled state of auto_increment_prefix To insert a prefix you had to toggle the checkbox, save the settings and reload. With this script it is immediate. * Toggles the disabled state of auto_increment_prefix To insert a prefix you had to toggle the checkbox, save the settings and reload. With this script it is immediate. Fixes #1390
This commit is contained in:
parent
c67b44b3d5
commit
9975d55249
|
@ -975,5 +975,11 @@
|
|||
<script>
|
||||
//color picker with addon
|
||||
$(".header-color").colorpicker();
|
||||
// toggle the disabled state of asset id prefix
|
||||
$('#auto_increment_assets').on('ifChecked', function(){
|
||||
$('#auto_increment_prefix').prop('disabled', false).focus();
|
||||
}).on('ifUnchecked', function(){
|
||||
$('#auto_increment_prefix').prop('disabled', true);
|
||||
});
|
||||
</script>
|
||||
@stop
|
||||
|
|
Loading…
Reference in a new issue