Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'core/Db/Schema/Mysql.php')
-rw-r--r--core/Db/Schema/Mysql.php19
1 files changed, 17 insertions, 2 deletions
diff --git a/core/Db/Schema/Mysql.php b/core/Db/Schema/Mysql.php
index 92d2b882fb..09b0b48922 100644
--- a/core/Db/Schema/Mysql.php
+++ b/core/Db/Schema/Mysql.php
@@ -52,6 +52,7 @@ class Mysql implements SchemaInterface
superuser_access TINYINT(2) unsigned NOT NULL DEFAULT '0',
date_registered TIMESTAMP NULL,
ts_password_modified TIMESTAMP NULL,
+ idchange_last_viewed TIMESTAMP NULL,
PRIMARY KEY(login)
) ENGINE=$engine DEFAULT CHARSET=$charset
",
@@ -358,6 +359,19 @@ class Mysql implements SchemaInterface
PRIMARY KEY (`key`)
) ENGINE=$engine DEFAULT CHARSET=$charset
",
+ 'changes' => "CREATE TABLE `{$prefixTables}changes` (
+ `idchange` INTEGER UNSIGNED NOT NULL AUTO_INCREMENT,
+ `created_time` DATETIME NOT NULL,
+ `plugin_name` VARCHAR(255) NOT NULL,
+ `version` VARCHAR(20) NOT NULL,
+ `title` VARCHAR(255) NOT NULL,
+ `description` TEXT NULL,
+ `link_name` VARCHAR(255) NULL,
+ `link` VARCHAR(255) NULL,
+ PRIMARY KEY(`idchange`),
+ UNIQUE KEY unique_plugin_version_title (`plugin_name`, `version`, `title`)
+ ) ENGINE=$engine DEFAULT CHARSET=$charset
+ ",
);
return $tables;
@@ -574,8 +588,9 @@ class Mysql implements SchemaInterface
// note that the token_auth value is anonymous, which is assigned by default as well in the Login plugin
$db = $this->getDb();
$db->query("INSERT IGNORE INTO " . Common::prefixTable("user") . "
- (`login`, `password`, `email`, `twofactor_secret`, `superuser_access`, `date_registered`, `ts_password_modified`)
- VALUES ( 'anonymous', '', 'anonymous@example.org', '', 0, '$now', '$now' );");
+ (`login`, `password`, `email`, `twofactor_secret`, `superuser_access`, `date_registered`, `ts_password_modified`,
+ `idchange_last_viewed`)
+ VALUES ( 'anonymous', '', 'anonymous@example.org', '', 0, '$now', '$now' , NULL);");
$model = new Model();
$model->addTokenAuth('anonymous', 'anonymous', 'anonymous default token', $now);