fix apa yang patut
This commit is contained in:
@@ -168,8 +168,8 @@
|
||||
</div>
|
||||
<div class="tab-pane fade" id="gadaian-belum-serah" role="tabpanel" aria-labelledby="gadaian-belum-serah-tab">
|
||||
<div class="float-right mb-3">
|
||||
<button class="btn btn-primary mt-4 pull-left" onclick="checkallfunc()">Check All</button>
|
||||
<button class="btn btn-primary mt-4 pull-left" onclick="uncheckallfunc()">Uncheck All</button>
|
||||
<button class="btn btn-primary mt-4 pull-left" onclick="checkallfunc()" disabled>Check All</button>
|
||||
<button class="btn btn-primary mt-4 pull-left" onclick="uncheckallfunc()" disabled>Uncheck All</button>
|
||||
</div>
|
||||
<table class='table table-striped table-hover' id='table-gadaian-belum-serah'>
|
||||
<thead class="thead-dark">
|
||||
@@ -289,19 +289,26 @@
|
||||
});
|
||||
|
||||
function checkallfunc(){
|
||||
|
||||
|
||||
let totalmarhun = 0;
|
||||
$(':checkbox').each(function() {
|
||||
let marhun = Number($(this).data("marhun"));
|
||||
totalmarhun += marhun;
|
||||
this.checked = true;
|
||||
});
|
||||
|
||||
$("#btn-serah").prop('disabled', false);
|
||||
$('#marhunpilih').val(formatter.format(totalmarhun.toFixed(2)));
|
||||
}
|
||||
|
||||
function uncheckallfunc(){
|
||||
|
||||
let totalmarhun = 0;
|
||||
$(':checkbox').each(function() {
|
||||
let marhun = Number($(this).data("marhun"));
|
||||
totalmarhun -= marhun;
|
||||
this.checked = false;
|
||||
});
|
||||
|
||||
$('#marhunpilih').val(0);
|
||||
$("#btn-serah").prop('disabled', true);
|
||||
}
|
||||
|
||||
function fetchRekodGadaian(){
|
||||
|
||||
Reference in New Issue
Block a user