Checks the status before activate the submit button on users bulk-checkin

This commit is contained in:
Ivan Nieto Vivanco 2022-11-23 17:45:59 -06:00
parent e426846c23
commit b1985a08c4

View file

@ -115,3 +115,18 @@
</div>
@stop
@section('moar_scripts')
<script>
$(":submit").attr("disabled", "disabled");
$("[name='status_id']").on('select2:select', function (e) {
if (e.params.data.id != ""){
console.log(e.params.data.id);
$(":submit").removeAttr("disabled");
}
else {
$(":submit").attr("disabled", "disabled");
}
});
</script>
@stop