1
0
mirror of https://gitee.com/zoujingli/ThinkAdmin.git synced 2025-04-06 03:58:04 +08:00

Update sys.php

This commit is contained in:
Anyon 2020-09-19 18:43:58 +08:00
parent 3d0f8f5601
commit 4d38916456

@ -26,6 +26,7 @@ app()->event->listen('HttpEnd', function () {
foreach (array_chunk($GLOBALS['oplogs'], 100) as $items) {
app()->db->name('SystemOplog')->insertAll($items);
}
$GLOBALS['oplogs'] = [];
app()->db->name('SystemOplog')->where('create_at', '<', strtotime('-7days'))->delete();
}
});