From: Roland Häder Date: Sun, 14 Sep 2008 02:51:21 +0000 (+0000) Subject: - Major change in menu system. You need to rewrite/update your member and guest X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=82d53dfb7f59fa1e37bd500e3db3d10a9d4a78da;p=mailer.git - Major change in menu system. You need to rewrite/update your member and guest menu template or else you will see "Array" in all menus. - Withdraw functionality re-added to wernis extension - Some minor fixes --- diff --git a/.gitattributes b/.gitattributes index c757d3301a..49b0ff6bf4 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1309,9 +1309,11 @@ templates/de/html/member/member_welcome_footer.tpl -text templates/de/html/member/member_welcome_header.tpl -text templates/de/html/member/member_wernis.tpl -text templates/de/html/member/member_wernis_form.tpl -text +templates/de/html/member/member_wernis_mode_choose.tpl -text templates/de/html/member/member_wernis_mode_list.tpl -text templates/de/html/member/member_wernis_mode_list_row.tpl -text -templates/de/html/member/member_wernis_mode_pay.tpl -text +templates/de/html/member/member_wernis_mode_payout.tpl -text +templates/de/html/member/member_wernis_mode_withdraw.tpl -text templates/de/html/member/member_wernis_row.tpl -text templates/de/html/message.tpl -text templates/de/html/metadata.tpl -text diff --git a/inc/databases.php b/inc/databases.php index 74de24b765..67b179c029 100644 --- a/inc/databases.php +++ b/inc/databases.php @@ -114,7 +114,7 @@ define('USAGE_BASE', "usage"); define('SERVER_URL', "http://www.mxchange.org"); // This current patch level -define('CURR_SVN_REVISION', "324"); +define('CURR_SVN_REVISION', "325"); // Take a prime number which is long (if you know a longer one please try it out!) define('_PRIME', 591623); diff --git a/inc/extensions/ext-active.php b/inc/extensions/ext-active.php index cef68ef784..47849445de 100644 --- a/inc/extensions/ext-active.php +++ b/inc/extensions/ext-active.php @@ -97,7 +97,7 @@ case "update": // Update an extension break; case "0.0.5": // SQL queries for v0.0.5 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD active_limit BIGINT(20) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD active_limit BIGINT(20) UNSIGNED NOT NULL DEFAULT '10'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'config_active', 'Aktiv-Liste', 'Einstellungen an der Aktiv-Liste (Heute Online im Gastbereich) vornehmen.', 8)"; // Update notes (these will be set as task text!) diff --git a/inc/extensions/ext-admins.php b/inc/extensions/ext-admins.php index b23f0f1377..119c33010f 100644 --- a/inc/extensions/ext-admins.php +++ b/inc/extensions/ext-admins.php @@ -99,8 +99,8 @@ case "update": // Update an extension $SQLs[] = "UPDATE "._MYSQL_PREFIX."_admins SET default_acl='allow' WHERE login='".get_session('admin_login')."' LIMIT 1"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_admins_acls"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_admins_acls ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -admin_id BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +admin_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', action_menu VARCHAR(255) NOT NULL DEFAULT '', what_menu VARCHAR(255) NOT NULL DEFAULT '', access_mode ENUM('deny', 'allow') NOT NULL DEFAULT 'deny', @@ -113,14 +113,14 @@ PRIMARY KEY (id) break; case "0.3.1": // SQL queries for v0.3.1 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_admins_acls MODIFY id BIGINT(20) NOT NULL AUTO_INCREMENT"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_admins_acls MODIFY id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT"; break; case "0.4.0": // SQL queries for v0.4.0 $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_admins_mails"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_admins_mails ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -admin_id BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +admin_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', mail_template VARCHAR(255) NOT NULL, KEY (admin_id), PRIMARY KEY (id) diff --git a/inc/extensions/ext-autopurge.php b/inc/extensions/ext-autopurge.php index 24c2364a6e..d029ba56fb 100644 --- a/inc/extensions/ext-autopurge.php +++ b/inc/extensions/ext-autopurge.php @@ -51,25 +51,20 @@ switch ($EXT_LOAD_MODE) { case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called) // SQL commands to run - $SQLs[] = "alter table "._MYSQL_PREFIX."_pool modify data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE','DELETED') NOT NULL DEFAULT 'TEMP'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_pool MODIFY data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE','DELETED') NOT NULL DEFAULT 'TEMP'"; if (EXT_IS_ACTIVE("bonus")) { - $SQLs[] = "alter table "._MYSQL_PREFIX."_bonus modify data_type ENUM('NEW','QUEUE','SEND','DELETED') NOT NULL DEFAULT 'NEW'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_bonus MODIFY data_type ENUM('NEW','QUEUE','SEND','DELETED') NOT NULL DEFAULT 'NEW'"; } break; case "remove": // Do stuff when removing extension // SQL commands to run - $SQLs[] = "alter table "._MYSQL_PREFIX."_pool modify data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_pool MODIFY data_type ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'"; if (EXT_IS_ACTIVE("bonus")) { - $SQLs[] = "alter table "._MYSQL_PREFIX."_bonus modify data_type ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_bonus MODIFY data_type ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW'"; } - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config DROP autopurge_inactive"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config DROP autopurge_unconfirmed"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config DROP ap_inactive_since"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config DROP ap_inactive_time"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config DROP ap_unconfirmed_time"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE action='setup' AND what='config_autopurge' LIMIT 1"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE action='user' AND what='list_autopurge' LIMIT 1"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data DROP ap_notified"; @@ -91,12 +86,12 @@ case "update": // Update an extension case "0.1": // SQL queries for v0.1 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD autopurge_inactive ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD autopurge_unconfirmed ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_inactive_since BIGINT(20) NOT NULL DEFAULT '2592000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_inactive_time BIGINT(20) NOT NULL DEFAULT '25200'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_unconfirmed_time BIGINT(20) NOT NULL DEFAULT '432000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_inactive_since BIGINT(20) UNSIGNED NOT NULL DEFAULT '2592000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_inactive_time BIGINT(20) UNSIGNED NOT NULL DEFAULT '25200'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_unconfirmed_time BIGINT(20) UNSIGNED NOT NULL DEFAULT '432000'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('setup', 'config_autopurge', 'Auto-Löschung', 'Automatisch inaktive oder nicht bestätigte Accounts löschen.', '12')"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('user', 'list_autopurge', 'Inaktive finden', 'Lassen Sie sich vor dem täglichen Reset anzeigen, welche Mitglieder als inaktiv erkannt werden und welche gelöscht werden.', '10')"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD ap_notified BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD ap_notified BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Automatisches Lö:schen von inaktiven bzw. nicht bestätigten Accounts hinzugefügt."; @@ -135,7 +130,7 @@ case "update": // Update an extension case "0.1.9": // SQL queries for v0.1.9 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD autopurge_tasks ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_tasks_time BIGINT(20) NOT NULL DEFAULT '".(60*60*24*7)."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_tasks_time BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(60*60*24*7)."'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Bereinigung von zu löschenden Aufgaben klappt wieder. Zeitlimit für genanntes kann eingestellt werden (Default = 7 Tage).

