提交 7aec53b7 编写于 作者: G gongfuxiang

优化

上级 93c097c9
......@@ -50,6 +50,12 @@ class StatisticalService
*/
public static function Init($params = [])
{
static $object = null;
if(!is_object($object))
{
// 初始化标记对象,避免重复初始化
$object = (object) [];
// 近7天日期
self::$seven_time_start = strtotime(date('Y-m-d 00:00:00', strtotime('-7 day')));
self::$seven_time_end = time();
......@@ -84,6 +90,7 @@ class StatisticalService
self::${$name} = $date;
}
}
}
/**
* 用户总数,今日,昨日,总数
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册