Order Expired by Expired date

This commit is contained in:
Ibnu Maksum 2024-01-08 15:24:35 +07:00
parent 081dd1b1b9
commit 1d29f8111e
No known key found for this signature in database
GPG key ID: 7FC82848810579E5
2 changed files with 6 additions and 5 deletions

View file

@ -57,7 +57,7 @@ $expire = ORM::for_table('tbl_user_recharges')
->where_lte('expiration', $mdate)
->offset($paginator['startpoint'])
->limit($paginator['limit'])
->order_by_desc('id')
->order_by_desc('expiration')
->find_many();
// Get the total count of expired records for pagination
@ -67,7 +67,6 @@ $totalCount = ORM::for_table('tbl_user_recharges')
// Pass the total count and current page to the paginator
$paginator['total_count'] = $totalCount;
$paginator['current_page'] = $paginator['current_page'];
// Assign the pagination HTML to the template variable
$ui->assign('paginator', $paginator);

View file

@ -119,7 +119,7 @@
{/foreach}
</table>
</div>
&nbsp; {$paginator['contents']}
&nbsp; {$paginator['contents']}
</div>
</div>
@ -150,7 +150,9 @@
$.getJSON("./version.json?" + Math.random(), function(data) {
var localVersion = data.version;
$('#version').html('Version: ' + localVersion);
$.getJSON("https://raw.githubusercontent.com/hotspotbilling/phpnuxbill/master/version.json?" + Math
$.getJSON(
"https://raw.githubusercontent.com/hotspotbilling/phpnuxbill/master/version.json?" +
Math
.random(),
function(data) {
var latestVersion = data.version;
@ -163,4 +165,4 @@
});
</script>
{include file="sections/footer.tpl"}
{include file="sections/footer.tpl"}