mirror of
https://github.com/hotspotbilling/phpnuxbill.git
synced 2025-08-03 01:34:53 +02:00
add refresh dashboard to get latest data
This commit is contained in:
parent
238fc03d03
commit
a5affdb674
2 changed files with 15 additions and 4 deletions
|
@ -9,6 +9,17 @@ _admin();
|
|||
$ui->assign('_title', Lang::T('Dashboard'));
|
||||
$ui->assign('_admin', $admin);
|
||||
|
||||
if(isset($_GET['refresh'])){
|
||||
$files = scandir($CACHE_PATH);
|
||||
foreach ($files as $file) {
|
||||
$ext = pathinfo($file, PATHINFO_EXTENSION);
|
||||
if (is_file($CACHE_PATH . DIRECTORY_SEPARATOR . $file) && $ext == 'temp') {
|
||||
unlink($CACHE_PATH . DIRECTORY_SEPARATOR . $file);
|
||||
}
|
||||
}
|
||||
r2(U . 'dashboard', 's', 'Data Refreshed');
|
||||
}
|
||||
|
||||
$fdate = date('Y-m-01');
|
||||
$tdate = date('Y-m-t');
|
||||
//first day of month
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue