mirror of
https://github.com/hotspotbilling/phpnuxbill.git
synced 2025-02-24 23:45:38 +08:00
Cache for 12 hours
This commit is contained in:
parent
009c890ab6
commit
1e0b246d74
1 changed files with 2 additions and 2 deletions
|
@ -124,8 +124,8 @@ if(file_exists($cacheMRfile) && time()- filemtime($cacheMRfile) < 3600){
|
||||||
}
|
}
|
||||||
|
|
||||||
$cacheMSfile = File::pathFixer('system/cache/monthlySales.json');
|
$cacheMSfile = File::pathFixer('system/cache/monthlySales.json');
|
||||||
//Cache for 24 hours
|
//Cache for 12 hours
|
||||||
if(file_exists($cacheMSfile) && time()- filemtime($cacheMSfile) < 86400){
|
if(file_exists($cacheMSfile) && time()- filemtime($cacheMSfile) < 43200){
|
||||||
$monthlySales = json_decode(file_get_contents($cacheMSfile), true);
|
$monthlySales = json_decode(file_get_contents($cacheMSfile), true);
|
||||||
}else{
|
}else{
|
||||||
// Query to retrieve monthly data
|
// Query to retrieve monthly data
|
||||||
|
|
Loading…
Reference in a new issue