Added license min amt formatter for BS table

Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
snipe 2024-02-28 11:06:50 +00:00
parent d0d29e03db
commit 3ccc55a78f

View file

@ -621,6 +621,22 @@
return frags.join(' ');
}
// Show the warning if below min qty
function minAmtFormatter(row, value) {
if ((row) && (row!=undefined)) {
console.log(row.free_seats_count);
console.log(row.min_amt);
if (value.free_seats_count <= value.min_amt) {
return '<span class="text-danger text-bold" data-tooltip="true" title="{{ trans('admin/licenses/general.below_threshold_short') }}">' + value.min_amt + '</span>';
}
return value.min_amt
}
}
// Create a linked phone number in the table list
function phoneFormatter(value) {