Bitte aktualisieren Sie auch die Admin-Templates!"; @@ -213,7 +208,7 @@ case "update": // Update an extension case "0.3.3": // SQL queries for v0.3.3 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_del_mails ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_dm_notify ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_dm_timeout BIGINT(20) NOT NULL DEFAULT '86400'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD ap_dm_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Von bereits gelöschten Mitgliedern die Mails löschen integriert."; diff --git a/inc/extensions/ext-beg.php b/inc/extensions/ext-beg.php index 068d91db64..310d5cf425 100644 --- a/inc/extensions/ext-beg.php +++ b/inc/extensions/ext-beg.php @@ -54,14 +54,14 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'config_beg', 'Bettel-Link', 'IP-Sperre, {!POINTS!}-Vergütung usw. können Sie hier einstellen.', 10)"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_guest_menu (action, what, title, sort, visible, locked) VALUES ('main', 'beg', '{!POINTS!} erbetteln!', 4, 'Y', 'Y')"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, sort, visible, locked) VALUES ('main', 'beg', 'Ihr Bettel-Link', 6, 'Y', 'Y')"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_timeout BIGINT(20) NOT NULL DEFAULT '600'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_uid_timeout BIGINT(20) NOT NULL DEFAULT '1800'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_points DOUBLE(20,5) NOT NULL DEFAULT '0.00100'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_clicks BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '600'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_uid_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '1800'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00100'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_clicks BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_beg_ips"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_beg_ips ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', remote_ip VARCHAR(15) NOT NULL DEFAULT '0.0.0.0', timeout VARCHAR(10) NOT NULL DEFAULT '', KEY (userid), @@ -108,7 +108,7 @@ case "update": // Update an extension break; case "0.0.3": // SQL queries for v0.0.3 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_points_max DOUBLE(20,5) NOT NULL DEFAULT '0.10000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_points_max DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.10000'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Maximale Obergrenze an {!POINTS!} einstellbar (Standart: 0,1 {!POINTS!})"; @@ -125,14 +125,14 @@ case "update": // Update an extension break; case "0.0.6": // SQL queries for v0.0.6 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_uid BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Ein Mitgliedsaccount (empfehlenswert ist Ihr eigenes!) kann zum Abbuchen der {!POINTS!} verwendet werden. Template admin_config_beg.tpl (und pro!) nicht vergessen, zu aktualisieren."; break; case "0.0.8": // SQL queries for v0.0.8 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ip_timeout BIGINT(20) NOT NULL DEFAULT '1800'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ip_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '1800'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Zeitsperre gegen die selbe IP-Nummer hinzugefügt."; @@ -156,7 +156,7 @@ case "update": // Update an extension case "0.1.2": // SQL queries for v0.1.2 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_mode ENUM('DIRECT', 'REF') NOT NULL DEFAULT 'REF'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ranks TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ranks TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_active ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_rallye ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_points DOUBLE(21,5) NOT NULL DEFAULT '0.00000'"; @@ -195,11 +195,11 @@ case "update": // Update an extension $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ral_en_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_ral_di_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_new_mem_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_notify_bonus DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_notify_wait BIGINT(20) NOT NULL DEFAULT '30'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_notify BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_en_notify BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_di_notify BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_notify_bonus DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD beg_notify_wait BIGINT(20) UNSIGNED NOT NULL DEFAULT '30'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_en_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD beg_ral_di_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Die Mitglieder können nun optional automatisch über eine aktivierte und/oder deaktivierte Bettel-Rallye informiert werden. Beide Benachrichtigungen können Sie unter Einstellungen --> Bettel-Link/-rallye seperat ein- und ausschalten! Zudem ist eine Sperre gegen eingeloggte Mitglieder eingebaut, die das Klicken auf den eigenen Bettel-Link etwas erschweren soll."; diff --git a/inc/extensions/ext-birthday.php b/inc/extensions/ext-birthday.php index 661e55e8b3..48008a6e61 100644 --- a/inc/extensions/ext-birthday.php +++ b/inc/extensions/ext-birthday.php @@ -81,12 +81,12 @@ case "update": // Update an extension break; case "0.2": // SQL queries for v0.2 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD birthday_points BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD birthday_points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_user_birthday"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_user_birthday ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', -points BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', chk_value VARCHAR(255) NOT NULL DEFAULT '', KEY(userid), PRIMARY KEY(id) diff --git a/inc/extensions/ext-bonus.php b/inc/extensions/ext-bonus.php index 54fbe20ffc..c3db49da19 100644 --- a/inc/extensions/ext-bonus.php +++ b/inc/extensions/ext-bonus.php @@ -55,37 +55,37 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu VALUES (NULL,'main','bonus','Bonuspunkte',7,'Y','Y', '', 0)"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_bonus"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_bonus ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -cat_id BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +cat_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', subject VARCHAR(255) NOT NULL DEFAULT '', text LONGBLOB NOT NULL, receivers LONGBLOB NOT NULL, -points BIGINT(20) NOT NULL DEFAULT '0', -time TINYINT(3) NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +time TINYINT(3) UNSIGNED NOT NULL DEFAULT '0', data_type ENUM('NEW','QUEUE','SEND') NOT NULL DEFAULT 'NEW', timestamp VARCHAR(10) NOT NULL DEFAULT '0', url VARCHAR(255) NOT NULL DEFAULT '', -target_send BIGINT(20) NOT NULL DEFAULT '0', -clicks BIGINT(20) NOT NULL DEFAULT '0', -mails_sent BIGINT(20) NOT NULL DEFAULT '0', +target_send BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +clicks BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +mails_sent BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', KEY(cat_id), PRIMARY KEY (id) )TYPE=MyISAM"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_links modify link_type ENUM('NORMAL','BONUS') NOT NULL DEFAULT 'NORMAL'"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_links ADD bonus_id BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_links MODIFY link_type ENUM('NORMAL','BONUS') NOT NULL DEFAULT 'NORMAL'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_links ADD bonus_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_links ADD INDEX (bonus_id)"; // Run this SQL when html or html_mail extension is installed - if (EXT_IS_ACTIVE("html_mail")) $SQLs[] = "alter table "._MYSQL_PREFIX."_bonus add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; + if (EXT_IS_ACTIVE("html_mail")) $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_bonus add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; break; case "remove": // Do stuff when removing extension // SQL commands to run - $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE what='bonus' OR what='config_bonus' OR what='send_bonus' OR what='list_bonus' LIMIT 4"; + $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE what IN ('bonus','config_bonus','send_bonus','list_bonus') LIMIT 4"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_member_menu WHERE what='bonus' LIMIT 1"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_guest_menu WHERE action='bonus' LIMIT 1"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_links modify link_type ENUM('NORMAL') NOT NULL DEFAULT 'NORMAL'"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_links drop bonus_id"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_links MODIFY link_type ENUM('NORMAL') NOT NULL DEFAULT 'NORMAL'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_links DROP bonus_id"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_bonus"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_bonus_urls"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_bonus_customer"; @@ -126,9 +126,9 @@ case "update": // Update an extension $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu VALUES (NULL,'setup','config_bonus','Bonus-{!POINTS!}',8,'Richten Sie Bonus-{!POINTS!} ein, die beim x'ten Klick auf die Mail verbucht werden sollen. Beispiele: Der 1. Klick sollte mehr {!POINTS!} zusätzlich bekommen, als der 10. Klick.')"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD login_bonus DOUBLE(20,3) NOT NULL DEFAULT '10.000'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD turbo_bonus DOUBLE(20,3) NOT NULL DEFAULT '100.000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD login_timeout BIGINT(20) NOT NULL DEFAULT '86400'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD login_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD turbo_rates VARCHAR(255) NOT NULL DEFAULT '50;20;10'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_ranks TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_ranks TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; // Use actual month for this update $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD login_bonus DOUBLE(20,3) NOT NULL DEFAULT '0.000'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD turbo_bonus DOUBLE(20,3) NOT NULL DEFAULT '0.000'"; @@ -142,11 +142,11 @@ case "update": // Update an extension case "0.2.2": // SQL queries for v0.2.2 $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_bonus_turbo"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_bonus_turbo ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', -mail_id BIGINT(20) NOT NULL DEFAULT '0', -bonus_id BIGINT(20) NOT NULL DEFAULT '0', -level BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +mail_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +bonus_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +level BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', points DOUBLE(20,3) NOT NULL DEFAULT '0.000', timemark VARCHAR(32) NOT NULL DEFAULT '0', PRIMARY KEY(id), @@ -236,7 +236,7 @@ KEY userid (userid) case "0.3.5": // SQL queries for v0.3.5 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_mode ENUM('UID', 'JACKPOT', 'ADD') NOT NULL DEFAULT 'ADD'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_uid BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Der Login-Bonus Aktiv-Bonus (= Klick-Bonus) können nun zuerst von einem Mitgliederaccount (das sollte Ihres sein!), vom Jackpot abgezogen oder einfach dazuadiert werden."; @@ -263,8 +263,8 @@ KEY userid (userid) break; case "0.4.0": // SQL queries for v0.4.0 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_timeout BIGINT(20) NOT NULL DEFAULT '".(ONE_DAY * 7)."'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_lines BIGINT(20) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(ONE_DAY * 7)."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_lines BIGINT(20) UNSIGNED NOT NULL DEFAULT '10'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Automatisches Löschen von Turbo-Bonus-Zeilen ("._MYSQL_PREFIX."_bonus_turbo) und begrenzte Anzahl von Einträgen hinzugefügt."; @@ -286,13 +286,13 @@ KEY userid (userid) break; case "0.4.4": // SQL queries for v0.4.4 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_order DOUBLE(20,5) NOT NULL DEFAULT '15.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_ref DOUBLE(20,5) NOT NULL DEFAULT '100.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_stats DOUBLE(20,5) NOT NULL DEFAULT '5.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_order DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '15.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_ref DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '100.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_stats DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '5.00000'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_active ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_order DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ref DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_stats DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_order DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ref DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_stats DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_stats ADD is_stats ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; // Update notes (these will be set as task text!) @@ -474,11 +474,11 @@ WHERE last_online < ".$mark." ORDER BY userid"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_en_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_di_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_new_mem_notify ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_notify_points DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_notify_wait BIGINT(20) NOT NULL DEFAULT '30'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_notify BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_en_notify BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_di_notify BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_notify_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD bonus_notify_wait BIGINT(20) UNSIGNED NOT NULL DEFAULT '30'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_en_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD bonus_ral_di_notify BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Optionale automatische Benachrichtigung über aktivierte und/oder deaktivierte Aktiv-Rallye einstellbar."; diff --git a/inc/extensions/ext-cache.php b/inc/extensions/ext-cache.php index c13a330d37..6ce6c3fa27 100644 --- a/inc/extensions/ext-cache.php +++ b/inc/extensions/ext-cache.php @@ -52,7 +52,7 @@ switch ($EXT_LOAD_MODE) { case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called) // SQL commands to run - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_update BIGINT(20) NOT NULL DEFAULT '3600'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_update BIGINT(20) UNSIGNED NOT NULL DEFAULT '3600'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_path VARCHAR(255) NOT NULL DEFAULT 'cache/'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_tested tinyint(1) NOT NULL DEFAULT '0'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('setup', 'config_cache', 'Cache-Einstellungen', 'Update-Interval des Caches usw. können Sie hier ändern.', 9)"; @@ -115,8 +115,8 @@ case "update": // Update an extension break; case "0.0.7": // SQL queries for v0.0.7 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD db_hits BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_hits BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD db_hits BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD cache_hits BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('stats', 'cache_stats', 'DB-Cache', 'Auf Cache und gesamte Datenbank registrierte Anfragen anzeigen.', 4)"; // Update notes (these will be set as task text!) diff --git a/inc/extensions/ext-country.php b/inc/extensions/ext-country.php index 0a28c5b1f5..10af68b4f7 100644 --- a/inc/extensions/ext-country.php +++ b/inc/extensions/ext-country.php @@ -53,7 +53,7 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // SQL commands to run $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_countries"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_countries ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, code CHAR(2) NOT NULL DEFAULT 'DE', descr VARCHAR(255) NOT NULL DEFAULT 'Deutschland', is_active ENUM('Y', 'N') NOT NULL DEFAULT 'N', @@ -67,7 +67,7 @@ PRIMARY KEY(id) $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('country', 'list_country', 'Verwalten', 'Hinzufügen, Ändern und Löschen von Ländercodes.', 1)"; // Add entry to user table - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD country_code BIGINT(20) NOT NULL DEFAULT '1'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD country_code BIGINT(20) UNSIGNED NOT NULL DEFAULT '1'"; break; case "remove": // Do stuff when removing extension diff --git a/inc/extensions/ext-doubler.php b/inc/extensions/ext-doubler.php index 0b3aff3158..afb8f39fcf 100644 --- a/inc/extensions/ext-doubler.php +++ b/inc/extensions/ext-doubler.php @@ -53,10 +53,10 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // Doubler table $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_doubler"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_doubler ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', -refid BIGINT(20) NOT NULL DEFAULT '0', -points DOUBLE(20,5) NOT NULL DEFAULT '0.00000', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +refid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000', remote_ip VARCHAR(15) NOT NULL DEFAULT '0.0.0.0', timemark VARCHAR(10) NOT NULL DEFAULT '', completed ENUM('Y', 'N') NOT NULL DEFAULT 'N', @@ -70,36 +70,36 @@ PRIMARY KEY(id) // --- SETTINGS --- // // Minimum points to double - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_min DOUBLE(20,5) NOT NULL DEFAULT '100.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_min DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '100.00000'"; // Maximum points to double - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_max DOUBLE(20,5) NOT NULL DEFAULT '10000.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_max DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '10000.00000'"; // Points left on users account after doubling - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_left BIGINT(20) NOT NULL DEFAULT '1000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_left BIGINT(20) UNSIGNED NOT NULL DEFAULT '1000'"; // Charge for doubling points which goes to the webmaster (shreddered in fact!) - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_charge FLOAT(7,3) NOT NULL DEFAULT '0.030'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_charge FLOAT(7,5) UNSIGNED NOT NULL DEFAULT '0.030'"; // Referral percents - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_ref FLOAT(7,3) NOT NULL DEFAULT '0.020'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_ref FLOAT(7,5) UNSIGNED NOT NULL DEFAULT '0.020'"; // Shall I use the jackpot to take points from? (Y/N, default=Y) $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_jackpot ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; // A user account to take points from (default: 0->none) - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_uid BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Total payed out points from your doublers - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_points DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; // Sending mode of mails (immediately/daily reset) // --> This also means who fast the doubled points will be payed out! $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_send_mode ENUM('DIRECT', 'RESET') NOT NULL DEFAULT 'DIRECT'"; // Timeout for entries to be purged (default: one week) - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_timeout BIGINT(20) NOT NULL DEFAULT '".(60*60*24*7)."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(60*60*24*7)."'"; // Number of newest entries to display - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_new TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_new TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; // Number of entries which will be payed out soon - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_pay TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_pay TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; // Number of entries which are already payed out - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_old TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_display_old TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; // Points used by every member - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD doubler_points DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD doubler_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; // Counter for usage of the doubler - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_counter BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_counter BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // // --- MENU SYSTEMS --- @@ -148,7 +148,7 @@ case "update": // Update an extension case "0.0.2": // SQL queries for v0.0.2 // Total used points - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_used DOUBLE(20,5) NOT NULL DEFAULT '0.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_used DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Gebühr wird vom Verdoppler-Pott abgezogen."; @@ -173,8 +173,8 @@ case "update": // Update an extension break; case "0.0.6": // SQL queries for v0.0.6 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_max_sent TINYINT(3) NOT NULL DEFAULT '1'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_group_sent TINYINT(3) NOT NULL DEFAULT '1'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_max_sent TINYINT(3) UNSIGNED NOT NULL DEFAULT '1'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_group_sent TINYINT(3) UNSIGNED NOT NULL DEFAULT '1'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD doubler_sent_all ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; // Update notes (these will be set as task text!) diff --git a/inc/extensions/ext-holiday.php b/inc/extensions/ext-holiday.php index e64a7576b1..9387596d95 100644 --- a/inc/extensions/ext-holiday.php +++ b/inc/extensions/ext-holiday.php @@ -53,8 +53,8 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // Create database $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_user_holidays"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_user_holidays ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', holiday_start VARCHAR(10) NOT NULL DEFAULT '0', holiday_end VARCHAR(10) NOT NULL DEFAULT '0', comments LONGBLOB NOT NULL, @@ -63,7 +63,7 @@ PRIMARY KEY(id) ) TYPE=MyISAM"; // Add default values to config - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD holiday_max BIGINT(20) NOT NULL DEFAULT '30'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD holiday_max BIGINT(20) UNSIGNED NOT NULL DEFAULT '30'"; // Add member menu $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, sort, visible, locked) VALUES ('main', 'holiday', 'Urlaubsschaltung', '4', 'Y', 'Y')"; @@ -158,7 +158,7 @@ case "update": // Update an extension case "0.1.3": // SQL queries for v0.1.3 $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD holiday_active ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_max_receive WHERE value='0' LIMIT 1"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD holiday_lock BIGINT(20) NOT NULL DEFAULT '".(60*60*24*2)."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD holiday_lock BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(60*60*24*2)."'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Die Mitglieder-Accounts werden nicht mehr gesperrt, sondern nur auf Urlaub geschaltet. Lassen Sie sich nicht davon verwirren, dass sie "freigegeben" sind!"; @@ -179,7 +179,7 @@ case "update": // Update an extension break; case "0.1.6": // SQL queries for v0.1.6 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD holiday_activated BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD holiday_activated BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Fehlende Tabellenspalte hinzugefügt."; diff --git a/inc/extensions/ext-html_mail.php b/inc/extensions/ext-html_mail.php index 821b0592eb..6ffd774e15 100644 --- a/inc/extensions/ext-html_mail.php +++ b/inc/extensions/ext-html_mail.php @@ -51,17 +51,17 @@ switch ($EXT_LOAD_MODE) { case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called) // SQL commands to run - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_data add html ENUM('Y','N') NOT NULL DEFAULT 'Y'"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_bonus add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_pool add html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD html ENUM('Y','N') NOT NULL DEFAULT 'Y'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_bonus ADD html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_pool ADD html_msg ENUM('Y','N') NOT NULL DEFAULT 'N'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, sort, visible, locked) VALUES ('main', 'html_mail', 'HTML-Empfang', '3', 'Y', 'Y')"; break; case "remove": // Do stuff when removing extension // SQL commands to run - $SQLs[] = "alter table "._MYSQL_PREFIX."_user_data drop html"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_bonus drop html_msg"; - $SQLs[] = "alter table "._MYSQL_PREFIX."_pool drop html_msg"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data DROP html"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_bonus DROP html_msg"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_pool DROP html_msg"; $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_member_menu WHERE action='main' AND what='html_mail' LIMIT 1"; break; diff --git a/inc/extensions/ext-maintenance.php b/inc/extensions/ext-maintenance.php index 835d898d57..c03dc6eb73 100644 --- a/inc/extensions/ext-maintenance.php +++ b/inc/extensions/ext-maintenance.php @@ -51,12 +51,8 @@ switch ($EXT_LOAD_MODE) { case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called) // SQL commands to run - $SQLs[] = "alter table "._MYSQL_PREFIX."_config add maintenance ENUM('Y', 'N') NOT NULL DEFAULT 'N';"; - if (SQL_NUMROWS(SQL_QUERY("SELECT id FROM "._MYSQL_PREFIX."_admin_menu WHERE what='maintenance' LIMIT 1", __FILE__, __LINE__)) == 0) - { - // Insert menu only when not exists - $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'maintenance', 'Wartungsmodus', 'Schalten Sie den Wartungsmodus ein, nur wenn sehr schwerwiegende Fehler vorliegen, die Sie oder mxchange.org nicht schenll genug beheben können.', '10')"; - } + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD maintenance ENUM('Y', 'N') NOT NULL DEFAULT 'N';"; + $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'maintenance', 'Wartungsmodus', 'Schalten Sie den Wartungsmodus ein, nur wenn sehr schwerwiegende Fehler vorliegen, die Sie oder mxchange.org nicht schenll genug beheben können.', '10')"; break; case "remove": // Do stuff when removing extension diff --git a/inc/extensions/ext-mediadata.php b/inc/extensions/ext-mediadata.php index efd1986f87..7c0aebd8bb 100644 --- a/inc/extensions/ext-mediadata.php +++ b/inc/extensions/ext-mediadata.php @@ -112,8 +112,8 @@ PRIMARY KEY(media_key) break; case "0.0.7": // SQL queries for v0.0.7 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mt_start BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mt_stage BIGINT(20) NOT NULL DEFAULT '500'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mt_start BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mt_stage BIGINT(20) UNSIGNED NOT NULL DEFAULT '500'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'config_mediadata', 'Mediendaten', 'Stellen Sie allgemeine Einstellungen zu den Mediendaten ein.', 10)"; // Update notes (these will be set as task text!) diff --git a/inc/extensions/ext-newsletter.php b/inc/extensions/ext-newsletter.php index 84dd50d1ed..f82a4989b6 100644 --- a/inc/extensions/ext-newsletter.php +++ b/inc/extensions/ext-newsletter.php @@ -79,7 +79,7 @@ case "update": // Update an extension $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('newsletter', 'config_newsletter', 'Einstellungen', 'Gebühr zum Abbestellen des Newsletters usw. sind hier einstellbar.', 3)"; $SQLs[] = "UPDATE "._MYSQL_PREFIX."_admin_menu SET action='newsletter', what='send_newsletter', title='Versenden', sort='1' WHERE what='newsletter' LIMIT 1"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, visible, locked, sort) VALUES ('main', 'newsletter', 'Newsletter-Empfang', 'N', 'Y', 10)"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nl_charge FLOAT(10,2) NOT NULL DEFAULT '5.00'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nl_charge FLOAT(10,2) UNSIGNED NOT NULL DEFAULT '5.00'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD nl_receive ENUM('Y', 'N') NOT NULL DEFAULT 'Y'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD nl_until VARCHAR(10) NOT NULL DEFAULT '0'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD nl_timespan VARCHAR(10) NOT NULL DEFAULT '0'"; diff --git a/inc/extensions/ext-nickname.php b/inc/extensions/ext-nickname.php index 9cd792f5b0..6a0dc98d9c 100644 --- a/inc/extensions/ext-nickname.php +++ b/inc/extensions/ext-nickname.php @@ -104,7 +104,7 @@ case "update": // Update an extension break; case "0.0.6": // SQL queries for v0.0.6 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nickname_len TINYINT(3) NOT NULL DEFAULT '5'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nickname_len TINYINT(3) UNSIGNED NOT NULL DEFAULT '5'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nickname_pattern VARCHAR(255) NOT NULL DEFAULT 'a-zA-Z0-9_'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD nickname_chars VARCHAR(255) NOT NULL DEFAULT 'a-z, A-Z, 0-9, _'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'config_nickname', 'Nicknamen', 'Stellen Sie minimale Nicknamenlänge, sowie erlaubte Zeichen hier ein.', 12)"; @@ -176,6 +176,18 @@ case "update": // Update an extension // Update notes (these will be set as task text!) $UPDATE_NOTES = "Fehlerhinweis bei deaktivierter Erweiterung verbessert."; break; + + case "0.1.9": // SQL queries for v0.1.9 + $SQLs[] = "DROP TABLE "._MYSQL_PREFIX."_nickname_history"; + $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_nickname_history ( +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, +PRIMARY KEY(id) +) TYPE=MyISAM COMMENT='History of used nicknames'"; + + // Update notes (these will be set as task text!) + $UPDATE_NOTES = "Historie eingegebener Nicknames hinzugefügt. Mitglied kann auf bereits verwendeter zurückgreifen und Liste selbst löschen."; + break; } break; diff --git a/inc/extensions/ext-online.php b/inc/extensions/ext-online.php index bb240f2a0e..b08ea40e94 100644 --- a/inc/extensions/ext-online.php +++ b/inc/extensions/ext-online.php @@ -53,11 +53,11 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // SQL commands to run $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_online"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_online ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, sid VARCHAR(32) NOT NULL DEFAULT '', ip VARCHAR(15) NOT NULL DEFAULT '', -userid BIGINT(20) NOT NULL DEFAULT '0', -refid BIGINT(20) NOT NULL DEFAULT '0', +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +refid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', module VARCHAR(255) NOT NULL DEFAULT '', action VARCHAR(255) NOT NULL DEFAULT '', what VARCHAR(255) NOT NULL DEFAULT '', diff --git a/inc/extensions/ext-optimize.php b/inc/extensions/ext-optimize.php index 3eca7ee90c..fe54048880 100644 --- a/inc/extensions/ext-optimize.php +++ b/inc/extensions/ext-optimize.php @@ -52,7 +52,7 @@ switch ($EXT_LOAD_MODE) case "register": // Do stuff when installtion is running (modules.php?module=admin&action=login is called) // SQL commands to run $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_optimize_gain( - id BIGINT(20) NOT NULL AUTO_INCREMENT, + id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, gain decimal(10,3) NOT NULL DEFAULT '0.000', PRIMARY KEY(id) ) TYPE=MyISAM"; diff --git a/inc/extensions/ext-order.php b/inc/extensions/ext-order.php index 4582e18254..077e192a30 100644 --- a/inc/extensions/ext-order.php +++ b/inc/extensions/ext-order.php @@ -85,7 +85,7 @@ case "update": // Update an extension case "0.1.1": // SQL queries for v0.1.1 $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE what='config_order' LIMIT 1"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, sort, descr) VALUES ('setup', 'config_order', 'Mailbuchungsseite', '7', 'Einstellungen am Mailbuchungsformular.')"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD mail_orders BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD mail_orders BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Maximale Mailbuchung vervollständigt (Admin-Bereich und im Buchungsformular selber)."; @@ -142,7 +142,7 @@ case "update": // Update an extension break; case "0.2.3": // SQL queries for v0.2.3 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD order_min BIGINT(20) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD order_min BIGINT(20) UNSIGNED NOT NULL DEFAULT '10'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Minimum an Empfänger pro Mailbuchung einstellbar. Standart: 10 Empfänger"; diff --git a/inc/extensions/ext-other.php b/inc/extensions/ext-other.php index 1ebdc23b2a..2b658190c8 100644 --- a/inc/extensions/ext-other.php +++ b/inc/extensions/ext-other.php @@ -88,7 +88,7 @@ case "update": // Update an extension break; case "0.0.4": // SQL queries for v0.0.4 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD max_comma TINYINT(3) NOT NULL DEFAULT '3'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD max_comma TINYINT(3) UNSIGNED NOT NULL DEFAULT '3'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Angezeigte Kommastellen können zwischen 0 und 5 eingestellt werden."; diff --git a/inc/extensions/ext-primera.php b/inc/extensions/ext-primera.php index cc860240fa..4995184559 100644 --- a/inc/extensions/ext-primera.php +++ b/inc/extensions/ext-primera.php @@ -66,8 +66,8 @@ PRIMARY KEY(id) ) TYPE=MyISAM"; // Confiuration - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_min_payout BIGINT(20) NOT NULL DEFAULT '40000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_min_withdraw BIGINT(20) NOT NULL DEFAULT '5000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_min_payout BIGINT(20) UNSIGNED NOT NULL DEFAULT '40000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_min_withdraw BIGINT(20) UNSIGNED NOT NULL DEFAULT '5000'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_api_name VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_api_md5 VARCHAR(32) NOT NULL DEFAULT ''"; diff --git a/inc/extensions/ext-rallye.php b/inc/extensions/ext-rallye.php index a398cc62d7..e5406153ff 100644 --- a/inc/extensions/ext-rallye.php +++ b/inc/extensions/ext-rallye.php @@ -55,8 +55,8 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_rallye_prices"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_rallye_users"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_rallye_data ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -admin_id BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +admin_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', title VARCHAR(255) NOT NULL DEFAULT '', descr LONGBLOB NOT NULL, template VARCHAR(255) NOT NULL DEFAULT '', @@ -70,19 +70,19 @@ KEY (admin_id), PRIMARY KEY (id) ) TYPE=MyISAM"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_rallye_prices ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -rallye_id BIGINT(20) NOT NULL DEFAULT '0', -price_level BIGINT(20) NOT NULL DEFAULT '0', -points BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +rallye_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +price_level BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', info LONGBLOB NOT NULL, KEY (rallye_id), PRIMARY KEY(id) ) TYPE=MyISAM"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_rallye_users ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -rallye_id BIGINT(20) NOT NULL DEFAULT '0', -userid BIGINT(20) NOT NULL DEFAULT '0', -refs BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +rallye_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +refs BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', KEY (rallye_id), KEY (userid), PRIMARY KEY(id) @@ -210,8 +210,8 @@ case "update": // Update an extension break; case "0.2.0": // SQL queries for v0.2.0 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_rallye_data ADD min_users BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_rallye_data ADD min_prices BIGINT(20) NOT NULL DEFAULT '3'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_rallye_data ADD min_users BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_rallye_data ADD min_prices BIGINT(20) UNSIGNED NOT NULL DEFAULT '3'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Ablaufen der Rallyes intergriert. Bauen Sie in Ihr Template templates/de/emails/member/member_rallye_notifty.tpl folgende zwei Zeilen ein:
diff --git a/inc/extensions/ext-sponsor.php b/inc/extensions/ext-sponsor.php index 3622ce3f86..75d85830b0 100644 --- a/inc/extensions/ext-sponsor.php +++ b/inc/extensions/ext-sponsor.php @@ -62,7 +62,7 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_data"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_data ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, company VARCHAR(255) NOT NULL DEFAULT '', position VARCHAR(255) NOT NULL DEFAULT '', tax_ident VARCHAR(255) NOT NULL DEFAULT '', @@ -86,13 +86,13 @@ last_online VARCHAR(10) NOT NULL DEFAULT '0', last_change VARCHAR(10) NOT NULL DEFAULT '0', status ENUM('UNCONFIRMED', 'PENDING', 'CONFIRMED', 'LOCKED') NOT NULL DEFAULT 'UNCONFIRMED', receive_warnings ENUM('Y', 'N') NOT NULL DEFAULT 'Y', -warning_interval BIGINT(20) NOT NULL DEFAULT '".(ONE_DAY*7)."', -points_amount DOUBLE(20,5) NOT NULL DEFAULT '0.00000', -points_used DOUBLE(20,5) NOT NULL DEFAULT '0.00000', -refid BIGINT(20) NOT NULL DEFAULT '0', -ref_count BIGINT(20) NOT NULL DEFAULT '0', +warning_interval BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(ONE_DAY*7)."', +points_amount DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000', +points_used DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000', +refid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +ref_count BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', hash VARCHAR(32) NOT NULL DEFAULT '', -last_pay FLOAT(7,2) NOT NULL DEFAULT '0.00', +last_pay FLOAT(7,2) UNSIGNED NOT NULL DEFAULT '0.00', last_curr VARCHAR(255) NOT NULL DEFAULT '€', KEY(refid), KEY(email), @@ -103,12 +103,12 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_orders"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_orders ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -sponsorid BIGINT(20) NOT NULL DEFAULT '0', -aid BIGINT(20) NOT NULL DEFAULT '0', -regid BIGINT(20) NOT NULL DEFAULT '0', -payid BIGINT(20) NOT NULL DEFAULT '0', -pay_count BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +sponsorid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +aid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +regid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +payid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +pay_count BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', pay_status ENUM('PENDING', 'PAYED', 'UNPAYED', 'DELETED') NOT NULL DEFAULT 'PENDING', pay_ordered VARCHAR(10) NOT NULL DEFAULT '0', pay_done VARCHAR(10) NOT NULL DEFAULT '0', @@ -123,10 +123,10 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_paytypes"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_paytypes ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, pay_name VARCHAR(255) NOT NULL DEFAULT '', -pay_rate DOUBLE(20,5) NOT NULL DEFAULT '0.00000', -pay_min_count BIGINT(20) NOT NULL DEFAULT '1', +pay_rate DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000', +pay_min_count BIGINT(20) UNSIGNED NOT NULL DEFAULT '1', pay_currency VARCHAR(255) NOT NULL DEFAULT '€', PRIMARY KEY(id) )TYPE=MyISAM"; @@ -135,9 +135,9 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_action_convert"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_action_convert ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, ext_name VARCHAR(255) NOT NULL DEFAULT 'sponsor', -conv_rate BIGINT(20) NOT NULL DEFAULT '0', +conv_rate BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', conv_name VARCHAR(255) NOT NULL DEFAULT 'Mails', KEY (ext_name), PRIMARY KEY(id) @@ -147,12 +147,12 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_menu"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_menu ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, action VARCHAR(255) NOT NULL DEFAULT '', what VARCHAR(255) NOT NULL DEFAULT '', title VARCHAR(255) NOT NULL DEFAULT '', active ENUM('Y', 'N') NOT NULL DEFAULT 'N', -sort BIGINT(20) NOT NULL DEFAULT '0', +sort BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', KEY(what), KEY(action), PRIMARY KEY(id) @@ -162,8 +162,8 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_registry"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_registry ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -aid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +aid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', ext_name VARCHAR(255) NOT NULL DEFAULT 'sponsor', is_active ENUM('Y', 'N') NOT NULL DEFAULT 'N', stamp_added VARCHAR(10) NOT NULL DEFAULT '0', @@ -176,11 +176,11 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_urls"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_urls ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -sponsorid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +sponsorid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', url VARCHAR(255) NOT NULL DEFAULT 'http://', title VARCHAR(255) NOT NULL DEFAULT '', -clicks BIGINT(20) NOT NULL DEFAULT '0', +clicks BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', status ENUM('PENDING', 'ACTIVE', 'LOCKED') NOT NULL DEFAULT 'PENDING', KEY(sponsorid), PRIMARY KEY(id) @@ -190,13 +190,13 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_banner"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_banner ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -sponsorid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +sponsorid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', url VARCHAR(255) NOT NULL DEFAULT 'http://', alternate VARCHAR(255) NOT NULL DEFAULT '', width INT(7) NOT NULL DEFAULT '468', height INT(7) NOT NULL DEFAULT '60', -views BIGINT(20) NOT NULL DEFAULT '0', +views BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', status ENUM('PENDING', 'ACTIVE', 'LOCKED') NOT NULL DEFAULT 'PENDING', KEY(sponsorid), PRIMARY KEY(id) @@ -206,13 +206,13 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_campaigns"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_campaigns ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -sponsorid BIGINT(20) NOT NULL DEFAULT '0', -aid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +sponsorid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +aid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', campaign_name VARCHAR(255) NOT NULL DEFAULT '', campaign_start VARCHAR(10) NOT NULL DEFAULT '0', campaign_end VARCHAR(10) NOT NULL DEFAULT '0', -campaign_amount DOUBLE(20,5) NOT NULL DEFAULT '0.00000', +campaign_amount DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '0.00000', campaign_expired ENUM('Y', 'N') NOT NULL DEFAULT 'N', campaign_locked ENUM('Y', 'N') NOT NULL DEFAULT 'Y', campaign_ended VARCHAR(10) NOT NULL DEFAULT '0', @@ -228,12 +228,12 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_campaign_assigns"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_campaign_assigns ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -campaignid BIGINT(20) NOT NULL DEFAULT '0', -urlid BIGINT(20) NOT NULL DEFAULT '0', -bannerid BIGINT(20) NOT NULL DEFAULT '0', -clicks BIGINT(20) NOT NULL DEFAULT '0', -views BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +campaignid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +urlid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +bannerid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +clicks BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +views BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', KEY(bannerid), KEY(urlid), KEY(campaignid), @@ -244,7 +244,7 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_admin_data"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_admin_data ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, data_row VARCHAR(255) NOT NULL DEFAULT '', display ENUM('Y', 'N') NOT NULL DEFAULT 'N', PRIMARY KEY(id) @@ -254,8 +254,8 @@ PRIMARY KEY(id) // $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_sponsor_display_data"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_sponsor_display_data ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -sponsorid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +sponsorid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', data_row VARCHAR(255) NOT NULL DEFAULT '', display ENUM('Y', 'N') NOT NULL DEFAULT 'N', KEY(sponsorid), @@ -366,8 +366,8 @@ PRIMARY KEY(id) // // General configuration stuff // - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD sponsor_ref_points DOUBLE(20,5) NOT NULL DEFAULT '100.00000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD sponsor_min_points DOUBLE(20,5) NOT NULL DEFAULT '1000.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD sponsor_ref_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '100.00000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD sponsor_min_points DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT '1000.00000'"; // Load CSS file $EXT_CSS = "Y"; diff --git a/inc/extensions/ext-sql_patches.php b/inc/extensions/ext-sql_patches.php index e7821b3026..c387d98aa6 100644 --- a/inc/extensions/ext-sql_patches.php +++ b/inc/extensions/ext-sql_patches.php @@ -109,7 +109,7 @@ case "update": // Update an extension break; case "0.0.2": // SQL queries for v0.0.2 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config CHANGE auto_purge auto_purge BIGINT(20) NOT NULL DEFAULT '1209600'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config CHANGE auto_purge auto_purge BIGINT(20) UNSIGNED NOT NULL DEFAULT '1209600'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "In der Tabelle mxchange_config musste die Spalte auto_purge (autom. Löschen von Bestätigungsmails angepasst werden (war auf dem Testsystem auf tiny(4) gesetzt.)"; @@ -123,7 +123,7 @@ case "update": // Update an extension break; case "0.0.4": // SQL queries for v0.0.4 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mails_page BIGINT(20) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD mails_page BIGINT(20) UNSIGNED NOT NULL DEFAULT '10'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Anzahl Mails pro Seite in EMail-Details ansehen und EMail-Archiv hinzugefügt."; @@ -174,8 +174,8 @@ case "update": // Update an extension case "0.1.1": // SQL queries for v0.1.1 $SQLs[] = "UPDATE "._MYSQL_PREFIX."_admin_menu SET title='Home-/Eingangsseite', descr='Stellen Sie hier ein, welcher Menüpunkt (what-welcome ist Standart) als Einstiegspunkt in das Menüsystem genutzt werden soll und wie die automatische Weiterleitung in der Eingangsseite funktionieren soll.' WHERE what='config_home' LIMIT 1"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD index_delay TINYINT(3) NOT NULL DEFAULT '-1'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD index_cookie BIGINT(20) NOT NULL DEFAULT '31536000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD index_delay TINYINT(3) UNSIGNED NOT NULL DEFAULT '-1'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD index_cookie BIGINT(20) UNSIGNED NOT NULL DEFAULT '31536000'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Sie können nun hier die Verzögerungszeit in der Eingangsseite einstellen."; @@ -183,7 +183,7 @@ case "update": // Update an extension case "0.1.2": // SQL queries for v0.1.2 $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('setup', 'config_refid', 'Standart-Ref-ID', 'Stellen Sie hier die User-ID ein, die genommen werden soll, wenn der Gast n icht per Referral-Link Ihren Mailtausch aufgerufen hat.', 7)"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD def_refid BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD def_refid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Standart Referral-ID kann per Admin-Bereich eingestellt werden (war vorher nur in modules.php und index.php direkt eingebbar.)"; @@ -206,7 +206,7 @@ case "update": // Update an extension $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, sort, visible, locked) VALUES ('themes', NULL, 'Design-Auswahl', 3, 'Y', 'N')"; $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_themes"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_themes ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, theme_path VARCHAR(255) NOT NULL DEFAULT '', theme_active ENUM('Y', 'N') NOT NULL DEFAULT 'N', theme_ver VARCHAR(255) NOT NULL DEFAULT '0.0', @@ -300,8 +300,8 @@ PRIMARY KEY(id) break; case "0.2.5": // SQL queries for v0.2.5 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data CHANGE receive_mails receive_mails BIGINT(20) NOT NULL DEFAULT '0'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data CHANGE max_mails max_mails BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data CHANGE receive_mails receive_mails BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data CHANGE max_mails max_mails BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Spalten max_mails und receive_mails auf BIGINT(20) gesetzt."; @@ -317,7 +317,7 @@ PRIMARY KEY(id) case "0.2.7": // SQL queries for v0.2.7 $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, sort) VALUES ('main', 'themes', 'Designs', 6)"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD curr_theme VARCHAR(255) NOT NULL DEFAULT 'default'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD stats_limit BIGINT(20) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD stats_limit BIGINT(20) UNSIGNED NOT NULL DEFAULT '10'"; $SQLs[] = "UPDATE "._MYSQL_PREFIX."_admin_menu SET what='config_stats' WHERE what='stats' LIMIT 1"; // Update notes (these will be set as task text!) @@ -394,7 +394,7 @@ PRIMARY KEY(id) // Connection table between the menu system and the "logical area" system $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_admin_menu_las"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_admin_menu_las ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, la_id VARCHAR(255) NOT NULL DEFAULT '', la_action VARCHAR(255) NOT NULL DEFAULT '', la_what VARCHAR(255) NOT NULL DEFAULT '', @@ -406,11 +406,11 @@ PRIMARY KEY(id) // All "logical areas" together $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_admin_menu_las_data"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_admin_menu_las_data ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, la_id VARCHAR(255) NOT NULL DEFAULT '', la_title VARCHAR(255) NOT NULL DEFAULT '', -la_posx BIGINT(20) NOT NULL DEFAULT '0', -la_posy BIGINT(20) NOT NULL DEFAULT '0', +la_posx BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +la_posy BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', UNIQUE KEY (la_id), INDEX (la_posx), INDEX (la_posy), @@ -433,10 +433,10 @@ PRIMARY KEY(id) // The statistics table $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_admin_menu_stats"; $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_admin_menu_stats ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -aid BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +aid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', type ENUM('la', 'action', 'what') NOT NULL DEFAULT 'what', -clicks BIGINT(20) NOT NULL DEFAULT '0', +clicks BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', INDEX (aid), PRIMARY KEY (id) ) TYPE=MyISAM"; @@ -470,12 +470,12 @@ PRIMARY KEY (id) break; case "0.3.6": // SQL queries for v0.3.6 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD salt_length TINYINT(3) NOT NULL DEFAULT '9'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD salt_length TINYINT(3) UNSIGNED NOT NULL DEFAULT '9'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD pass_scramble VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data MODIFY password VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data MODIFY user_hash VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_admins MODIFY password VARCHAR(255) NOT NULL DEFAULT ''"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD rand_no BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD rand_no BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD file_hash VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD master_salt VARCHAR(255) NOT NULL DEFAULT ''"; $SQLs[] = "UPDATE "._MYSQL_PREFIX."_config SET rand_no=(ROUND(RAND() * 99999) + 100000) WHERE config=0 LIMIT 1"; diff --git a/inc/extensions/ext-surfbar.php b/inc/extensions/ext-surfbar.php index 4550e539ac..6151ba4a98 100644 --- a/inc/extensions/ext-surfbar.php +++ b/inc/extensions/ext-surfbar.php @@ -70,7 +70,7 @@ UNIQUE KEY `userid_url` (`userid`, `url`) // Reload locks $SQLs[] = "DROP TABLE IF EXISTS `"._MYSQL_PREFIX."_surfbar_locks`"; $SQLs[] = "CREATE TABLE `"._MYSQL_PREFIX."_surfbar_locks` ( -`id` BIGINT(20) NOT NULL AUTO_INCREMENT, +`id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', `url_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', `last_surfed` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, @@ -82,7 +82,7 @@ INDEX (`url_id`) // Surfbar salts $SQLs[] = "DROP TABLE IF EXISTS `"._MYSQL_PREFIX."_surfbar_salts`"; $SQLs[] = "CREATE TABLE `"._MYSQL_PREFIX."_surfbar_salts` ( -`id` BIGINT(20) NOT NULL AUTO_INCREMENT, +`id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', `url_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', `last_salt` VARCHAR(255) NOT NULL DEFAULT '', diff --git a/inc/extensions/ext-top10.php b/inc/extensions/ext-top10.php index e21a58a082..c764d09346 100644 --- a/inc/extensions/ext-top10.php +++ b/inc/extensions/ext-top10.php @@ -53,7 +53,7 @@ case "register": // Do stuff when installtion is running (modules.php?module=adm // SQL commands to run $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_guest_menu (action, what, title, visible, locked, sort) VALUES ('main', 'top10', 'TOP-10', 'Y', 'Y', 7)"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES ('setup', 'config_top10', 'TOP-10 Listen', 'Stellen Sie hier ein, wie lang die TOP-Listen sein sollen, also wie viele Plätze angezeigt werden sollen.', 8)"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD top10_max TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD top10_max TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; // Load CSS file? $EXT_CSS = "Y"; diff --git a/inc/extensions/ext-transfer.php b/inc/extensions/ext-transfer.php index 7431b2166e..3d7905dfdf 100644 --- a/inc/extensions/ext-transfer.php +++ b/inc/extensions/ext-transfer.php @@ -56,10 +56,10 @@ case "register": // Do stuff when installtion is running // Transfer from a member $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_user_transfers_in ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', -from_uid BIGINT(20) NOT NULL DEFAULT '0', -points BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +from_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', reason VARCHAR(255) NOT NULL DEFAULT '', time_trans VARCHAR(14) NOT NULL DEFAULT '0', trans_id VARCHAR(12) NOT NULL DEFAULT '', @@ -70,10 +70,10 @@ PRIMARY KEY(id) // Transfers to a member $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_user_transfers_out ( -id BIGINT(20) NOT NULL AUTO_INCREMENT, -userid BIGINT(20) NOT NULL DEFAULT '0', -to_uid BIGINT(20) NOT NULL DEFAULT '0', -points BIGINT(20) NOT NULL DEFAULT '0', +id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, +userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +to_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', reason VARCHAR(255) NOT NULL DEFAULT '', time_trans VARCHAR(14) NOT NULL DEFAULT '0', trans_id VARCHAR(12) NOT NULL DEFAULT '', @@ -92,11 +92,11 @@ PRIMARY KEY(id) $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, visible, locked, sort) VALUES ('main', 'transfer', '{!POINTS!}-Transfer', 'Y', 'Y', 5)"; // Add config values - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_max BIGINT(20) NOT NULL DEFAULT '50'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_age BIGINT(20) NOT NULL DEFAULT '".(ONE_DAY*28)."'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_timeout BIGINT(20) NOT NULL DEFAULT '".ONE_DAY."'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_balance BIGINT(20) NOT NULL DEFAULT '100'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_code BIGINT(20) NOT NULL DEFAULT '5'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_max BIGINT(20) UNSIGNED NOT NULL DEFAULT '50'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_age BIGINT(20) UNSIGNED NOT NULL DEFAULT '".(ONE_DAY*28)."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_timeout BIGINT(20) UNSIGNED NOT NULL DEFAULT '".ONE_DAY."'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_balance BIGINT(20) UNSIGNED NOT NULL DEFAULT '100'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD transfer_code BIGINT(20) UNSIGNED NOT NULL DEFAULT '5'"; // Add row(s) to user's data $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD opt_in ENUM('Y', 'N') NOT NULL DEFAULT 'N'"; diff --git a/inc/extensions/ext-user.php b/inc/extensions/ext-user.php index b93a2731eb..c10a34665a 100644 --- a/inc/extensions/ext-user.php +++ b/inc/extensions/ext-user.php @@ -89,7 +89,7 @@ case "update": // Update an extension $UPDATE_NOTES = "CSS-Datei kann per Admin-Bereich ein- und ausgeschaltet werden."; case "0.1.2": // SQL queries for v0.1.2 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD mails_confirmed BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD mails_confirmed BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Dem Mitglied wird nun angezeigt, wie viele Mails er bestätigt hat. Alle vor dieser Version best. Mails werden leider nicht mehr berücksichtigt! Bitte teilen Sie dies Ihren Mitgliedern mit."; @@ -101,7 +101,7 @@ case "update": // Update an extension break; case "0.1.4": // SQL queries for v0.1.4 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD emails_received BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD emails_received BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; // Update notes (these will be set as task text!) $UPDATE_NOTES = "Anzahl empfangener Mails wird angezeigt. Diese Anzeige kann fehlerhaft sein, wenn Sie bereits Mitglieder in Ihrem {!MT_WORD!} haben sollen!"; @@ -138,7 +138,7 @@ case "update": // Update an extension break; case "0.2.1": // SQL queries for v0.2.1 - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD user_alpha TINYINT(3) NOT NULL DEFAULT '10'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD user_alpha TINYINT(3) UNSIGNED NOT NULL DEFAULT '10'"; $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('setup', 'config_user', 'Mitgliederliste', 'Anzahl Mitglieder pro Seite, Anzahl Buchstaben pro Zeile usw.', 8)"; // Update notes (these will be set as task text!) diff --git a/inc/extensions/ext-wernis.php b/inc/extensions/ext-wernis.php index bc2c925691..24634ea2c2 100644 --- a/inc/extensions/ext-wernis.php +++ b/inc/extensions/ext-wernis.php @@ -39,13 +39,13 @@ if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) } // Version of this extension -$EXT_VERSION = "0.0"; +$EXT_VERSION = "0.0.1"; // Auto-set extension version if (empty($EXT_VER)) $EXT_VER = $EXT_VERSION; // Version history array (add more with , "0.1" and so on) -$EXT_VER_HISTORY = array("0.0"); +$EXT_VER_HISTORY = array("0.0", "0.0.1"); switch ($EXT_LOAD_MODE) { @@ -66,9 +66,9 @@ PRIMARY KEY(id) ) TYPE=MyISAM"; // Confiuration - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_min_payout BIGINT(20) NOT NULL DEFAULT '40000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_min_withdraw BIGINT(20) NOT NULL DEFAULT '5000'"; - $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_api_id BIGINT(20) NOT NULL DEFAULT '0'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_min_payout BIGINT(20) UNSIGNED NOT NULL DEFAULT '40000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_min_withdraw BIGINT(20) UNSIGNED NOT NULL DEFAULT '5000'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_api_id BIGINT(20) UNSIGNED NOT NULL DEFAULT '0'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_api_md5 VARCHAR(32) NOT NULL DEFAULT ''"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_api_url VARCHAR(255) NOT NULL DEFAULT 'http://www.wds66.com/api/'"; $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_refid VARCHAR(6) NOT NULL DEFAULT ''"; @@ -110,8 +110,17 @@ case "update": // Update an extension switch ($EXT_VER) { case "0.0.1": // SQL queries for v0.0.1 + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_payout_active ENUM ('Y', 'N') NOT NULL DEFAULT 'Y'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_withdraw_active ENUM ('Y', 'N') NOT NULL DEFAULT 'Y'"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_payout_factor DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT 1.00000"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_withdraw_factor DOUBLE(20,5) UNSIGNED NOT NULL DEFAULT 1.00000"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_payout_fee_percent FLOAT(8,5) UNSIGNED NOT NULL DEFAULT 0.00000"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_withdraw_fee_percent FLOAT(8,5) UNSIGNED NOT NULL DEFAULT 0.00000"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_payout_fee_fix BIGINT(20) UNSIGNED NOT NULL DEFAULT 0"; + $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD wernis_withdraw_fee_fix BIGINT(20) UNSIGNED NOT NULL DEFAULT 0"; + // Update notes (these will be set as task text!) - $UPDATE_NOTES = ""; + $UPDATE_NOTES = "Ein-/Auszahlungsfunktion getrennt ein- und ausschaltbar, sowie mit Umrechungsfaktoren {!POINTS!}->Wernis versehen. Prozentualer Abzug als "Betreibergebühr hinzugefügt, was z.B. für Wechselstuben interessant ist."; break; } break; diff --git a/inc/functions.php b/inc/functions.php index 59e8c8c4a9..cc64df1b28 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -2420,7 +2420,26 @@ function CONVERT_SELECTIONS_TO_TIMESTAMP(&$POST, &$DATA, &$id, &$skip) { } // Reverts the german decimal comma into Computer decimal dot function REVERT_COMMA ($str) { - $float = (float)str_replace(",", ".", $str); + // Default float is not a float... ;-) + $float = false; + + // Which language is selected? + switch (GET_LANGUAGE()) { + case "de": // German language + // Remove german thousand dots first + $str = str_replace(".", "", $str); + + // Replace german commata with decimal dot and cast it + $float = (float)str_replace(",", ".", $str); + break; + + default: // US and so on + // Remove thousand dots first and cast + $float = (float)str_replace(",", "", $str); + break; + } + + // Return float return $float; } // diff --git a/inc/language/wernis_de.php b/inc/language/wernis_de.php index 7be49074c6..df862d63d1 100644 --- a/inc/language/wernis_de.php +++ b/inc/language/wernis_de.php @@ -40,6 +40,18 @@ if (basename($_SERVER['PHP_SELF']) == basename(__FILE__)) { // Language definitions define('TASK_ADMIN_LIST_WERNIS_ALL', "Alle Wernis-Ein-/Auszahlungen"); define('TASK_ADMIN_LIST_WERNIS_ALL_TITLE', "Listet alle Wernis-Ein- und Auszahlungen auf."); +define('MEMBER_WERNIS_MODE_WITHDRAW', "Wernis einzahlen"); +define('MEMBER_WERNIS_MODE_PAYOUT', "Wernis auszahlen"); +define('WERNIS_STATUS_UNKNWOWN', "Wernis-Typ %s unbekannt."); +define('WERNIS_STATUS_WITHDRAW', "Einzahlung von WDS66"); +define('WERNIS_STATUS_PAYOUT', "Auszahlung an WDS66"); +define('WERNIS_STATUS_FAILED', "Fehlgeschlagen"); +define('WERNIS_TIMESTAMP', "Buchungszeitmarke"); +define('WERNIS_ACCOUNT', "WDS66-Hauptaccount"); +define('WERNIS_TOTAL_WERNIS', "Gesamt überwiesen"); +define('WERNIS_MEMBER_LIST_WERNIS', "Überweisungsliste von/an WDS66-Hauptaccount"); + +// Admin messages define('WERNIS_ADMIN_CONFIG_TITLE', "Einstellungen zum WDS66-Hauptaccount:"); define('WERNIS_ADMIN_MIN_PAYOUT', "Minimumguthaben für Auszahlungen."); define('WERNIS_ADMIN_MIN_WITHDRAW', "Minimumguthaben für Einzahlungen."); @@ -47,7 +59,7 @@ define('WERNIS_ADMIN_API_ID', "WDS66-API-ID (api_id=x)"); define('WERNIS_ADMIN_API_MD5', "WDS66-API-Key (api_md5=xxxxx; 32-stellig)"); define('WERNIS_ADMIN_API_URL', "Basis-URL der API-Skripte"); define('WERNIS_ADMIN_REFID', "Ihre Referral-ID bei WDS66-Portal (= Ihr Username!)"); -define('WERNIS_ADMIN_CONFIG_NOTE', "Hier können Sie schon für 5,00€=25.000 Abfragen ein API-Account beantragen (dazu ist ein kostenloses Wernis-Account dennoch nötig!) Geben Sie immer Ihren Usernamen von WDS66-Hauptaccount ein und überprüfen Sie diesen mehrmals! Er wird zum Überweisen von Wernis/Wernis benötigt."); +define('WERNIS_ADMIN_CONFIG_NOTE', "Hier können Sie schon für 5,00€=25.000 Abfragen ein API-Account beantragen (dazu ist ein kostenloses Wernis-Account dennoch nötig!) Geben Sie immer Ihren Usernamen von WDS66-Hauptaccount ein und überprüfen Sie diesen mehrmals! Er wird zum Überweisen von und nach WDS66-Wernis-Portal benötigt. Die Betreibergebühren und Umrechnungsfaktoren sind für den Betrieb Ihres {!MT_WORD2!} komplett in Wernis ausgelegt, diese müssen Sie also noch anpassen, wenn Sie z.B. Punkte haben und in Wernis auszahlen lassen wollen."); define('WERNIS_ADMIN_NO_TRANSFERS', "Derzeit keine Wernis transferiert!"); define('WERNIS_ADMIN_WDS66_ACCOUNT', "Account bei WDS66-Portal"); define('WERNIS_ADMIN_TRANSFERED', "Wernis transferiert"); @@ -55,16 +67,14 @@ define('WERNIS_ADMIN_TIMESTAMP', "Zeitpunkt Überweisung"); define('WERNIS_ADMIN_TYPE', "Überweisungsrichtung"); define('WERNIS_ADMIN_API_MESSAGE', "Nachricht von WDS66-API"); define('WERNIS_ADMIN_API_STATUS', "Status von WDS66-API"); -define('MEMBER_WERNIS_MODE_WITHDRAW', "Wernis einzahlen"); -define('MEMBER_WERNIS_MODE_PAYOUT', "Wernis auszahlen"); -define('WERNIS_STATUS_UNKNWOWN', "Wernis-Typ %s unbekannt."); -define('WERNIS_STATUS_WITHDRAW', "Einzahlung von WDS66"); -define('WERNIS_STATUS_PAYOUT', "Auszahlung an WDS66"); -define('WERNIS_STATUS_FAILED', "Fehlgeschlagen"); -define('WERNIS_TIMESTAMP', "Buchungszeitmarke"); -define('WERNIS_ACCOUNT', "WDS66-Hauptaccount"); -define('WERNIS_TOTAL_WERNIS', "Gesamt überwiesen"); -define('WERNIS_MEMBER_LIST_WERNIS', "Überweisungsliste von/an WDS66-Hauptaccount"); +define('WERNIS_ADMIN_PAYOUT_ACTIVE', "Auszahlungen zum WDS66-Portal aktiviert?"); +define('WERNIS_ADMIN_WITHDRAW_ACTIVE', "Einzahlungen vom WDS66-Portal aktiviert?"); +define('WERNIS_ADMIN_PAYOUT_FACTOR', "Umrechnungsfaktor von {!POINTS!} in Wernis für Auszahlungen"); +define('WERNIS_ADMIN_WITHDRAW_FACTOR', "Umrechnungsfaktor von Wernis in {!POINTS!} für Einzahlungen"); +define('WERNIS_ADMIN_PAYOUT_FEE_PERCENT', "Prozentuale Betreibergebühr für Auszahlungen"); +define('WERNIS_ADMIN_WITHDRAW_FEE_PERCENT', "Prozentuale Betreibergebühr für Einzahlungen"); +define('WERNIS_ADMIN_PAYOUT_FEE_FIX', "Fixe Betreibergebühr für Auszahlungen"); +define('WERNIS_ADMIN_WITHDRAW_FEE_FIX', "Fixe Betreibergebühr für Einzahlungen"); // API messages define('WERNIS_API_REQUEST_DATA_INVALID', "Interner Fehler: Abfragedaten sind defekt!"); @@ -84,9 +94,11 @@ define('WERNIS_ERROR_STATUS', "Fehler-Status %s erhalten."); define('WERNIS_UNKNOWN_ERROR', "Unbekannter Fehler aufgetreten!"); // Member messages +define('MEMBER_WERNIS_MODE_CHOOSE', "Möchten Sie Wernis zu Ihrem WDS66-Hauptaccount ausbezahlt bekommen oder Wernis hier einzahlen?"); +define('MEMBER_WERNIS_MODE_CHOOSE2', "Hier klicken um neue Überweisung zu starten..."); define('WERNIS_MEMBER_NO_ACCOUNT', "Noch kein WDS66-Account? Hier entlang!"); define('WERNIS_MEMBER_API_DATA_MISSING', "Diese Funktion kann derzeit nicht genutzt werden, da wir sie noch einrichten müssen."); -define('WERNIS_MEMBER_MIN_PAYOUT_PAYOUT', "Sie haben nicht genügend Wernis zum Auszahlen! Mindestens: %s Wernis."); +define('WERNIS_MEMBER_MIN_PAYOUT', "Sie haben nicht genügend Wernis zum Auszahlen! Mindestens: %s Wernis."); define('WERNIS_MEMBER_WITHDRAW_TITLE', "Wernis bei {!MAIN_TITLE!} einzahlen:"); define('WERNIS_MEMBER_WITHDRAW_POINTS_ACCOUNT', "Wernis hier im Account:"); define('WERNIS_MEMBER_WITHDRAW_MIN_POINTS', "Mindest einzuzahlendes Wernis-Guthaben:"); @@ -112,6 +124,8 @@ define('WERNIS_MEMBER_WITHDRAW_DONE', "Einzahlung auf Ihr {!MAIN_TITLE!} Konto e define('WERNIS_MEMBER_PAYOUT_DONE', "Auszahlung auf WDS66-Hauptaccount erfolgreich abgeschlossen. :-)"); define('WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED', "Sie können nicht %s Wernis auszahlen, da Sie nur %s übrig haben."); define('WERNIS_MEMBER_STATUS', "Überweisungsart"); +define('WERNIS_MEMBER_PAYOUT_DISABLED', "Auszahlung wurde administrativ deaktiviert."); +define('WERNIS_MEMBER_WITHDRAW_DISABLED', "Einzahlung wurde administrativ deaktiviert."); // ?> diff --git a/inc/libs/sponsor_functions.php b/inc/libs/sponsor_functions.php index 7bc398f5b5..3b17afa3ff 100644 --- a/inc/libs/sponsor_functions.php +++ b/inc/libs/sponsor_functions.php @@ -420,7 +420,7 @@ ORDER BY sort", array($action), __FILE__, __LINE__); // function GENERATE_SPONSOR_CONTENT($what) { - global $HTTP_POST_VARS, $_GET, $CONFIG; + global $_CONFIG; $OUT = ""; $FILE = sprintf("%sinc/modules/sponsor/%s.php", PATH, $what); if (FILE_READABLE($FILE)) { @@ -437,14 +437,14 @@ function GENERATE_SPONSOR_CONTENT($what) // function UPDATE_SPONSOR_LOGIN() { - global $_COOKIE, $CONFIG; + global $_COOKIE, $_CONFIG; // Check if cookies are set if ((empty($_COOKIE['sponsorid'])) || (empty($_COOKIE['sponsorpass']))) return false; // Calculate cookie lifetime, maybe we have to change this so the admin can setup a // seperate timeout for these two cookies? - $life = (time() + $CONFIG['online_timeout']); + $life = (time() + $_CONFIG['online_timeout']); // Is confirmed so both is fine and we can continue with login procedure $login = ((setcookie("sponsorid" , bigintval($_COOKIE['sponsorid']), $life, COOKIE_PATH)) && diff --git a/inc/libs/wernis_functions.php b/inc/libs/wernis_functions.php index 6a3725ac02..64bcddf27d 100644 --- a/inc/libs/wernis_functions.php +++ b/inc/libs/wernis_functions.php @@ -95,7 +95,7 @@ function WERNIS_SEND_REQUEST ($scriptName, $requestData = array()) { // Add more request data $requestData['api_id'] = bigintval($_CONFIG['wernis_api_id']); - $requestData['api_key'] = $_CONFIG['wernis_api_key']; + $requestData['api_key'] = $_CONFIG['wernis_api_md5']; // Construct the request string $requestString = $_CONFIG['wernis_api_url'] . $scriptName; @@ -325,11 +325,86 @@ function WERNIS_TRANSFER_STATUS ($status) { return $return; } -function WERNIS_LOG_TRANSFER ($wdsId, $amount, $type = 'FAILED', $message = null, $status = null) { +// Log the transfer +function WERNIS_LOG_TRANSFER ($wdsId, $amount, $type = 'FAILED', $message = "", $status = "") { // Register this wernis movement $result = 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(%d, %d, %d, UNIX_TIMESTAMP(), '%s', '%s', '%s')", array($GLOBALS['userid'], bigintval($wdsId), bigintval($amount), $type, $message, $status), __FILE__, __LINE__); } +// Take fees and factor +function WERNIS_TAKE_FEE ($points, $mode) { + global $_CONFIG; + + // Payout or withdraw are allowed modes! + //* DEBUG: */ echo "mode={$mode},points={$points}
\n"; + if (!in_array($mode, array('payout', 'withdraw'))) { + // Log error and abort + DEBUG_LOG(__FUNCTION__.":uid={$GLOBALS['userid']},mode={$mode},points={$points}"); + return false; + } // END - if + + // Is there a percentage or fixed fee? + if ($_CONFIG['wernis_'.$mode.'_fee_percent'] > 0) { + // Percentage fee + $points -= $points * $_CONFIG['wernis_'.$mode.'_fee_percent'] / 100; + } elseif ($_CONFIG['wernis_'.$mode.'_fee_fix'] > 0) { + // Fixed fee + $points -= $_CONFIG['wernis_'.$mode.'_fee_fix']; + } + + // Divide/multiply the factor + if ($mode == "payout") { + // Divide for payout + $points = $points / $_CONFIG['wernis_payout_factor']; + } else { + // Multiply for withdraw + $points = $points * $_CONFIG['wernis_withdraw_factor']; + } + + // Return value + //* DEBUG: */ echo "mode={$mode},points={$points}
\n"; + return $points; +} + +// Add withdraw fees and factor +function WERNIS_ADD_WITHDRAW_FEE ($points) { + global $_CONFIG; + + // Is there a percentage or fixed fee? + if ($_CONFIG['wernis_withdraw_fee_percent'] > 0) { + // Percentage fee + $points += $points * $_CONFIG['wernis_withdraw_fee_percent'] / 100; + } elseif ($_CONFIG['wernis_withdraw_fee_fix'] > 0) { + // Fixed fee + $points += $_CONFIG['wernis_withdraw_fee_fix']; + } + + // Return value + return $points; +} + +// Add all fees to the array +function WERNIS_ADD_FEES_TO_ARRAY (&$array) { + global $_CONFIG; + + // Is the array an array? ;-) + if (!is_array($array)) { + // Log error and return + DEBUG_LOG(__FUNCTION__.": Type ".gettype($array)." != array."); + return; + } // END - if + + // Add both factors + $array['payout_factor'] = TRANSLATE_COMMA($_CONFIG['wernis_payout_factor']); + $array['withdraw_factor'] = TRANSLATE_COMMA($_CONFIG['wernis_withdraw_factor']); + + // Add all fees + $array['payout_fee_percent'] = TRANSLATE_COMMA($_CONFIG['wernis_payout_fee_percent']); + $array['withdraw_fee_percent'] = TRANSLATE_COMMA($_CONFIG['wernis_withdraw_fee_percent']); + $array['payout_fee_fix'] = TRANSLATE_COMMA($_CONFIG['wernis_payout_fee_fix']); + $array['withdraw_fee_fix'] = TRANSLATE_COMMA($_CONFIG['wernis_withdraw_fee_fix']); +} + // ?> diff --git a/inc/modules/admin/what-add_sponsor.php b/inc/modules/admin/what-add_sponsor.php index 2d056ebce7..08da77df9f 100644 --- a/inc/modules/admin/what-add_sponsor.php +++ b/inc/modules/admin/what-add_sponsor.php @@ -44,7 +44,7 @@ if (isset($_POST['ok'])) { SPONSOR_HANDLE_SPONSOR($_POST); } else { // Prepare constants for the template - define('__SPONSOR_MIN_VALUE', $CONFIG['sponsor_min_points']); + define('__SPONSOR_MIN_VALUE', $_CONFIG['sponsor_min_points']); // Output form LOAD_TEMPLATE("admin_add_sponsor"); diff --git a/inc/modules/admin/what-config_sponsor.php b/inc/modules/admin/what-config_sponsor.php index dc81d948a9..70a64890fc 100644 --- a/inc/modules/admin/what-config_sponsor.php +++ b/inc/modules/admin/what-config_sponsor.php @@ -48,8 +48,8 @@ if (isset($_POST['ok'])) { ADMIN_SAVE_SETTINGS($_POST); } else { // Remember config data in constants for the template - define('__SPONSOR_MIN_POINTS', $CONFIG['sponsor_min_points']); - define('__SPONSOR_REF_POINTS', $CONFIG['sponsor_ref_points']); + define('__SPONSOR_MIN_POINTS', $_CONFIG['sponsor_min_points']); + define('__SPONSOR_REF_POINTS', $_CONFIG['sponsor_ref_points']); // Load template LOAD_TEMPLATE("admin_config_sponsor"); diff --git a/inc/modules/admin/what-config_wernis.php b/inc/modules/admin/what-config_wernis.php index 9f1fa093f5..c5478c8ce7 100644 --- a/inc/modules/admin/what-config_wernis.php +++ b/inc/modules/admin/what-config_wernis.php @@ -46,6 +46,11 @@ if (isset($_POST['ok'])) { // Let's test the API first (hold your horses here, cowboy! Thanks. :) ) if (WERNIS_TEST_API()) { + // Revert german commata + foreach (array('payout_factor', 'withdraw_factor', 'payout_fee_percent', 'withdraw_fee_percent') as $revert) { + $_POST['wernis_'.$revert] = REVERT_COMMA($_POST['wernis_'.$revert]); + } // END - if + // Save settings ADMIN_SAVE_SETTINGS($_POST); } else { @@ -55,14 +60,42 @@ if (isset($_POST['ok'])) { } else { // Prepare data for template output $content = array( - 'min_payout' => bigintval($_CONFIG['wernis_min_payout']), - 'min_withdraw' => bigintval($_CONFIG['wernis_min_withdraw']), - 'api_id' => bigintval($_CONFIG['wernis_api_id']), - 'api_md5' => $_CONFIG['wernis_api_md5'], - 'api_url' => $_CONFIG['wernis_api_url'], - 'refid' => bigintval($_CONFIG['wernis_refid']) + 'min_payout' => bigintval($_CONFIG['wernis_min_payout']), + 'min_withdraw' => bigintval($_CONFIG['wernis_min_withdraw']), + 'api_id' => bigintval($_CONFIG['wernis_api_id']), + 'api_md5' => $_CONFIG['wernis_api_md5'], + 'api_url' => $_CONFIG['wernis_api_url'], + 'refid' => bigintval($_CONFIG['wernis_refid']), + 'payout_factor' => TRANSLATE_COMMA($_CONFIG['wernis_payout_factor']), + 'withdraw_factor' => TRANSLATE_COMMA($_CONFIG['wernis_withdraw_factor']), + 'payout_fee_percent' => TRANSLATE_COMMA($_CONFIG['wernis_payout_fee_percent']), + 'withdraw_fee_percent' => TRANSLATE_COMMA($_CONFIG['wernis_withdraw_fee_percent']), + 'payout_fee_fix' => bigintval($_CONFIG['wernis_payout_fee_fix']), + 'withdraw_fee_fix' => bigintval($_CONFIG['wernis_withdraw_fee_fix']) ); + // Prepare payout Y/N selection + if ($_CONFIG['wernis_payout_active'] == "Y") { + // Payout allowed + define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', " checked=\"checked\""); + define('__CFG_WERNIS_PAYOUT_ACTIVE_N', ""); + } else { + // Payout disabled + define('__CFG_WERNIS_PAYOUT_ACTIVE_Y', ""); + define('__CFG_WERNIS_PAYOUT_ACTIVE_N', " checked=\"checked\""); + } + + // Prepare withdraw Y/N selection + if ($_CONFIG['wernis_withdraw_active'] == "Y") { + // Payout allowed + define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', " checked=\"checked\""); + define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', ""); + } else { + // Payout disabled + define('__CFG_WERNIS_WITHDRAW_ACTIVE_Y', ""); + define('__CFG_WERNIS_WITHDRAW_ACTIVE_N', " checked=\"checked\""); + } + // Load template LOAD_TEMPLATE("admin_config_wernis", false, $content); } diff --git a/inc/modules/admin/what-unlock_sponsor.php b/inc/modules/admin/what-unlock_sponsor.php index c3894d99a6..a66577b270 100644 --- a/inc/modules/admin/what-unlock_sponsor.php +++ b/inc/modules/admin/what-unlock_sponsor.php @@ -109,7 +109,7 @@ WHERE id='%s' AND status='PENDING' LIMIT 1", $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_sponsor_data SET points_amount=points_amount+%s, ref_count=ref_count+1 WHERE id='%s' LIMIT 1", - array($CONFIG['sponsor_ref_points'], bigintval($refid)), __FILE__, __LINE__); + array($_CONFIG['sponsor_ref_points'], bigintval($refid)), __FILE__, __LINE__); // Whas that update fine? if (SQL_AFFECTEDROWS() == 1) { @@ -125,7 +125,7 @@ WHERE id='%s' LIMIT 1", if ($REFERRAL['receive_warnings'] == "Y") { // Translate some data $REFERRAL['points'] = TRANSLATE_COMMA($REFERRAL['points']); - $REFERRAL['ref_points'] = TRANSLATE_COMMA($CONFIG['sponsor_ref_points']); + $REFERRAL['ref_points'] = TRANSLATE_COMMA($_CONFIG['sponsor_ref_points']); $REFERRAL['gender'] = TRANSLATE_GENDER($REFERRAL['gender']); // Send notification to referral diff --git a/inc/modules/guest/what-sponsor_infos.php b/inc/modules/guest/what-sponsor_infos.php index 01a0f202b4..a47c9567da 100644 --- a/inc/modules/guest/what-sponsor_infos.php +++ b/inc/modules/guest/what-sponsor_infos.php @@ -92,7 +92,7 @@ if ($num_act > 0) if (!ereg(",", $content['price'])) { // Add missing zeros - $content['price'] .= ",".str_repeat("0", $CONFIG['max_comma']); + $content['price'] .= ",".str_repeat("0", $_CONFIG['max_comma']); } // Load row template and switch color diff --git a/inc/modules/guest/what-sponsor_login.php b/inc/modules/guest/what-sponsor_login.php index 6da3f8aa85..b70f75f38b 100644 --- a/inc/modules/guest/what-sponsor_login.php +++ b/inc/modules/guest/what-sponsor_login.php @@ -258,7 +258,7 @@ WHERE id='%s' AND password='%s' LIMIT 1", { // Calculate cookie lifetime, maybe we have to change this so the admin can setup a // seperate timeout for these two cookies? - $life = (time() + $CONFIG['online_timeout']); + $life = (time() + $_CONFIG['online_timeout']); // Is confirmed so both is fine and we can continue with login procedure $login = ((setcookie("sponsorid" , bigintval($_POST['sponsorid']), $life, COOKIE_PATH)) && diff --git a/inc/modules/guest/what-sponsor_reg.php b/inc/modules/guest/what-sponsor_reg.php index ec788933bf..e013faa9de 100644 --- a/inc/modules/guest/what-sponsor_reg.php +++ b/inc/modules/guest/what-sponsor_reg.php @@ -193,7 +193,7 @@ if (isset($_POST['ok'])) { } } // Is the password long enough? - elseif (strlen($_POST['pass1']) < $CONFIG['pass_len']) + elseif (strlen($_POST['pass1']) < $_CONFIG['pass_len']) { // Too short! $FORM_ERRORS[] = SPONSOR_PASSWORD_TOO_SHORT; diff --git a/inc/modules/member/what-transfer.php b/inc/modules/member/what-transfer.php index baa8aad018..59d36bc655 100644 --- a/inc/modules/member/what-transfer.php +++ b/inc/modules/member/what-transfer.php @@ -422,8 +422,8 @@ case "list_all": // List all transactions // First of all create the temporary table $result = SQL_QUERY("CREATE TEMPORARY TABLE "._MYSQL_PREFIX."_transfers_tmp ( trans_id VARCHAR(12) NOT NULL DEFAULT '', -party_uid BIGINT(20) NOT NULL DEFAULT '0', -points BIGINT(20) NOT NULL DEFAULT '0', +party_uid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', +points BIGINT(20) UNSIGNED NOT NULL DEFAULT '0', reason VARCHAR(255) NOT NULL DEFAULT '', time_trans VARCHAR(10) NOT NULL DEFAULT '0', trans_type ENUM('IN', 'OUT') NOT NULL DEFAULT 'IN', diff --git a/inc/modules/member/what-wernis.php b/inc/modules/member/what-wernis.php index 5edf6ac7a6..3c48c8640b 100644 --- a/inc/modules/member/what-wernis.php +++ b/inc/modules/member/what-wernis.php @@ -52,15 +52,16 @@ if ((empty($_CONFIG['wernis_api_id'])) || (empty($_CONFIG['wernis_api_md5']))) { // Something important is missing... LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_API_DATA_MISSING); return; -} +} // END - if // Init the content array and points $content = array(); $points = false; -// Is the mode set (payout only!) -if (!isset($_GET['mode'])) { - // Get referal id - $content['refid'] = bigintval($_CONFIG['wernis_refid']); +// Is the mode set (withdraw or payout) +if ((!isset($_GET['mode'])) || ($_GET['mode'] == "choose")) { + // Let the user choose what he wants to do + $content['refid'] = bigintval($_CONFIG['wernis_refid']); + $content['wds66_id'] = 0; // Get WDS66 id $result = SQL_QUERY_ESC("SELECT wernis_userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%s LIMIT 1", @@ -70,7 +71,7 @@ if (!isset($_GET['mode'])) { if (SQL_NUMROWS($result) == 1) { // Fetch ID list($content['wds66_id']) = SQL_FETCHROW($result); - } + } // END - if // Free result SQL_FREERESULT($result); @@ -89,12 +90,12 @@ if (!isset($_GET['mode'])) { while ($data = SQL_FETCHARRAY($result)) { // Prepare data for output $rowContent = array( - 'stamp' => MAKE_DATETIME($data['wernis_timestamp'], "2"), - 'points' => TRANSLATE_COMMA($data['wernis_amount']), - 'acc' => bigintval($data['wernis_account']), - 'status' => WERNIS_TRANSFER_STATUS($data['wernis_type']), - 'raw_type' => strtolower($data['wernis_type']), - 'sw' => $SW, + 'stamp' => MAKE_DATETIME($data['wernis_timestamp'], "2"), + 'points' => TRANSLATE_COMMA($data['wernis_amount']), + 'acc' => bigintval($data['wernis_account']), + 'status' => WERNIS_TRANSFER_STATUS($data['wernis_type']), + 'raw_type' => strtolower($data['wernis_type']), + 'sw' => $SW, ); // Load row template @@ -105,31 +106,52 @@ if (!isset($_GET['mode'])) { // Free result SQL_FREERESULT($result); } else { - // Mode pay - $_GET['mode'] = "pay"; + // Default links are not active! + $content['payout_link'] = "".WERNIS_MEMBER_PAYOUT_DISABLED.""; + $content['withdraw_link'] = "".WERNIS_MEMBER_WITHDRAW_DISABLED.""; + + // Is the payout mode active? + if ($_CONFIG['wernis_payout_active'] == "Y") { + // Add link + $content['payout_link'] = "
".MEMBER_WERNIS_MODE_PAYOUT."
"; + } // END - if + + // Is the withdraw mode active? + if ($_CONFIG['wernis_withdraw_active'] == "Y") { + // Add link + $content['withdraw_link'] = "
".MEMBER_WERNIS_MODE_WITHDRAW."
"; + } // END - if + + // Mode chooser! ;-) + $_GET['mode'] = "choose"; } -} -if ($_GET['mode'] == "pay") { +} elseif (($_GET['mode'] == "payout") && ($_CONFIG['wernis_payout_active'] == "Y")) { // Get total points and check if the user can request a payout $points = GET_TOTAL_DATA($GLOBALS['userid'], "user_points", "points") - GET_TOTAL_DATA($GLOBALS['userid'], "user_data", "used_points"); - // No dots here... - $points = explode(".", $points); - $points = bigintval($points[0]); - // Remove the registration fee $points = $points - $_CONFIG['points_register']; + // Is there a percentage or fixed fee? + $points = WERNIS_TAKE_FEE($points, "payout"); + // Is this enougth for a payout? if ($points < $_CONFIG['wernis_min_payout']) { // No, then abort here - LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_MIN_PAYOUT_PAYOUT, TRANSLATE_COMMA($_CONFIG['wernis_min_payout']))); + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_MIN_PAYOUT, TRANSLATE_COMMA($_CONFIG['wernis_min_payout']))); return; - } + } // END - if + + // No dots here... + $points = explode(".", $points); + $points = bigintval($points[0]); // Add points to content array - $content['points'] = $points; - $content['min_points'] = TRANSLATE_COMMA($_CONFIG['wernis_min_payout']); + $content['points'] = TRANSLATE_COMMA($points); + $content['min_points'] = TRANSLATE_COMMA($_CONFIG['wernis_min_payout']); + + // Add fees to array + WERNIS_ADD_FEES_TO_ARRAY($content); // Get WDS66 id $content['wds66_id'] = ""; @@ -140,7 +162,31 @@ if ($_GET['mode'] == "pay") { if (SQL_NUMROWS($result) == 1) { // Fetch ID list($content['wds66_id']) = SQL_FETCHROW($result); - } + } // END - if + + // Free result + SQL_FREERESULT($result); +} elseif (($_GET['mode'] == "withdraw") && ($_CONFIG['wernis_withdraw_active'] == "Y")) { + // Get total points for just displaying them + $points = GET_TOTAL_DATA($GLOBALS['userid'], "user_points", "points") - GET_TOTAL_DATA($GLOBALS['userid'], "user_data", "used_points"); + + // Prepare data for the template + $content['points'] = TRANSLATE_COMMA($points); + $content['min_points'] = TRANSLATE_COMMA($_CONFIG['wernis_min_withdraw']); + $content['wds66_id'] = ""; + + // Add fees to array + WERNIS_ADD_FEES_TO_ARRAY($content); + + // Get WDS66 id + $result = SQL_QUERY_ESC("SELECT wernis_userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%s LIMIT 1", + array($GLOBALS['userid']), __FILE__, __LINE__); + + // Are there some entries? + if (SQL_NUMROWS($result) == 1) { + // Fetch ID + list($content['wds66_id']) = SQL_FETCHROW($result); + } // END - if // Free result SQL_FREERESULT($result); @@ -152,76 +198,101 @@ if ($_GET['mode'] == "pay") { // Is the formular sent? if ((isset($_POST['ok'])) && (isset($_GET['mode']))) { - // Check input data depending on the mode and execute the requested mode - switch ($_GET['mode']) { - case "pay": // Payout this exchange -> WDS66 - // Is the user ID and password set? - if (empty($_POST['wds66_id'])) { - // Nothing entered in WDS66 user ID - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_USERNAME); - OUTPUT_HTML("
"); - } elseif (empty($_POST['wds66_password'])) { - // Nothing entered in WDS66 password - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_PASSWORD); - OUTPUT_HTML("
"); - } elseif (empty($_POST['amount'])) { - // Nothing entered in amount - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_AMOUNT); - OUTPUT_HTML("
"); - } elseif ($_POST['wds66_id'] != bigintval($_POST['wds66_id'])) { - // Only numbers in account ID! - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_INVALID_USERNAME); - OUTPUT_HTML("
"); - } elseif ($_POST['amount'] != bigintval($_POST['amount'])) { - // Only numbers in amount! - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_INVALID_AMOUNT); - OUTPUT_HTML("
"); - } elseif ($_POST['amount'] < $_CONFIG['wernis_min_payout']) { - // Not enougth entered! - LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_AMOUNT_SMALLER_MIN, bigintval($_CONFIG['wernis_min_payout']))); - OUTPUT_HTML("
"); - } elseif ($_POST['amount'] > $points) { - // Not enougth points left! - LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED, bigintval($_POST['amount']), bigintval($points))); - OUTPUT_HTML("
"); - } else { - // All is fine here so do the payout - $success = WERNIS_EXECUTE_PAYOUT($_POST['wds66_id'], md5($_POST['wds66_password']), $_POST['amount']); - if ($success) { - // Default is locked! - $locked = true; - - // Shall I "pay" the referral points imidiately? - if ($_CONFIG['ref_payout'] == "0") { - // Yes, "pay" it now - $locked = false; - } + // Is the user ID and password set? + if (empty($_POST['wds66_id'])) { + // Nothing entered in WDS66 user ID + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_USERNAME); + OUTPUT_HTML("
"); + } elseif (empty($_POST['wds66_password'])) { + // Nothing entered in WDS66 password + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_PASSWORD); + OUTPUT_HTML("
"); + } elseif (empty($_POST['amount'])) { + // Nothing entered in amount + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_EMPTY_AMOUNT); + OUTPUT_HTML("
"); + } elseif ($_POST['wds66_id'] != bigintval($_POST['wds66_id'])) { + // Only numbers in account ID! + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_INVALID_USERNAME); + OUTPUT_HTML("
"); + } elseif ($_POST['amount'] != bigintval($_POST['amount'])) { + // Only numbers in amount! + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_INVALID_AMOUNT); + OUTPUT_HTML("
"); + } else { + // Check input data depending on the mode and execute the requested mode + switch ($_GET['mode']) { + case "withdraw": // Widthdraws WDS66 -> This exchange + if ($_POST['amount'] < $_CONFIG['wernis_min_withdraw']) { + // Not enougth entered! + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_AMOUNT_SMALLER_MIN, bigintval($_CONFIG['wernis_min_withdraw']))); + OUTPUT_HTML("
"); + } else { + // All is fine here so do the withdraw + $success = WERNIS_EXECUTE_WITHDRAW($_POST['wds66_id'], md5($_POST['wds66_password']), $_POST['amount']); + if ($success) { + // Add it to this amount + $DEPTH = 0; + ADD_POINTS_REFSYSTEM($GLOBALS['userid'], bigintval($_POST['amount']), false, 0, false, "direct"); - // Sub points - SUB_POINTS($GLOBALS['userid'], $_POST['amount']); + // Update the user data as well.. + $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET `wernis_userid`=%s WHERE userid=%s LIMIT 1", + array(bigintval($_POST['wds66_id']), $GLOBALS['userid']), __FILE__, __LINE__); - // Update WDS66 id - $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET `wernis_userid`=%s WHERE userid=%s LIMIT 1", - array(bigintval($_POST['wds66_id']), $GLOBALS['userid']), __FILE__, __LINE__); + // All done! + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_WITHDRAW_DONE); + return; + } elseif ((GET_WERNIS_ERROR_CODE() == "user_failed") || (GET_WERNIS_ERROR_CODE() == "own_failed") || (GET_WERNIS_ERROR_CODE() == "amount_failed")) { + // Wrong login data + LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE()); + OUTPUT_HTML("
"); + } else { + // Something went wrong + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_WITHDRAW_FAILED, GET_WERNIS_ERROR_MESSAGE())); + OUTPUT_HTML("
"); + } + } + break; - // All done! - LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_PAYOUT_DONE); - return; - } elseif ((GET_WERNIS_ERROR_CODE() == "user_failed") || (GET_WERNIS_ERROR_CODE() == "own_failed") || (GET_WERNIS_ERROR_CODE() == "amount_failed") || (GET_WERNIS_ERROR_CODE() == "api_amount_failed")) { - // Wrong login data - LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE()); + case "payout": // Payout this exchange -> WDS66 + if ($_POST['amount'] < $_CONFIG['wernis_min_payout']) { + // Not enougth entered! + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_AMOUNT_SMALLER_MIN, bigintval($_CONFIG['wernis_min_payout']))); OUTPUT_HTML("
"); - } else { - // Something went wrong - LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_PAYOUT_FAILED, GET_WERNIS_ERROR_MESSAGE())); + } elseif ($_POST['amount'] > $points) { + // Not enougth points left! + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED, bigintval($_POST['amount']), bigintval($points))); OUTPUT_HTML("
"); + } else { + // All is fine here so do the withdraw + $success = WERNIS_EXECUTE_PAYOUT($_POST['wds66_id'], md5($_POST['wds66_password']), $_POST['amount']); + if ($success) { + // Sub points + SUB_POINTS($GLOBALS['userid'], $_POST['amount']); + + // Update WDS66 id + $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET `wernis_userid`=%s WHERE userid=%s LIMIT 1", + array(bigintval($_POST['wds66_id']), $GLOBALS['userid']), __FILE__, __LINE__); + + // All done! + LOAD_TEMPLATE("admin_settings_saved", false, WERNIS_MEMBER_PAYOUT_DONE); + return; + } elseif ((GET_WERNIS_ERROR_CODE() == "user_failed") || (GET_WERNIS_ERROR_CODE() == "own_failed") || (GET_WERNIS_ERROR_CODE() == "amount_failed") || (GET_WERNIS_ERROR_CODE() == "api_amount_failed")) { + // Wrong login data + LOAD_TEMPLATE("admin_settings_saved", false, GET_WERNIS_ERROR_MESSAGE()); + OUTPUT_HTML("
"); + } else { + // Something went wrong + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_WITHDRAW_FAILED, GET_WERNIS_ERROR_MESSAGE())); + OUTPUT_HTML("
"); + } } - } - break; + break; - default: // Invalid mode! - LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_MODE_INVALID, SQL_ESCAPE($_GET['mode']))); - return; + default: // Invalid mode! + LOAD_TEMPLATE("admin_settings_saved", false, sprintf(WERNIS_MEMBER_MODE_INVALID, SQL_ESCAPE($_GET['mode']))); + return; + } } } diff --git a/inc/modules/sponsor/account.php b/inc/modules/sponsor/account.php index f9912e53d9..b23ec6a99a 100644 --- a/inc/modules/sponsor/account.php +++ b/inc/modules/sponsor/account.php @@ -73,9 +73,9 @@ if (SQL_NUMROWS($result) == 1) { } elseif ((!empty($_POST['pass1'])) && (empty($_POST['pass2']))) { // No password two entered $MSG = SPONSOR_PASSWORD_TWO_EMPTY; - } elseif ((!empty($_POST['pass1'])) && (strlen($_POST['pass1']) < $CONFIG['pass_len'])) { + } elseif ((!empty($_POST['pass1'])) && (strlen($_POST['pass1']) < $_CONFIG['pass_len'])) { // Too short password - $MSG = SPONSOR_PASSWORD_TOO_SHORT_1.$CONFIG['pass_len'].SPONSOR_PASSWORD_TOO_SHORT_2; + $MSG = SPONSOR_PASSWORD_TOO_SHORT_1.$_CONFIG['pass_len'].SPONSOR_PASSWORD_TOO_SHORT_2; } else { // Default is we don't want to change password! $PASS_AND = ""; $PASS_DATA = ""; diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index 19750af9c4..96e7cfb9d5 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -314,9 +314,17 @@ function ADD_MENU($MODE, $act, $wht) { // There are menus available, so we simply display them... :) while (list($main_title, $main_action) = SQL_FETCHROW($result_main)) { //* DEBUG: */ echo __LINE__."/".$main_cnt."/".$main_action."/".$sub_what.":".$GLOBALS['what']."*
\n"; - // Load menu header template + // Init variables $BLOCK_MODE = false; $act = $main_action; - LOAD_TEMPLATE($MODE."_menu_title", false, $main_title); + + // Prepare content + $content = array( + 'action' => $main_action, + 'title' => $main_title + ); + + // Load menu header template + LOAD_TEMPLATE($MODE."_menu_title", false, $content); $result_sub = SQL_QUERY_ESC("SELECT title, what FROM "._MYSQL_PREFIX."_%s_menu WHERE action='%s' AND what != '' ".$AND." ORDER BY sort", array($MODE, $main_action), __FILE__, __LINE__); @@ -355,6 +363,13 @@ function ADD_MENU($MODE, $act, $wht) { $content .= "
"; } $wht = $sub_what; $cnt++; + // Prepare array + $content = array( + 'menu' => $content, + 'what' => $sub_what + ); + + // Add regular menu row or bottom row? if ($cnt < $ctl) { LOAD_TEMPLATE($MODE."_menu_row", false, $content); } else { diff --git a/install/tables.sql b/install/tables.sql index cbcca3921b..dd1a805a23 100644 --- a/install/tables.sql +++ b/install/tables.sql @@ -4,14 +4,14 @@ CREATE TABLE `mxchange_admin_menu` ( `action` VARCHAR(255) NOT NULL DEFAULT '', `what` VARCHAR(255) NOT NULL DEFAULT '', `title` VARCHAR(50) NOT NULL DEFAULT '', - `sort` BIGINT(20) NOT NULL DEFAULT '0', + `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `descr` blob NOT NULL, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_admins`; CREATE TABLE `mxchange_admins` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `login` VARCHAR(100) NOT NULL DEFAULT '', `password` VARCHAR(40) NOT NULL DEFAULT '', PRIMARY KEY (`id`) @@ -22,23 +22,23 @@ CREATE TABLE `mxchange_cats` ( `id` BIGINT(22) NOT NULL AUTO_INCREMENT, `cat` VARCHAR(255) NOT NULL DEFAULT '', `visible` ENUM('Y','N') NOT NULL DEFAULT 'Y', - `sort` BIGINT(20) NOT NULL DEFAULT '0', + `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_config`; CREATE TABLE `mxchange_config` ( - `config` tinyint(1) NOT NULL DEFAULT '0', - `pass_len` TINYINT(3) NOT NULL DEFAULT '5', - `points_register` BIGINT(20) NOT NULL DEFAULT '0', - `points_ref` BIGINT(20) NOT NULL DEFAULT '0', - `least_cats` TINYINT(3) NOT NULL DEFAULT '5', + `config` tinyint(1) NOT NULL DEFAULT 0, + `pass_len` TINYINT(3) UNSIGNED NOT NULL DEFAULT 5, + `points_register` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `points_ref` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `least_cats` TINYINT(3) UNSIGNED NOT NULL DEFAULT 5, `check_double_email` ENUM('Y','N') NOT NULL DEFAULT 'Y', `check_double_pass` ENUM('Y','N') NOT NULL DEFAULT 'N', `admin_notify` ENUM('Y','N') NOT NULL DEFAULT 'Y', - `url_tlock` BIGINT(20) NOT NULL DEFAULT '86400', + `url_tlock` BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400', `test_text` ENUM('Y','N') NOT NULL DEFAULT 'Y', - `max_tlength` BIGINT(20) NOT NULL DEFAULT '1000', + `max_tlength` BIGINT(20) UNSIGNED NOT NULL DEFAULT '1000', `test_subj` ENUM('Y','N') NOT NULL DEFAULT 'Y', `autosend_active` ENUM('Y','N') NOT NULL DEFAULT 'N', PRIMARY KEY (`config`) @@ -52,17 +52,17 @@ CREATE TABLE `mxchange_guest_menu` ( `action` VARCHAR(20) NOT NULL DEFAULT '', `what` VARCHAR(20) NOT NULL DEFAULT '', `title` VARCHAR(50) NOT NULL DEFAULT '', - `sort` BIGINT(20) NOT NULL DEFAULT '0', + `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `visible` ENUM('Y','N') NOT NULL DEFAULT 'Y', `locked` ENUM('Y','N') NOT NULL DEFAULT 'Y', - `counter` BIGINT(20) NOT NULL DEFAULT '0', + `counter` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_max_receive`; CREATE TABLE `mxchange_max_receive` ( `id` BIGINT(22) NOT NULL AUTO_INCREMENT, - `value` MEDIUMINT(9) NOT NULL DEFAULT '0', + `value` MEDIUMINT(9) NOT NULL DEFAULT 0, `comment` VARCHAR(255) NOT NULL DEFAULT '', PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -73,24 +73,24 @@ CREATE TABLE `mxchange_member_menu` ( `action` VARCHAR(20) NOT NULL DEFAULT '', `what` VARCHAR(20) NOT NULL DEFAULT '', `title` VARCHAR(50) NOT NULL DEFAULT '', - `sort` BIGINT(20) NOT NULL DEFAULT '0', + `sort` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `visible` ENUM('Y','N') NOT NULL DEFAULT 'Y', `locked` ENUM('Y','N') NOT NULL DEFAULT 'Y', `descr` blob NOT NULL, - `counter` BIGINT(20) NOT NULL DEFAULT '0', + `counter` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_mod_reg`; CREATE TABLE `mxchange_mod_reg` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `module` VARCHAR(50) NOT NULL DEFAULT '', `locked` ENUM('Y','N') NOT NULL DEFAULT 'Y', `hidden` ENUM('Y','N') NOT NULL DEFAULT 'N', `admin_only` ENUM('Y','N') NOT NULL DEFAULT 'N', `title` VARCHAR(200) NOT NULL DEFAULT '', `mem_only` ENUM('Y','N') NOT NULL DEFAULT 'N', - `clicks` BIGINT(20) NOT NULL DEFAULT '0', + `clicks` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -104,27 +104,27 @@ INSERT INTO `mxchange_mod_reg` VALUES (8,'order','N','N','N','','N',0); DROP TABLE IF EXISTS `mxchange_payments`; CREATE TABLE `mxchange_payments` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, - `time` INT(7) NOT NULL DEFAULT '0', - `payment` FLOAT(5,3) NOT NULL DEFAULT '0.000', + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `time` INT(7) NOT NULL DEFAULT 0, + `payment` FLOAT(5,3) UNSIGNED NOT NULL DEFAULT '0.000', `mail_title` VARCHAR(255) NOT NULL DEFAULT '', - `price` FLOAT(5,3) NOT NULL DEFAULT '0.000', + `price` FLOAT(5,5) UNSIGNED NOT NULL DEFAULT '0.00000', PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_pool`; CREATE TABLE `mxchange_pool` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, - `sender` BIGINT(20) NOT NULL DEFAULT '0', + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `sender` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `subject` VARCHAR(200) NOT NULL DEFAULT '', `text` LONGBLOB NOT NULL, `receivers` LONGBLOB NOT NULL, - `payment_id` TINYINT(3) NOT NULL DEFAULT '0', + `payment_id` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, `data_type` ENUM('TEMP','SEND','NEW','ADMIN') NOT NULL DEFAULT 'TEMP', - `timestamp` VARCHAR(10) NOT NULL DEFAULT '0', + `timestamp` VARCHAR(10) NOT NULL DEFAULT 0, `url` tinytext NOT NULL, - `target_send` BIGINT(20) NOT NULL DEFAULT '0', - `cat_id` BIGINT(20) NOT NULL DEFAULT '0', + `target_send` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `cat_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -134,15 +134,15 @@ CREATE TABLE `mxchange_refbanner` ( `url` TEXT NOT NULL, `alternate` TEXT NOT NULL, `visible` ENUM('Y','N') NOT NULL DEFAULT 'Y', - `counter` BIGINT(22) NOT NULL DEFAULT '0', + `counter` BIGINT(22) NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_refdepths`; CREATE TABLE `mxchange_refdepths` ( - `id` TINYINT(3) NOT NULL AUTO_INCREMENT, - `level` TINYINT(3) NOT NULL DEFAULT '0', - `percents` TINYINT(3) NOT NULL DEFAULT '0', + `id` TINYINT(3) UNSIGNED NOT NULL AUTO_INCREMENT, + `level` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, + `percents` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -156,17 +156,17 @@ INSERT INTO `mxchange_refdepths` VALUES (6,5,5); DROP TABLE IF EXISTS `mxchange_refsystem`; CREATE TABLE `mxchange_refsystem` ( `id` BIGINT(22) NOT NULL AUTO_INCREMENT, - `userid` BIGINT(20) NOT NULL DEFAULT '0', - `level` TINYINT(3) NOT NULL DEFAULT '0', - `counter` BIGINT(20) NOT NULL DEFAULT '0', + `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `level` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, + `counter` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_user_cats`; CREATE TABLE `mxchange_user_cats` ( `id` BIGINT(22) NOT NULL AUTO_INCREMENT, - `userid` BIGINT(20) NOT NULL DEFAULT '0', - `cat_id` TINYINT(3) NOT NULL DEFAULT '0', + `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `cat_id` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -184,67 +184,67 @@ CREATE TABLE `mxchange_user_data` ( `birth_month` CHAR(2) NOT NULL DEFAULT '01', `birth_year` VARCHAR(4) NOT NULL DEFAULT '1970', `password` VARCHAR(32) NOT NULL DEFAULT '', - `max_mails` INT(7) NOT NULL DEFAULT '0', - `receive_mails` INT(7) NOT NULL DEFAULT '0', - `refid` BIGINT(22) NOT NULL DEFAULT '0', + `max_mails` INT(7) NOT NULL DEFAULT 0, + `receive_mails` INT(7) NOT NULL DEFAULT 0, + `refid` BIGINT(22) NOT NULL DEFAULT 0, `status` ENUM('UNCONFIRMED','CONFIRMED','LOCKED') NOT NULL DEFAULT 'UNCONFIRMED', `user_hash` VARCHAR(32) NOT NULL DEFAULT '', `REMOTE_ADDR` VARCHAR(15) NOT NULL DEFAULT '0.0.0.0', - `last_online` VARCHAR(10) NOT NULL DEFAULT '0', + `last_online` VARCHAR(10) NOT NULL DEFAULT 0, `last_module` VARCHAR(20) NOT NULL DEFAULT '', - `ref_clicks` BIGINT(20) NOT NULL DEFAULT '0', - `total_logins` BIGINT(20) NOT NULL DEFAULT '0', + `ref_clicks` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `total_logins` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `gender` ENUM('M','F') NOT NULL DEFAULT 'M', `used_points` DOUBLE(22,3) NOT NULL DEFAULT '0.000', - `emails_sent` BIGINT(20) NOT NULL DEFAULT '0', + `emails_sent` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (`userid`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_user_points`; CREATE TABLE `mxchange_user_points` ( `id` BIGINT(22) NOT NULL AUTO_INCREMENT, - `userid` BIGINT(22) NOT NULL DEFAULT '0', - `ref_depth` TINYINT(3) NOT NULL DEFAULT '0', + `userid` BIGINT(22) NOT NULL DEFAULT 0, + `ref_depth` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0, `points` DOUBLE(22,3) NOT NULL DEFAULT '0.000', PRIMARY KEY (`id`) ) TYPE=MyISAM; -alter table `mxchange_config` add `max_send` TINYINT(3) NOT NULL DEFAULT '100'; -alter table `mxchange_config` add `url_blacklist` ENUM('Y','N') NOT NULL DEFAULT 'Y'; -alter table `mxchange_config` add `auto_purge` TINYINT(3) NOT NULL DEFAULT '14'; -alter table `mxchange_config` add `auto_purge_active` ENUM('Y','N') NOT NULL DEFAULT 'Y'; +ALTER TABLE `mxchange_config` ADD `max_send` TINYINT(3) UNSIGNED NOT NULL DEFAULT '100'; +ALTER TABLE `mxchange_config` ADD `url_blacklist` ENUM('Y','N') NOT NULL DEFAULT 'Y'; +ALTER TABLE `mxchange_config` ADD `auto_purge` TINYINT(3) UNSIGNED NOT NULL DEFAULT '14'; +ALTER TABLE `mxchange_config` ADD `auto_purge_active` ENUM('Y','N') NOT NULL DEFAULT 'Y'; -alter table `mxchange_pool` modify `url` tinytext NOT NULL; -alter table `mxchange_pool` change `url` `url` tinyblob NOT NULL; -alter table `mxchange_pool` modify `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'; +ALTER TABLE `mxchange_pool` MODIFY `url` tinytext NOT NULL; +ALTER TABLE `mxchange_pool` CHANGE `url` `url` tinyblob NOT NULL; +ALTER TABLE `mxchange_pool` MODIFY `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'; DROP TABLE IF EXISTS `mxchange_user_links`; CREATE TABLE `mxchange_user_links` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, - `stats_id` BIGINT(20) NOT NULL DEFAULT '0', - `userid` BIGINT(20) NOT NULL DEFAULT '0', + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `stats_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `link_type` ENUM('NORMAL') NOT NULL DEFAULT 'NORMAL', PRIMARY KEY (`id`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mxchange_user_stats`; CREATE TABLE `mxchange_user_stats` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, - `userid` BIGINT(20) NOT NULL DEFAULT '0', - `cat_id` BIGINT(20) NOT NULL DEFAULT '0', - `payment_id` BIGINT(20) NOT NULL DEFAULT '0', + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `cat_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `payment_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `subject` VARCHAR(200) NOT NULL DEFAULT '', `url` tinyblob NOT NULL, - `max_rec` BIGINT(20) NOT NULL DEFAULT '0', + `max_rec` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `timestamp_ordered` VARCHAR(10) NOT NULL DEFAULT '', - `pool_id` BIGINT(20) NOT NULL DEFAULT '0', + `pool_id` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `timestamp_sstart` VARCHAR(10) NOT NULL DEFAULT '', `timestamp_send` VARCHAR(10) NOT NULL DEFAULT '', PRIMARY KEY (`id`) ) TYPE=MyISAM; -alter table `mxchange_user_data` add `joined` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_config` add `last_update` VARCHAR(10) NOT NULL DEFAULT '0'; +ALTER TABLE `mxchange_user_data` ADD `joined` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_config` ADD `last_update` VARCHAR(10) NOT NULL DEFAULT 0; UPDATE `mxchange_member_menu` SET `locked` = 'N' WHERE 'id'='12' OR 'id'='11' LIMIT 1; @@ -252,37 +252,37 @@ UPDATE `mxchange_guest_menu` SET `counter`=0; UPDATE `mxchange_member_menu` SET `counter`=0; INSERT INTO `mxchange_mod_reg` VALUES (NULL,'chk_login','N','N','N','','N',0); -alter table `mxchange_pool` modify `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'; -alter table `mxchange_config` add `unconfirmed` BIGINT(20) NOT NULL DEFAULT '100'; -alter table `mxchange_config` add `profile_lock` BIGINT(20) NOT NULL DEFAULT '86400'; -alter table `mxchange_user_data` add `last_update` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_refbanner` add `clicks` BIGINT(20) NOT NULL DEFAULT '0'; -alter table `mxchange_config` add `online_timeout` BIGINT(20) NOT NULL DEFAULT '1800'; +ALTER TABLE `mxchange_pool` MODIFY `data_type` ENUM('TEMP','SEND','NEW','ADMIN','ACTIVE') NOT NULL DEFAULT 'TEMP'; +ALTER TABLE `mxchange_config` ADD `unconfirmed` BIGINT(20) UNSIGNED NOT NULL DEFAULT '100'; +ALTER TABLE `mxchange_config` ADD `profile_lock` BIGINT(20) UNSIGNED NOT NULL DEFAULT '86400'; +ALTER TABLE `mxchange_user_data` ADD `last_update` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_refbanner` ADD `clicks` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_config` ADD `online_timeout` BIGINT(20) UNSIGNED NOT NULL DEFAULT '1800'; -alter table `mxchange_config` add `mad_timestamp` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_config` add `mad_count` BIGINT(20) NOT NULL; -alter table `mxchange_config` add `profile_update` BIGINT(20) NOT NULL DEFAULT '15768000'; -alter table `mxchange_config` add `send_prof_update` ENUM('Y','N') NOT NULL DEFAULT 'Y'; -alter table `mxchange_config` add `resend_profile_update` BIGINT(20) NOT NULL DEFAULT '172800'; +ALTER TABLE `mxchange_config` ADD `mad_timestamp` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_config` ADD `mad_count` BIGINT(20) UNSIGNED NOT NULL; +ALTER TABLE `mxchange_config` ADD `profile_update` BIGINT(20) UNSIGNED NOT NULL DEFAULT '15768000'; +ALTER TABLE `mxchange_config` ADD `send_prof_update` ENUM('Y','N') NOT NULL DEFAULT 'Y'; +ALTER TABLE `mxchange_config` ADD `resend_profile_update` BIGINT(20) UNSIGNED NOT NULL DEFAULT '172800'; -alter table `mxchange_user_data` add `last_profile_sent` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_user_data` add `notified` ENUM('Y','N') NOT NULL DEFAULT 'N'; +ALTER TABLE `mxchange_user_data` ADD `last_profile_sent` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_user_data` ADD `notified` ENUM('Y','N') NOT NULL DEFAULT 'N'; -alter table `mxchange_config` add `patch_level` VARCHAR(100) NOT NULL DEFAULT '78'; -alter table `mxchange_config` add `patch_ctime` VARCHAR(10) NOT NULL DEFAULT '0'; +ALTER TABLE `mxchange_config` ADD `patch_level` VARCHAR(100) NOT NULL DEFAULT '78'; +ALTER TABLE `mxchange_config` ADD `patch_ctime` VARCHAR(10) NOT NULL DEFAULT 0; -alter table `mxchange_admins` add `email` VARCHAR(255) NOT NULL; +ALTER TABLE `mxchange_admins` ADD `email` VARCHAR(255) NOT NULL; DROP TABLE IF EXISTS `mxchange_task_system`; CREATE TABLE `mxchange_task_system` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, - `assigned_admin` BIGINT(20) NOT NULL DEFAULT '0', - `userid` BIGINT(20) NOT NULL DEFAULT '0', + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, + `assigned_admin` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, + `userid` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0, `status` ENUM('NEW','OPEN','SOLVED','CLOSED','DELETED') NOT NULL DEFAULT 'NEW', `task_type` ENUM('FIRST_USER','SUPPORT_MEMBER','SUPPORT_ADMIN','OTHERS', 'EXTENSION', 'EXTENSION_UPDATE') NOT NULL DEFAULT 'FIRST_USER', `subject` VARCHAR(255) NOT NULL DEFAULT '', `text` LONGBLOB NOT NULL, - `task_created` VARCHAR(10) NOT NULL DEFAULT '0', + `task_created` VARCHAR(10) NOT NULL DEFAULT 0, KEY (`assigned_admin`), PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -304,20 +304,20 @@ ALTER TABLE `mxchange_user_stats` ADD INDEX (`cat_id`); ALTER TABLE `mxchange_user_stats` ADD INDEX (`payment_id`); ALTER TABLE `mxchange_user_stats` ADD INDEX (`pool_id`); -alter table `mxchange_user_stats` add `clicks` BIGINT(20) NOT NULL; -alter table `mxchange_config` add `code_length` TINYINT(3) NOT NULL DEFAULT '5'; -alter table `mxchange_config` add `guest_stats` ENUM('MEMBERS','MODULES','INACTIVE') NOT NULL DEFAULT 'MEMBERS'; -alter table `mxchange_config` add `ref_payout` TINYINT(3) NOT NULL DEFAULT '5'; -alter table `mxchange_user_data` add `ref_payout` TINYINT(3) NOT NULL DEFAULT '0'; -alter table `mxchange_user_points` add `locked_points` BIGINT(20) NOT NULL DEFAULT '0'; +ALTER TABLE `mxchange_user_stats` ADD `clicks` BIGINT(20) UNSIGNED NOT NULL; +ALTER TABLE `mxchange_config` ADD `code_length` TINYINT(3) UNSIGNED NOT NULL DEFAULT 5; +ALTER TABLE `mxchange_config` ADD `guest_stats` ENUM('MEMBERS','MODULES','INACTIVE') NOT NULL DEFAULT 'MEMBERS'; +ALTER TABLE `mxchange_config` ADD `ref_payout` TINYINT(3) UNSIGNED NOT NULL DEFAULT 5; +ALTER TABLE `mxchange_user_data` ADD `ref_payout` TINYINT(3) UNSIGNED NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_user_points` ADD `locked_points` BIGINT(20) UNSIGNED NOT NULL DEFAULT 0; DROP TABLE IF EXISTS `mxchange_extensions`; CREATE TABLE `mxchange_extensions` ( - `id` BIGINT(20) NOT NULL AUTO_INCREMENT, + `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, `ext_name` VARCHAR(255) NOT NULL DEFAULT '', `ext_lang_file` VARCHAR(255) NOT NULL DEFAULT '', `ext_active` ENUM('Y','N') NOT NULL DEFAULT 'N', - `ext_version` VARCHAR(255) NOT NULL DEFAULT '0.', + `ext_version` VARCHAR(255) NOT NULL DEFAULT 'INVALID', PRIMARY KEY (`id`) ) TYPE=MyISAM; @@ -328,19 +328,19 @@ CREATE TABLE `mxchange_jackpot` ( PRIMARY KEY (`ok`) ) TYPE=MyISAM; -alter table `mxchange_config` add `activate_xchange` BIGINT(20) NOT NULL DEFAULT '100'; -alter table `mxchange_config` add `order_multi_page` ENUM('Y','N') NOT NULL DEFAULT 'Y'; -alter table `mxchange_config` add `display_refid` ENUM('Y','N') NOT NULL DEFAULT 'Y'; -alter table `mxchange_config` add `ip_timeout` BIGINT(20) NOT NULL DEFAULT '86400'; -alter table `mxchange_pool` add `zip` VARCHAR(6) NOT NULL DEFAULT ''; - -alter table `mxchange_task_system` change `task_type` `task_type` VARCHAR(255) NOT NULL DEFAULT 'FIRST_USER'; -alter table `mxchange_user_data` modify `zip` VARCHAR(6) NOT NULL DEFAULT ''; -alter table `mxchange_admin_menu` modify `action` VARCHAR(255) NOT NULL DEFAULT ''; -alter table `mxchange_admin_menu` modify `what` VARCHAR(255) NOT NULL DEFAULT ''; -alter table `mxchange_user_data` modify `last_module` VARCHAR(255) NOT NULL DEFAULT ''; -alter table `mxchange_config` add `allow_direct_pay` ENUM('N', 'Y') NOT NULL DEFAULT 'N'; -alter table `mxchange_user_data` modify `last_profile_sent` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_user_data` modify `last_update` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_user_data` modify `joined` VARCHAR(10) NOT NULL DEFAULT '0'; -alter table `mxchange_user_data` modify `last_online` VARCHAR(10) NOT NULL DEFAULT '0'; +ALTER TABLE `mxchange_config` ADD `activate_xchange` BIGINT(20) UNSIGNED NOT NULL DEFAULT 100; +ALTER TABLE `mxchange_config` ADD `order_multi_page` ENUM('Y','N') NOT NULL DEFAULT 'Y'; +ALTER TABLE `mxchange_config` ADD `display_refid` ENUM('Y','N') NOT NULL DEFAULT 'Y'; +ALTER TABLE `mxchange_config` ADD `ip_timeout` BIGINT(20) UNSIGNED NOT NULL DEFAULT 86400; +ALTER TABLE `mxchange_pool` ADD `zip` VARCHAR(6) NOT NULL DEFAULT ''; + +ALTER TABLE `mxchange_task_system` CHANGE `task_type` `task_type` VARCHAR(255) NOT NULL DEFAULT 'FIRST_USER'; +ALTER TABLE `mxchange_user_data` MODIFY `zip` VARCHAR(6) NOT NULL DEFAULT ''; +ALTER TABLE `mxchange_admin_menu` MODIFY `action` VARCHAR(255) NOT NULL DEFAULT ''; +ALTER TABLE `mxchange_admin_menu` MODIFY `what` VARCHAR(255) NOT NULL DEFAULT ''; +ALTER TABLE `mxchange_user_data` MODIFY `last_module` VARCHAR(255) NOT NULL DEFAULT ''; +ALTER TABLE `mxchange_config` ADD `allow_direct_pay` ENUM('N', 'Y') NOT NULL DEFAULT 'N'; +ALTER TABLE `mxchange_user_data` MODIFY `last_profile_sent` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_user_data` MODIFY `last_update` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_user_data` MODIFY `joined` VARCHAR(10) NOT NULL DEFAULT 0; +ALTER TABLE `mxchange_user_data` MODIFY `last_online` VARCHAR(10) NOT NULL DEFAULT 0; diff --git a/templates/de/emails/confirm-member.tpl b/templates/de/emails/confirm-member.tpl index a6145704c8..889ff57ba2 100644 --- a/templates/de/emails/confirm-member.tpl +++ b/templates/de/emails/confirm-member.tpl @@ -7,7 +7,7 @@ Sie können sich nun hier einloggen: Ihre Login-ID lautet: $UID URL zum Login: {!URL!}/login.php -für Ihre Anmeldung werden wir Ihnen als Willkommensgutschrift $content[points] {!POINTS!} gutschreiben, sobald Sie $CONFIG[ref_payout] Mails bestätigt haben. Erst dann können Sie Mails an die anderen Mitglieder verschicken! +für Ihre Anmeldung werden wir Ihnen als Willkommensgutschrift $content[points] {!POINTS!} gutschreiben, sobald Sie $_CONFIG[ref_payout] Mails bestätigt haben. Erst dann können Sie Mails an die anderen Mitglieder verschicken! Wir wünschen Ihnen viel Spass und Erfolg beim Mail-Versand! diff --git a/templates/de/html/admin/admin_config_wernis.tpl b/templates/de/html/admin/admin_config_wernis.tpl index 9f45d20580..a8853f04f9 100644 --- a/templates/de/html/admin/admin_config_wernis.tpl +++ b/templates/de/html/admin/admin_config_wernis.tpl @@ -8,7 +8,7 @@   - {--WERNIS_ADMIN_API_ID--}: + {--WERNIS_ADMIN_API_ID--}:     - {--WERNIS_ADMIN_API_MD5--}: + {--WERNIS_ADMIN_API_MD5--}:     - {--WERNIS_ADMIN_API_URL--}: + {--WERNIS_ADMIN_API_URL--}:     - {--WERNIS_ADMIN_REFID--}: + {--WERNIS_ADMIN_REFID--}:   - + + + + + +   + + +   + + + {--WERNIS_ADMIN_MIN_PAYOUT--}: +   + + Wernis + + + +   + + + {--WERNIS_ADMIN_MIN_WITHDRAW--}: +   + + Wernis + + + +   + + + {--WERNIS_ADMIN_PAYOUT_FACTOR--}: +   + + + + + +   + + + {--WERNIS_ADMIN_WITHDRAW_FACTOR--}: +   + + + + + +   + + + {--WERNIS_ADMIN_PAYOUT_FEE_PERCENT--}: +   + + + + + +   + + + {--WERNIS_ADMIN_WITHDRAW_FEE_PERCENT--}: +   + + % + + + +   + + + {--WERNIS_ADMIN_PAYOUT_FEE_FIX--}: +   + + {!POINTS!} + + + +   + + + {--WERNIS_ADMIN_WITHDRAW_FEE_FIX--}: +   + + {!POINTS!} +   @@ -51,21 +134,23 @@   - {--WERNIS_ADMIN_MIN_PAYOUT--}: + {--WERNIS_ADMIN_PAYOUT_ACTIVE--}   - Wernis + +  {--YES--} +  {--NO--} +   - {--WERNIS_ADMIN_MIN_WITHDRAW--}: + {--WERNIS_ADMIN_WITHDRAW_ACTIVE--}   - Wernis + +  {--YES--} +  {--NO--} +   diff --git a/templates/de/html/admin/admin_list_wernis_main.tpl b/templates/de/html/admin/admin_list_wernis_main.tpl index f2c2a5ce53..1fbacac849 100644 --- a/templates/de/html/admin/admin_list_wernis_main.tpl +++ b/templates/de/html/admin/admin_list_wernis_main.tpl @@ -2,12 +2,12 @@ {--ID_SELECT--} {--_UID--} - {--WERNIS_ADMIN_WDS66_ACCOUNT--} - {--WERNIS_ADMIN_TRANSFERED--} - {--WERNIS_ADMIN_TIMESTAMP--} - {--WERNIS_ADMIN_TYPE--} - {--WERNIS_ADMIN_API_MESSAGE--} - {--WERNIS_ADMIN_API_STATUS--} + {--ADMIN_WERNISWDS66_ACCOUNT--} + {--ADMIN_WERNISTRANSFERED--} + {--ADMIN_WERNISTIMESTAMP--} + {--ADMIN_WERNISTYPE--} + {--ADMIN_WERNISAPI_MESSAGE--} + {--ADMIN_WERNISAPI_STATUS--} $content diff --git a/templates/de/html/ext/ext_primera.tpl b/templates/de/html/ext/ext_primera.tpl index 565f7bdb2f..a757416c71 100644 --- a/templates/de/html/ext/ext_primera.tpl +++ b/templates/de/html/ext/ext_primera.tpl @@ -1,10 +1,10 @@ Mit dieser Erweiterung können Sie Ihren Mitgliedern eine Auszahlung -ihrer Internet-Währung -Primera -auf ihr Primera-Account überweisen lassen. Sie als Primera-Anbieter -brauchen dazu selbstverständlich ein Primera-Account. Mehr dazu auf -www.primusportal.de. Damit Ihr System einheitlicher -ist, sollten Sie unter Sonstige Einstellungen die Währung Ihres {!MT_WORD2!} -von {!POINTS!} auf Primera umstellen. +ihrer Internet-Währung Primera auf ihr Primera-Account überweisen +lassen. Sie als Primera-Anbieter brauchen dazu selbstverständlich +ein Primera-Account. Mehr dazu auf www.primusportal.de. Wenn Sie möchten, können Sie +auch ganz zu Primera wechseln. Sie unter Sonstige +Einstellungen die Währung Ihres {!MT_WORD2!} von {!POINTS!} auf Primera +umstellen. diff --git a/templates/de/html/ext/ext_wernis.tpl b/templates/de/html/ext/ext_wernis.tpl index 908914395b..b5f47ff62e 100644 --- a/templates/de/html/ext/ext_wernis.tpl +++ b/templates/de/html/ext/ext_wernis.tpl @@ -1,11 +1,11 @@ Mit dieser Erweiterung können Sie Ihren Mitgliedern eine Auszahlung -ihrer Internet-Währung -Wernis -auf ihr WDS66-Hauptaccount überweisen lassen. Sie als -Wernis-Anbieter brauchen dazu selbstverständlich ein Wernis-Account -mit einem API-Account. Mehr dazu auf -www.wds66.com -. Damit Ihr System einheitlicher ist, sollten Sie unter -Sonstige Einstellungen -die Währung Ihres {!MT_WORD2!} von {!POINTS!} auf Wernis umstellen. +ihrer Internet-Währung Wernis auf ihr +WDS66-Hauptaccount überweisen lassen. Sie als Wernis-Anbieter brauchen +dazu selbstverständlich ein Wernis-Account mit einem API-Account. Mehr +dazu auf www.wds66.com. Wenn Sie möchten, können Sie auch +ganz zu Wernis wechseln. Sie unter Sonstige +Einstellungen die Währung Ihres {!MT_WORD2!} von {!POINTS!} auf Wernis +umstellen. diff --git a/templates/de/html/guest/guest_menu_bottom.tpl b/templates/de/html/guest/guest_menu_bottom.tpl index 700c71c524..cff0c9a227 100644 --- a/templates/de/html/guest/guest_menu_bottom.tpl +++ b/templates/de/html/guest/guest_menu_bottom.tpl @@ -1,3 +1,3 @@ - - $content - \ No newline at end of file + + $content[menu] + diff --git a/templates/de/html/guest/guest_menu_row.tpl b/templates/de/html/guest/guest_menu_row.tpl index af1c144a80..856c660ab2 100644 --- a/templates/de/html/guest/guest_menu_row.tpl +++ b/templates/de/html/guest/guest_menu_row.tpl @@ -1,3 +1,3 @@ - - $content - \ No newline at end of file + + $content[menu] + diff --git a/templates/de/html/guest/guest_menu_title.tpl b/templates/de/html/guest/guest_menu_title.tpl index 518f4e585b..f40a066e99 100644 --- a/templates/de/html/guest/guest_menu_title.tpl +++ b/templates/de/html/guest/guest_menu_title.tpl @@ -1,4 +1,5 @@ - - ::: $content ::: - - \ No newline at end of file + + + ::: $content[title] ::: + + diff --git a/templates/de/html/member/member_menu_bottom.tpl b/templates/de/html/member/member_menu_bottom.tpl index 17830d522d..f17f94675c 100644 --- a/templates/de/html/member/member_menu_bottom.tpl +++ b/templates/de/html/member/member_menu_bottom.tpl @@ -1,3 +1,3 @@ - $content - \ No newline at end of file + $content[menu] + diff --git a/templates/de/html/member/member_menu_row.tpl b/templates/de/html/member/member_menu_row.tpl index c0ee533a78..9dc45d750b 100644 --- a/templates/de/html/member/member_menu_row.tpl +++ b/templates/de/html/member/member_menu_row.tpl @@ -1,3 +1,3 @@ - - $content - \ No newline at end of file + + $content[menu] + diff --git a/templates/de/html/member/member_menu_title.tpl b/templates/de/html/member/member_menu_title.tpl index 4836b9fde0..db1d0fd7a2 100644 --- a/templates/de/html/member/member_menu_title.tpl +++ b/templates/de/html/member/member_menu_title.tpl @@ -1,4 +1,5 @@ - - ::: $content ::: - - \ No newline at end of file + + + ::: $content[title] ::: + + diff --git a/templates/de/html/member/member_wernis_form.tpl b/templates/de/html/member/member_wernis_form.tpl index b9de6fa55f..3909da6654 100644 --- a/templates/de/html/member/member_wernis_form.tpl +++ b/templates/de/html/member/member_wernis_form.tpl @@ -1,48 +1,48 @@ -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
{--WERNIS_NOW_TITLE--}
 
