We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 30fc47f commit db18227Copy full SHA for db18227
1 file changed
src/WebApp/DataModel/LogDAO.php
@@ -28,6 +28,11 @@ public function createTable() {
28
return TRUE;
29
}
30
31
+ public function deleteAll() {
32
+ $sql = 'DELETE * FROM '.$this->database->quoteName($this->tableName);
33
+ $this->database->query($sql);
34
+ }
35
+
36
public function housekeeping($days = 30) {
37
$this->threshold = new Date(time()-$days*Date::SECONDS_PER_DAY, WFW_TIMEZONE);
38
$sql = 'DELETE * FROM '.$this->database->quoteName($this->tableName).' WHERE log_date < '.$this->database->prepareValue($threshold);
0 commit comments