// Some security stuff...
if (!defined('__SECURITY')) {
die();
-}
+} // END - if
// Version number
-setThisExtensionVersion('0.5.0');
+setThisExtensionVersion('0.5.1');
// 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', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0'));
+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', '0.4.1', '0.4.2', '0.4.3', '0.4.4', '0.4.5', '0.4.6', '0.4.7', '0.4.8', '0.4.9', '0.5.0', '0.5.1'));
switch (getExtensionMode()) {
case 'register': // Do stuff when installation is running (modules.php?module=admin is called)
case 'remove': // Do stuff when removing extension
// SQL commands to run
- addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='config_order'");
+ addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='config_order' LIMIT 1");
+ addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_member_menu` WHERE `what`='order' LIMIT 1");
break;
case 'activate': // Do stuff when admin activates this extension
switch (getCurrentExtensionVersion()) {
case '0.1.0': // SQL queries for v0.1
addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_config` ADD order_max_full ENUM('ORDER','MAX') NOT NULL DEFAULT 'MAX'");
- addAdminMenuSql('setup','config_order','Mailbuchungsseite',7,'Einstellungen am Mailbuchungsformular.');
+ addAdminMenuSql('setup','config_order','Mailbuchungsseite','Einstellungen am Mailbuchungsformular.',7);
// Update notes (these will be set as task text!)
setExtensionUpdateNotes("Maximale Mailbuchungen sind nun vom maximalen Empfang abhägig.");
break;
case '0.1.1': // SQL queries for v0.1.1
- addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='config_order' LIMIT 1");
- addAdminMenuSql('setup','config_order','Mailbuchungsseite',7,'Einstellungen am Mailbuchungsformular.');
- addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_user_data` ADD mail_orders BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
+ // OLD QUERIES: addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `what`='config_order' LIMIT 1");
+ // OLD QUERIES: addAdminMenuSql('setup','config_order','Mailbuchungsseite','Einstellungen am Mailbuchungsformular.',7);
+ addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_user_data` ADD `mail_orders` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0");
// Update notes (these will be set as task text!)
setExtensionUpdateNotes("Maximale Mailbuchung vervollständigt (Admin-Bereich und im Buchungsformular selber).");
// Update notes (these will be set as task text!)
setExtensionUpdateNotes("Tabelle für URL-Sperrliste angelegt.");
break;
+
+ case '0.5.1': // SQL queries for v0.5.1
+ addMemberMenuSql('main','order','Mailbuchung','N','Y',8);
+
+ // Update notes (these will be set as task text!)
+ setExtensionUpdateNotes("Weiteren Menü-Query in Erweiterung verlagert.");
+ break;
}
break;