{--WERNIS_MAX_WERNIS--}: {!WERNIS_MAX_VALUE!}
{--WERNIS_WANT_WERNIS--}: 
{--WERNIS_TARGET_ACCOUNT--}: 
{--WERNIS_OPTIONAL_PASSWORD--}: 
 
-
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
{--WERNIS_NOW_TITLE--}
 
{--WERNIS_MAX_WERNIS--}: {!WERNIS_MAX_VALUE!}
{--WERNIS_WANT_WERNIS--}: 
{--WERNIS_TARGET_ACCOUNT--}: 
{--WERNIS_OPTIONAL_PASSWORD--}: 
 
+
-
{--WERNIS_MEMBER_NOTE--}
+
{--WERNIS_MEMBER_NOTE--}

-{--WERNIS_REMEMBER_TERMS--} -
+{--WERNIS_REMEMBER_TERMS--} +
diff --git a/templates/de/html/member/member_wernis_mode_choose.tpl b/templates/de/html/member/member_wernis_mode_choose.tpl new file mode 100644 index 0000000000..b5ba087fe4 --- /dev/null +++ b/templates/de/html/member/member_wernis_mode_choose.tpl @@ -0,0 +1,18 @@ + + + + + + + + +
+ {--MEMBER_WERNIS_MODE_CHOOSE--}
+ $content[withdraw_link] + + $content[payout_link] +
+ +

