X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=inc%2Fextensions%2Fext-autopurge.php;h=1fc0951f73efffc2b39104f602de25d427e9febe;hb=f4d7dc336fde4cebc47701026a94d193f77854a1;hp=840842d869332cc5a4cca76043494dacdcc40c87;hpb=b8e38719844932afed4b1ac23755a4c05b72eb99;p=mailer.git diff --git a/inc/extensions/ext-autopurge.php b/inc/extensions/ext-autopurge.php index 840842d869..1fc0951f73 100644 --- a/inc/extensions/ext-autopurge.php +++ b/inc/extensions/ext-autopurge.php @@ -43,26 +43,26 @@ if (!defined('__SECURITY')) { // Version number setThisExtensionVersion('0.4.0'); -// Version history array (add more with , '0.1.0' and so on) -setExtensionVersionHistory(array('0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0')); +// Version history array (add more with , '0.0.1' and so on) +setExtensionVersionHistory(array('0.0.0', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2', '0.3.3', '0.3.4', '0.3.5', '0.3.6', '0.3.7', '0.3.8', '0.3.9', '0.4.0')); // Keep this extension always active! setExtensionAlwaysActive('Y'); switch (getExtensionMode()) { - case 'register': // Do stuff when installation is running (modules.php?module=admin is called) + case 'register': // Do stuff when installation is running // Add dependency to 'bonus' addExtensionDependency('bonus'); // SQL commands to run - addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_pool` MODIFY data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE','DELETED') NOT NULL DEFAULT 'TEMP'"); - addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_bonus` MODIFY `data_type` ENUM('NEW','QUEUE','SEND','DELETED') NOT NULL DEFAULT 'NEW'"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_pool` CHANGE `data_type` `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE','DELETED') NOT NULL DEFAULT 'TEMP'"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_bonus` CHANGE `data_type` ENUM('NEW','QUEUE','SEND','DELETED') NOT NULL DEFAULT 'NEW'"); break; case 'remove': // Do stuff when removing extension // SQL commands to run - addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_pool` MODIFY `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'"); - addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_bonus` MODIFY `data_type` ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW'"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_pool` CHANGE `data_type` `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_bonus` CHANGE `data_type` `data_type` ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW'"); addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what` IN('config_autopurge','list_autopurge')"); addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_user_data` DROP `ap_notified`"); break; @@ -86,11 +86,11 @@ switch (getExtensionMode()) { // SQL queries addConfigAddSql('autopurge_inactive', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); addConfigAddSql('autopurge_unconfirmed', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); - addConfigAddSql('ap_inactive_since', "BIGINT(20) UNSIGNED NOT NULL DEFAULT '2592000'"); - addConfigAddSql('ap_inactive_time', "BIGINT(20) UNSIGNED NOT NULL DEFAULT '25200'"); - addConfigAddSql('ap_unconfirmed_time', "BIGINT(20) UNSIGNED NOT NULL DEFAULT '432000'"); - addAdminMenuSql('setup','config_autopurge','Auto-Löschung','Automatisch inaktive oder nicht bestätigte Accounts löschen.',12); - addAdminMenuSql('user','list_autopurge','Inaktive finden','Lassen Sie sich vor dem täglichen Reset anzeigen, welche Mitglieder als inaktiv erkannt werden und welche gelöscht werden.',10); + addConfigAddSql('ap_inactive_since', 'BIGINT(20) UNSIGNED NOT NULL DEFAULT 2592000'); + addConfigAddSql('ap_inactive_time', 'BIGINT(20) UNSIGNED NOT NULL DEFAULT 25200'); + addConfigAddSql('ap_unconfirmed_time', 'BIGINT(20) UNSIGNED NOT NULL DEFAULT 432000'); + addAdminMenuSql('setup', 'config_autopurge', 'Auto-Löschung', 'Automatisch inaktive oder nicht bestätigte Accounts löschen.', 12); + addAdminMenuSql('user', 'list_autopurge', 'Inaktive finden', 'Lassen Sie sich vor dem täglichen Reset anzeigen, welche Mitglieder als inaktiv erkannt werden und welche gelöscht werden.', 10); addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_user_data` ADD `ap_notified` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0"); // Update notes (these will be set as task text!) @@ -130,7 +130,7 @@ switch (getExtensionMode()) { case '0.1.9': // SQL queries for v0.1.9 addConfigAddSql('autopurge_tasks', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); - addConfigAddSql('ap_tasks_time', "BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(getOneDay()*7)."'"); + addConfigAddSql('ap_tasks_time', 'BIGINT(20) UNSIGNED NOT NULL DEFAULT ' . (getOneDay() * 7)); // Update notes (these will be set as task text!) setExtensionUpdateNotes("Bereinigung von zu löschenden Aufgaben klappt wieder. Zeitlimit für genanntes kann eingestellt werden (Default = 7 Tage).

Bitte aktualisieren Sie auch die Admin-Templates!"); @@ -208,7 +208,7 @@ switch (getExtensionMode()) { case '0.3.3': // SQL queries for v0.3.3 addConfigAddSql('ap_del_mails', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); addConfigAddSql('ap_dm_notify', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); - addConfigAddSql('ap_dm_timeout', "BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400'"); + addConfigAddSql('ap_dm_timeout', 'BIGINT(20) UNSIGNED NOT NULL DEFAULT {?ONE_DAY?}'); // Update notes (these will be set as task text!) setExtensionUpdateNotes("Von bereits gelöschten Mitgliedern die Mails löschen integriert.");