From: Roland Häder Date: Tue, 12 Jul 2011 12:50:37 +0000 (+0000) Subject: Referal system refactured (and some parts fixed), wrapper function introduced: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=56931cd9321119dd37372bd16d6c552857e40066;p=mailer.git Referal system refactured (and some parts fixed), wrapper function introduced: - Referal points system refactured: All point accounts can now be handled (admin menu is not yet finished) through the table 'points_data', including notification by email. - Introduced new "translation" wrapper generateYesNoOptionList() to simplify many configuration menus - Some internal TODOs closed (e.g. handling of registration welcome points) - TODOs.txt updated --- diff --git a/.gitattributes b/.gitattributes index 96bf5151f0..1b137e06b0 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1117,6 +1117,7 @@ templates/de/html/admin/admin_delete_admins_acls_row.tpl svneol=native#text/plai templates/de/html/admin/admin_delete_admins_row.tpl svneol=native#text/plain templates/de/html/admin/admin_delete_cats.tpl svneol=native#text/plain templates/de/html/admin/admin_delete_cats_row.tpl svneol=native#text/plain +templates/de/html/admin/admin_delete_country_row.tpl svneol=native#text/plain templates/de/html/admin/admin_delete_email_bonus.tpl svneol=native#text/plain templates/de/html/admin/admin_delete_email_max_rec.tpl svneol=native#text/plain templates/de/html/admin/admin_delete_email_max_rec_row.tpl svneol=native#text/plain @@ -1155,6 +1156,7 @@ templates/de/html/admin/admin_edit_bank_packages_row.tpl svneol=native#text/plai templates/de/html/admin/admin_edit_bonus_email.tpl svneol=native#text/plain templates/de/html/admin/admin_edit_cats.tpl svneol=native#text/plain templates/de/html/admin/admin_edit_cats_row.tpl svneol=native#text/plain +templates/de/html/admin/admin_edit_country_row.tpl svneol=native#text/plain templates/de/html/admin/admin_edit_email.tpl svneol=native#text/plain templates/de/html/admin/admin_edit_email_max_rec.tpl svneol=native#text/plain templates/de/html/admin/admin_edit_email_max_rec_row.tpl svneol=native#text/plain diff --git a/DOCS/TODOs.txt b/DOCS/TODOs.txt index 561837e4b3..abac6c9d44 100644 --- a/DOCS/TODOs.txt +++ b/DOCS/TODOs.txt @@ -35,7 +35,7 @@ ./inc/extensions/ext-network.php:93: // @TODO network_type_handle is an internal name and needs documentation ./inc/extensions/ext-newsletter.php:218: // @TODO Move these into configuration ./inc/extensions/ext-order.php:358: // @TODO This should be moved out to inc/daily/ -./inc/extensions/ext-rallye.php:331: // @TODO Move this code into a hook +./inc/extensions/ext-rallye.php:341: // @TODO Move this code into a hook ./inc/extensions/ext-rallye.php:94: // @TODO Fix config_rallye_prices to list_rallye_prices ./inc/extensions/ext-yoomedia.php:121: // @TODO Can this be moved into a database table? ./inc/extensions/ext-yoomedia.php:54:// @TODO Only deprecated when 'ext-network' is ready! setExtensionDeprecated('Y'); @@ -54,8 +54,8 @@ ./inc/functions.php:2200: // @TODO Rename column data_type to e.g. mail_status ./inc/gen_sql_patches.php:95:// @TODO Rewrite this to a filter ./inc/install-functions.php:57: // @TODO DEACTIVATED: changeDataInLocalConfigurationFile('OUTPUT-MODE', "setConfigEntry('OUTPUT_MODE', '", "');", postRequestParameter('omode'), 0); -./inc/language/de.php:1066: // @TODO Rewrite these two constants -./inc/language/de.php:1082: // @TODO Rewrite these three constants +./inc/language/de.php:1063: // @TODO Rewrite these two constants +./inc/language/de.php:1079: // @TODO Rewrite these three constants ./inc/language/de.php:758:// @TODO Are these constants longer used? ./inc/language-functions.php:255: // @TODO These are all valid languages, again hard-coded ./inc/language-functions.php:44:// @TODO Rewrite all language constants to this function. @@ -73,7 +73,6 @@ ./inc/libs/rallye_functions.php:854:// @TODO Please document this function ./inc/libs/rallye_functions.php:910: // Load count @TODO Can't we rewrite this to our API? ./inc/libs/register_functions.php:290: // @TODO Rewrite these all to a single filter -./inc/libs/register_functions.php:363: // @TODO Wether the registration bonus should only be added to user directly or through referal system should be configurable ./inc/libs/sponsor_functions.php:159: // @TODO Rewrite this to API function ./inc/libs/sponsor_functions.php:430: // @TODO Rewrite this to API function ./inc/libs/surfbar_functions.php:1621: // @TODO This can be somehow rewritten @@ -171,12 +170,12 @@ ./inc/modules/member/what-unconfirmed.php:209: // @TODO This 'userid' cannot be saved because of encapsulated EL code ./inc/modules/order.php:74: // @TODO Unused: 2,4 ./inc/monthly/monthly_bonus.php:64: // @TODO Rewrite this to a filter -./inc/mysql-manager.php:1258: // @TODO Rewrite this to a filter -./inc/mysql-manager.php:1520: // @TODO Try to rewrite this to $content = SQL_FETCHARRAY() -./inc/mysql-manager.php:1608: // @TODO Rewrite these lines to a filter -./inc/mysql-manager.php:1632: // @TODO Rewrite this to a filter -./inc/mysql-manager.php:1998: // @TODO Rewrite this to a filter -./inc/mysql-manager.php:2042:// @TODO Fix inconsistency between last_module and getWhat() +./inc/mysql-manager.php:1267: // @TODO Rewrite this to a filter +./inc/mysql-manager.php:1529: // @TODO Try to rewrite this to $content = SQL_FETCHARRAY() +./inc/mysql-manager.php:1617: // @TODO Rewrite these lines to a filter +./inc/mysql-manager.php:1641: // @TODO Rewrite this to a filter +./inc/mysql-manager.php:2007: // @TODO Rewrite this to a filter +./inc/mysql-manager.php:2051:// @TODO Fix inconsistency between last_module and getWhat() ./inc/mysql-manager.php:371: // @TODO Try to rewrite this to one or more functions ./inc/mysql-manager.php:44:// @TODO Can we cache this? ./inc/purge/purge-inact.php:55: // @TODO Rewrite these if() blocks to a filter @@ -310,6 +309,8 @@ ./templates/de/html/admin/admin_list_cats_404.tpl:1: ./templates/de/html/admin/admin_list_chk_reg_row.tpl:1: ./templates/de/html/admin/admin_list_chk_reg.tpl:1: +./templates/de/html/admin/admin_list_country_del_row.tpl:1: +./templates/de/html/admin/admin_list_country_edit_row.tpl:1: ./templates/de/html/admin/admin_reset_pass_done.tpl:1: ./templates/de/html/admin/admin_send_reset_link.tpl:1: ./templates/de/html/member/member_surfbar_book_dynamic.tpl:1: diff --git a/birthday_confirm.php b/birthday_confirm.php index 24f71259c4..2923ceb2c9 100644 --- a/birthday_confirm.php +++ b/birthday_confirm.php @@ -91,7 +91,7 @@ if (SQL_NUMROWS($result) == 1) { if ($data['status'] == 'CONFIRMED') { // Add points to account initReferalSystem(); - addPointsThroughReferalSystem('birthday_confirm', $userid, $data['points'], false, 0, strtolower(getConfig('birthday_mode'))); + addPointsThroughReferalSystem('birthday_confirm', $userid, $data['points']); // Remove entry from table SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_user_birthday` WHERE `userid`=%s AND `chk_value`='%s' LIMIT 1", diff --git a/doubler.php b/doubler.php index 306e8f01ab..a7f83cfeb2 100644 --- a/doubler.php +++ b/doubler.php @@ -172,7 +172,9 @@ if (isFormSent()) { } // END - if (isFormSet()) // Shall I check for points immediately? -if (getConfig('doubler_send_mode') == 'DIRECT') loadInclude('inc/mails/doubler_mails.php'); +if (getConfig('doubler_send_mode') == 'DIRECT') { + loadInclude('inc/mails/doubler_mails.php'); +} // END - if // Output header loadIncludeOnce('inc/header.php'); diff --git a/inc/classes/resolver.class.php b/inc/classes/resolver.class.php index 317114d27b..57afe95342 100644 --- a/inc/classes/resolver.class.php +++ b/inc/classes/resolver.class.php @@ -92,7 +92,7 @@ class HostnameResolver { // Seems to be an IP! Now check deeper... if (($matches[0] == $ip) && ($matches[1] >= 0) && ($matches[1] <= 255) && ($matches[2] >= 0) && ($matches[2] <= 255) && ($matches[3] >= 0) && ($matches[3] <= 255) && ($matches[4] > 0) && ($matches[4] < 255)) { // We also cache IP addresses - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_dns_cache` (`ip`, `hostname`, `added`) VALUES('%s', '%s', NOW())", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_dns_cache` (`ip`, `hostname`, `added`) VALUES ('%s', '%s', NOW())", array($ip, $hostname), __METHOD__, __LINE__); // Set return value to $ip @@ -106,7 +106,7 @@ class HostnameResolver { //* DEBUG: */ logDebugMessage(__METHOD__, __LINE__, sprintf("Cannot lookup: %s", $hostname)); } else { // Put entry in DB - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_dns_cache` (`ip`, `hostname`, `added`) VALUES('%s', '%s', NOW())", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_dns_cache` (`ip`, `hostname`, `added`) VALUES ('%s', '%s', NOW())", array($ip, $hostname), __METHOD__, __LINE__); // Set return value to $ip diff --git a/inc/db/lib-mysql3.php b/inc/db/lib-mysql3.php index 68cdd067ad..2d25cdea88 100644 --- a/inc/db/lib-mysql3.php +++ b/inc/db/lib-mysql3.php @@ -339,7 +339,7 @@ function SQL_RESULT_FROM_ARRAY ($table, $columns, $idRow, $id, $F, $L) { } // END - if // Prepare the SQL statement - $sql = "SELECT `".implode("`,`", $columns)."` FROM `{?_MYSQL_PREFIX?}_%s` WHERE `%s`='%s' LIMIT 1"; + $sql = "SELECT `".implode("`, `", $columns)."` FROM `{?_MYSQL_PREFIX?}_%s` WHERE `%s`='%s' LIMIT 1"; // Return the result return SQL_QUERY_ESC($sql, @@ -434,12 +434,13 @@ function SQL_ALTER_TABLE ($sql, $F, $L, $enableCodes = true) { $keyName = ','; while (strpos($keyName, ',') !== false) { // Use last + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'keyName=' . $keyName . 'begin=' . $begin . ' - BEFORE'); $keyName = str_replace('`', '', $tableArray[count($tableArray) - $begin]); - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, $keyName . '----------------' . $begin); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'keyName=' . $keyName . 'begin=' . $begin . ' - BETWEEN'); // Remove brackes $keyName = str_replace('(', '', str_replace(')', '', $keyName)); - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, $keyName . '----------------' . $begin); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'keyName=' . $keyName . 'begin=' . $begin . ' - AFTER'); // Continue $begin++; @@ -448,13 +449,13 @@ function SQL_ALTER_TABLE ($sql, $F, $L, $enableCodes = true) { // Shall we run it? //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ', tableArray[3]=' . $tableArray[3] . ',keyName=' . $keyName); - if ((!isSqlTableIndexAdded($tableName, $tableArray[3], $keyName)) && ($tableArray[3] == 'ADD')) { + if (($tableArray[3] == 'ADD') && (!isSqlTableIndexFound($tableName, $keyName))) { // Send it to the SQL_QUERY() function to add it - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, $sql); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'sql=' . $sql . ' - ADDING!'); $result = SQL_QUERY($sql, $F, $L, $enableCodes); - } elseif ((isSqlTableIndexAdded($tableName, $tableArray[3], $keyName)) && ($tableArray[3] == 'DROP')) { + } elseif (($tableArray[3] == 'DROP') && (isSqlTableIndexFound($tableName, $keyName))) { // Send it to the SQL_QUERY() function to drop it - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, $sql); + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'sql=' . $sql . ' - DROPPING!'); $result = SQL_QUERY($sql, $F, $L, $enableCodes); } else { // Not executed @@ -559,6 +560,7 @@ function SQL_EPOCHE_TO_TIMESTAMP ($timestamp) { // Check if there is a SQL table created function isSqlTableCreated ($tableName) { + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ' - ENTERED!'); // Do we have cache? if (!isset($GLOBALS[__FUNCTION__][$tableName])) { // Check if the table is there @@ -571,11 +573,13 @@ function isSqlTableCreated ($tableName) { } // END - if // Return cache + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',result=' . intval($GLOBALS[__FUNCTION__][$tableName]) . ' - EXIT!'); return $GLOBALS[__FUNCTION__][$tableName]; } // Is a table column there? function isSqlTableColumnFound ($tableName, $columnName) { + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',columnName=' . $columName . ' - ENTERED!'); // Do we have cache? if (!isset($GLOBALS[__FUNCTION__][$tableName][$columnName])) { // And column name as well @@ -594,49 +598,37 @@ function isSqlTableColumnFound ($tableName, $columnName) { } // END - if // Return cache + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',columnName=' . $columName . ',result=' . intval($GLOBALS[__FUNCTION__][$tableName][$columnName]) . ' - EXIT!'); return $GLOBALS[__FUNCTION__][$tableName][$columnName]; } -// Checks depending on the mode if the table is there -function isSqlTableIndexAdded ($tableName, $mode, $keyName) { +// Checks depending on the mode if the index is there +function isSqlTableIndexFound ($tableName, $keyName) { + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',columnName=' . $keyName . ' - ENTERED!'); // Do we have cache? - if (!isset($GLOBALS[__FUNCTION__][$tableName][$mode])) { + if (!isset($GLOBALS[__FUNCTION__][$tableName][$keyName])) { // Show indexes $result = SQL_QUERY_ESC("SHOW INDEX FROM `%s`", array($tableName), __FUNCTION__, __LINE__); - // Non-skipping is default for ADD - $GLOBALS[__FUNCTION__][$tableName][$mode] = false; - - // But should we DROP? - if ($mode == 'DROP') { - // Then skip if nothing found - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Going to drop key ' . $keyName); - $GLOBALS[__FUNCTION__][$tableName][$mode] = true; - } // END - if + // The column is not found by default + $GLOBALS[__FUNCTION__][$tableName][$keyName] = false; // Walk through all while ($content = SQL_FETCHARRAY($result)) { - // Is it found? - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'columnName='.$keyName.',content=
' . print_r($content, true) . '
'); - if (($content['Key_name'] == $keyName) && ($mode == 'ADD')) { - // Skip this query! - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ADD: Skiped: tableName=' . $tableName . ',mode=' . $mode . ',keyName=' . $keyName); - $GLOBALS[__FUNCTION__][$tableName][$mode] = true; - break; - } elseif (($content['Key_name'] == $keyName) && ($mode == 'DROP')) { - // Don't skip this! - //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'DROP: Not skiped: tableName=' . $tableName . ',mode=' . $mode . ',keyName=' . $keyName); - $GLOBALS[__FUNCTION__][$tableName][$mode] = false; - break; - } + // Add all entries for better caching behavior + $GLOBALS[__FUNCTION__][$tableName][$content['Key_name']] = true; } // END - while // Free result SQL_FREERESULT($result); + } else { + // Cache used + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',columnName=' . $keyName . ',result=' . intval($GLOBALS[__FUNCTION__][$tableName][$keyName]) . ' - CACHE!'); } // END - if // Return cache - return $GLOBALS[__FUNCTION__][$tableName][$mode]; + //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'tableName=' . $tableName . ',columnName=' . $keyName . ',result=' . intval($GLOBALS[__FUNCTION__][$tableName][$keyName]) . ' - EXIT!'); + return $GLOBALS[__FUNCTION__][$tableName][$keyName]; } // [EOF] diff --git a/inc/extensions-functions.php b/inc/extensions-functions.php index be86049739..9768022912 100644 --- a/inc/extensions-functions.php +++ b/inc/extensions-functions.php @@ -359,7 +359,7 @@ function registerExtension ($ext_name, $taskId, $dry_run = false, $ignoreUpdates if (isExtensionInstalledAndNewer('sql_patches', '0.0.6')) { // New way, with CSS //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . getCurrentExtensionName() . ',always_active=' . getThisExtensionAlwaysActive() . ', ext_ver=' . getCurrentExtensionVersion() . 'ext_css=' . getExtensionHasCss()); - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_extensions` (`ext_name`, `ext_active`, `ext_version`,`ext_has_css`) VALUES ('%s','%s','%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_extensions` (`ext_name`, `ext_active`, `ext_version`, `ext_has_css`) VALUES ('%s','%s','%s','%s')", array( getCurrentExtensionName(), getThisExtensionAlwaysActive(), @@ -1792,7 +1792,7 @@ function addAdminMenuSql ($action, $what, $title, $descr, $sort) { // Is what null? if (is_null($what)) { // Add main menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES('%s',NULL,'%s','%s',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('%s',NULL,'%s','%s',%s)", $action, $title, $descr, @@ -1800,7 +1800,7 @@ function addAdminMenuSql ($action, $what, $title, $descr, $sort) { ); } else { // Add sub menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES('%s','%s','%s','%s',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('%s','%s','%s','%s',%s)", $action, $what, $title, @@ -1824,14 +1824,14 @@ function addGuestMenuSql ($action, $what, $title, $sort) { // Is what null? if (is_null($what)) { // Add main menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES('%s',NULL,'%s','N','Y',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `visible`, `locked`, `sort`) VALUES ('%s',NULL,'%s','N','Y',%s)", $action, $title, bigintval($sort) ); } else { // Add sub menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES('%s','%s','%s','N','Y',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `visible`, `locked`, `sort`) VALUES ('%s','%s','%s','N','Y',%s)", $action, $what, $title, @@ -1854,14 +1854,14 @@ function addMemberMenuSql ($action, $what, $title, $sort) { // Is what null? if (is_null($what)) { // Add main menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES('%s',NULL,'%s','N','Y',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `visible`, `locked`, `sort`) VALUES ('%s',NULL,'%s','N','Y',%s)", $action, $title, bigintval($sort) ); } else { // Add sub menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES('%s','%s','%s','N','Y',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `visible`, `locked`, `sort`) VALUES ('%s','%s','%s','N','Y',%s)", $action, $what, $title, @@ -1884,7 +1884,7 @@ function addSponsorMenuSql ($action, $what, $title, $active, $sort) { // Is what null? if (is_null($what)) { // Add main menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_menu` (`action`,`what`,`title`,`active`,`sort`) VALUES('%s',NULL,'%s','%s',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_menu` (`action`, `what`, `title`, `active`, `sort`) VALUES ('%s',NULL,'%s','%s',%s)", $action, $title, $active, @@ -1892,7 +1892,7 @@ function addSponsorMenuSql ($action, $what, $title, $active, $sort) { ); } else { // Add sub menu - $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_menu` (`action`,`what`,`title`,`active`,`sort`) VALUES('%s','%s','%s','%s',%s)", + $sql = sprintf("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_menu` (`action`, `what`, `title`, `active`, `sort`) VALUES ('%s','%s','%s','%s',%s)", $action, $what, $title, diff --git a/inc/extensions/ext-admins.php b/inc/extensions/ext-admins.php index fa2482a170..c70d07f972 100644 --- a/inc/extensions/ext-admins.php +++ b/inc/extensions/ext-admins.php @@ -130,7 +130,7 @@ KEY (`admin_id`)", PRIMARY KEY (`id`), INDEX (`admin_id`)", 'Mail template -> admin connection table'); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('admins','admins_mails','Admin-Mails','Stellen Sie hier ein, welcher Admin welche Mail erhalten soll. Sie können dies (derzeit) jedoch erst, wenn einmal die Mail versendet wurde!',5)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('admins','admins_mails','Admin-Mails','Stellen Sie hier ein, welcher Admin welche Mail erhalten soll. Sie können dies (derzeit) jedoch erst, wenn einmal die Mail versendet wurde!',5)"); // Update notes (these will be set as task text!) setExtensionUpdateNotes("Kontrollieren Sie, welche Mails welcher Admin oder alle (admin_id=0) bekommen soll oder im UserLog (admin_id=-1) verzeichnet werden soll. Standardmässig wird weiter an alle versendet."); diff --git a/inc/extensions/ext-autopurge.php b/inc/extensions/ext-autopurge.php index c963ddeb13..517afd2a52 100644 --- a/inc/extensions/ext-autopurge.php +++ b/inc/extensions/ext-autopurge.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.4.0'); +setThisExtensionVersion('0.4.1'); // 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')); +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', '0.4.1')); // Keep this extension always active! setExtensionAlwaysActive('Y'); @@ -252,6 +252,16 @@ switch (getExtensionMode()) { // Update notes (these will be set as task text!) setExtensionUpdateNotes("Template-Problem beseitigt. Dies verhinderte das Abspeichern der Einstellungen."); break; + + case '0.4.1': // SQL queries for v0.4.1 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('autopurge_add','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Rückschriften bei Auto-Löschungen werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-beg.php b/inc/extensions/ext-beg.php index 183f82a66f..0210a77943 100644 --- a/inc/extensions/ext-beg.php +++ b/inc/extensions/ext-beg.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.2.9'); +setThisExtensionVersion('0.3.0'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -153,7 +153,6 @@ INDEX (`userid`)", case '0.1.2': // SQL queries for v0.1.2 - addConfigAddSql('beg_mode', "ENUM('DIRECT','REF') NOT NULL DEFAULT 'REF'"); addConfigAddSql('beg_ranks', 'TINYINT(3) UNSIGNED NOT NULL DEFAULT 10'); addConfigAddSql('beg_active', "ENUM('Y','N') NOT NULL DEFAULT 'N'"); addConfigAddSql('beg_rallye', "ENUM('Y','N') NOT NULL DEFAULT 'N'"); @@ -294,6 +293,18 @@ INDEX (`userid`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("Loggen der Referal-URLs hinzugefügt."); break; + + case '0.3.0': // SQL queries for v0.3.0 + addConfigDropSql('beg_mode'); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('beg','points','LOCKED','DIRECT')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('monthly_beg','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Monatliche Bettelrallye und die erbettelten {?POINTS?} werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-birthday.php b/inc/extensions/ext-birthday.php index 6d408decc2..223b85d70f 100644 --- a/inc/extensions/ext-birthday.php +++ b/inc/extensions/ext-birthday.php @@ -160,7 +160,6 @@ KEY (`userid`)", break; case '0.3.6': // SQL queries for v0.3.6 - addConfigAddSql('birthday_mode', "ENUM('DIRECT','REF') NOT NULL DEFAULT 'DIRECT'"); addConfigAddSql('birthday_active', "ENUM('Y','N') NOT NULL DEFAULT 'N'"); // Update notes (these will be set as task text!) @@ -186,6 +185,13 @@ CHANGE `birth_year` `birth_year` SMALLINT(4) UNSIGNED ZEROFILL NOT NULL DEFAULT // Update notes (these will be set as task text!) setExtensionUpdateNotes("Datenbankspalten umgestellt auf SMALLINT() UNSIGNED ZEROFILL."); break; + + case '0.4.0': // SQL queries for v0.4.0 + addConfigDropSql('birthday_mode'); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Dies brauchen wir nicht mehr."); + break; } // END - if break; diff --git a/inc/extensions/ext-bonus.php b/inc/extensions/ext-bonus.php index 28dd83f7df..b8b987bb2e 100644 --- a/inc/extensions/ext-bonus.php +++ b/inc/extensions/ext-bonus.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version of this extension -setThisExtensionVersion('0.9.5'); +setThisExtensionVersion('0.9.6'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.1.6', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2', '0.8.3', '0.8.4', '0.8.5', '0.8.6', '0.8.7', '0.8.8', '0.8.9', '0.9.0', '0.9.1', '0.9.2', '0.9.3', '0.9.4', '0.9.5')); +setExtensionVersionHistory(array('0.0.0', '0.1.6', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2', '0.8.3', '0.8.4', '0.8.5', '0.8.6', '0.8.7', '0.8.8', '0.8.9', '0.9.0', '0.9.1', '0.9.2', '0.9.3', '0.9.4', '0.9.5', '0.9.6')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -608,6 +608,16 @@ ORDER BY // Update notes setExtensionUpdateNotes("Filter zum Generieren von Admin-Links für Bonus-Mails hinzugefügt."); break; + + case '0.9.6': // SQL queries for v0.9.6 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('monthly_bonus','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Monatlicher Bonus wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-coupon.php b/inc/extensions/ext-coupon.php index a84c4b20eb..7b532b0830 100644 --- a/inc/extensions/ext-coupon.php +++ b/inc/extensions/ext-coupon.php @@ -77,7 +77,7 @@ PRIMARY KEY (`id`)", `coupon_code` VARCHAR(30) NULL DEFAULT NULL, `cashed_on` TIMESTAMP NULL DEFAULT NULL, PRIMARY KEY (`id`), -UNIQUE KEY `coupon_user` (`coupon_id`,`userid`), +UNIQUE KEY `coupon_user` (`coupon_id`, `userid`), UNIQUE KEY (`coupon_code`)", 'Coupon->user connection'); @@ -138,7 +138,15 @@ UNIQUE KEY (`coupon_code`)", addExtensionDependency('order'); // Insert data in new table - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`ext_name`,`column_name`,`locked_mode`,`payment_method`) VALUES('coupon','order_points','LOCKED','DIRECT')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('coupon_cashed','order_points','LOCKED','DIRECT')"); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes(''); + break; + + case '0.0.1': // SQL queries for v0.0.1 + // Update data in points_data table + addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_points_data` SET `subject`='coupon_cashed' WHERE `subject`='coupon' LIMIT 1"); // Update notes (these will be set as task text!) setExtensionUpdateNotes(''); diff --git a/inc/extensions/ext-debug.php b/inc/extensions/ext-debug.php index a4c4d1ac36..121ca72587 100644 --- a/inc/extensions/ext-debug.php +++ b/inc/extensions/ext-debug.php @@ -100,7 +100,7 @@ UNIQUE (`url`)", 'Debug clients'); // Add this exchange as first client - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_debug_client` (`url`,`title`,`webmaster`,`status`) VALUES ('{?URL?}','{?MAIN_TITLE?}','{?WEBMASTER?}','ACTIVE')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_debug_client` (`url`, `title`, `webmaster`, `status`) VALUES ('{?URL?}','{?MAIN_TITLE?}','{?WEBMASTER?}','ACTIVE')"); // Table for debug log <-> client connection addDropTableSql('debug_client_log'); @@ -110,7 +110,7 @@ UNIQUE (`url`)", `log_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE (`log_id`), -INDEX `client_log` (`client_id`,`log_id`)", +INDEX `client_log` (`client_id`, `log_id`)", 'Debug client <-> log connection'); // Guest menus diff --git a/inc/extensions/ext-doubler.php b/inc/extensions/ext-doubler.php index e411c54321..da45567cbb 100644 --- a/inc/extensions/ext-doubler.php +++ b/inc/extensions/ext-doubler.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.1.7'); +setThisExtensionVersion('0.1.8'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -164,79 +164,90 @@ INDEX (`userid`)", setExtensionUpdateNotes("{?POINTS?}-Guthaben des Verdopplers kann optional nicht mit einbezogen werden."); break; - case '0.0.5': // SQL queries for v0.0.5 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Counter-Stand und noch zum Verdoppeln übrige {?POINTS?} in Templates eingebunden. Auflistung in Admin-Bereich komplettiert."); - break; - - case '0.0.6': // SQL queries for v0.0.6 - addConfigAddSql('doubler_max_sent', 'TINYINT(3) UNSIGNED NOT NULL DEFAULT 1'); - addConfigAddSql('doubler_group_sent', 'TINYINT(3) UNSIGNED NOT NULL DEFAULT 1'); - addConfigAddSql('doubler_sent_all', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); - - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Gebührenabzug wird beim Einzahlen abgezogen (wurde von Auszahlung abgezogen) und maximal bei Auszahlung zu kontrollierende Accounts einstellbar.
Template admin_config_doubler_pro.tpl ist überflüssig geworden. Bitte löschen Sie dies!"); - break; - - case '0.0.7': // SQL queries for v0.0.7 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Wörter {?mt_word?}, {?mt_word2?} und {?mt_word3?} sind austauschbar.

Minus-Guthaben des Verdoppler-Accounts repariert und Mitgliedsmail erweitert mit Transaktionsummer und IP-Nummer."); - break; - - case '0.0.8': // SQL queries for v0.0.8 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Bitte verschieben Sie die doubler-Templates (Ordner: {?PATH?}/templates/".getLanguage()."/html/) in den neuen Order doubler!"); - break; - - case '0.0.9': // SQL queries for v0.0.9 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Abspeichern von Einstellungen repariert."); - break; - - case '0.1.0': // SQL queries for v0.2.1 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Vorbereitung auf die neue Mediendaten v0.0.4."); - break; - - case '0.1.1': // SQL queries for v0.1.1 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Zwei SQL-Fehler in inc/doubler_send.php beseitigt."); - break; - - case '0.1.2': // SQL queries for v0.1.2 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Sicherheitsupdate für die Include-Befehle."); - break; - - case '0.1.3': // SQL queries for v0.1.3 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("De-/Aktivieren des mit dieser Erweiterung verknüpften Modules eingebunden."); - break; - - case '0.1.4': // SQL queries for v0.1.4 - addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_member_menu` SET `action`='extras', `sort`=4 WHERE `what`='doubler' LIMIT 1"); - - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Mitgliedsmenü komplett umgebaut."); - break; - - case '0.1.5': // SQL queries for v0.1.5 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Hash-Erstellung von md5() auf bessere Funktion generateHash() umgestellt."); - break; - - case '0.1.6': // SQL queries for v0.1.6 - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Fehlerhinweis bei deaktivierter Erweiterung verbessert."); - break; - - case '0.1.7': // SQL queries for v0.1.7 - addExtensionSql('UPDATE `{?_MYSQL_PREFIX?}_config` SET `doubler_charge`=`doubler_charge`*100 WHERE `config`=0 LIMIT 1'); - addExtensionSql('UPDATE `{?_MYSQL_PREFIX?}_config` SET `doubler_ref`=`doubler_ref`*100 WHERE `config`=0 LIMIT 1'); - - // Update notes (these will be set as task text!) - setExtensionUpdateNotes("Fehlerhinweis bei deaktivierter Erweiterung verbessert."); - break; + case '0.0.5': // SQL queries for v0.0.5 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Counter-Stand und noch zum Verdoppeln übrige {?POINTS?} in Templates eingebunden. Auflistung in Admin-Bereich komplettiert."); + break; + + case '0.0.6': // SQL queries for v0.0.6 + addConfigAddSql('doubler_max_sent', 'TINYINT(3) UNSIGNED NOT NULL DEFAULT 1'); + addConfigAddSql('doubler_group_sent', 'TINYINT(3) UNSIGNED NOT NULL DEFAULT 1'); + addConfigAddSql('doubler_sent_all', "ENUM('Y','N') NOT NULL DEFAULT 'Y'"); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Gebührenabzug wird beim Einzahlen abgezogen (wurde von Auszahlung abgezogen) und maximal bei Auszahlung zu kontrollierende Accounts einstellbar.
Template admin_config_doubler_pro.tpl ist überflüssig geworden. Bitte löschen Sie dies!"); + break; + + case '0.0.7': // SQL queries for v0.0.7 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Wörter {?mt_word?}, {?mt_word2?} und {?mt_word3?} sind austauschbar.