+ {--WERNIS_MEMBER_NO_ACCOUNT--} +

diff --git a/templates/de/html/member/member_wernis_mode_list.tpl b/templates/de/html/member/member_wernis_mode_list.tpl index 4eca22651d..aa0e8e62cf 100644 --- a/templates/de/html/member/member_wernis_mode_list.tpl +++ b/templates/de/html/member/member_wernis_mode_list.tpl @@ -1,20 +1,19 @@ - - - - - - - - - - +
- {--WERNIS_MEMBER_LIST_WERNIS--} -
{--WERNIS_TOTAL_WERNIS--}{--WERNIS_ACCOUNT--}{--WERNIS_TIMESTAMP--}{--WERNIS_MEMBER_STATUS--}
+ + + + + + + + + $content[rows] - - + - -
+ {--WERNIS_MEMBER_LIST_WERNIS--} +
{--WERNIS_TOTAL_WERNIS--}{--WERNIS_ACCOUNT--}{--WERNIS_TIMESTAMP--}{--WERNIS_MEMBER_STATUS--}
+ + + diff --git a/templates/de/html/member/member_wernis_mode_list_row.tpl b/templates/de/html/member/member_wernis_mode_list_row.tpl index 976dcfb0a4..121a4a4c5a 100644 --- a/templates/de/html/member/member_wernis_mode_list_row.tpl +++ b/templates/de/html/member/member_wernis_mode_list_row.tpl @@ -1,6 +1,6 @@ - - $content[points] Wernis - $content[acc] - $content[stamp] - $content[status] - + + $content[points] Wernis + $content[acc] + $content[stamp] + $content[status] + diff --git a/templates/de/html/member/member_wernis_mode_pay.tpl b/templates/de/html/member/member_wernis_mode_pay.tpl deleted file mode 100644 index 061c395197..0000000000 --- a/templates/de/html/member/member_wernis_mode_pay.tpl +++ /dev/null @@ -1,47 +0,0 @@ -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
{--WERNIS_MEMBER_PAYOUT_TITLE--}
{--WERNIS_MEMBER_PAYOUT_POINTS--} $content[points] Wernis
{--WERNIS_MEMBER_PAYOUT_MIN_POINTS--} $content[min_points] Wernis
 
