summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/Model/ProjectActivityModel.php9
-rw-r--r--app/constants.php2
-rw-r--r--config.default.php3
-rw-r--r--doc/en_US/config.markdown6
4 files changed, 12 insertions, 8 deletions
diff --git a/app/Model/ProjectActivityModel.php b/app/Model/ProjectActivityModel.php
index 380ea125..17cf6485 100644
--- a/app/Model/ProjectActivityModel.php
+++ b/app/Model/ProjectActivityModel.php
@@ -21,13 +21,6 @@ class ProjectActivityModel extends Base
const TABLE = 'project_activities';
/**
- * Maximum number of events
- *
- * @var integer
- */
- const MAX_EVENTS = 1000;
-
- /**
* Add a new event for the project
*
* @access public
@@ -49,7 +42,7 @@ class ProjectActivityModel extends Base
'data' => json_encode($data),
);
- $this->cleanup(self::MAX_EVENTS - 1);
+ $this->cleanup(PROJECT_ACTIVITIES_MAX_EVENTS - 1);
return $this->db->table(self::TABLE)->insert($values);
}
diff --git a/app/constants.php b/app/constants.php
index d62bfd3a..2266014d 100644
--- a/app/constants.php
+++ b/app/constants.php
@@ -146,3 +146,5 @@ defined('HTTP_PROXY_PASSWORD') or define('HTTP_PROXY_PASSWORD', '');
defined('HTTP_VERIFY_SSL_CERTIFICATE') or define('HTTP_VERIFY_SSL_CERTIFICATE', true);
defined('TOTP_ISSUER') or define('TOTP_ISSUER', 'Kanboard');
+
+defined('PROJECT_ACTIVITIES_MAX_EVENTS') or define('PROJECT_ACTIVITIES_MAX_EVENTS', 10000);
diff --git a/config.default.php b/config.default.php
index 1f08fbad..fb3aa477 100644
--- a/config.default.php
+++ b/config.default.php
@@ -237,3 +237,6 @@ define('HTTP_VERIFY_SSL_CERTIFICATE', true);
// TOTP (2FA) issuer name
define('TOTP_ISSUER', 'Kanboard');
+
+// Maximum number of events stored in the table "project_activities"
+define('PROJECT_ACTIVITIES_MAX_EVENTS', 10000);
diff --git a/doc/en_US/config.markdown b/doc/en_US/config.markdown
index 4ccaec27..4fbb9548 100644
--- a/doc/en_US/config.markdown
+++ b/doc/en_US/config.markdown
@@ -10,6 +10,9 @@ Enable/Disable debug mode
```php
define('DEBUG', true);
define('LOG_DRIVER', 'file'); // Other drivers are: syslog, stdout, stderr or file
+
+// By default, the log file is in data/debug.log but you can change the path:
+define('LOG_FILE', '/path/to/debug.log');
```
The log driver must be defined if you enable the debug mode.
@@ -332,4 +335,7 @@ define('API_AUTHENTICATION_TOKEN', 'My unique API Token');
// TOTP (2FA) issuer name
define('TOTP_ISSUER', 'Kanboard');
+
+// Maximum number of events stored in the table "project_activities"
+define('PROJECT_ACTIVITIES_MAX_EVENTS', 10000);
```