Minus-Guthaben des Verdoppler-Accounts repariert und Mitgliedsmail erweitert mit Transaktionsummer und IP-Nummer."); + break; + + case '0.0.8': // SQL queries for v0.0.8 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Bitte verschieben Sie die doubler-Templates (Ordner: {?PATH?}/templates/".getLanguage()."/html/) in den neuen Order doubler!"); + break; + + case '0.0.9': // SQL queries for v0.0.9 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Abspeichern von Einstellungen repariert."); + break; + + case '0.1.0': // SQL queries for v0.2.1 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Vorbereitung auf die neue Mediendaten v0.0.4."); + break; + + case '0.1.1': // SQL queries for v0.1.1 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Zwei SQL-Fehler in inc/doubler_send.php beseitigt."); + break; + + case '0.1.2': // SQL queries for v0.1.2 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Sicherheitsupdate für die Include-Befehle."); + break; + + case '0.1.3': // SQL queries for v0.1.3 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("De-/Aktivieren des mit dieser Erweiterung verknüpften Modules eingebunden."); + break; + + case '0.1.4': // SQL queries for v0.1.4 + addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_member_menu` SET `action`='extras', `sort`=4 WHERE `what`='doubler' LIMIT 1"); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Mitgliedsmenü komplett umgebaut."); + break; + + case '0.1.5': // SQL queries for v0.1.5 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Hash-Erstellung von md5() auf bessere Funktion generateHash() umgestellt."); + break; + + case '0.1.6': // SQL queries for v0.1.6 + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Fehlerhinweis bei deaktivierter Erweiterung verbessert."); + break; + + case '0.1.7': // SQL queries for v0.1.7 + addExtensionSql('UPDATE `{?_MYSQL_PREFIX?}_config` SET `doubler_charge`=`doubler_charge`*100 WHERE `config`=0 LIMIT 1'); + addExtensionSql('UPDATE `{?_MYSQL_PREFIX?}_config` SET `doubler_ref`=`doubler_ref`*100 WHERE `config`=0 LIMIT 1'); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Fehlerhinweis bei deaktivierter Erweiterung verbessert."); + break; + + case '0.1.8': // SQL queries for v0.1.8 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('doubler_direct','points','LOCKED','DIRECT')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('doubler_reset','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Doppler-Gutschriften werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-grade.php b/inc/extensions/ext-grade.php index 21fc8de95d..c09535931c 100644 --- a/inc/extensions/ext-grade.php +++ b/inc/extensions/ext-grade.php @@ -83,7 +83,7 @@ UNIQUE KEY (`grade_cash_name`)", `grade_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `grade_cash_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`), -UNIQUE KEY `grade_cash` (`grade_id`,`grade_cash_id`), +UNIQUE KEY `grade_cash` (`grade_id`, `grade_cash_id`), INDEX (`grade_cash_id`)", 'Grade<->cash data connection'); @@ -95,7 +95,7 @@ INDEX (`grade_cash_id`)", `grade_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `grade_expired` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), -UNIQUE KEY (`userid`,`grade_id`), +UNIQUE KEY (`userid`, `grade_id`), INDEX (`grade_id`)", 'Grade<->user connection'); diff --git a/inc/extensions/ext-iso3166.php b/inc/extensions/ext-iso3166.php index 28aa12dd97..4dbab08b30 100644 --- a/inc/extensions/ext-iso3166.php +++ b/inc/extensions/ext-iso3166.php @@ -73,7 +73,7 @@ switch (getExtensionMode()) { switch (getCurrentExtensionVersion()) { case '0.0.1': // SQL queries for v0.0.2 addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_countries` ADD `provider` ENUM('user','ext-iso3166') NOT NULL DEFAULT 'user'"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_countries` (`code`,`descr`,`provider`) + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_countries` (`code`, `descr`, `provider`) VALUES ('AD', 'Andorra', 'ext-iso3166'), ('AE', 'Vereinigte Arabische Emirate', 'ext-iso3166'), ('AF', 'Afghanistan', 'ext-iso3166'), diff --git a/inc/extensions/ext-mailid.php b/inc/extensions/ext-mailid.php index f1c09b1f3d..e83b2905de 100644 --- a/inc/extensions/ext-mailid.php +++ b/inc/extensions/ext-mailid.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.3.3'); +setThisExtensionVersion('0.3.4'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -228,7 +228,15 @@ switch (getExtensionMode()) { // Update notes (these will be set as task text!) setExtensionUpdateNotes("Variablen-Handling scripteweitgeändert."); break; - } + + case '0.3.4': // SQL queries for v0.3.4 + // This update depends on latest sql_patches version + addExtensionDependency('sql_patches'); + + // Insert data in points_data + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('mailid_payback','points','LOCKED','DIRECT')"); + break; + } // END - switch break; case 'modify': // When the extension got modified @@ -243,7 +251,7 @@ switch (getExtensionMode()) { default: // Unknown extension mode logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName())); break; -} +} // END - switch // [EOF] ?> diff --git a/inc/extensions/ext-network.php b/inc/extensions/ext-network.php index 2284ecbfe5..d65ad5faf1 100644 --- a/inc/extensions/ext-network.php +++ b/inc/extensions/ext-network.php @@ -100,7 +100,7 @@ UNIQUE (`network_short_name`)", `network_type_click_url` VARCHAR(255) NOT NULL DEFAULT '', `network_type_banner_url` VARCHAR(255) NULL DEFAULT NULL, PRIMARY KEY (`network_type_id`), -UNIQUE `provider_type` (`network_id`,`network_type_handle`)", +UNIQUE `provider_type` (`network_id`, `network_type_handle`)", 'Types provideable by networks'); // HTTP parameters (names) for URLs @@ -113,8 +113,8 @@ UNIQUE `provider_type` (`network_id`,`network_type_handle`)", `request_param_value` VARCHAR(20) NOT NULL DEFAULT 'invalid', `request_param_default` VARCHAR(255) NULL DEFAULT NULL, PRIMARY KEY (`network_param_id`), -UNIQUE `provider_type_key` (`network_id`,`network_type_id`,`request_param_key`), -UNIQUE `provider_type_value` (`network_id`,`network_type_id`,`request_param_value`),", +UNIQUE `provider_type_key` (`network_id`, `network_type_id`, `request_param_key`), +UNIQUE `provider_type_value` (`network_id`, `network_type_id`, `request_param_value`),", 'Request parameters for GET/POST request'); // Error status codes @@ -125,7 +125,7 @@ UNIQUE `provider_type_value` (`network_id`,`network_type_id`,`request_param_valu `network_type_code_value` VARCHAR(50) NOT NULL DEFAULT '', `network_type_code_type` VARCHAR(100) NOT NULL DEFAULT 'INVALID_TYPE', PRIMARY KEY (`network_type_code_id`), -UNIQUE `code_type` (`network_type_code_value`,`network_type_id`), +UNIQUE `code_type` (`network_type_code_value`, `network_type_id`), INDEX (`network_type_id`)", 'Error codes for all types'); @@ -156,7 +156,7 @@ UNIQUE (`network_translation_name`)", `network_api_index` SMALLINT(5) UNSIGNED NOT NULL DEFAULT 0, `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`network_api_id`), -UNIQUE `provider_type_key` (`network_id`,`network_type_id`,`network_api_index`), +UNIQUE `provider_type_key` (`network_id`, `network_type_id`, `network_api_index`), INDEX (`sort`)", 'Translation of API responses, generic data, DO NOT ALTER!'); @@ -170,8 +170,8 @@ INDEX (`sort`)", `network_query_amount` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `network_active` ENUM('Y','N') NOT NULL DEFAULT 'Y', PRIMARY KEY (`network_id`), -UNIQUE `network_affiliate` (`network_id`,`network_affiliate_id`), -UNIQUE `affiliate_site` (`network_affiliate_id`,`network_site_id`)", +UNIQUE `network_affiliate` (`network_id`, `network_affiliate_id`), +UNIQUE `affiliate_site` (`network_affiliate_id`, `network_site_id`)", 'Configuration data from the webmaster (you!)'); // Configuration data for e.g. reload-time @@ -186,7 +186,7 @@ UNIQUE `affiliate_site` (`network_affiliate_id`,`network_site_id`)", `min_payment` FLOAT(20,5) UNSIGNED NOT NULL DEFAULT 0.00000, `allow_erotic` VARCHAR(10) NOT NULL DEFAULT '', PRIMARY KEY (`network_data_id`), -UNIQUE `provider_type` (`network_id`,`network_type_id`)", +UNIQUE `provider_type` (`network_id`, `network_type_id`)", 'Configuration data for every type (e.g. reload-time)'); // Cache for queried APIs. Re-check depends on config @@ -200,7 +200,7 @@ UNIQUE `provider_type` (`network_id`,`network_type_id`)", `network_cache_data` MEDIUMBLOB, `network_cache_timestamp` TIMESTAMP NULL DEFAULT NULL, PRIMARY KEY (`network_cache_id`), -UNIQUE `provider_type` (`network_id`,`network_type_id`)", +UNIQUE `provider_type` (`network_id`, `network_type_id`)", 'Cache for all queried APIs'); // Reload locks for several types @@ -212,7 +212,7 @@ UNIQUE `provider_type` (`network_id`,`network_type_id`)", `network_reload_lock` SMALLINT(5) UNSIGNED NOT NULL DEFAULT 0, `network_inserted` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`network_reload_id`), -UNIQUE `provider_type` (`network_id`,`network_type_id`)", +UNIQUE `provider_type` (`network_id`, `network_type_id`)", 'Reload locks'); // Insert API response array translations, these will be used for calling the right filter function @@ -270,7 +270,7 @@ UNIQUE `provider_type` (`network_id`,`network_type_id`)", ('REQUEST_PARAMETER_INCOMPLETE')"); // Sponsor networks - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_network_data` (`network_short_name`, `network_title`, `network_reflink`, `network_data_seperator`, `network_row_seperator`, `network_request_type`, `network_charset`,`network_require_id_card`) VALUES + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_network_data` (`network_short_name`, `network_title`, `network_reflink`, `network_data_seperator`, `network_row_seperator`, `network_request_type`, `network_charset`, `network_require_id_card`) VALUES ('a3h', 'A3H', 'http://www.a3h.de?ref=1447', '|', '|', 'GET', 'WINDOWS-1252','N'), ('abiszed','AbisZED-Netz','http://abiszed-netz.de/index.php?ref=557', '|', '|', 'GET', 'WINDOWS-1252','Y'), ('admagnet', 'AD-Magnet', 'http://www.ad-magnet.de/index.php?ref=495', '|', '|', 'GET', 'ISO-8859-1','N'), @@ -303,7 +303,7 @@ UNIQUE `provider_type` (`network_id`,`network_type_id`)", ('adconvention', 'AdConvention', 'http://www.adconvention.de?ref=233', '|', '|', 'GET', 'WINDOWS-1252','N')"); // Network type handlers - A3H - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_network_types` (`network_type_id`, `network_id`,`network_type_handle`,`network_type_api_url`,`network_type_click_url`,`network_type_banner_url`) VALUES + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_network_types` (`network_type_id`, `network_id`, `network_type_handle`, `network_type_api_url`, `network_type_click_url`, `network_type_banner_url`) VALUES (1, 1, 'banner', 'http://www.a3h.de/interface/out_banner.php', 'http://www.a3h.de/bannerklf.php?id=%CID%', 'http://www.a3h.de/banner.php?id=%CID%'), (2, 1, 'textlink', 'http://www.a3h.de/interface/out_textlink.php', 'http://www.a3h.de/textlinkklick.php?id=%CID%', NULL), (3, 1, 'surfbar', 'http://www.a3h.de/interface/out_sbanner.php', 'http://www.a3h.de/bannerklf.php?id=%CID%', 'http://www.a3h.de/banner.php?id=%CID%'), diff --git a/inc/extensions/ext-newsletter.php b/inc/extensions/ext-newsletter.php index 3a81974a5a..f3ee17bd03 100644 --- a/inc/extensions/ext-newsletter.php +++ b/inc/extensions/ext-newsletter.php @@ -179,7 +179,7 @@ INDEX `newsletter_id` (`nl_id`)", `nl_order_placed` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, `nl_order_accepted` ENUM('Y','N') NOT NULL DEFAULT 'N', PRIMARY KEY (`nl_order_id`), -UNIQUE KEY `sponsor_nl_topic` (`nl_sponsor_id`,`nl_id`,`nl_topic_id`), +UNIQUE KEY `sponsor_nl_topic` (`nl_sponsor_id`, `nl_id`, `nl_topic_id`), INDEX `topic` (`nl_topic_id`)", 'Newsletter orders'); diff --git a/inc/extensions/ext-rallye.php b/inc/extensions/ext-rallye.php index 6bdaf75503..812197fd9e 100644 --- a/inc/extensions/ext-rallye.php +++ b/inc/extensions/ext-rallye.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.3.5'); +setThisExtensionVersion('0.3.6'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -317,6 +317,16 @@ Zudem sollten Sie mindestens folgende Templates (in templates/".getLangu // Update notes (these will be set as task text!) setExtensionUpdateNotes("Filter hinzugefügt und ist von sql_patches abhängig."); break; + + case '0.3.6': // SQL queries for v0.3.6 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('rallye_winner','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Gewinn aus der Referal-Rallye wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-refback.php b/inc/extensions/ext-refback.php index 1720650b01..1c65b0cd5c 100644 --- a/inc/extensions/ext-refback.php +++ b/inc/extensions/ext-refback.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.0.2'); +setThisExtensionVersion('0.0.3'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0','0.0.1', '0.0.2')); +setExtensionVersionHistory(array('0.0.0','0.0.1', '0.0.2', '0.0.3')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -58,7 +58,7 @@ switch (getExtensionMode()) { `refback` float(4,1) NOT NULL DEFAULT 0.0, `points` FLOAT(20,5) DEFAULT 0.00000 NOT NULL, PRIMARY KEY (`id`), -UNIQUE `user_refid` (`userid`,`level`,`refid`), +UNIQUE `user_refid` (`userid`, `level`, `refid`), INDEX (`level`), INDEX (`refid`)", 'User Referals With Refback'); @@ -108,6 +108,16 @@ INDEX (`refid`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("Updates von ext-user hier her verschoben."); break; + + case '0.0.3': // SQL queries for v0.0.3 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('refback','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Refback-Gutschriften werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-register.php b/inc/extensions/ext-register.php index 26b080afc7..473c5195d0 100644 --- a/inc/extensions/ext-register.php +++ b/inc/extensions/ext-register.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.5.5'); +setThisExtensionVersion('0.5.6'); // 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', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5')); +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', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -343,6 +343,16 @@ PRIMARY KEY (`id`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("Weiteren Menüpunkt aus menu-{?DEFAULT_LANG?} heraus geholt."); break; + + case '0.5.6': // SQL queries for v0.5.6 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('register_welcome','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Anmeldewillkommensgutschrift wird nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-sponsor.php b/inc/extensions/ext-sponsor.php index 915d96807f..ca5943df12 100644 --- a/inc/extensions/ext-sponsor.php +++ b/inc/extensions/ext-sponsor.php @@ -155,7 +155,7 @@ INDEX (`ext_name`)", `active` ENUM('Y','N') NOT NULL DEFAULT 'N', `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) -UNIQUE KEY `action_what` (`action`,`what`), +UNIQUE KEY `action_what` (`action`, `what`), UNIQUE KEY (`what`), INDEX (`action`)", 'Sponsor menu'); @@ -303,10 +303,10 @@ INDEX (`sponsor_id`)", // addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_registry` (`ext_name`, `is_active`, `admin_id`, `stamp_added`) VALUES ('sponsor','N',".getCurrentAdminId().",NOW())"); addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_action_convert` (`ext_name`, `conv_rate`, `conv_name`) VALUES ('sponsor','10','Mails')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`,`pay_min_count`,`pay_rate`,`pay_currency`) VALUES ('Standard-Paket', 5, 1000.00000, '€')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`,`pay_min_count`,`pay_rate`,`pay_currency`) VALUES ('Spar-Paket', 1, 200.00000, '€')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`,`pay_min_count`,`pay_rate`,`pay_currency`) VALUES ('Power-Paket', 10, 2000.00000, '€')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`,`pay_min_count`,`pay_rate`,`pay_currency`) VALUES ('Sponsor-Paket', 20, 4000.00000, '€')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`, `pay_min_count`, `pay_rate`, `pay_currency`) VALUES ('Standard-Paket', 5, 1000.00000, '€')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`, `pay_min_count`, `pay_rate`, `pay_currency`) VALUES ('Spar-Paket', 1, 200.00000, '€')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`, `pay_min_count`, `pay_rate`, `pay_currency`) VALUES ('Power-Paket', 10, 2000.00000, '€')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_sponsor_paytypes` (`pay_name`, `pay_min_count`, `pay_rate`, `pay_currency`) VALUES ('Sponsor-Paket', 20, 4000.00000, '€')"); // // Admin menu // diff --git a/inc/extensions/ext-sql_patches.php b/inc/extensions/ext-sql_patches.php index 5adb509dfa..fcd19bfb74 100644 --- a/inc/extensions/ext-sql_patches.php +++ b/inc/extensions/ext-sql_patches.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.8.1'); +setThisExtensionVersion('0.8.2'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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', '0.5.2', '0.5.3', '0.5.4', '0.5.5', '0.5.6', '0.5.7', '0.5.8', '0.5.9', '0.6.0', '0.6.1', '0.6.2', '0.6.3', '0.6.4', '0.6.4', '0.6.5', '0.6.6', '0.6.7', '0.6.8', '0.6.9', '0.7.0', '0.7.1', '0.7.2', '0.7.3', '0.7.4', '0.7.5', '0.7.6', '0.7.7', '0.7.8', '0.7.9', '0.8.0', '0.8.1', '0.8.2')); // Keep this extension always active! setExtensionAlwaysActive('Y'); @@ -178,8 +178,6 @@ IN ( break; case '0.1.0': // SQL queries for v0.1.0 - addConfigAddSql('reg_points_mode', "ENUM('ref','direct') NOT NULL DEFAULT 'ref'"); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Soll der einmalige Ref-Bonus über das Referal-System (also alle oberen Refs bekommen auch etwas davon ab) oder direkt dem Werber aufgebucht werden?"); break; @@ -557,7 +555,7 @@ INDEX (`admin_id`)", case '0.5.0': // SQL queries for v0.5.0 addExtensionSql('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` DROP INDEX `level`'); addExtensionSql('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` DROP INDEX `userid`'); - addExtensionSql('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` ADD UNIQUE `userid_level` (`userid`,`level`)'); + addExtensionSql('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` ADD UNIQUE `userid_level` (`userid`, `level`)'); // Update notes (these will be set as task text!) setExtensionUpdateNotes("Referal-System unterstützt nun detailierte Referal-Übersicht und vieles mehr."); @@ -797,8 +795,6 @@ INDEX (`ip`)", break; case '0.7.8': // SQL queries for v0.7.8 - addConfigChangeSql('reg_points_mode', 'reg_points_mode', "ENUM('REF','DIRECT') NOT NULL DEFAULT 'REFERAL'"); - // Update notes (these will be set as task text!) setExtensionUpdateNotes("Konfigurationseinträge mit Spaltentyp ENUM werden nun immer komplett gross geschrieben."); break; @@ -811,16 +807,16 @@ INDEX (`ip`)", break; case '0.8.0': // SQL queries for v0.8.0 - // Points account data - addDropTableSql('points_data'); + // Points account data (this table should not be dropped or else you may have to re-install a lot extensions) addCreateTableSql('points_data', " `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, -`ext_name` VARCHAR(255) NOT NULL DEFAULT '', +`subject` VARCHAR(255) NOT NULL DEFAULT '', `column_name` VARCHAR(255) NOT NULL DEFAULT 'points', `locked_mode` ENUM('LOCKED','UNLOCKED') NOT NULL DEFAULT 'LOCKED', -`payment_method` ENUM('DIRECT','REF') NOT NULL DEFAULT 'REF', +`payment_method` ENUM('DIRECT','REFERAL') NOT NULL DEFAULT 'REFERAL', +`notify_recipient` ENUM('Y','N') NOT NULL DEFAULT 'N', PRIMARY KEY(`id`), -INDEX (`ext_name`)", +INDEX (`subject`)", 'Points account data'); // Admin menu @@ -837,6 +833,20 @@ INDEX (`ext_name`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("Level 0 ist nun auch NULL."); break; + + case '0.8.2': // SQL queries for v0.8.2 + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_points_data` DROP INDEX `ext_name`"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_points_data` CHANGE `ext_name` `subject` VARCHAR(255) NOT NULL DEFAULT ''"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_points_data` CHANGE `payment_method` `payment_method` ENUM('DIRECT','REFERAL') NOT NULL DEFAULT 'REFERAL'"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_points_data` ADD INDEX `subject` (`subject`)"); + addExtensionSql("ALTER TABLE `{?_MYSQL_PREFIX?}_points_data` ADD `notify_recipient` ENUM('Y','N') NOT NULL DEFAULT 'N'"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('pool_payback','points','LOCKED','DIRECT')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('mail_deleted','points','LOCKED','DIRECT')"); + addConfigDropSql('reg_points_mode'); + + // Update notes (these will be set as task text!) + setExtensionUpdateNotes("Es sollte der Gutschriftenbetreff und nicht der Erweiterungsname gepeichert werden, zudem brauchen wir einen Konfigurationseintrag nicht mehr."); + break; } // END - switch break; diff --git a/inc/extensions/ext-surfbar.php b/inc/extensions/ext-surfbar.php index f3e8a896b8..e0f0156358 100644 --- a/inc/extensions/ext-surfbar.php +++ b/inc/extensions/ext-surfbar.php @@ -68,8 +68,8 @@ switch (getExtensionMode()) { `url_reject_reason` VARCHAR(255) NOT NULL DEFAULT '', `url_fixed_reload` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`url_id`), -UNIQUE KEY `userid_url` (`url_userid`,`url`), -INDEX `status_userid` (`url_status`,`url_userid`)", +UNIQUE KEY `userid_url` (`url_userid`, `url`), +INDEX `status_userid` (`url_status`, `url_userid`)", 'Surfbar URLs'); // Reload locks @@ -80,7 +80,7 @@ INDEX `status_userid` (`url_status`,`url_userid`)", `locks_url_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `locks_last_surfed` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`locks_id`), -UNIQUE KEY `userid_url` (`locks_userid`,`locks_url_id`), +UNIQUE KEY `userid_url` (`locks_userid`, `locks_url_id`), INDEX (`locks_url_id`)", 'Surfbar reload locks'); @@ -92,7 +92,7 @@ INDEX (`locks_url_id`)", `salts_url_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `salts_last_salt` VARCHAR(255) NOT NULL DEFAULT '', PRIMARY KEY (`salts_id`), -UNIQUE KEY `salts_userid_url` (`salts_userid`,`salts_url_id`), +UNIQUE KEY `salts_userid_url` (`salts_userid`, `salts_url_id`), INDEX (`salts_url_id`)", 'Surfbar last used salts'); @@ -105,7 +105,7 @@ INDEX (`salts_url_id`)", `stats_count` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `stats_last_surfed` TIMESTAMP ON UPDATE CURRENT_TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`stats_id`), -UNIQUE KEY `userid_url` (`stats_userid`,`stats_url_id`), +UNIQUE KEY `userid_url` (`stats_userid`, `stats_url_id`), INDEX (`stats_url_id`)", 'Surfbar Statistics'); @@ -117,33 +117,33 @@ INDEX (`stats_url_id`)", `actions_action` ENUM('EDIT','DELETE','PAUSE','UNPAUSE','FRAMETEST','RETREAT','RESUBMIT','BOOKNOW') NULL DEFAULT NULL, `actions_new_status` ENUM('PENDING','ACTIVE','LOCKED','STOPPED','REJECTED','DELETED','MIGRATED','DEPLETED') NULL DEFAULT NULL, PRIMARY KEY (`actions_id`), -UNIQUE KEY `status_action` (`actions_status`,`actions_action`)", +UNIQUE KEY `status_action` (`actions_status`, `actions_action`)", 'Surfbar Member Actions'); // Member actions - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('PENDING','RETREAT','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('PENDING','FRAMETEST',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('PENDING','EDIT',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('ACTIVE','EDIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('ACTIVE','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('ACTIVE','PAUSE','STOPPED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('ACTIVE','FRAMETEST',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('LOCKED','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('LOCKED','FRAMETEST',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('LOCKED','RESUBMIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('STOPPED','EDIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('STOPPED','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('STOPPED','UNPAUSE','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('DEPLETED','EDIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('DEPLETED','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('REJECTED','EDIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('REJECTED','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('REJECTED','FRAMETEST',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('REJECTED','RESUBMIT','PENDING')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('MIGRATED','EDIT','MIGRATED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('MIGRATED','DELETE','DELETED')"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('MIGRATED','FRAMETEST',NULL)"); - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`,`actions_action`,`actions_new_status`) VALUES ('MIGRATED','BOOKNOW','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('PENDING','RETREAT','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('PENDING','FRAMETEST',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('PENDING','EDIT',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('ACTIVE','EDIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('ACTIVE','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('ACTIVE','PAUSE','STOPPED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('ACTIVE','FRAMETEST',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('LOCKED','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('LOCKED','FRAMETEST',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('LOCKED','RESUBMIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('STOPPED','EDIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('STOPPED','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('STOPPED','UNPAUSE','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('DEPLETED','EDIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('DEPLETED','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('REJECTED','EDIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('REJECTED','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('REJECTED','FRAMETEST',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('REJECTED','RESUBMIT','PENDING')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('MIGRATED','EDIT','MIGRATED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('MIGRATED','DELETE','DELETED')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('MIGRATED','FRAMETEST',NULL)"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_actions` (`actions_status`, `actions_action`, `actions_new_status`) VALUES ('MIGRATED','BOOKNOW','PENDING')"); // Config entries addConfigAddSql('surfbar_payment_model', "ENUM('STATIC','DYNAMIC') NOT NULL DEFAULT 'STATIC'"); @@ -196,6 +196,12 @@ UNIQUE KEY `status_action` (`actions_status`,`actions_action`)", // Register module addModuleSql('surfbar', 'Y', 'Y', 'N', 'N'); + // Insert data for points accounts + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('monthly_bonus','points','LOCKED','DIRECT')"); + + // This extension depends on ext-sql_patches + addExtensionDependency('sql_patches'); + // Register filters registerFilter('post_change_surfbar_url_status', 'SURFBAR_CHANGE_URL_STATUS', false, true, isExtensionDryRun()); registerFilter('pre_change_surfbar_url_status', 'SURFBAR_CHANGE_URL_VALIDATE_DATA', false, true, isExtensionDryRun()); diff --git a/inc/extensions/ext-transfer.php b/inc/extensions/ext-transfer.php index ebd9ba3152..200775833a 100644 --- a/inc/extensions/ext-transfer.php +++ b/inc/extensions/ext-transfer.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version number -setThisExtensionVersion('0.2.9'); +setThisExtensionVersion('0.3.0'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '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')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -269,7 +269,17 @@ KEY (`to_userid`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("Fehlerhinweis bei deaktivierter Erweiterung verbessert."); break; - } + + case '0.3.0': // SQL queries for v0.3.0 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('transfer','points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Ünerweisungen anderer Mitglieder werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; + } // END - switch break; case 'modify': // When the extension got modified @@ -288,7 +298,7 @@ KEY (`to_userid`)", default: // Unknown extension mode logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName())); break; -} +} // END - switch // [EOF] ?> diff --git a/inc/extensions/ext-user.php b/inc/extensions/ext-user.php index 195d0dd1aa..76cebee280 100644 --- a/inc/extensions/ext-user.php +++ b/inc/extensions/ext-user.php @@ -99,7 +99,7 @@ INDEX (`cat_id`)", PRIMARY KEY (`userid`), UNIQUE (`user_hash`), INDEX (`refid`), -INDEX `status_mails` (`status`,`max_mails`)", +INDEX `status_mails` (`status`, `max_mails`)", 'Main user data'); addDropTableSql('user_points'); diff --git a/inc/extensions/ext-wernis.php b/inc/extensions/ext-wernis.php index 3f6a9240ac..0418aa952c 100644 --- a/inc/extensions/ext-wernis.php +++ b/inc/extensions/ext-wernis.php @@ -41,10 +41,10 @@ if (!defined('__SECURITY')) { } // END - if // Version of this extension -setThisExtensionVersion('0.0.3'); +setThisExtensionVersion('0.0.4'); // Version history array (add more with , '0.0.1' and so on) -setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3')); +setExtensionVersionHistory(array('0.0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4')); switch (getExtensionMode()) { case 'register': // Do stuff when installation is running @@ -134,6 +134,16 @@ INDEX (`userid`)", // Update notes (these will be set as task text!) setExtensionUpdateNotes("WDS66-Username muss nun eintragen werden (API-Anpassung)."); break; + + case '0.0.4': // SQL queries for v0.0.4 + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`) VALUES ('wernis_withdraw','order_points','LOCKED','DIRECT')"); + + // This depends on ext-sql_patches + addExtensionDependency('sql_patches'); + + // Update notes + setExtensionUpdateNotes("Überweisungen vom Portal werden nun über die Tabelle {OPEN_CONFIG}_MYSQL_PREFIX{CLOSE_CONFIG}_points_data verwaltet."); + break; } // END - switch break; diff --git a/inc/extensions/ext-yoomedia.php b/inc/extensions/ext-yoomedia.php index 7e52a3bb00..a1ae4ba2e2 100644 --- a/inc/extensions/ext-yoomedia.php +++ b/inc/extensions/ext-yoomedia.php @@ -80,7 +80,7 @@ switch (getExtensionMode()) { `y_reload` SMALLINT(6) UNSIGNED NOT NULL DEFAULT 0, `inserted` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`id`), -UNIQUE `y_type` (`type`,`y_id`)", +UNIQUE `y_type` (`type`, `y_id`)", 'Reload lock reminder for Yoo!Media campaigns'); break; diff --git a/inc/filter-functions.php b/inc/filter-functions.php index cadab03f46..d4d890b7c5 100644 --- a/inc/filter-functions.php +++ b/inc/filter-functions.php @@ -64,7 +64,7 @@ function initFilterSystem () { // Load all filters $result = SQL_QUERY('SELECT - `filter_name`,`filter_function`,`filter_active`' . $add . ' + `filter_name`, `filter_function`, `filter_active`' . $add . ' FROM `{?_MYSQL_PREFIX?}_filters` ORDER BY diff --git a/inc/filter/coupon_filter.php b/inc/filter/coupon_filter.php index 4aa7b8e82f..9a25fb0100 100644 --- a/inc/filter/coupon_filter.php +++ b/inc/filter/coupon_filter.php @@ -42,9 +42,10 @@ if (!defined('__SECURITY')) { // Filter to change column name for the right "points account" function FILTER_COUPON_CHANGE_POINTS_COLUMN_NAME ($filterData) { - // Get the column name from extension's name and 'locked' //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Called!'); - $filterData['column'] = getPointsColumnNameFromExtensionNameLocked('coupon', $filterData['locked']); + // Get the column name from extension's name and 'locked' + die('
'.print_r($filterData,true).'
'); + $filterData['column'] = getPointsColumnNameFromSubjectLocked($filterData['subject'], $filterData['locked']); // Return data //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Done!'); diff --git a/inc/filter/order_filter.php b/inc/filter/order_filter.php index 1e508f73a5..dd80fcdc35 100644 --- a/inc/filter/order_filter.php +++ b/inc/filter/order_filter.php @@ -42,8 +42,8 @@ if (!defined('__SECURITY')) { // Filter for returning given user's order points function FILTER_ORDER_POINTS ($filterData) { - // Is ext-user installed and active? //* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'Called!'); + // Is ext-user installed and active? if (isExtensionActive('user')) { // Get the points and add them to the existing $filterData['points'] += countSumTotalData($filterData['userid'], 'user_points', 'order_points'); diff --git a/inc/filters.php b/inc/filters.php index 5a52b5e742..775b140a7b 100644 --- a/inc/filters.php +++ b/inc/filters.php @@ -70,7 +70,7 @@ function FILTER_FLUSH_FILTERS () { $removed = '0'; // Prepare SQL queries - $insertSQL = 'INSERT INTO `{?_MYSQL_PREFIX?}_filters` (`filter_name`,`filter_function`,`filter_active`) VALUES'; + $insertSQL = 'INSERT INTO `{?_MYSQL_PREFIX?}_filters` (`filter_name`, `filter_function`, `filter_active`) VALUES'; $removeSQL = 'DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_filters` WHERE'; // Write all filters to database diff --git a/inc/fix_user_points.php b/inc/fix_user_points.php index addaae100c..0d8dd917c2 100644 --- a/inc/fix_user_points.php +++ b/inc/fix_user_points.php @@ -74,7 +74,7 @@ if (!SQL_HASZERONUMS($result)) { // Nothing has been updated? if (SQL_HASZEROAFFECTED()) { // Then insert it - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_points` (`userid`,`ref_depth`,`%s`) VALUES(%s,NULL,%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_points` (`userid`, `ref_depth`, `%s`) VALUES (%s,NULL,%s)", array( $column, $row['userid'], diff --git a/inc/functions.php b/inc/functions.php index c85d6fde9a..08fa13dc17 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -2410,6 +2410,24 @@ function translateTaskType ($taskType) { return $message; } +// Translates points subject to human-readable +function translatePointsSubject ($subject) { + // Construct message id + $messageId = 'POINTS_SUBJECT_' . strtoupper($subject) . ''; + + // Is the message id there? + if (isMessageIdValid($messageId)) { + // Then construct message + $message = '{--' . $messageId . '--}'; + } else { + // Else it is an unknown task type + $message = '{%message,POINTS_SUBJECT_UNKNOWN=' . $subject . '%}'; + } // END - if + + // Return message + return $message; +} + // "Translates" 'true' to true and 'false' to false function convertStringToBoolean ($str) { // Trim it lower-case for validation diff --git a/inc/gen_refback.php b/inc/gen_refback.php index cd20c0f730..9f137f0bfd 100644 --- a/inc/gen_refback.php +++ b/inc/gen_refback.php @@ -53,7 +53,7 @@ if (!SQL_HASZERONUMS($result)) { SQL_QUERY('UPDATE `{?_MYSQL_PREFIX?}_refsystem` SET `level`=`level`+1', __FILE__, __LINE__); // Add it again - SQL_ALTER_TABLE('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` ADD UNIQUE `userid_level` ( `userid`,`level` )', __FILE__, __LINE__); + SQL_ALTER_TABLE('ALTER TABLE `{?_MYSQL_PREFIX?}_refsystem` ADD UNIQUE `userid_level` ( `userid`, `level` )', __FILE__, __LINE__); // Rebuild cache rebuildCache('refsystem', 'refsystem'); diff --git a/inc/language/beg_de.php b/inc/language/beg_de.php index 700eecaa99..fb22599967 100644 --- a/inc/language/beg_de.php +++ b/inc/language/beg_de.php @@ -74,7 +74,6 @@ addMessages(array( 'GUEST_BEG_HAVE_FUN' => "Heute noch anmelden und Spass haben.", 'ADMIN_CONFIG_BEG_POINTS_MAX' => "Maximale erbettelbare {?POINTS?} bei Klick auf Bettellink", 'ADMIN_CONFIG_BEG_USERID' => "Mitglied-Account zum Abbuchen der erbettelten {?POINTS?}", - 'ADMIN_CONFIG_SELECT_BEG_MODE' => "Vergütungsmodus der erbettelten {?POINTS?}", 'BEG_SORRY_YOURE_LOGGED_IN_1' => "Oh, schade! Sie haben vermutlich auf Ihren eigenen Bettel-Link mit der Mitglieder-Id ", 'BEG_SORRY_YOURE_LOGGED_IN_2' => " geklickt. Sie haben somit auch keine ", 'BEG_SORRY_YOURE_LOGGED_IN_3' => " {?POINTS?} erhalten.", diff --git a/inc/language/birthday_de.php b/inc/language/birthday_de.php index 64b81b9851..db2aea6953 100644 --- a/inc/language/birthday_de.php +++ b/inc/language/birthday_de.php @@ -48,7 +48,6 @@ addMessages(array( 'ADMIN_CONFIG_BIRTHDAY_POINTS_NOTE' => "Wert 0 deaktiviert die Extragutschrift.", 'MEMBER_BIRTHDAY_CANNOT_STATUS' => "Kann keine {?POINTS?} gutschreiben! Status Ihres Accounts: {%%pipe,translateUserStatus=%s%%}", 'MEMBER_BIRTHDAY_CANNOT_LOAD_DATA' => "Entweder haben Sie bereits Ihr Geburtsgeschenk erhalten oder Sie haben heute keinen Geburtstag.", - 'ADMIN_CONFIG_SELECT_BIRTHDAY_MODE' => "Vergütungsmodus der {?POINTS?}", 'ADMIN_CONFIG_BIRTHDAY_ONLY_ACTIVE' => "Nur aktive Mitglieder erhalten die Geburtstagsgutschrift?
(Nur in Verbindung mit der Erweiterung autopurge!)
", )); diff --git a/inc/language/de.php b/inc/language/de.php index 81b0e2e829..3944de41ff 100644 --- a/inc/language/de.php +++ b/inc/language/de.php @@ -764,9 +764,6 @@ addMessages(array( 'ADMIN_UNCONFIRMED_STATS_MISSING' => "Es fehlen Daten in der Mitglieder-Statistik zur Mail-Id %s .", 'ADMIN_UNCONFIRMED_INVALID_LINK' => "Ungütigen Link aufgerufen oder Mail ist nicht mehr vorhanden.", 'ADMIN_UNCONFIRMED_NO_LINK_LEFT' => "Diese Mailbuchung wurde komplett bestätigt.", - 'ADMIN_CONFIG_REFMODE' => "Soll die einmalige Referal-Gutschrift dem Werber alleine oder auch seinem Werber (usw.) gutgeschrieben werden?", - 'ADMIN_CONFIG_REFMODE_REF' => "Werber und seinen Werbern gutschreiben.", - 'ADMIN_CONFIG_REFMODE_DIRECT' => "Nur dem direkten Werber gutschreiben.", 'ADMIN_HEADER_LOCK_ACCOUNT' => "Mitgliedsaccount %s sperren", 'ADMIN_HEADER_UNLOCK_ACCOUNT' => "Mitgliedsaccount %s freigeben", 'ADMIN_HEADER_DELETE_ACCOUNT' => "Mitgliedsaccount %s löschen", diff --git a/inc/language/other_de.php b/inc/language/other_de.php index b598172354..d0fc4a8266 100644 --- a/inc/language/other_de.php +++ b/inc/language/other_de.php @@ -66,13 +66,11 @@ addMessages(array( 'ADMIN_CONFIG_SELECT_CSS_OUTPUT_MODE_DIRECT' => "Per <link>-Tag ausgeben (Debug!)", 'ADMIN_CONFIG_SELECT_CSS_OUTPUT_MODE_FILE' => "Per css.php ausgeben", 'ADMIN_CONFIG_SELECT_CSS_OUTPUT_MODE_INLINE' => "In <style>-Tag ausgeben", - 'ADMIN_CONFIG_GUEST_MENU' => "Gastmenü ein-/ausblenden", - 'ADMIN_CONFIG_MEMBER_MENU' => "Mitgliedsmenü ein-/ausblenden", - 'ADMIN_CONFIG_YOURE_HERE' => "Navigation "Sie sind hier" ein-/ausblenden", - 'ADMIN_IS_SHOWN' => "Einblenden", - 'ADMIN_IS_NOT_SHOWN' => "Ausblenden", - 'ADMIN_CONFIG_MT_WORD' => "Art Ihres Tausches (1. Fall)", - 'ADMIN_CONFIG_MT_WORD2' => "Art Ihres Tausches (2. Fall)", + 'ADMIN_CONFIG_GUEST_MENU' => "Gastmenü einblenden?", + 'ADMIN_CONFIG_MEMBER_MENU' => "Mitgliedsmenü einblenden?", + 'ADMIN_CONFIG_YOURE_HERE' => "Navigation "Sie sind hier" einblenden?", + 'ADMIN_CONFIG_MT_WORD' => "Art Ihres Tausches (1. Fall, Singular)", + 'ADMIN_CONFIG_MT_WORD2' => "Art Ihres Tausches (2. Fall, Singular)", 'ADMIN_CONFIG_MT_WORD3' => "Art Ihres Tausches (1. Fall, Plural)", 'ADMIN_CONFIG_REJECT_URL' => "Standard-URL bei Ablehnung der Mailbuchung", 'ADMIN_CONFIG_SHOW_TIMINGS' => "Skript-Statistiken im Seitenfuss einblenden (nützlich zum Debuggen)", diff --git a/inc/language/surfbar_de.php b/inc/language/surfbar_de.php index ee670c7e64..735f79f6cd 100644 --- a/inc/language/surfbar_de.php +++ b/inc/language/surfbar_de.php @@ -71,9 +71,7 @@ addMessages(array( 'ADMIN_CONFIG_SURFBAR_NOTIFICATION_MODE' => "Benachrichtigungen sofort oder beim täglichen Reset aussenden? ("Sofort" kann zu Verzögerungen und/oder Belastung des Servers führen.", 'ADMIN_CONFIG_SURFBAR_NOTIFICATION_MODE_INSTANT' => "Sofort aussenden", 'ADMIN_CONFIG_SURFBAR_NOTIFICATION_MODE_RESET' => "Beim täglichen Reset", - 'ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM' => "Soll bei Aufruf der Surfbar durch einen Gast ein Loginformular angezeigt oder zur Startseite weitergeleitet werden?", - 'ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM_Y' => "Loginformular angzeigen.", - 'ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM_N' => "Zur Startseite weiterleiten.", + 'ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM' => "Soll bei Aufruf der Surfbar durch einen Gast ein Loginformular angezeigt oder zur Startseite weitergeleitet werden? Ja=Loginformular anzeigen; Nein=Zur Startseite weiterleiten.", // Admin non-config titles 'ADMIN_SURFBAR_STATS_TITLE' => "Mitglieder-Statistik der Surfbar", diff --git a/inc/libs/autopurge_functions.php b/inc/libs/autopurge_functions.php index 270c7a9f90..72d4e0ae7e 100644 --- a/inc/libs/autopurge_functions.php +++ b/inc/libs/autopurge_functions.php @@ -49,7 +49,7 @@ function addPointsAutoPurge ($userid, $points) { } // END - if // Add points over the ref system directly now - addPointsDirectly('autopurge_add', $userid, $points); + addPointsThroughReferalSystem('autopurge_add', $userid, $points); // Send out mail to user $message = loadEmailTemplate('member_autopurge_points', array('points' => $points), $userid); diff --git a/inc/libs/beg_functions.php b/inc/libs/beg_functions.php index 8035ccf27d..12941204e0 100644 --- a/inc/libs/beg_functions.php +++ b/inc/libs/beg_functions.php @@ -53,7 +53,7 @@ function addPointsBeg ($userid, $points) { } else { // Add points to account initReferalSystem(); - $added = addPointsThroughReferalSystem('beg', $userid, $points, false, 0, getBegMode()); + $added = addPointsThroughReferalSystem('beg', $userid, $points); } // Subtract begged points from member account if the admin has selected one @@ -214,18 +214,6 @@ function getBegPayMode () { return $GLOBALS[__FUNCTION__]; } -// "Getter" for beg_mode -function getBegMode () { - // Do we have cache? - if (!isset($GLOBALS[__FUNCTION__])) { - // Determine it - $GLOBALS[__FUNCTION__] = getConfig('beg_mode'); - } // END - if - - // Return cache - return $GLOBALS[__FUNCTION__]; -} - // "Getter" for beg_include_own function getBegIncludeOwn () { // Do we have cache? diff --git a/inc/libs/booking_functions.php b/inc/libs/booking_functions.php index 02ac68ede6..ece61e39c9 100644 --- a/inc/libs/booking_functions.php +++ b/inc/libs/booking_functions.php @@ -49,7 +49,7 @@ function addBookingRecord ($subject, $userid, $points, $mode) { } // END - if // Add record entry here - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_booking` (`userid`,`subject`,`mode`,`points`) VALUES(%s,'%s','%s',%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_booking` (`userid`, `subject`, `mode`, `points`) VALUES (%s,'%s','%s',%s)", array( bigintval($userid), $subject, diff --git a/inc/libs/network_functions.php b/inc/libs/network_functions.php index 3895fd7949..db096e9b0d 100644 --- a/inc/libs/network_functions.php +++ b/inc/libs/network_functions.php @@ -656,18 +656,7 @@ function generateNetworkActiveOptions ($default = '') { // Do we have cache? if (!isset($GLOBALS[__FUNCTION__][$default])) { // Generate the list - $GLOBALS[__FUNCTION__][$default] = generateOptionList( - '/ARRAY/', - array( - 'Y', - 'N' - ), - array( - '{--YES--}', - '{--NO--}' - ), - $default - ); + $GLOBALS[__FUNCTION__][$default] = generateYesNoOptionList($default); } // END - if // Return cache @@ -763,7 +752,7 @@ function doAdminNetworkProcessAddNetwork () { SQL_QUERY('INSERT INTO `{?_MYSQL_PREFIX?}_network_data` ( - `' . implode('`,`', array_keys(postRequestArray())) . "` + `' . implode('`, `', array_keys(postRequestArray())) . "` ) VALUES ( '" . implode("','", array_values(postRequestArray())) . "' )", __FUNCTION__, __LINE__); @@ -1039,7 +1028,7 @@ function doAdminNetworkProcessAddNetworkType () { SQL_QUERY('INSERT INTO `{?_MYSQL_PREFIX?}_network_types` ( - `' . implode('`,`', array_keys(postRequestArray())) . "` + `' . implode('`, `', array_keys(postRequestArray())) . "` ) VALUES ( '" . implode("','", array_values(postRequestArray())) . "' )", __FUNCTION__, __LINE__); @@ -1237,7 +1226,7 @@ function doAdminNetworkProcessAddNetworkParam () { SQL_QUERY('INSERT INTO `{?_MYSQL_PREFIX?}_network_request_params` ( - `' . implode('`,`', array_keys(postRequestArray())) . "` + `' . implode('`, `', array_keys(postRequestArray())) . "` ) VALUES ( '" . implode("','", array_values(postRequestArray())) . "' )", __FUNCTION__, __LINE__); @@ -1283,7 +1272,7 @@ function doAdminNetworkProcessAddNetworkApiTranslation () { SQL_QUERY('INSERT INTO `{?_MYSQL_PREFIX?}_network_api_translation` ( - `' . implode('`,`', array_keys(postRequestArray())) . "` + `' . implode('`, `', array_keys(postRequestArray())) . "` ) VALUES ( '" . implode("','", array_values(postRequestArray())) . "' )", __FUNCTION__, __LINE__); diff --git a/inc/libs/rallye_functions.php b/inc/libs/rallye_functions.php index 4f86bd6cfd..c301b593e0 100644 --- a/inc/libs/rallye_functions.php +++ b/inc/libs/rallye_functions.php @@ -498,18 +498,18 @@ function markReferalRallyesAsExpired ($result) { // Determine winner level if ($DATA['level'] == 1) { // The winner! - $winnerLevel = '_gold'; + $winnerLevel = 'gold'; } elseif ($DATA['level'] == 2) { // The vice winner! - $winnerLevel = '_silver'; + $winnerLevel = 'silver'; } elseif ($DATA['level'] == 3) { // The bronce winner - $winnerLevel = '_bronce'; + $winnerLevel = 'bronce'; } if ($DATA['points'] > 0) { // Add points directly to user's account - addPointsDirectly('rallye_winner' . $winnerLevel, $userid, $DATA['points']); + addPointsThroughReferalSystem('rallye_winner:' . $winnerLevel, $userid, $DATA['points']); } // END - if if ($notify == 'Y') { diff --git a/inc/libs/refback_functions.php b/inc/libs/refback_functions.php index c66cdcf680..5856a6aeda 100644 --- a/inc/libs/refback_functions.php +++ b/inc/libs/refback_functions.php @@ -92,7 +92,7 @@ function addRefbackPoints ($userid, $ref, $points, $ref_points) { // Add points again, but only directly /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'refback=' . $refback . ',userid=' . $userid . ',ref=' . $ref . ',refid=' . $refid . ' - UPDATE! (' . SQL_AFFECTEDROWS() . ')'); - addPointsDirectly(sprintf("refback:%s", $refid), $userid, $refback); + addPointsThroughReferalSystem(sprintf("refback:%s", $refid), $userid, $refback); // Reduce points if refid is found if ($refid == $ref) { @@ -246,7 +246,7 @@ function updateRefbackTable ($userid) { if (SQL_HASZERONUMS($result)) { // Insert this level /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid=' . $userid . ',level=' . $GLOBALS['refback_level'] . ',ref=' . $GLOBALS['refback_refid'][$GLOBALS['refback_level']] . ' - ADD!'); - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_refs` (`userid`,`level`,`refid`) VALUES (%s,%s,%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_refs` (`userid`, `level`, `refid`) VALUES (%s,%s,%s)", array( bigintval($userid), $GLOBALS['refback_level'], @@ -275,7 +275,7 @@ function updateRefbackTable ($userid) { /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid=' . $userid . ',level=' . ($GLOBALS['refback_level'] - $minus) . ',minus=' . $minus . ',ref=' . $GLOBALS['refback_refid'][$GLOBALS['refback_level']] . ',numRows=' . SQL_NUMROWS($result) . ' - BACK!'); if (SQL_HASZERONUMS($result)) { // Insert this level - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_refs` (`userid`,`level`,`refid`) VALUES (%s,%s,%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_refs` (`userid`, `level`, `refid`) VALUES (%s,%s,%s)", array( bigintval($userid), ($GLOBALS['refback_level'] - $minus), diff --git a/inc/libs/register_functions.php b/inc/libs/register_functions.php index 0b2f58f63a..c302d4742c 100644 --- a/inc/libs/register_functions.php +++ b/inc/libs/register_functions.php @@ -320,7 +320,7 @@ function doRegistration () { // Create user's account... SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_data` -(`gender`, `surname`, `family`, `street_nr`,%s, `zip`, `city`, `email`, `birth_day`, `birth_month`, `birth_year`, `password`, `max_mails`, `receive_mails`, `refid`, `status`, `user_hash`, `REMOTE_ADDR`, `joined`, `last_update`,`ref_payout`".$GLOBALS['register_sql_columns'].") +(`gender`, `surname`, `family`, `street_nr`,%s, `zip`, `city`, `email`, `birth_day`, `birth_month`, `birth_year`, `password`, `max_mails`, `receive_mails`, `refid`, `status`, `user_hash`, `REMOTE_ADDR`, `joined`, `last_update`, `ref_payout`".$GLOBALS['register_sql_columns'].") VALUES ('%s','%s','%s','%s','%s',%s,'%s','%s',%s, %s,%s,'%s',%s, %s,'%s','UNCONFIRMED','%s','%s', UNIX_TIMESTAMP(), UNIX_TIMESTAMP(), {?ref_payout?}".$GLOBALS['register_sql_data'].")", array( @@ -360,8 +360,7 @@ function doRegistration () { updateReferalCounter($userid); // Write his welcome-points - // @TODO Wether the registration bonus should only be added to user directly or through referal system should be configurable - addPointsDirectly('register_welcome', $userid, getPointsRegister()); + addPointsThroughReferalSystem('register_welcome', $userid, getPointsRegister()); // Write catgories if ((is_array(postRequestParameter('cat'))) && (count(postRequestParameter('cat')))) { diff --git a/inc/libs/surfbar_functions.php b/inc/libs/surfbar_functions.php index 2e5c248c66..9072b7439a 100644 --- a/inc/libs/surfbar_functions.php +++ b/inc/libs/surfbar_functions.php @@ -656,7 +656,7 @@ function SURFBAR_INSERT_URL_BY_ARRAY ($urlData) { if (empty($userid)) $userid = '0'; // Just run the insert query for now - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_urls` (`url_userid`,`url`,`url_status`,`url_views_max`,`url_views_allowed`,`url_fixed_reload`) VALUES (%s,'%s','%s',%s,%s,%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_surfbar_urls` (`url_userid`, `url`, `url_status`, `url_views_max`, `url_views_allowed`, `url_fixed_reload`) VALUES (%s,'%s','%s',%s,%s,%s)", array( $userid, $urlData['url'], @@ -1093,7 +1093,7 @@ function SURFBAR_PAY_POINTS () { initReferalSystem(); // Book it to the user - addPointsThroughReferalSystem(sprintf("surfbar_%s", getSurfbarPaymentModel()), getMemberId(), SURFBAR_GET_REWARD()); + addPointsThroughReferalSystem(sprintf("surfbar:%s", getSurfbarPaymentModel()), getMemberId(), SURFBAR_GET_REWARD()); /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.SURFBAR_GET_USERID().',costs='.SURFBAR_GET_COSTS() . ' - EXIT!'); } diff --git a/inc/libs/user_functions.php b/inc/libs/user_functions.php index 09dc679ba2..827ee9c2c6 100644 --- a/inc/libs/user_functions.php +++ b/inc/libs/user_functions.php @@ -544,7 +544,7 @@ function insertUserStatsRecord ($userid, $statsType, $statsData) { // Does it exist? if ((!getEpocheTimeFromUserStats($statsType, $statsData, $userid)) && (!is_array($statsData))) { // Then insert it! - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_stats_data` (`userid`,`stats_type`,`stats_data`) VALUES (%s,'%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_stats_data` (`userid`, `stats_type`, `stats_data`) VALUES (%s,'%s','%s')", array( bigintval($userid), $statsType, @@ -622,7 +622,7 @@ LIMIT 1", // Add one-time referal bonus over referal system or directly initReferalSystem(); - addPointsThroughReferalSystem('referal_bonus', $refid, getPointsRef(), true, bigintval($userid), getConfig('reg_points_mode')); + addPointsThroughReferalSystem('referal_bonus', $refid, getPointsRef(), bigintval($userid)); } // END - if } // END - if diff --git a/inc/libs/wernis_functions.php b/inc/libs/wernis_functions.php index fb8c57c709..e4d421f554 100644 --- a/inc/libs/wernis_functions.php +++ b/inc/libs/wernis_functions.php @@ -341,7 +341,7 @@ function translateWernisTransferStatus ($status) { // Log the transfer function WERNIS_LOG_TRANSFER ($wdsId, $amount, $type = 'FAILED', $message = '', $status = '') { // Register this wernis movement - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_wernis` (`userid`,`wernis_account`,`wernis_amount`,`wernis_timestamp`,`wernis_type`,`wernis_api_message`,`wernis_api_status`) VALUES (%s, %s, %s, UNIX_TIMESTAMP(), '%s', '%s', '%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_wernis` (`userid`, `wernis_account`, `wernis_amount`, `wernis_timestamp`, `wernis_type`, `wernis_api_message`, `wernis_api_status`) VALUES (%s, %s, %s, UNIX_TIMESTAMP(), '%s', '%s', '%s')", array( getMemberId(), bigintval($wdsId), diff --git a/inc/libs/yoomedia_functions.php b/inc/libs/yoomedia_functions.php index e3e1a739a2..ff7b85a9b8 100644 --- a/inc/libs/yoomedia_functions.php +++ b/inc/libs/yoomedia_functions.php @@ -265,7 +265,7 @@ function YOOMEDIA_EXCLUDE_MAIL ($data, $mode) { $mode = YOOMEDIA_CONVERT_MODE($mode); // Add the entry - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_yoomedia_reload` (`type`,`y_id`,`y_reload`,`inserted`) VALUES ('%s',%s,%s,'0000-00-00 00:00')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_yoomedia_reload` (`type`, `y_id`, `y_reload`, `inserted`) VALUES ('%s',%s,%s,'0000-00-00 00:00')", array( $mode, bigintval($data['id']), @@ -360,7 +360,7 @@ function YOOMEDIA_RELOAD_LOCK ($data, $mode) { $mode = YOOMEDIA_CONVERT_MODE($mode); // Add the entry - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_yoomedia_reload` (`type`,`y_id`,`y_reload`) VALUES ('%s',%s,%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_yoomedia_reload` (`type`, `y_id`, `y_reload`) VALUES ('%s',%s,%s)", array($mode, bigintval($data['id']), bigintval($data['reload'])), __FUNCTION__, __LINE__); } // END - if } diff --git a/inc/mails/doubler_mails.php b/inc/mails/doubler_mails.php index 038086d566..7fa1ae34a1 100644 --- a/inc/mails/doubler_mails.php +++ b/inc/mails/doubler_mails.php @@ -142,7 +142,7 @@ if (((!SQL_HASZERONUMS($result_total)) && (getConfig('doubler_sent_all') == 'Y') // Exclude webmaster from doubling... if ($content['userid'] != getConfig('doubler_userid')) { // Add points - addPointsDirectly(sprintf("doubler_%s", strtolower(getConfig('doubler_send_mode'))), $content['userid'], $content['points']); + addPointsThroughReferalSystem(sprintf("doubler_%s", strtolower(getConfig('doubler_send_mode'))), $content['userid'], $content['points']); } // END - if // Set entry as "payed" diff --git a/inc/module-functions.php b/inc/module-functions.php index ad6cc2a906..a0841a6a60 100644 --- a/inc/module-functions.php +++ b/inc/module-functions.php @@ -396,7 +396,7 @@ function addModuleSql ($module, $locked, $hidden, $adminOnly, $memOnly) { // Is the module already registered? if (!isModuleRegistered($module)) { // Add it - addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`mem_only`) VALUES('" . $module . "','" . $locked . "','" . $hidden . "','" . $adminOnly . "','" . $memOnly . "')"); + addExtensionSql("INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `mem_only`) VALUES ('" . $module . "','" . $locked . "','" . $hidden . "','" . $adminOnly . "','" . $memOnly . "')"); } else { // Already registered logDebugMessage(__FUNCTION__, __LINE__, sprintf("Already registered: module=%s,locked=%s,hidden=%s,admin=%s,mem=%s", diff --git a/inc/modules/admin/what-add_rallye.php b/inc/modules/admin/what-add_rallye.php index ace68d7486..d3cae625a0 100644 --- a/inc/modules/admin/what-add_rallye.php +++ b/inc/modules/admin/what-add_rallye.php @@ -87,11 +87,6 @@ VALUES (%s,'%s','%s','%s',%s,%s,'%s','%s','%s')", } } // END - if -// Prepare some constants for the template -$content['auto_add_options'] = generateOptionList('/ARRAY/', array('Y','N'), array('{--YES--}', '{--NO--}' )); -$content['active_options'] = generateOptionList('/ARRAY/', array('N','Y'), array('{--NO--}' , '{--YES--}')); -$content['notify_options'] = generateOptionList('/ARRAY/', array('Y','N'), array('{--YES--}', '{--NO--}' )); - // Starting day $content['start_sec'] = addSelectionBox('sec' , 0 , 'start'); $content['start_min'] = addSelectionBox('min' , 0 , 'start'); @@ -111,9 +106,6 @@ $content['end_day'] = addSelectionBox('day' , getDay($endingStamp) , 'end'); $content['end_month'] = addSelectionBox('month', getMonth($endingStamp), 'end'); $content['end_year'] = addSelectionBox('year' , getYear($endingStamp) , 'end'); -// Transfer (maybe found) templates into constant for the template -$content['templates_selection'] = addReferalRallyeTemplateSelection(); - // Load template loadTemplate('admin_add_rallye', false, $content); diff --git a/inc/modules/admin/what-admin_add.php b/inc/modules/admin/what-admin_add.php index 812d82357d..aef693aec4 100644 --- a/inc/modules/admin/what-admin_add.php +++ b/inc/modules/admin/what-admin_add.php @@ -163,7 +163,7 @@ if (!isFormSent()) { // Insert new menu entry if (isPostRequestParameterSet('menu')) { // Add sub menu - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('%s','%s','%s','%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('%s','%s','%s','%s','%s')", array( postRequestParameter('menu'), postRequestParameter('name'), diff --git a/inc/modules/admin/what-config_autopurge.php b/inc/modules/admin/what-config_autopurge.php index 61f640ec9f..40c43c5fdf 100644 --- a/inc/modules/admin/what-config_autopurge.php +++ b/inc/modules/admin/what-config_autopurge.php @@ -69,13 +69,6 @@ if (isFormSent()) { // Mail confirmation links $content['auto_purge'] = createConfigurationTimeSelections('auto_purge', 'MWD'); - // Prepare more Y/N selections - foreach (array('auto_purge_active') as $entry) { - $content[$entry . '_y'] = ''; - $content[$entry . '_n'] = ''; - $content[$entry . '_' . strtolower(getConfig('auto_purge_active'))] = ' checked="checked"'; - } // END - foreach - // Output template loadTemplate('admin_config_autopurge', false, $content); } diff --git a/inc/modules/admin/what-config_beg.php b/inc/modules/admin/what-config_beg.php index a01277b134..786d5c4385 100644 --- a/inc/modules/admin/what-config_beg.php +++ b/inc/modules/admin/what-config_beg.php @@ -76,14 +76,6 @@ if (isFormSent()) { // Set default faker-mode $content['pay_mode_' . strtolower(getBegPayMode())] = ' selected="selected"'; - // Init beg_mode elements - foreach (array('DIRECT', 'REF') as $entry) { - $content['beg_mode_' . strtolower($entry)] = ''; - } // END - foreach - - // Set default mode - $content['beg_mode_' . strtolower(getBegMode())] = ' checked="checked"'; - // Member selection box $content['beg_userid'] = addMemberSelectionBox(getBegUserid(), false, true, true, 'beg_userid'); diff --git a/inc/modules/admin/what-config_birthday.php b/inc/modules/admin/what-config_birthday.php index cac121f34c..83c2c54b49 100644 --- a/inc/modules/admin/what-config_birthday.php +++ b/inc/modules/admin/what-config_birthday.php @@ -48,13 +48,13 @@ if (isFormSent()) { adminSaveSettingsFromPostData(); } else { // Init all other template entries - foreach (array('active_y','active_n','mode_direct','mode_ref') as $entry) { + foreach (array('active_y','active_n') as $entry) { $content[$entry] = ''; } // END - foreach // Set current selections - foreach (array('active','mode') as $entry) { - $content[$entry . '_' . strtolower(getConfig('birthday_' . $entry))] = ' checked="checked"'; + foreach (array('active') as $entry) { + $content['birthday_' . $entry . '_' . strtolower(getConfig('birthday_' . $entry))] = ' checked="checked"'; } // END - foreach // Display form diff --git a/inc/modules/admin/what-config_imprint.php b/inc/modules/admin/what-config_imprint.php index 795fdb1ac1..752442fbf5 100644 --- a/inc/modules/admin/what-config_imprint.php +++ b/inc/modules/admin/what-config_imprint.php @@ -48,7 +48,7 @@ if (isFormSent()) { // Handle form ... } else { // Query for all imprint data rows - $result = SQL_QUERY('SELECT `imprint_key`,`imprint_value` FROM `{?_MYSQL_PREFIX?}_imprint_data` ORDER BY `imprint_id` ASC', __FILE__, __LINE__); + $result = SQL_QUERY('SELECT `imprint_key`, `imprint_value` FROM `{?_MYSQL_PREFIX?}_imprint_data` ORDER BY `imprint_id` ASC', __FILE__, __LINE__); // Do we have entries? if (!SQL_HASZERONUMS($result)) { diff --git a/inc/modules/admin/what-config_menu.php b/inc/modules/admin/what-config_menu.php index 5cc6861570..321e03a2d9 100644 --- a/inc/modules/admin/what-config_menu.php +++ b/inc/modules/admin/what-config_menu.php @@ -47,15 +47,8 @@ if (isFormSent()) { // Save settings adminSaveSettingsFromPostData(); } else { - // Set all entries - foreach (array('guest_menu_advert_enabled','member_menu_advert_enabled') as $entry) { - $content[$entry . '_y'] = ''; - $content[$entry . '_n'] = ''; - $content[$entry . '_' . strtolower(getConfig($entry))] = ' checked="checked"'; - } // END - if - // Load form template - loadTemplate('admin_config_menu', false, $content); + loadTemplate('admin_config_menu'); } // [EOF] diff --git a/inc/modules/admin/what-config_points.php b/inc/modules/admin/what-config_points.php index 2f0808e26f..d458da5004 100644 --- a/inc/modules/admin/what-config_points.php +++ b/inc/modules/admin/what-config_points.php @@ -116,8 +116,8 @@ if (isFormSent()) { case 'settings': $REF = bigintval(postRequestParameter('ref_payout')); updateConfiguration( - array('allow_direct_pay', 'reg_points_mode', 'ref_payout'), - array(postRequestParameter('allow_direct_pay'), postRequestParameter('reg_points_mode'), $REF) + array('allow_direct_pay', 'ref_payout'), + array(postRequestParameter('allow_direct_pay'), $REF) ); if ((getConfig('ref_payout') == '0') && (postRequestParameter('ref_payout') > 0)) { // Update account's ref_payout for "must-confirm" @@ -172,12 +172,6 @@ WHERE $content[$entry . '_' . strtolower(getConfig($entry))] = ' checked="checked"'; } // END - foreach - // One-time referal bonus add-mode - foreach (array('reg_points_mode_ref','reg_points_mode_direct') as $entry) { - $content[$entry] = ''; - } // END - foreach - $content['reg_points_mode_' . strtolower(getConfig('reg_points_mode'))] = ' checked="checked"'; - // Load template loadTemplate('admin_config_point_settings', false, $content); } elseif (getRequestParameter('sub') == 'ref') { diff --git a/inc/modules/admin/what-config_surfbar.php b/inc/modules/admin/what-config_surfbar.php index 23ed02aab0..1af1c77483 100644 --- a/inc/modules/admin/what-config_surfbar.php +++ b/inc/modules/admin/what-config_surfbar.php @@ -62,13 +62,6 @@ if (isFormSent()) { 'surfbar_low_interval' => createConfigurationTimeSelections('surfbar_low_interval' , 'WDh', 'left'), ); - // Prepare further Y/N config entries - foreach (array('surfbar_autostart','surfbar_notify_limits','surfbar_notify_admin_unlock','surfbar_migrate_order','surfbar_guest_login_form') as $entry) { - $content[$entry . '_y'] = ''; - $content[$entry . '_n'] = ''; - $content[$entry . '_' . strtolower(getConfig($entry))] = ' checked="checked"'; - } // END - foreach - // Even some more... foreach (array('surfbar_payment_model_static','surfbar_payment_model_dynamic','surfbar_pause_mode_internal','surfbar_pause_mode_external','surfbar_notification_mode_instant','surfbar_notification_mode_reset') as $entry) { $content[$entry] = ''; diff --git a/inc/modules/admin/what-del_email.php b/inc/modules/admin/what-del_email.php index f23808f9f2..2727c7173e 100644 --- a/inc/modules/admin/what-del_email.php +++ b/inc/modules/admin/what-del_email.php @@ -109,8 +109,7 @@ LIMIT 1", } // END - if // Pay back points - //* DEBUG: */ debugOutput('PAYBACK:'.$content['sender']); - addPointsDirectly('mail_deleted', $content['sender'], $totalPoints); + addPointsThroughReferalSystem('mail_deleted', $content['sender'], $totalPoints); // Output message if (getConfig('repay_deleted_mails') == 'REPAY') { diff --git a/inc/modules/admin/what-guest_add.php b/inc/modules/admin/what-guest_add.php index 33da7e1b78..20d458f0d6 100644 --- a/inc/modules/admin/what-guest_add.php +++ b/inc/modules/admin/what-guest_add.php @@ -181,7 +181,7 @@ ORDER BY `sort` ASC", } elseif (!isDemoModeActive()) { // Insert new menu entry if (isPostRequestParameterSet('menu')) { - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('%s','%s','%s','%s','%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('%s','%s','%s','%s','%s','%s')", array( postRequestParameter('menu'), postRequestParameter('name'), diff --git a/inc/modules/admin/what-guestedit.php b/inc/modules/admin/what-guestedit.php index d7543eaa8a..4587458acb 100644 --- a/inc/modules/admin/what-guestedit.php +++ b/inc/modules/admin/what-guestedit.php @@ -184,10 +184,10 @@ if ((isFormSent('edit')) && (ifPostContainsSelections()) && (!isDemoModeActive() // By default list menus if (empty($subMenu)) { // List only main menus - $result = SQL_QUERY("SELECT `id`,`action`,`what`,`title`,`sort` FROM `{?_MYSQL_PREFIX?}_guest_menu` WHERE (`what`='' OR `what` IS NULL) ORDER BY `sort` ASC", __FILE__, __LINE__); + $result = SQL_QUERY("SELECT `id`, `action`, `what`, `title`, `sort` FROM `{?_MYSQL_PREFIX?}_guest_menu` WHERE (`what`='' OR `what` IS NULL) ORDER BY `sort` ASC", __FILE__, __LINE__); } else { // List sub menus - $result = SQL_QUERY_ESC("SELECT `id`,`action`,`what`,`title`,`sort` FROM `{?_MYSQL_PREFIX?}_guest_menu` WHERE `action`='%s' AND `what` != '' AND `what` IS NOT NULL ORDER BY `sort` ASC", + $result = SQL_QUERY_ESC("SELECT `id`, `action`, `what`, `title`, `sort` FROM `{?_MYSQL_PREFIX?}_guest_menu` WHERE `action`='%s' AND `what` != '' AND `what` IS NOT NULL ORDER BY `sort` ASC", array($subMenu), __FILE__, __LINE__); } diff --git a/inc/modules/admin/what-list_country.php b/inc/modules/admin/what-list_country.php index 05397487ce..40418c251c 100644 --- a/inc/modules/admin/what-list_country.php +++ b/inc/modules/admin/what-list_country.php @@ -82,7 +82,7 @@ if ((isFormSent('add')) && (isPostRequestParameterSet('code')) && (isPostRequest if (count(postRequestParameter('id')) > 0) { if (isFormSent('edit')) { // Edit template - $row = 'admin_list_country_edit_row'; + $row = 'admin_edit_country_row'; $post = 'modify'; $class = 'form_submit'; $submit = '{--ADMIN_COUNTRY_EDIT_NOW--}'; @@ -90,7 +90,7 @@ if ((isFormSent('add')) && (isPostRequestParameterSet('code')) && (isPostRequest $reset = ' '; } else { // Delete template - $row = 'admin_list_country_del_row'; + $row = 'admin_delete_country_row'; $post = 'remove'; $class = 'form_delete'; $submit = '{--ADMIN_COUNTRY_DELETE_NOW--}'; @@ -108,13 +108,8 @@ if ((isFormSent('add')) && (isPostRequestParameterSet('code')) && (isPostRequest // Load data $content = SQL_FETCHARRAY($result); - if ($post == 'modify') { - // Generate default selection in edit-mode - $content['is_active'] = generateOptionList('/ARRAY/', array('Y', 'N'), array('{--YES--}', '{--NO--}'), $isActive); - } else { - // Only display status when in delete-mode - $content['is_active'] = '{%pipe,translateYesNo=' . $isActive . '%}'; - } + // Add $isActive + $content['is_active'] = $isActive; // Insert row template and switch color $OUT .= loadTemplate($row, true, $content); diff --git a/inc/modules/admin/what-mem_add.php b/inc/modules/admin/what-mem_add.php index d77a7b1cf8..5c87bf8f84 100644 --- a/inc/modules/admin/what-mem_add.php +++ b/inc/modules/admin/what-mem_add.php @@ -170,7 +170,7 @@ if (!isFormSent()) { } elseif (!isDemoModeActive()) { // Insert new menu entry if (isPostRequestParameterSet('menu')) { - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`visible`,`locked`,`sort`) VALUES ('%s','%s','%s','%s','%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `visible`, `locked`, `sort`) VALUES ('%s','%s','%s','%s','%s','%s')", array( postRequestParameter('menu'), postRequestParameter('name'), @@ -180,7 +180,7 @@ if (!isFormSent()) { bigintval(postRequestParameter('sort')), ), __FILE__, __LINE__); } else { - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`title`,`visible`,`locked`,`sort`) VALUES ('%s','%s','%s','%s','%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `title`, `visible`, `locked`, `sort`) VALUES ('%s','%s','%s','%s','%s')", array( postRequestParameter('name'), postRequestParameter('title'), diff --git a/inc/modules/admin/what-send_coupon.php b/inc/modules/admin/what-send_coupon.php index 84309479f8..2d359b3661 100644 --- a/inc/modules/admin/what-send_coupon.php +++ b/inc/modules/admin/what-send_coupon.php @@ -63,7 +63,7 @@ if (isFormSent()) { $expirationTime = time() + createEpocheTimeFromSelections('coupon_default_time', postRequestArray()); // Insert coupon data - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_coupon_data` (`coupon_expired`, `total_created`, `points`, `coupon_description`) VALUES('{%%pipe,SQL_EPOCHE_TO_TIMESTAMP=%s%%}', %s,%s,'%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_coupon_data` (`coupon_expired`, `total_created`, `points`, `coupon_description`) VALUES ('{%%pipe,SQL_EPOCHE_TO_TIMESTAMP=%s%%}', %s,%s,'%s')", array( $expirationTime, SQL_NUMROWS($result), @@ -95,7 +95,7 @@ if (isFormSent()) { } // END - while // The above loop should always set $couponCode, so we can now insert it - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_coupons` (`coupon_id`, `userid`, `coupon_code`) VALUES(%s,%s,'%s')", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_coupons` (`coupon_id`, `userid`, `coupon_code`) VALUES (%s,%s,'%s')", array($couponId, $userid, $couponCode), __FILE__, __LINE__); // Fill array with all required data diff --git a/inc/modules/admin/what-theme_import.php b/inc/modules/admin/what-theme_import.php index c3665f9881..c2a407f2bb 100644 --- a/inc/modules/admin/what-theme_import.php +++ b/inc/modules/admin/what-theme_import.php @@ -59,7 +59,7 @@ if (isPostRequestParameterSet('theme')) { loadInclude($inc); // Register it ith the exchange - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_themes` (`theme_path`,`theme_active`,`theme_ver`,`theme_name`) + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_themes` (`theme_path`, `theme_active`, `theme_ver`, `theme_name`) VALUES ('%s','N','%s','%s')", array( postRequestParameter('theme'), diff --git a/inc/modules/admin/what-unlock_emails.php b/inc/modules/admin/what-unlock_emails.php index de4eead956..8a135b2d30 100644 --- a/inc/modules/admin/what-unlock_emails.php +++ b/inc/modules/admin/what-unlock_emails.php @@ -179,7 +179,7 @@ LIMIT 1", array($url), __FILE__, __LINE__); if (SQL_HASZERONUMS($result)) { // Did not find a record so we can add it... :) - SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_url_blacklist` (`url`,`pool_id`) VALUES ('%s',%s)", + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_url_blacklist` (`url`, `pool_id`) VALUES ('%s',%s)", array($url, $id), __FILE__, __LINE__); } // END - if diff --git a/inc/modules/member/what-cash_coupon.php b/inc/modules/member/what-cash_coupon.php index 3e538b9aa2..7c9a24241f 100644 --- a/inc/modules/member/what-cash_coupon.php +++ b/inc/modules/member/what-cash_coupon.php @@ -119,7 +119,7 @@ LIMIT 1", } // END - if // Now we just need to book that points on the user's account - addPointsThroughReferalSystem('coupon_cashed', getMemberId(), $content['points'], false, 0, getPaymentMethodFromExtensionName('coupon')); + addPointsThroughReferalSystem('coupon_cashed', getMemberId(), $content['points']); // Subtract points from member account if the admin has selected one if (isValidUserId(getConfig('coupon_userid'))) { diff --git a/inc/modules/member/what-primera.php b/inc/modules/member/what-primera.php index 684bd1e2c3..929169226f 100644 --- a/inc/modules/member/what-primera.php +++ b/inc/modules/member/what-primera.php @@ -71,7 +71,7 @@ if (!isGetRequestParameterSet('mode')) { setGetRequestParameter('mode', 'list'); // And load all rows! - $result = SQL_QUERY_ESC("SELECT `id`,`primera_account`,`primera_amount`,`primera_timestamp`,`primera_type` FROM `{?_MYSQL_PREFIX?}_user_primera` WHERE `userid`=%s ORDER BY `primera_timestamp` DESC", + $result = SQL_QUERY_ESC("SELECT `id`, `primera_account`, `primera_amount`, `primera_timestamp`, `primera_type` FROM `{?_MYSQL_PREFIX?}_user_primera` WHERE `userid`=%s ORDER BY `primera_timestamp` DESC", array(getMemberId()), __FILE__, __LINE__); // Load all rows diff --git a/inc/modules/member/what-transfer.php b/inc/modules/member/what-transfer.php index 6376feb753..d003780249 100644 --- a/inc/modules/member/what-transfer.php +++ b/inc/modules/member/what-transfer.php @@ -144,12 +144,24 @@ switch ($mode) { // Add entries to both tables SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_transfers_in` (`userid`, `from_userid`, `points`, `reason`, `time_trans`, `trans_id`) VALUES (%s,%s,%s,'%s', UNIX_TIMESTAMP(),%s)", - array(bigintval(postRequestParameter('to_userid')), getMemberId(), bigintval(postRequestParameter('points')), postRequestParameter('reason'), $content['trans_id']), __FILE__, __LINE__); + array( + bigintval(postRequestParameter('to_userid')), + getMemberId(), + bigintval(postRequestParameter('points')), + postRequestParameter('reason'), + $content['trans_id'] + ), __FILE__, __LINE__); SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_user_transfers_out` (`userid`, `to_userid`, `points`, `reason`, `time_trans`, `trans_id`) VALUES (%s,%s,%s,'%s', UNIX_TIMESTAMP(),%s)", - array(getMemberId(), bigintval(postRequestParameter('to_userid')), bigintval(postRequestParameter('points')), postRequestParameter('reason'), $content['trans_id']), __FILE__, __LINE__); + array( + getMemberId(), + bigintval(postRequestParameter('to_userid')), + bigintval(postRequestParameter('points')), + postRequestParameter('reason'), + $content['trans_id'] + ), __FILE__, __LINE__); // Add points to account *directly* ... - addPointsDirectly('transfer', bigintval(postRequestParameter('to_userid')), bigintval(postRequestParameter('points'))); + addPointsThroughReferalSystem('transfer', bigintval(postRequestParameter('to_userid')), bigintval(postRequestParameter('points'))); // ... and add it to current user's used points subtractPoints('transfer', getMemberId(), postRequestParameter('points')); diff --git a/inc/modules/member/what-wernis.php b/inc/modules/member/what-wernis.php index 9ea20c2112..e00af871a2 100644 --- a/inc/modules/member/what-wernis.php +++ b/inc/modules/member/what-wernis.php @@ -175,7 +175,7 @@ if ((isFormSent()) && (isGetRequestParameterSet('mode'))) { $success = WERNIS_EXECUTE_WITHDRAW(postRequestParameter('wernis_userid'), md5(postRequestParameter('wds66_password')), postRequestParameter('amount')); if ($success === true) { // Add it to this amount - addPointsDirectly('wernis_withdraw', getMemberId(), bigintval(postRequestParameter('amount'))); + addPointsThroughReferalSystem('wernis_withdraw', getMemberId(), bigintval(postRequestParameter('amount'))); // Update the user data as well.. SQL_QUERY_ESC("UPDATE `{?_MYSQL_PREFIX?}_user_data` SET `wernis_userid`=%s WHERE `userid`=%s LIMIT 1", diff --git a/inc/monthly/monthly_beg.php b/inc/monthly/monthly_beg.php index 56a93a0786..5372ce06be 100644 --- a/inc/monthly/monthly_beg.php +++ b/inc/monthly/monthly_beg.php @@ -83,7 +83,7 @@ LIMIT {?beg_ranks?}", __FILE__, __LINE__); // Load our winners... while ($content = SQL_FETCHARRAY($result_main)) { // Add points to user's account directly - addPointsDirectly('monthly_beg', $content['userid'], $content['beg_points']); + addPointsThroughReferalSystem('monthly_beg', $content['userid'], $content['beg_points']); // Load email template and email it away $message = loadEmailTemplate('member_beg', $content, bigintval($content['userid'])); diff --git a/inc/monthly/monthly_bonus.php b/inc/monthly/monthly_bonus.php index 037b2a949c..ff5981a30a 100644 --- a/inc/monthly/monthly_bonus.php +++ b/inc/monthly/monthly_bonus.php @@ -91,7 +91,7 @@ LIMIT {?bonus_ranks?}', __FILE__, __LINE__); // Make sure zero points are not mailed if ($content['points'] > 0) { // Add points to user's account directly - addPointsDirectly('monthly_bonus', $content['userid'], $content['points']); + addPointsThroughReferalSystem('monthly_bonus', $content['userid'], $content['points']); // Load email template and email it away $message = loadEmailTemplate('member_bonus', $content, bigintval($content['userid'])); diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index 177da67eb5..9ffbb0297c 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -1035,31 +1035,39 @@ function initReferalSystem () { * * Dynamic referal and points system, can also send mails! * - * subject = Subject line, write in lower-case letters and underscore is allowed - * userid = Referal id wich should receive... - * points = ... xxx points - * sendNotify = shall I send the referal an email or not? - * refid = inc/modules/guest/what-confirm.php need this - * locked = Shall I pay it to normal (false) or locked (true) points ammount? - * add_mode = Add points only to $userid or also refs? (WARNING! Changing 'REFERAL' to 'DIRECT' - * for default value will cause no referal will get points ever!!!) + * subject = Subject line, write in lower-case letters and underscore is allowed + * userid = Referal id wich should receive... + * points = ... xxx points + * refid = inc/modules/guest/what-confirm.php need this + * locked = Shall I pay it to normal (false) or locked (true) points ammount? + * paymentMethod = Deprecated parameter, the payment method */ -function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify = false, $refid = '0', $addMode = 'REFERAL') { - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'subject=' . $subject . ',userid=' . $userid . ',points=' . $points . ',sendNotify=' . intval($sendNotify) . ',refid=' . $refid . ',addMode=' . $addMode . ' - ENTERED!'); +function addPointsThroughReferalSystem ($subject, $userid, $points, $refid = '0', $paymentMethod = 'INVALID') { + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'subject=' . $subject . ',userid=' . $userid . ',points=' . $points . ',sendNotify=' . intval($sendNotify) . ',refid=' . $refid . ',paymentMethod=' . $paymentMethod . ' - ENTERED!'); // By default nothing has been added $added = false; // Convert mode to upper-case - $addMode = strtoupper($addMode); + $paymentMethod = strtoupper($paymentMethod); + + // Is it not invalid? + if ($paymentMethod != 'INVALID') { + // We are not using this anymore + debug_report_bug(__FUNCTION__, __LINE__, 'subject=' . $subject . ',paymentMethod=' . $paymentMethod . ' - deprecated parameter used.'); + } // END - if + + // Determine payment method and notification + $paymentMethod = getPaymentMethodFromSubject($subject); + $sendNotify = isPaymentRecipientNotificationEnabled($subject); // When $userid = '0' add points to jackpot - if (($userid == '0') && ($addMode == 'DIRECT') && (isExtensionActive('jackpot'))) { + if (($userid == '0') && ($paymentMethod == 'DIRECT') && (isExtensionActive('jackpot'))) { // Add points to jackpot only in DIRECT mode return addPointsToJackpot($points); } // END - if // Check user account - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',points='.$points); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid=' . $userid . ',points=' . $points); if (fetchUserData($userid)) { // Determine wether the user has some mails to click before he/she gets the points $locked = ifUserPointsLocked($userid); @@ -1072,7 +1080,7 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify // Get percents $per = getReferalLevelPercents($GLOBALS['ref_level']); - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',points='.$points.',depth='.$GLOBALS['ref_level'].',per='.$per.',mode='.$addMode); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',points='.$points.',depth='.$GLOBALS['ref_level'].',per='.$per.',mode='.$paymentMethod); // Some percents found? if ($per > 0) { @@ -1081,7 +1089,7 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',points='.$points.',per='.$per.',depth='.$GLOBALS['ref_level'].',ref_points='.$ref_points); // Pay refback here if level > 0 and in ref-mode - if ((isExtensionActive('refback')) && ($GLOBALS['ref_level'] > 0) && ($per < 100) && ($addMode == 'REFERAL') && (isset($GLOBALS['cache_array']['add_userid'][$userid]))) { + if ((isExtensionActive('refback')) && ($GLOBALS['ref_level'] > 0) && ($per < 100) && ($paymentMethod == 'REFERAL') && (isset($GLOBALS['cache_array']['add_userid'][$userid]))) { /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',data='.$GLOBALS['cache_array']['add_userid'][$userid].',ref_points='.$ref_points.',depth='.$GLOBALS['ref_level'].' - BEFORE!'); $ref_points = addRefbackPoints($GLOBALS['cache_array']['add_userid'][$userid], $userid, $points, $ref_points); /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid='.$userid.',data='.$GLOBALS['cache_array']['add_userid'][$userid].',ref_points='.$ref_points.',depth='.$GLOBALS['ref_level'].' - AFTER!'); @@ -1108,7 +1116,7 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify bigintval($GLOBALS['ref_level']) ), __FUNCTION__, __LINE__); } - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'pointsColumn='.$pointsColumn.',ref_points='.$ref_points.',userid='.$userid.',depth='.$GLOBALS['ref_level'].',mode='.$addMode.' - UPDATE! ('.SQL_AFFECTEDROWS().')'); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'pointsColumn='.$pointsColumn.',ref_points='.$ref_points.',userid='.$userid.',depth='.$GLOBALS['ref_level'].',mode='.$paymentMethod.' - UPDATE! ('.SQL_AFFECTEDROWS().')'); // No entry updated? if (SQL_HASZEROAFFECTED()) { @@ -1120,7 +1128,7 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify makeZeroToNull($GLOBALS['ref_level']), $ref_points ), __FUNCTION__, __LINE__); - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'data='.$pointsColumn.',ref_points='.$ref_points.',userid='.$userid.',depth='.$GLOBALS['ref_level'].',mode='.$addMode.' - INSERTED! ('.SQL_AFFECTEDROWS().')'); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'data='.$pointsColumn.',ref_points='.$ref_points.',userid='.$userid.',depth='.$GLOBALS['ref_level'].',mode='.$paymentMethod.' - INSERTED! ('.SQL_AFFECTEDROWS().')'); } // END - if // Check affected rows @@ -1138,7 +1146,7 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify 'refid' => $refid, 'locked' => $locked, 'mode' => 'add', - 'add_mode' => $addMode, + 'add_mode' => $paymentMethod, 'added' => $added ); @@ -1163,11 +1171,12 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify // Send email sendEmail($userid, '{--THANX_REFERAL_ONE_SUBJECT--}', $message); - } elseif (($sendNotify === true) && (!isValidUserId(getUserData('refid'))) && ($locked === false) && ($addMode == 'DIRECT')) { + } elseif (($sendNotify === true) && (!isValidUserId(getUserData('refid'))) && ($locked === false) && ($paymentMethod == 'DIRECT')) { // Prepare content $content = array( - 'reason' => '{--REASON_DIRECT_PAYMENT--}', - 'points' => $ref_points + 'reason' => '{--REASON_DIRECT_PAYMENT--}', + 'subject' => $subject, + 'points' => $ref_points ); // Load message @@ -1186,15 +1195,15 @@ function addPointsThroughReferalSystem ($subject, $userid, $points, $sendNotify /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, ' Referal level increased, ref_level=' . $GLOBALS['ref_level']); // Maybe there's another ref? - if ((isValidUserId(getUserData('refid'))) && ($points > 0) && (getUserData('refid') != $userid) && ($addMode == 'REFERAL')) { + if ((isValidUserId(getUserData('refid'))) && ($points > 0) && (getUserData('refid') != $userid) && ($paymentMethod == 'REFERAL')) { // Then let's credit him here... /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'userid=' . $userid . ',refid=' . getUserData('refid') . ',points=' . $points . ',ref_points=' . $ref_points . ' - ADVANCE!'); - $added = ($added && addPointsThroughReferalSystem(sprintf("%s_ref:%s", $subject, $GLOBALS['ref_level']), getUserData('refid'), $points, $sendNotify, getUserData('refid'))); + $added = ($added && addPointsThroughReferalSystem(sprintf("%s_ref:%s", $subject, $GLOBALS['ref_level']), getUserData('refid'), $points, getUserData('refid'))); } // END - if } // END - if } // END - if - /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'subject=' . $subject . ',userid=' . $userid . ',points=' . $points . ',sendNotify=' . intval($sendNotify) . ',refid=' . $refid . ',addMode=' . $addMode . ' - EXIT!'); + /* DEBUG: */ logDebugMessage(__FUNCTION__, __LINE__, 'subject=' . $subject . ',userid=' . $userid . ',points=' . $points . ',sendNotify=' . intval($sendNotify) . ',refid=' . $refid . ',paymentMethod=' . $paymentMethod . ' - EXIT!'); return $added; } @@ -2051,51 +2060,57 @@ function updateLastActivity($userid) { } // Get points data for given extension's name -function getPointsDataArrayFromExtensionName ($ext_name) { +function getPointsDataArrayFromSubject ($subject) { + // Extension sql_patches must be up-to-date + if (isExtensionInstalledAndOlder('sql_patches', '0.8.2')) { + // Please update ext-sql_patches + debug_report_bug(__FUNCTION__, __LINE__, 'sql_patches is out-dated. Please update to at least 0.8.2 to continue. subject=' . $subject); + } // END - if + + // Remove any double-dot from it + $subjectArray = explode(':', $subject); + $subject = $subjectArray[0]; + unset($subjectArray); + // If we have cache, shortcut it here - if (isset($GLOBALS['cache_array']['points_data'][$ext_name])) { + if (isset($GLOBALS['cache_array']['points_data'][$subject])) { // Return it - return $GLOBALS['cache_array']['points_data'][$ext_name]; + return $GLOBALS['cache_array']['points_data'][$subject]; } // END - if // Now checkout the entry in database table - $result = SQL_QUERY_ESC("SELECT `id`, `ext_name`, `column_name`, `locked_mode`, `payment_method` FROM `{?_MYSQL_PREFIX?}_points_data` WHERE `ext_name`='%s' LIMIT 1", - array($ext_name), __FUNCTION__, __LINE__); + $result = SQL_QUERY_ESC("SELECT `id`, `subject`, `column_name`, `locked_mode`, `payment_method`, `notify_recipient` FROM `{?_MYSQL_PREFIX?}_points_data` WHERE `subject`='%s' LIMIT 1", + array($subject), __FUNCTION__, __LINE__); // Do we have an entry? if (SQL_NUMROWS($result) == 1) { // Then load it $pointsData = SQL_FETCHARRAY($result); - // Add all remaining entries + // Add all entries to our cache array foreach ($pointsData as $key=>$value) { - $GLOBALS['cache_array']['points_data'][$ext_name][$key] = $value; + $GLOBALS['cache_array']['points_data'][$subject][$key] = $value; } // END - foreach } else { - /* - * Having no entry is not bad but it means that all points will go to - * the general account which the user can let payout. - */ - logDebugMessage(__FUNCTION__, __LINE__, 'ext_name=' . $ext_name . ' - No entry found, switching to general points account.'); + // Register this automatically + SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_points_data` (`subject`, `column_name`, `locked_mode`, `payment_method`, `notify_recipient`) VALUES ('%s','points','LOCKED','REFERAL','N')", + array($subject), __FUNCTION__, __LINE__); + + // Re-request it + return getPointsDataArrayFromSubject($subject); } // Free result SQL_FREERESULT($result); // Return it - return $GLOBALS['cache_array']['points_data'][$ext_name]; + return $GLOBALS['cache_array']['points_data'][$subject]; } -// Determines the right points column name for given extension and 'locked' -function getPointsColumnNameFromExtensionNameLocked ($ext_name, $isLocked) { - // Extension sql_patches must be up-to-date - if (isExtensionInstalledAndOlder('sql_patches', '0.8.0')) { - // Please update ext-sql_patches - debug_report_bug(__FUNCTION__, __LINE__, 'sql_patches is out-dated. Please update to at least 0.8.0 to continue. ext_name=' . $ext_name . ',isLocked=' . intval($isLocked)); - } // END - if - +// Determines the right points column name for given subject and 'locked' +function getPointsColumnNameFromSubjectLocked ($subject, $isLocked) { // Get the points_data entry - $pointsData = getPointsDataArrayFromExtensionName($ext_name); + $pointsData = getPointsDataArrayFromSubject($subject); // Regular points by default $columnName = $pointsData['column_name']; @@ -2111,15 +2126,9 @@ function getPointsColumnNameFromExtensionNameLocked ($ext_name, $isLocked) { } // Determines the payment method for given extension and 'locked' -function getPaymentMethodFromExtensionName ($ext_name) { - // Extension sql_patches must be up-to-date - if (isExtensionInstalledAndOlder('sql_patches', '0.8.0')) { - // Please update ext-sql_patches - debug_report_bug(__FUNCTION__, __LINE__, 'sql_patches is out-dated. Please update to at least 0.8.0 to continue. ext_name=' . $ext_name . ',isLocked=' . intval($isLocked)); - } // END - if - +function getPaymentMethodFromSubject ($subject) { // Get the points_data entry - $pointsData = getPointsDataArrayFromExtensionName($ext_name); + $pointsData = getPointsDataArrayFromSubject($subject); // Regular points by default $paymentMethod = $pointsData['payment_method']; @@ -2128,5 +2137,17 @@ function getPaymentMethodFromExtensionName ($ext_name) { return $paymentMethod; } +// Checks wether notification of points recipient is enabled +function isPaymentRecipientNotificationEnabled ($subject) { + // Get the points_data entry + $pointsData = getPointsDataArrayFromSubject($subject); + + // Is it enabled? + $isEnabled = ($pointsData['notify_recipient'] == 'Y'); + + // Return the result + return $isEnabled; +} + // [EOF] ?> diff --git a/inc/pool/pool-user.php b/inc/pool/pool-user.php index 906ceb9d1d..1ddd1a9959 100644 --- a/inc/pool/pool-user.php +++ b/inc/pool/pool-user.php @@ -255,7 +255,7 @@ if (!SQL_HASZERONUMS($result_main)) { if (isValidUserId($userid)) { // User does not exists, pay points back $points = getPaymentPoints($DATA['payment_id']); - addPointsDirectly('pool_payback', $DATA['sender_userid'], $points); + addPointsThroughReferalSystem('pool_payback', $DATA['sender_userid'], $points); // Add points together and remove user $pointsBack[$DATA['sender_userid']] += $points; diff --git a/inc/stats-functions.php b/inc/stats-functions.php index 5b6e48c0be..130e9ae2b3 100644 --- a/inc/stats-functions.php +++ b/inc/stats-functions.php @@ -159,7 +159,7 @@ function writeStatsTable () { array(generateDateTime(time(), '6')), __FUNCTION__, __LINE__); // Begin the SQL command - $sql = sprintf("REPLACE INTO `{?_MYSQL_PREFIX?}_stats_%s` (`stats_entry`,`stats_value`) VALUES ", + $sql = sprintf("REPLACE INTO `{?_MYSQL_PREFIX?}_stats_%s` (`stats_entry`, `stats_value`) VALUES ", generateDateTime(time(), '6')); // Add all entries to the final query diff --git a/inc/wrapper-functions.php b/inc/wrapper-functions.php index 16b10bcb27..4384212523 100644 --- a/inc/wrapper-functions.php +++ b/inc/wrapper-functions.php @@ -741,7 +741,16 @@ function isBlockModeEnabled () { return $GLOBALS['block_mode']; } -// Wrapper function for addPointsThroughReferalSystem() +/** + * Wrapper function for addPointsThroughReferalSystem(), you should generally + * avoid this function and use addPointsThroughReferalSystem() directly and add + * your special payment method entry to points_data instead. + * + * @param $subject A string-encoded subject for this add + * @param $userid The recipient (member) for given points + * @param $points Points to be added to member's account + * @return $added Wether the points has been added to the user's account + */ function addPointsDirectly ($subject, $userid, $points) { // Reset level here initReferalSystem(); @@ -2557,6 +2566,12 @@ function parseFloat ($floatString){ return floatval($floatString); } +// Generates a YES/NO option list from given default +function generateYesNoOptionList ($default = '') { + // Generate it + return generateOptionList('/ARRAY/', array('Y', 'N'), array('{--YES--}', '{--NO--}'), $default); +} + //----------------------------------------------------------------------------- // Configuration wrapper //----------------------------------------------------------------------------- diff --git a/install/menu-de.sql b/install/menu-de.sql index d257a91e33..6e4a3bac3e 100644 --- a/install/menu-de.sql +++ b/install/menu-de.sql @@ -1,84 +1,84 @@ -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('login',NULL,'Willkommen','Eingangsseite zum Admin-Bereich',0); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email',NULL,'Email-Management','Gebuchte Mails umleiten, Details zu den Buchungen anzeigen, Emails freigeben, registrierte Email-Adress auf Verfügbarkeit testen (Mass-Mailing!), Newsletter versenden, Email-Adressen sperren (Email-Backlist), gebuchte URLs sperren (URL-Blacklist)',4); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','email_stats','Email-Statistiken','Schauen Sie sich detailierte Statistiken zu den bereits versanden Mails an.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','edit_emails','Email-Daten ändern','Hier können Sie u.a. die gebuchte URL der Emails umändern, usw.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','unlock_emails','Emails freigeben','Geben Sie bei manuellem Versand gebuchte Mails hier frei.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','email_details','Email-Details ansehen','Sehen Sie sich jedes Details bereits gebuchter Mails an.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup',NULL,'Einstellungen','Interessen ändern, News schreiben, allgmeine Einstellungen (Auto-Versand usw.). Auto-Lock Funktion einrichten, manueller Lock des Versandes einrichten, Teile der Homepage sperren (wegen Wartungsarbeiten)',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_email','Versand, Empfang','Hier können Sie die maximal empfangbaren Mails usw. einstellen.',8); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_cats','Kategorien einrichten','Ändern oder löschen Sie bereits bestehende Kategorien oder fügen Sie weitere hinzu.',7); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','refbanner','Referal-Banner','Fügen Sie neue Banner hinzu, die dann die Mitglieder verlinken können, um neue Mitglieder zu werben. Oder editieren / löschen Sie bestehende. Hier sehen Sie auch die Anzahl der Klicks auf den jeweiligen Banner!',12); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','payments','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen','Fügen Sie neue {OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen hinzu oder ändern / löschen Sie bestende.',11); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc',NULL,'Verschiedenes','Verschiedene Einstellungen / Info-Seiten, die sonst nirgenswo reinpassten...',6); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('stats',NULL,'Statistiken','Sonstige Statistiken, die nirgenswo reinpassen',7); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('logout',NULL,'Ausloggen','Ausloggen aus dem Admin-Bereich. Dadurch wird Ihre Session gelöscht und Sie müssen sich erneut anmelden.',999); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('login',NULL,'Willkommen','Eingangsseite zum Admin-Bereich',0); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email',NULL,'Email-Management','Gebuchte Mails umleiten, Details zu den Buchungen anzeigen, Emails freigeben, registrierte Email-Adress auf Verfügbarkeit testen (Mass-Mailing!), Newsletter versenden, Email-Adressen sperren (Email-Backlist), gebuchte URLs sperren (URL-Blacklist)',4); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','email_stats','Email-Statistiken','Schauen Sie sich detailierte Statistiken zu den bereits versanden Mails an.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','edit_emails','Email-Daten ändern','Hier können Sie u.a. die gebuchte URL der Emails umändern, usw.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','unlock_emails','Emails freigeben','Geben Sie bei manuellem Versand gebuchte Mails hier frei.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','email_details','Email-Details ansehen','Sehen Sie sich jedes Details bereits gebuchter Mails an.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup',NULL,'Einstellungen','Interessen ändern, News schreiben, allgmeine Einstellungen (Auto-Versand usw.). Auto-Lock Funktion einrichten, manueller Lock des Versandes einrichten, Teile der Homepage sperren (wegen Wartungsarbeiten)',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','config_email','Versand, Empfang','Hier können Sie die maximal empfangbaren Mails usw. einstellen.',8); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','config_cats','Kategorien einrichten','Ändern oder löschen Sie bereits bestehende Kategorien oder fügen Sie weitere hinzu.',7); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','refbanner','Referal-Banner','Fügen Sie neue Banner hinzu, die dann die Mitglieder verlinken können, um neue Mitglieder zu werben. Oder editieren / löschen Sie bestehende. Hier sehen Sie auch die Anzahl der Klicks auf den jeweiligen Banner!',12); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','payments','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen','Fügen Sie neue {OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen hinzu oder ändern / löschen Sie bestende.',11); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('misc',NULL,'Verschiedenes','Verschiedene Einstellungen / Info-Seiten, die sonst nirgenswo reinpassten...',6); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('stats',NULL,'Statistiken','Sonstige Statistiken, die nirgenswo reinpassen',7); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('logout',NULL,'Ausloggen','Ausloggen aus dem Admin-Bereich. Dadurch wird Ihre Session gelöscht und Sie müssen sich erneut anmelden.',999); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Mix / Alles Senden --> keine Erotik!','Y',0); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Mix / Alles Senden --> ohne PopUps, keine Erotik','Y',1); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Traffic, Reflinks, Kostenloses, KEIN MLM!','Y',2); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Geldverdienen, Beruf, Arbeit, KEIN MLM!','Y',3); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Download, PC- Software, HP-Design','Y',4); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Investment, Banken, Börse, Versicherungen, KEIN MLM','Y',5); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Politik, Wissenschaft','Y',6); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Handy, SMS, ISDN, DSL,','Y',7); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Elektronik, Technik, Server, PC-Hardware, Hosting','Y',8); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Auto, Motorrad','Y',9); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Reise,Touristik','Y',10); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Kunst, Kultur, Bildung','Y',11); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Gesundheit, Fitness, Sport, KEIN MLM!','Y',12); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Lifestyle, Mode, Kosmetik, KEIN MLM!','Y',13); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Auktionen, Shopping, Verkauf, KEIN MLM!','Y',14); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Medien, Musik, Film, TV, Video & DVD','Y',15); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Singles, Flirten, Partnerschaft','Y',16); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Gewinnspiele, Wetten, Lotto, KEIN MLM!','Y',17); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Haus, Garten, Freizeit, Hobbys','Y',18); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Erotik --> Keine Hardcore !','Y',19); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Multi Level Marketing (alle Arten)','Y',20); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Wernis-Seiten','Y',21); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Primera-Seiten','Y',22); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Mix / Alles Senden --> keine Erotik!','Y',0); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Mix / Alles Senden --> ohne PopUps, keine Erotik','Y',1); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Traffic, Reflinks, Kostenloses, KEIN MLM!','Y',2); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Geldverdienen, Beruf, Arbeit, KEIN MLM!','Y',3); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Download, PC- Software, HP-Design','Y',4); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Investment, Banken, Börse, Versicherungen, KEIN MLM','Y',5); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Politik, Wissenschaft','Y',6); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Handy, SMS, ISDN, DSL,','Y',7); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Elektronik, Technik, Server, PC-Hardware, Hosting','Y',8); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Auto, Motorrad','Y',9); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Reise,Touristik','Y',10); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Kunst, Kultur, Bildung','Y',11); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Gesundheit, Fitness, Sport, KEIN MLM!','Y',12); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Lifestyle, Mode, Kosmetik, KEIN MLM!','Y',13); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Auktionen, Shopping, Verkauf, KEIN MLM!','Y',14); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Medien, Musik, Film, TV, Video & DVD','Y',15); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Singles, Flirten, Partnerschaft','Y',16); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Gewinnspiele, Wetten, Lotto, KEIN MLM!','Y',17); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Haus, Garten, Freizeit, Hobbys','Y',18); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Erotik --> Keine Hardcore !','Y',19); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Multi Level Marketing (alle Arten)','Y',20); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Wernis-Seiten','Y',21); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Primera-Seiten','Y',22); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main',NULL,'Hauptmenü',0,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','welcome','Willkommen',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','impressum','Impressum',5,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','agb','AGBs',4,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','infos','Infos',2,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members','confirm','Bestätigungslink',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members',NULL,'Mitglieder',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members','login','Einloggen',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main',NULL,'Hauptmenü',0,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','welcome','Willkommen',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','impressum','Impressum',5,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','agb','AGBs',4,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','infos','Infos',2,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members','confirm','Bestätigungslink',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members',NULL,'Mitglieder',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members','login','Einloggen',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (0,'Urlaub'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (5,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (10,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (15,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (20,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (25,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (30,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (35,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (40,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (45,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (50,'Bonus möglich!'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (90,'Bonus möglich!'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (0,'Urlaub'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (5,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (10,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (15,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (20,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (25,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (30,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (35,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (40,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (45,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (50,'Bonus möglich!'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (90,'Bonus möglich!'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main',NULL,'Mitgliedsmenü',0,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','welcome','Willkommen!',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','points','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Guthaben',4,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','categories','Kategorien auswählen',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','reflinks','Referal-Links',6,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','unconfirmed','Unbestätigte Emails',5,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','stats','Statistiken',9, 'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout',NULL,'Ausloggen',999,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout','logout','Ausloggen',999,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout','guest','Zum Gastmenü',1000,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main',NULL,'Mitgliedsmenü',0,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','welcome','Willkommen!',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','points','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Guthaben',4,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','categories','Kategorien auswählen',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','reflinks','Referal-Links',6,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','unconfirmed','Unbestätigte Emails',5,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','stats','Statistiken',9, 'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout',NULL,'Ausloggen',999,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout','logout','Ausloggen',999,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout','guest','Zum Gastmenü',1000,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (10,1.000,'Klick-Mail 10 Sek.',2.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (20,5.000,'Klick-Mail 20 Sek.',10.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (30,25.000,'Klick-Mail 30 Sek.',30.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (40,35.000,'Klick-Mail 40 Sek.',40.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (50,45.000,'Klick-Mail 50 Sek.',50.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (10,1.000,'Klick-Mail 10 Sek.',2.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (20,5.000,'Klick-Mail 20 Sek.',10.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (30,25.000,'Klick-Mail 30 Sek.',30.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (40,35.000,'Klick-Mail 40 Sek.',40.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (50,45.000,'Klick-Mail 50 Sek.',50.000); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','del_email','E-Mail löschen','Löschen Sie hierrüber E-Mails (sowohl Bonus- als auch Normal-Mails) aus Ihrem {?mt_word?}-System. Nur bei Normal-Mails: {OPEN_CONFIG}POINTS{CLOSE_CONFIG} aus den unbestätigten Mails werden dem Werber wieder vergütet.','7'); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc','extensions','Erweiterungen','Erweiterungen installieren, updaten, sperren, löschen usw.','8'); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','del_email','E-Mail löschen','Löschen Sie hierrüber E-Mails (sowohl Bonus- als auch Normal-Mails) aus Ihrem {?mt_word?}-System. Nur bei Normal-Mails: {OPEN_CONFIG}POINTS{CLOSE_CONFIG} aus den unbestätigten Mails werden dem Werber wieder vergütet.','7'); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('misc','extensions','Erweiterungen','Erweiterungen installieren, updaten, sperren, löschen usw.','8'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','stats','Statistiken','7','Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('admin',NULL,'Administrative Links','3','N','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('admin','admin','Zum Admin-Bereich','4','N','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','stats','Statistiken','7','Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('admin',NULL,'Administrative Links','3','N','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('admin','admin','Zum Admin-Bereich','4','N','N'); diff --git a/install/menu-en.sql b/install/menu-en.sql index a08a1739b7..702285728e 100644 --- a/install/menu-en.sql +++ b/install/menu-en.sql @@ -1,84 +1,84 @@ -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('login',NULL,'Willkommen','Eingangsseite zum Admin-Bereich',0); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email',NULL,'Email-Management','Gebuchte Mails umleiten, Details zu den Buchungen anzeigen, Emails freigeben, registrierte Email-Adress auf Verfügbarkeit testen (Mass-Mailing!), Newsletter versenden, Email-Adressen sperren (Email-Backlist), gebuchte URLs sperren (URL-Blacklist)',4); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','email_stats','Email-Statistiken','Schauen Sie sich detailierte Statistiken zu den bereits versanden Mails an.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','edit_emails','Email-Daten ändern','Hier können Sie u.a. die gebuchte URL der Emails umändern, usw.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','unlock_emails','Emails freigeben','Geben Sie bei manuellem Versand gebuchte Mails hier frei.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','email_details','Email-Details ansehen','Sehen Sie sich jedes Details bereits gebuchter Mails an.',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup',NULL,'Einstellungen','Interessen ändern, News schreiben, allgmeine Einstellungen (Auto-Versand usw.). Auto-Lock Funktion einrichten, manueller Lock des Versandes einrichten, Teile der Homepage sperren (wegen Wartungsarbeiten)',5); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_email','Versand, Empfang','Hier können Sie die maximal empfangbaren Mails usw. einstellen.',8); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','config_cats','Kategorien einrichten','Ändern oder löschen Sie bereits bestehende Kategorien oder fügen Sie weitere hinzu.',7); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','refbanner','Referal-Banner','Fügen Sie neue Banner hinzu, die dann die Mitglieder verlinken können, um neue Mitglieder zu werben. Oder editieren / löschen Sie bestehende. Hier sehen Sie auch die Anzahl der Klicks auf den jeweiligen Banner!',12); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('setup','payments','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen','Fügen Sie neue {OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen hinzu oder ändern / löschen Sie bestende.',11); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc',NULL,'Verschiedenes','Verschiedene Einstellungen / Info-Seiten, die sonst nirgenswo reinpassten...',6); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('stats',NULL,'Statistiken','Sonstige Statistiken, die nirgenswo reinpassen',7); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('logout',NULL,'Ausloggen','Ausloggen aus dem Admin-Bereich. Dadurch wird Ihre Session gelöscht und Sie müssen sich erneut anmelden.',999); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('login',NULL,'Willkommen','Eingangsseite zum Admin-Bereich',0); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email',NULL,'Email-Management','Gebuchte Mails umleiten, Details zu den Buchungen anzeigen, Emails freigeben, registrierte Email-Adress auf Verfügbarkeit testen (Mass-Mailing!), Newsletter versenden, Email-Adressen sperren (Email-Backlist), gebuchte URLs sperren (URL-Blacklist)',4); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','email_stats','Email-Statistiken','Schauen Sie sich detailierte Statistiken zu den bereits versanden Mails an.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','edit_emails','Email-Daten ändern','Hier können Sie u.a. die gebuchte URL der Emails umändern, usw.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','unlock_emails','Emails freigeben','Geben Sie bei manuellem Versand gebuchte Mails hier frei.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','email_details','Email-Details ansehen','Sehen Sie sich jedes Details bereits gebuchter Mails an.',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup',NULL,'Einstellungen','Interessen ändern, News schreiben, allgmeine Einstellungen (Auto-Versand usw.). Auto-Lock Funktion einrichten, manueller Lock des Versandes einrichten, Teile der Homepage sperren (wegen Wartungsarbeiten)',5); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','config_email','Versand, Empfang','Hier können Sie die maximal empfangbaren Mails usw. einstellen.',8); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','config_cats','Kategorien einrichten','Ändern oder löschen Sie bereits bestehende Kategorien oder fügen Sie weitere hinzu.',7); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','refbanner','Referal-Banner','Fügen Sie neue Banner hinzu, die dann die Mitglieder verlinken können, um neue Mitglieder zu werben. Oder editieren / löschen Sie bestehende. Hier sehen Sie auch die Anzahl der Klicks auf den jeweiligen Banner!',12); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('setup','payments','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen','Fügen Sie neue {OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Vergütungen hinzu oder ändern / löschen Sie bestende.',11); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('misc',NULL,'Verschiedenes','Verschiedene Einstellungen / Info-Seiten, die sonst nirgenswo reinpassten...',6); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('stats',NULL,'Statistiken','Sonstige Statistiken, die nirgenswo reinpassen',7); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('logout',NULL,'Ausloggen','Ausloggen aus dem Admin-Bereich. Dadurch wird Ihre Session gelöscht und Sie müssen sich erneut anmelden.',999); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Mix / Alles Senden --> keine Erotik!','Y',0); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Mix / Alles Senden --> ohne PopUps, keine Erotik','Y',1); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Traffic, Reflinks, Kostenloses, KEIN MLM!','Y',2); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Geldverdienen, Beruf, Arbeit, KEIN MLM!','Y',3); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Download, PC- Software, HP-Design','Y',4); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Investment, Banken, Börse, Versicherungen, KEIN MLM','Y',5); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Politik, Wissenschaft','Y',6); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Handy, SMS, ISDN, DSL,','Y',7); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Elektronik, Technik, Server, PC-Hardware, Hosting','Y',8); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Auto, Motorrad','Y',9); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Reise,Touristik','Y',10); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Kunst, Kultur, Bildung','Y',11); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Gesundheit, Fitness, Sport, KEIN MLM!','Y',12); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Lifestyle, Mode, Kosmetik, KEIN MLM!','Y',13); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Auktionen, Shopping, Verkauf, KEIN MLM!','Y',14); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Medien, Musik, Film, TV, Video & DVD','Y',15); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Singles, Flirten, Partnerschaft','Y',16); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Gewinnspiele, Wetten, Lotto, KEIN MLM!','Y',17); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Haus, Garten, Freizeit, Hobbys','Y',18); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Erotik --> Keine Hardcore !','Y',19); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Multi Level Marketing (alle Arten)','Y',20); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Wernis-Seiten','Y',21); -INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`,`visible`,`sort`) VALUES ('Primera-Seiten','Y',22); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Mix / Alles Senden --> keine Erotik!','Y',0); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Mix / Alles Senden --> ohne PopUps, keine Erotik','Y',1); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Traffic, Reflinks, Kostenloses, KEIN MLM!','Y',2); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Geldverdienen, Beruf, Arbeit, KEIN MLM!','Y',3); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Download, PC- Software, HP-Design','Y',4); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Investment, Banken, Börse, Versicherungen, KEIN MLM','Y',5); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Politik, Wissenschaft','Y',6); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Handy, SMS, ISDN, DSL,','Y',7); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Elektronik, Technik, Server, PC-Hardware, Hosting','Y',8); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Auto, Motorrad','Y',9); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Reise,Touristik','Y',10); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Kunst, Kultur, Bildung','Y',11); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Gesundheit, Fitness, Sport, KEIN MLM!','Y',12); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Lifestyle, Mode, Kosmetik, KEIN MLM!','Y',13); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Auktionen, Shopping, Verkauf, KEIN MLM!','Y',14); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Medien, Musik, Film, TV, Video & DVD','Y',15); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Singles, Flirten, Partnerschaft','Y',16); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Gewinnspiele, Wetten, Lotto, KEIN MLM!','Y',17); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Haus, Garten, Freizeit, Hobbys','Y',18); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Erotik --> Keine Hardcore !','Y',19); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Multi Level Marketing (alle Arten)','Y',20); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Wernis-Seiten','Y',21); +INSERT INTO `{?_MYSQL_PREFIX?}_cats` (`cat`, `visible`, `sort`) VALUES ('Primera-Seiten','Y',22); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main',NULL,'Hauptmenü',0,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','welcome','Willkommen',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','impressum','Impressum',5,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','agb','AGBs',4,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','infos','Infos',2,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members',NULL,'Mitglieder',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members','confirm','Bestätigungslink',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('members','login','Einloggen',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main',NULL,'Hauptmenü',0,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','welcome','Willkommen',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','impressum','Impressum',5,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','agb','AGBs',4,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','infos','Infos',2,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members',NULL,'Mitglieder',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members','confirm','Bestätigungslink',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('members','login','Einloggen',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (0,'Urlaub'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (5,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (10,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (15,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (20,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (25,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (30,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (35,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (40,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (45,''); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (50,'Bonus möglich!'); -INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`,`comment`) VALUES (90,'Bonus möglich!'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (0,'Urlaub'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (5,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (10,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (15,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (20,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (25,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (30,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (35,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (40,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (45,''); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (50,'Bonus möglich!'); +INSERT INTO `{?_MYSQL_PREFIX?}_max_receive` (`value`, `comment`) VALUES (90,'Bonus möglich!'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main',NULL,'Mitgliedsmenü',0,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','welcome','Willkommen!',1,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','points','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Guthaben',4,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','categories','Kategorien auswählen',3,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','reflinks','Referal-Links',6,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','unconfirmed','Unbestätigte Emails',5,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','stats','Statistiken',9,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout',NULL,'Ausloggen',999,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout','logout','Ausloggen',999,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('logout','guest','Zum Gastmenü',1000,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main',NULL,'Mitgliedsmenü',0,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','welcome','Willkommen!',1,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','points','{OPEN_CONFIG}POINTS{CLOSE_CONFIG}-Guthaben',4,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','categories','Kategorien auswählen',3,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','reflinks','Referal-Links',6,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','unconfirmed','Unbestätigte Emails',5,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','stats','Statistiken',9,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout',NULL,'Ausloggen',999,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout','logout','Ausloggen',999,'Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_member_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('logout','guest','Zum Gastmenü',1000,'Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (10,1.000,'Klick-Mail 10 Sek.',2.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (20,5.000,'Klick-Mail 20 Sek.',10.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (30,25.000,'Klick-Mail 30 Sek.',30.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (40,35.000,'Klick-Mail 40 Sek.',40.000); -INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`,`payment`,`mail_title`,`price`) VALUES (50,45.000,'Klick-Mail 50 Sek.',50.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (10,1.000,'Klick-Mail 10 Sek.',2.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (20,5.000,'Klick-Mail 20 Sek.',10.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (30,25.000,'Klick-Mail 30 Sek.',30.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (40,35.000,'Klick-Mail 40 Sek.',40.000); +INSERT INTO `{?_MYSQL_PREFIX?}_payments` (`time`, `payment`, `mail_title`, `price`) VALUES (50,45.000,'Klick-Mail 50 Sek.',50.000); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('email','del_email','E-Mail löschen','Löschen Sie hierrüber E-Mails (sowohl Bonus- als auch Normal-Mails) aus Ihrem {?mt_word?}-System. Nur bei Normal-Mails: {OPEN_CONFIG}POINTS{CLOSE_CONFIG} aus den unbestätigten Mails werden dem Werber wieder vergütet.','7'); -INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`,`what`,`title`,`descr`,`sort`) VALUES ('misc','extensions','Erweiterungen','Erweiterungen installieren, updaten, sperren, löschen usw.','8'); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('email','del_email','E-Mail löschen','Löschen Sie hierrüber E-Mails (sowohl Bonus- als auch Normal-Mails) aus Ihrem {?mt_word?}-System. Nur bei Normal-Mails: {OPEN_CONFIG}POINTS{CLOSE_CONFIG} aus den unbestätigten Mails werden dem Werber wieder vergütet.','7'); +INSERT INTO `{?_MYSQL_PREFIX?}_admin_menu` (`action`, `what`, `title`, `descr`, `sort`) VALUES ('misc','extensions','Erweiterungen','Erweiterungen installieren, updaten, sperren, löschen usw.','8'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('main','stats','Statistiken','7','Y','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('admin',NULL,'Administrative Links','3','N','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`,`what`,`title`,`sort`,`visible`,`locked`) VALUES ('admin','admin','Zum Admin-Bereich','4','N','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('main','stats','Statistiken','7','Y','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('admin',NULL,'Administrative Links','3','N','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_guest_menu` (`action`, `what`, `title`, `sort`, `visible`, `locked`) VALUES ('admin','admin','Zum Admin-Bereich','4','N','N'); diff --git a/install/tables.sql b/install/tables.sql index ac64e2ff2b..401e47f7f5 100644 --- a/install/tables.sql +++ b/install/tables.sql @@ -205,20 +205,20 @@ CREATE TABLE `{?_MYSQL_PREFIX?}_jackpot` ( INSERT INTO `{?_MYSQL_PREFIX?}_config` (`config`) VALUES (0); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('admin','N','N','Y','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('chk_login','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('confirm','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('css','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('frametester','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('index','N','N','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('js','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('loader','N','Y','N','','N'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('login','N','N','N','','Y'); -INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`,`locked`,`hidden`,`admin_only`,`title`,`mem_only`) VALUES ('ref','N','Y','N','','N'); - -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (0,100); -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (1,30); -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (2,15); -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (3,10); -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (4,8); -INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`,`percents`) VALUES (5,5); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('admin','N','N','Y','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('chk_login','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('confirm','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('css','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('frametester','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('index','N','N','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('js','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('loader','N','Y','N','','N'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('login','N','N','N','','Y'); +INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` (`module`, `locked`, `hidden`, `admin_only`, `title`, `mem_only`) VALUES ('ref','N','Y','N','','N'); + +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (0,100); +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (1,30); +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (2,15); +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (3,10); +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (4,8); +INSERT INTO `{?_MYSQL_PREFIX?}_refdepths` (`level`, `percents`) VALUES (5,5); diff --git a/mailid_top.php b/mailid_top.php index 68aff4de92..3afc87b511 100644 --- a/mailid_top.php +++ b/mailid_top.php @@ -296,7 +296,7 @@ if ((isValidUserId($userId)) && (($mailId > 0) || ($bonusId > 0)) && (!ifFatalEr loadTemplate($template, false, $content); } elseif (isValidUserId($sender)) { // Wrong image code! So add points to sender's account - addPointsDirectly('mailid_payback', $sender, $payment); + addPointsThroughReferalSystem('mailid_payback', $sender, $payment); // Load template loadTemplate('mailid_points_failed', false, $content); diff --git a/templates/de/emails/member/member_add_points.tpl b/templates/de/emails/member/member_add_points.tpl index af5f371749..e7257d2e62 100644 --- a/templates/de/emails/member/member_add_points.tpl +++ b/templates/de/emails/member/member_add_points.tpl @@ -6,6 +6,9 @@ Grund dazu war folgender: ------------------------------ $content[reason] ------------------------------ +Genauere Spezifizierung (Betreff): +{%pipe,translatePointsSubject=$content[subject]%} +------------------------------ Mit freundlichen Grüßen, Ihr {?MAIN_TITLE?} Team diff --git a/templates/de/html/admin/admin_add_rallye.tpl b/templates/de/html/admin/admin_add_rallye.tpl index dffbd35727..d52b093899 100644 --- a/templates/de/html/admin/admin_add_rallye.tpl +++ b/templates/de/html/admin/admin_add_rallye.tpl @@ -20,7 +20,9 @@ {--RALLYE_TEMPLATE--}: - $content[templates_selection] + + {%pipe,addReferalRallyeTemplateSelection%} + {--RALLYE_START_DAY--}: @@ -40,7 +42,7 @@ {--RALLYE_IS_ACTIVE--}: @@ -48,7 +50,7 @@ {--RALLYE_AUTO_ADD_USER--}: @@ -56,7 +58,7 @@ {--RALLYE_SEND_NOTIFY--}: diff --git a/templates/de/html/admin/admin_config_autopurge.tpl b/templates/de/html/admin/admin_config_autopurge.tpl index 9d907baace..e36092421c 100644 --- a/templates/de/html/admin/admin_config_autopurge.tpl +++ b/templates/de/html/admin/admin_config_autopurge.tpl @@ -59,8 +59,9 @@ {--ADMIN_CONFIG_AUTOPURGE_ACTIVE--}: - {--YES--}
- {--NO--} + diff --git a/templates/de/html/admin/admin_config_beg.tpl b/templates/de/html/admin/admin_config_beg.tpl index 079682e87b..914b4665ff 100644 --- a/templates/de/html/admin/admin_config_beg.tpl +++ b/templates/de/html/admin/admin_config_beg.tpl @@ -52,21 +52,6 @@ $content[beg_userid] - - - {--ADMIN_CONFIG_SELECT_BEG_MODE--}: - - - - - - {--ADMIN_CONFIG_PAYMENT_MODE_DIRECT--} - - - - {--ADMIN_CONFIG_PAYMENT_MODE_REF--} - - {--ADMIN_CONFIG_BEG_RALLYE_TITLE--} diff --git a/templates/de/html/admin/admin_config_birthday.tpl b/templates/de/html/admin/admin_config_birthday.tpl index 05142791a2..669221ea14 100644 --- a/templates/de/html/admin/admin_config_birthday.tpl +++ b/templates/de/html/admin/admin_config_birthday.tpl @@ -19,23 +19,8 @@ {--ADMIN_CONFIG_BIRTHDAY_ONLY_ACTIVE--} - {--YES--}
- {--NO--} - - - - - {--ADMIN_CONFIG_SELECT_BIRTHDAY_MODE--}: - - - - - - {--ADMIN_CONFIG_PAYMENT_MODE_DIRECT--} - - - - {--ADMIN_CONFIG_PAYMENT_MODE_REF--} + {--YES--}
+ {--NO--} diff --git a/templates/de/html/admin/admin_config_menu.tpl b/templates/de/html/admin/admin_config_menu.tpl index 29cba16973..a0d82e0bcd 100644 --- a/templates/de/html/admin/admin_config_menu.tpl +++ b/templates/de/html/admin/admin_config_menu.tpl @@ -11,8 +11,9 @@ {--ADMIN_CONFIG_GUEST_MENU_ADVERT_ENABLED--} - {--YES--}
- {--NO--} + @@ -20,8 +21,9 @@ {--ADMIN_CONFIG_MEMBER_MENU_ADVERT_ENABLED--} - {--YES--}
- {--NO--} + diff --git a/templates/de/html/admin/admin_config_other.tpl b/templates/de/html/admin/admin_config_other.tpl index abff036710..b1c9ff7738 100644 --- a/templates/de/html/admin/admin_config_other.tpl +++ b/templates/de/html/admin/admin_config_other.tpl @@ -113,8 +113,9 @@ {--ADMIN_CONFIG_GUEST_MENU--}: - {--ADMIN_IS_SHOWN--}
- {--ADMIN_IS_NOT_SHOWN--} + @@ -123,8 +124,9 @@ {--ADMIN_CONFIG_MEMBER_MENU--}: - {--ADMIN_IS_SHOWN--}
- {--ADMIN_IS_NOT_SHOWN--} + @@ -133,8 +135,9 @@ {--ADMIN_CONFIG_YOURE_HERE--}: - {--ADMIN_IS_SHOWN--}
- {--ADMIN_IS_NOT_SHOWN--} + @@ -143,8 +146,9 @@ {--ADMIN_CONFIG_SHOW_TIMINGS--}: - {--YES--}
- {--NO--} + @@ -153,8 +157,9 @@ {--ADMIN_CONFIG_SHOW_POINTS_UNCONFIRMED--}: - {--YES--}
- {--NO--} + @@ -188,8 +193,9 @@ {--ADMIN_CONFIG_ZIPCODE_ACTIVE--}: - {--YES--}
- {--NO--} + @@ -198,8 +204,9 @@ {--ADMIN_CONFIG_AUTOSEND_ACTIVE--}: - {--YES--}
- {--NO--} + @@ -214,8 +221,9 @@ {--ADMIN_CONFIG_SEND_UPDATE--}: - {--YES--}
- {--NO--} + @@ -224,8 +232,9 @@ {--ADMIN_CONFIG_NOTIFY_ADMIN--}: - {--YES--}
- {--NO--} + @@ -277,8 +286,9 @@ {--ADMIN_CONFIG_DISPLAY_DEBUG_SQLS--} - {--YES--}
- {--NO--} + @@ -293,8 +303,9 @@ {--ADMIN_CONFIG_STATS_ENABLED--} - {--YES--}
- {--NO--} + diff --git a/templates/de/html/admin/admin_config_point_settings.tpl b/templates/de/html/admin/admin_config_point_settings.tpl index f74fad7371..ddfb9b2909 100644 --- a/templates/de/html/admin/admin_config_point_settings.tpl +++ b/templates/de/html/admin/admin_config_point_settings.tpl @@ -18,16 +18,6 @@ - - {--ADMIN_CONFIG_REFMODE--} - - {--ADMIN_CONFIG_REFMODE_REF--} - -
- {--ADMIN_CONFIG_REFMODE_DIRECT--} - - - {--ADMIN_CONFIG_REFERAL_PAYOUT--} diff --git a/templates/de/html/admin/admin_config_surfbar.tpl b/templates/de/html/admin/admin_config_surfbar.tpl index 719fed2245..56b617651d 100644 --- a/templates/de/html/admin/admin_config_surfbar.tpl +++ b/templates/de/html/admin/admin_config_surfbar.tpl @@ -143,8 +143,9 @@ {--ADMIN_CONFIG_SURFBAR_AUTOSTART--} - {--YES--}
- {--NO--} + @@ -152,8 +153,9 @@ {--ADMIN_CONFIG_SURFBAR_NOTIFY_LIMITS--} - {--YES--}
- {--NO--} + @@ -161,8 +163,9 @@ {--ADMIN_CONFIG_SURFBAR_NOTIFY_ADMIN_UNLOCK--} - {--YES--}
- {--NO--} + @@ -198,8 +201,9 @@ {--ADMIN_CONFIG_SURFBAR_MIGRATE_ORDER--} - {--YES--}
- {--NO--} + @@ -207,8 +211,9 @@ {--ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM--} - {--ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM_Y--}
- {--ADMIN_CONFIG_SURFBAR_GUEST_LOGIN_FORM_N--} + diff --git a/templates/de/html/admin/admin_delete_country_row.tpl b/templates/de/html/admin/admin_delete_country_row.tpl new file mode 100644 index 0000000000..e1fb9e6205 --- /dev/null +++ b/templates/de/html/admin/admin_delete_country_row.tpl @@ -0,0 +1,14 @@ + + $content[id] + + + + $content[code] + + + $content[descr] + + + {%pipe,translateYesNo=$content[is_active]%} + + diff --git a/templates/de/html/admin/admin_edit_country_row.tpl b/templates/de/html/admin/admin_edit_country_row.tpl new file mode 100644 index 0000000000..42f7eac1aa --- /dev/null +++ b/templates/de/html/admin/admin_edit_country_row.tpl @@ -0,0 +1,16 @@ + + $content[id] + + + + + + + + + + + + diff --git a/templates/de/html/admin/admin_list_country_del_row.tpl b/templates/de/html/admin/admin_list_country_del_row.tpl index 99f3f61547..11f5d85d80 100644 --- a/templates/de/html/admin/admin_list_country_del_row.tpl +++ b/templates/de/html/admin/admin_list_country_del_row.tpl @@ -1,14 +1 @@ - - $content[id] - - - - $content[code] - - - $content[descr] - - - $content[is_active] - - + diff --git a/templates/de/html/admin/admin_list_country_edit_row.tpl b/templates/de/html/admin/admin_list_country_edit_row.tpl index 607fb30d96..11f5d85d80 100644 --- a/templates/de/html/admin/admin_list_country_edit_row.tpl +++ b/templates/de/html/admin/admin_list_country_edit_row.tpl @@ -1,16 +1 @@ - - $content[id] - - - - - - - - - - - - +