{--WERNIS_MEMBER_WDS66_ID--} 
{--WERNIS_MEMBER_WDS66_PASSWORD--} 
{--WERNIS_MEMBER_WDS66_AMOUNT--} 
 
-
- {--WERNIS_MEMBER_PAYOUT_NOTE--} -
diff --git a/templates/de/html/member/member_wernis_mode_payout.tpl b/templates/de/html/member/member_wernis_mode_payout.tpl new file mode 100644 index 0000000000..9047c5b138 --- /dev/null +++ b/templates/de/html/member/member_wernis_mode_payout.tpl @@ -0,0 +1,55 @@ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
{--WERNIS_MEMBER_PAYOUT_TITLE--}
{--WERNIS_MEMBER_PAYOUT_POINTS--} $content[points] Wernis
{--WERNIS_MEMBER_PAYOUT_MIN_POINTS--} $content[min_points] Wernis
 
{--WERNIS_MEMBER_WDS66_ID--} 
{--WERNIS_MEMBER_WDS66_PASSWORD--} 
{--WERNIS_MEMBER_WDS66_AMOUNT--} 
 
+
+{--WERNIS_MEMBER_PAYOUT_NOTE--} +
+ +
+ Die Umrechnung von {!POINTS!} in Wernis enspricht derzeit $content[payout_factor]:1. + Das auszahlungsfähige {!POINTS!}-Guthaben ist entweder um eine + prozentuale Gebühr von $content[payout_fee_percent]% + oder um einen fixen Betrag von $content[payout_fee_fix] {!POINTS!} + bereits reduziert. +
diff --git a/templates/de/html/member/member_wernis_mode_withdraw.tpl b/templates/de/html/member/member_wernis_mode_withdraw.tpl new file mode 100644 index 0000000000..2557a47e33 --- /dev/null +++ b/templates/de/html/member/member_wernis_mode_withdraw.tpl @@ -0,0 +1,51 @@ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ {--WERNIS_MEMBER_WITHDRAW_TITLE--} +
{--WERNIS_MEMBER_WITHDRAW_POINTS_ACCOUNT--} $content[points] Wernis
{--WERNIS_MEMBER_WITHDRAW_MIN_POINTS--} $content[min_points] Wernis
 
{--WERNIS_MEMBER_WDS66_ID--} 
{--WERNIS_MEMBER_WDS66_PASSWORD--} 
{--WERNIS_MEMBER_WDS66_AMOUNT--} 
 
+
+{--WERNIS_MEMBER_WITHDRAW_NOTE--} +
+ +
+