]> git.mxchange.org Git - mailer.git/commitdiff
Initial non-working import for Primera, Wernis now as static word
authorRoland Häder <roland@mxchange.org>
Tue, 9 Sep 2008 19:53:18 +0000 (19:53 +0000)
committerRoland Häder <roland@mxchange.org>
Tue, 9 Sep 2008 19:53:18 +0000 (19:53 +0000)
30 files changed:
.gitattributes
inc/extensions/ext-primera.php [new file with mode: 0644]
inc/extensions/ext-wernis.php
inc/language/primera_de.php [new file with mode: 0644]
inc/language/wernis_de.php
inc/libs/primera_functions.php [new file with mode: 0644]
inc/modules/admin/action-primera.php [new file with mode: 0644]
inc/modules/admin/what-config_primera.php [new file with mode: 0644]
inc/modules/admin/what-list_primera.php [new file with mode: 0644]
inc/modules/member/what-primera.php [new file with mode: 0644]
templates/de/emails/admin/admin_wernis_request.tpl
templates/de/emails/member/member_wernis_rejected.tpl
templates/de/emails/member/member_wernis_request.tpl
templates/de/html/admin/admin_config_primera.tpl [new file with mode: 0644]
templates/de/html/admin/admin_config_wernis.tpl
templates/de/html/admin/admin_list_primera_main.tpl [new file with mode: 0644]
templates/de/html/admin/admin_list_primera_row.tpl [new file with mode: 0644]
templates/de/html/ext/ext_primera.tpl [new file with mode: 0644]
templates/de/html/ext/ext_wernis.tpl
templates/de/html/member/member_primera.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_form.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_mode_choose.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_mode_list.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_mode_list_row.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_mode_pay.tpl [new file with mode: 0644]
templates/de/html/member/member_primera_mode_withdraw.tpl [new file with mode: 0644]
templates/de/html/member/member_wernis_mode_list_row.tpl
templates/de/html/member/member_wernis_mode_pay.tpl
templates/de/html/member/member_wernis_mode_withdraw.tpl
templates/de/html/member/member_wernis_row.tpl

index 0eca02c90b77089ceac33ecb47cbab38128b6536..99dc328357f4d142ee1167e2e1c35449bb46944d 100644 (file)
@@ -113,6 +113,7 @@ inc/extensions/ext-optimize.php -text
 inc/extensions/ext-order.php -text
 inc/extensions/ext-other.php -text
 inc/extensions/ext-payout.php -text
+inc/extensions/ext-primera.php -text
 inc/extensions/ext-profile.php -text
 inc/extensions/ext-rallye.php -text
 inc/extensions/ext-register.php -text
@@ -165,6 +166,7 @@ inc/language/optimize_de.php -text
 inc/language/order_de.php -text
 inc/language/other_de.php -text
 inc/language/payout_de.php -text
+inc/language/primera_de.php -text
 inc/language/rallye_de.php -text
 inc/language/register_de.php -text
 inc/language/repair_de.php -text
@@ -194,6 +196,7 @@ inc/libs/optimize_functions.php -text
 inc/libs/order_functions.php -text
 inc/libs/output_functions.php -text
 inc/libs/payout_functions.php -text
+inc/libs/primera_functions.php -text
 inc/libs/rallye_functions.php -text
 inc/libs/register_functions.php -text
 inc/libs/rewrite_functions.php -text
@@ -233,6 +236,7 @@ inc/modules/admin/action-misc.php -text
 inc/modules/admin/action-mods.php -text
 inc/modules/admin/action-newsletter.php -text
 inc/modules/admin/action-payouts.php -text
+inc/modules/admin/action-primera.php -text
 inc/modules/admin/action-rallye.php -text
 inc/modules/admin/action-repair.php -text
 inc/modules/admin/action-setup.php -text
@@ -286,6 +290,7 @@ inc/modules/admin/what-config_order.php -text
 inc/modules/admin/what-config_other.php -text
 inc/modules/admin/what-config_payouts.php -text
 inc/modules/admin/what-config_points.php -text
+inc/modules/admin/what-config_primera.php -text
 inc/modules/admin/what-config_proxy.php -text
 inc/modules/admin/what-config_rallye_prices.php -text
 inc/modules/admin/what-config_refid.php -text
@@ -331,6 +336,7 @@ inc/modules/admin/what-list_links.php -text
 inc/modules/admin/what-list_newsletter.php -text
 inc/modules/admin/what-list_norefs.php -text
 inc/modules/admin/what-list_payouts.php -text
+inc/modules/admin/what-list_primera.php -text
 inc/modules/admin/what-list_rallyes.php -text
 inc/modules/admin/what-list_refs.php -text
 inc/modules/admin/what-list_sponsor.php -text
@@ -442,6 +448,7 @@ inc/modules/member/what-nickname.php -text
 inc/modules/member/what-order.php -text
 inc/modules/member/what-payout.php -text
 inc/modules/member/what-points.php -text
+inc/modules/member/what-primera.php -text
 inc/modules/member/what-rallyes.php -text
 inc/modules/member/what-reflinks.php -text
 inc/modules/member/what-sponsor.php -text
@@ -789,6 +796,7 @@ templates/de/html/admin/admin_config_payouts_edit_row.tpl -text
 templates/de/html/admin/admin_config_payouts_row.tpl -text
 templates/de/html/admin/admin_config_point_settings.tpl -text
 templates/de/html/admin/admin_config_points.tpl -text
+templates/de/html/admin/admin_config_primera.tpl -text
 templates/de/html/admin/admin_config_proxy.tpl -text
 templates/de/html/admin/admin_config_rallye_del.tpl -text
 templates/de/html/admin/admin_config_rallye_del_row.tpl -text
@@ -902,6 +910,8 @@ templates/de/html/admin/admin_list_payouts.tpl -text
 templates/de/html/admin/admin_list_payouts_banner.tpl -text
 templates/de/html/admin/admin_list_payouts_row.tpl -text
 templates/de/html/admin/admin_list_payouts_txt.tpl -text
+templates/de/html/admin/admin_list_primera_main.tpl -text
+templates/de/html/admin/admin_list_primera_row.tpl -text
 templates/de/html/admin/admin_list_rallye_noselect.tpl -text
 templates/de/html/admin/admin_list_rallye_prices.tpl -text
 templates/de/html/admin/admin_list_rallye_prices_row.tpl -text
@@ -1088,6 +1098,7 @@ templates/de/html/ext/ext_optimize.tpl -text
 templates/de/html/ext/ext_order.tpl -text
 templates/de/html/ext/ext_other.tpl -text
 templates/de/html/ext/ext_payout.tpl -text
+templates/de/html/ext/ext_primera.tpl -text
 templates/de/html/ext/ext_profile.tpl -text
 templates/de/html/ext/ext_rallye.tpl -text
 templates/de/html/ext/ext_register.tpl -text
@@ -1247,6 +1258,13 @@ templates/de/html/member/member_points_bonus_disabled.tpl -text
 templates/de/html/member/member_points_bonus_rows.tpl -text
 templates/de/html/member/member_points_row.tpl -text
 templates/de/html/member/member_points_upgrade.tpl -text
+templates/de/html/member/member_primera.tpl -text
+templates/de/html/member/member_primera_form.tpl -text
+templates/de/html/member/member_primera_mode_choose.tpl -text
+templates/de/html/member/member_primera_mode_list.tpl -text
+templates/de/html/member/member_primera_mode_list_row.tpl -text
+templates/de/html/member/member_primera_mode_pay.tpl -text
+templates/de/html/member/member_primera_mode_withdraw.tpl -text
 templates/de/html/member/member_receive_table.tpl -text
 templates/de/html/member/member_reflinks_row.tpl -text
 templates/de/html/member/member_reflinks_table.tpl -text
diff --git a/inc/extensions/ext-primera.php b/inc/extensions/ext-primera.php
new file mode 100644 (file)
index 0000000..cc86024
--- /dev/null
@@ -0,0 +1,130 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 09/09/2008 *
+ * ================                             Last change: 09/09/2008 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : ext-primera.php                                  *
+ * -------------------------------------------------------------------- *
+ * Short description : Payout extension                                 *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Auszahlung-Erweiterung                           *
+ * -------------------------------------------------------------------- *
+ * Modified payout extension! See: http://www.mxchange.org for details  *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (ereg(basename(__FILE__), $_SERVER['PHP_SELF']))
+{
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+// Version of this extension
+$EXT_VERSION = "0.0";
+
+// 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");
+
+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[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_user_primera";
+       $SQLs[] = "CREATE TABLE "._MYSQL_PREFIX."_user_primera (
+id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
+userid BIGINT(20) UNSIGNED NOT NULL DEFAULT '0',
+primera_account VARCHAR(255) NOT NULL DEFAULT '',
+primera_amount DOUBLE(22,5) UNSIGNED NOT NULL DEFAULT '0.00000',
+primera_timestamp VARCHAR(10) NOT NULL DEFAULT '0',
+primera_type ENUM('IN','OUT', 'FAILED') NOT NULL DEFAULT 'FAILED',
+primera_api_message TINYTEXT,
+primera_api_status VARCHAR(255) NULL DEFAULT NULL,
+KEY(userid),
+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_api_name VARCHAR(255) NOT NULL DEFAULT ''";
+       $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_config ADD primera_api_md5 VARCHAR(32) NOT NULL DEFAULT ''";
+
+       // User data
+       $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD primera_userid VARCHAR(255) NOT NULL DEFAULT ''";
+
+       // Admin menu
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('primera', NULL, 'Primera-Management', 'Konfiguration zur Primera-API einstellen, Auszahlungen auflisten usw..', 15)";
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('primera', 'config_primera', 'Primera-API-Einstellungen', 'Konfiguration zur Primera-API einstellen.', 1)";
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('primera', 'list_primera', 'Primera-Anfragen auflisten', 'Listet alle Primera-Auszahlungsanfragen Ihrer Mitglieder auf.', 2)";
+
+       // Member menu
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, visible, locked, sort) VALUES('main', 'primera', 'Primera-Ein-/Auszahlungen', 'N', 'N', '11')";
+       break;
+
+case "remove": // Do stuff when removing extension
+       // SQL commands to run
+       $SQLs[] = "DROP TABLE IF EXISTS "._MYSQL_PREFIX."_user_primera";
+       $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_admin_menu WHERE action='primera'";
+       $SQLs[] = "DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_member_menu WHERE action='main' AND what='primera' LIMIT 1";
+       break;
+
+case "activate": // Do stuff when admin activates this extension
+       // SQL commands to run
+       $SQLs[] = "UPDATE "._MYSQL_PREFIX."_member_menu SET visible='Y', locked='N' WHERE action='main' AND what='primera' LIMIT 1";
+       break;
+
+case "deactivate": // Do stuff when admin deactivates this extension
+       // SQL commands to run
+       $SQLs[] = "UPDATE "._MYSQL_PREFIX."_member_menu SET visible='Y', locked='Y' WHERE action='main' AND what='primera' LIMIT 1";
+       break;
+
+case "update": // Update an extension
+       switch ($EXT_VER)
+       {
+       case "0.0.1": // SQL queries for v0.0.1
+               // Update notes (these will be set as task text!)
+               $UPDATE_NOTES = "";
+               break;
+       }
+       break;
+
+default: // Do stuff when extension is loaded
+       $dummy = LOAD_CONFIG();
+       $_CONFIG = merge_array($_CONFIG, $dummy);
+       unset($dummy);
+       break;
+}
+// Language file prefix
+$EXT_LANG_PREFIX = "primera";
+
+// Extension is always active?
+$EXT_ALWAYS_ACTIVE = "N";
+
+// Init array
+global $primera;
+$primera = array();
+
+//
+?>
index 97c0b4ce9d0eefc772c41fdc30906b89eb7765fa..6ad1238c1029a267e64ce3ef947b9cc7e164df21 100644 (file)
@@ -64,17 +64,25 @@ wernis_api_status VARCHAR(255) NULL DEFAULT NULL,
 KEY(userid),
 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_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 ''";
+
+       // User data
        $SQLs[] = "ALTER TABLE "._MYSQL_PREFIX."_user_data ADD wernis_userid VARCHAR(6) NOT NULL DEFAULT ''";
-       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('wernis', NULL, '{!POINTS!}-Management', 'Konfiguration zur WDS66-API einstellen, Auszahlungen auflisten usw..', 15)";
+
+       // Admin menu
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('wernis', NULL, 'Wernis-Management', 'Konfiguration zur WDS66-API einstellen, Auszahlungen auflisten usw..', 15)";
        $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('wernis', 'config_wernis', 'WDS66-API-Einstellungen', 'Konfiguration zur WDS66-API einstellen.', 1)";
-       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('wernis', 'list_wernis', '{!POINTS!}-Anfragen auflisten', 'Listet alle {!POINTS!}-Auszahlungsanfragen Ihrer Mitglieder auf.', 2)";
-       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, visible, locked, sort) VALUES('main', 'wernis', '{!POINTS!}-Ein-/Auszahlungen', 'N', 'N', '11')";
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_admin_menu (action, what, title, descr, sort) VALUES('wernis', 'list_wernis', 'Wernis-Anfragen auflisten', 'Listet alle Wernis-Auszahlungsanfragen Ihrer Mitglieder auf.', 2)";
+
+       // Member menu
+       $SQLs[] = "INSERT INTO "._MYSQL_PREFIX."_member_menu (action, what, title, visible, locked, sort) VALUES('main', 'wernis', 'Wernis-Ein-/Auszahlungen', 'N', 'N', '11')";
        break;
 
 case "remove": // Do stuff when removing extension
@@ -106,12 +114,7 @@ case "update": // Update an extension
 
 default: // Do stuff when extension is loaded
        $dummy = LOAD_CONFIG();
-       $_CONFIG['wernis_min_payout']           = $dummy['wernis_min_payout'];
-       $_CONFIG['wernis_min_withdraw'] = $dummy['wernis_min_withdraw'];
-       $_CONFIG['wernis_api_id']                       = $dummy['wernis_api_id'];
-       $_CONFIG['wernis_api_md5']                      = $dummy['wernis_api_md5'];
-       $_CONFIG['wernis_api_url']                      = $dummy['wernis_api_url'];
-       $_CONFIG['wernis_refid']                        = $dummy['wernis_refid'];
+       $_CONFIG = merge_array($_CONFIG, $dummy);
        unset($dummy);
        break;
 }
diff --git a/inc/language/primera_de.php b/inc/language/primera_de.php
new file mode 100644 (file)
index 0000000..716acd6
--- /dev/null
@@ -0,0 +1,117 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 04/11/2004 *
+ * ===============                              Last change: 08/12/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : primera_de.php                                   *
+ * -------------------------------------------------------------------- *
+ * Short description : German langugage support                         *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Deutsche Sprachunterstuetzung                    *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (basename($_SERVER['PHP_SELF']) == basename(__FILE__)) {
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+// Language definitions
+define('TASK_ADMIN_LIST_PRIMERA_ALL', "Alle Primera-Ein-/Auszahlungen");
+define('TASK_ADMIN_LIST_PRIMERA_ALL_TITLE', "Listet alle Primera-Ein- und Auszahlungen auf.");
+define('PRIMERA_ADMIN_CONFIG_TITLE', "Einstellungen zum Primus-Portal:");
+define('PRIMERA_ADMIN_MIN_PAYOUT', "Minimumguthaben f&uuml;r Auszahlungen.");
+define('PRIMERA_ADMIN_MIN_WITHDRAW', "Minimumguthaben f&uuml;r Einzahlungen.");
+define('PRIMERA_ADMIN_API_NAME', "Primus-Nickname ()");
+define('PRIMERA_ADMIN_API_MD5', "Primera-Account Passwort (Wird als MD5-Hash gespeichert)");
+define('PRIMERA_ADMIN_CONFIG_NOTE', "<A href=\"http://www.primusportal.de/r/Quix0r\" target=\"_blank\">Hier</A> k&ouml;nnen Sie sich ein Primus-Portal-Account holen. <strong>Geben Sie immer Ihren Usernamen von Primus-Portal ein und &uuml;berpr&uuml;fen Sie diesen mehrmals! Er wird zum &Uuml;berweisen von Primera ben&ouml;tigt.");
+define('PRIMERA_ADMIN_NO_TRANSFERS', "Derzeit keine Primera transferiert!");
+define('PRIMERA_ADMIN_ACCOUNT', "Account bei Primus-Portal");
+define('PRIMERA_ADMIN_TRANSFERED', "Primera transferiert");
+define('PRIMERA_ADMIN_TIMESTAMP', "Zeitpunkt &Uuml;berweisung");
+define('PRIMERA_ADMIN_TYPE', "&Uuml;berweisungsrichtung");
+define('PRIMERA_ADMIN_API_MESSAGE', "Nachricht von Primus-API");
+define('PRIMERA_ADMIN_API_STATUS', "Status von Primus-API");
+define('MEMBER_PRIMERA_MODE_CHOOSE', "M&ouml;chten Sie Primera zu Ihrem Primus-Portal ausbezahlt bekommen oder Primera hier einzahlen?");
+define('MEMBER_PRIMERA_MODE_CHOOSE2', "Hier klicken um neue &Uuml;berweisung zu starten...");
+define('MEMBER_PRIMERA_MODE_WITHDRAW', "Primera einzahlen");
+define('MEMBER_PRIMERA_MODE_PAYOUT', "Primera auszahlen");
+define('PRIMERA_STATUS_UNKNWOWN', "Primera-Typ <u>%s</u> unbekannt.");
+define('PRIMERA_STATUS_WITHDRAW', "Einzahlung von Primus");
+define('PRIMERA_STATUS_PAYOUT', "Auszahlung an Primus");
+define('PRIMERA_STATUS_FAILED', "Fehlgeschlagen");
+define('PRIMERA_TIMESTAMP', "Buchungszeitmarke");
+define('PRIMERA_ACCOUNT', "Primus-Portal");
+define('PRIMERA_TOTAL_PRIMERA', "Gesamt &uuml;berwiesen");
+define('PRIMERA_MEMBER_LIST_PRIMERA', "&Uuml;berweisungsliste von/an Primus-Portal");
+
+// API messages
+define('PRIMERA_API_REQUEST_DATA_INVALID', "Interner Fehler: Abfragedaten sind defekt!");
+define('PRIMERA_API_REQUEST_DATA_MISSING', "Interner Fehler: Abfragedaten sind nicht komplett!");
+define('PRIMERA_API_REQUEST_ERROR', "Abfragefehler: <u>%s</u>");
+define('PRIMERA_API_REQUEST_FAILED', "Unbekannter Fehler <u>%s</u> von API erhalten! Bitte im [<A href=\"http://forum.mxchange.org\" target=\"_blank\" title=\"Direktlink zum Forum\">Forum melden</A>], den Fehlercode nennen und wie es dazu gekommen ist.");
+define('PRIMERA_API_REQUEST_FAILED_AUTH', "Authorisierung an API fehlgeschlagen! Bitte Primera-Nickname und Passwort &uuml;berpr&uuml;fen. [<A href=\"http://www.primusportal.de/\" target=\"_blank\" title=\"Direkt zum Primus-Exportaccount\">Hier</A>] direkt zum Primera-Account. Sie ben&ouml;tigen Ihren Usernamen und Passwort!");
+define('PRIMERA_API_REQUEST_FAILED_USER', "Useraccount nicht gefunden oder Primera-Passwort ist ung&uuml;ltig!");
+define('PRIMERA_API_REQUEST_FAILED_OWN', "&Uuml;berweisung an eigenes Account nicht m&ouml;glich.");
+define('PRIMERA_API_REQUEST_FAILED_AMOUNT', "Konto weist nicht gen&uuml;gend Deckung auf.");
+define('PRIMERA_API_REQUEST_FAILED_API_AMOUNT', "Primera-Account weist nicht gen&uuml;gend Deckung auf.");
+define('PRIMERA_API_PURPOSE_WITHDRAW', "Einzahlung auf {!MAIN_TITLE!} ({!URL!})");
+define('PRIMERA_API_PURPOSE_PAYOUT', "Auszahlung von {!MAIN_TITLE!} ({!URL!})");
+
+// Error messages
+define('PRIMERA_ERROR_STATUS', "Fehler-Status <u>%s</u> erhalten.");
+define('PRIMERA_UNKNOWN_ERROR', "Unbekannter Fehler aufgetreten!");
+
+// Member messages
+define('PRIMERA_MEMBER_NO_ACCOUNT', "Noch kein Primus-Account? Hier entlang!");
+define('PRIMERA_MEMBER_API_DATA_MISSING', "Diese Funktion kann derzeit nicht genutzt werden, da wir sie noch einrichten m&uuml;ssen.");
+define('PRIMERA_MEMBER_MIN_PAYOUT_PAYOUT', "Sie haben nicht gen&uuml;gend Primera zum Auszahlen! Mindestens: <u>%s</u> Primera.");
+define('PRIMERA_MEMBER_WITHDRAW_TITLE', "Primera bei {!MAIN_TITLE!} einzahlen:");
+define('PRIMERA_MEMBER_WITHDRAW_POINTS_ACCOUNT', "Primera hier im Account:");
+define('PRIMERA_MEMBER_WITHDRAW_MIN_POINTS', "Mindest einzuzahlendes Primera-Guthaben:");
+define('PRIMERA_MEMBER_WITHDRAW_SUBMIT', "Primera jetzt einzahlen");
+define('PRIMERA_MEMBER_WITHDRAW_NOTE', "Ihr Primera-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei Primera-Betrag nur gerade Betr&auml;ge eingeben! Ihr Primera-Account sollte ausreichend Deckung aufweisen!");
+define('PRIMERA_MEMBER_PAYOUT_TITLE', "Primera auf Ihr Portal-Account auszahlen");
+define('PRIMERA_MEMBER_PAYOUT_POINTS', "Auszahlf&auml;higes Primera-Guthaben");
+define('PRIMERA_MEMBER_PAYOUT_MIN_POINTS', "Mindestens auszuzahlendes Primera-Guthaben");
+define('PRIMERA_MEMBER_PAYOUT_SUBMIT', "Auszahlung durchf&uuml;hren");
+define('PRIMERA_MEMBER_PAYOUT_NOTE', "Ihr Primera-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei Primera-Betrag nur gerade Betr&auml;ge eingeben! &Uuml;berpr&uuml;fen Sie vor dem Absenden Ihren Primus-Usernamen.");
+define('PRIMERA_MEMBER_ID', "Username bei Primus-Portal: [<A href=\"http://www.primusportal.de/lost_password.php\" target=\"_blank\">Vergessen?</A>]");
+define('PRIMERA_MEMBER_PASSWORD', "Primera-Passwort (nicht Accountpasswort!): [<A href=\"http://www.primusportal.de/lost_password.php\" target=\"_blank\">Vergessen?</A>]");
+define('PRIMERA_MEMBER_AMOUNT', "Zu &uuml;berweisenden Betrag eingeben:");
+define('PRIMERA_MEMBER_MODE_INVALID', "Ung&uuml;ltiger Modus <u>%s</u> erkannt! Bitte links im Men&uuml; fortfahren.");
+define('PRIMERA_MEMBER_EMPTY_USERNAME', "Sie haben Ihren Primus-Usernamen nicht eingegeben.");
+define('PRIMERA_MEMBER_EMPTY_PASSWORD', "Sieh haben kein Primera-Passwort eingegeben.");
+define('PRIMERA_MEMBER_EMPTY_AMOUNT', "Sie haben keine zu &uuml;berweisende Betrag angegeben.");
+define('PRIMERA_MEMBER_INVALID_USERNAME', "Bitte nur Zahlen f&uuml;r den Primus-Usernamen eingeben!");
+define('PRIMERA_MEMBER_INVALID_AMOUNT', "Bitte nur Zahlen f&uuml;r den zu &uuml;berweisenden Betrag eingeben!");
+define('PRIMERA_MEMBER_AMOUNT_SMALLER_MIN', "Bitte geben Sie mindestens <u>%s</u> Primera an!");
+define('PRIMERA_MEMBER_WITHDRAW_FAILED', "Die Einzahlung hat nicht geklappt! R&uuml;ckmeldung f&uuml;r den Support: <em>%s</em>.");
+define('PRIMERA_MEMBER_WITHDRAW_DONE', "Einzahlung auf Ihr {!MAIN_TITLE!} Konto erfolgreich abgeschlossen. :-)");
+define('PRIMERA_MEMBER_PAYOUT_DONE', "Auszahlung auf Primus-Portal erfolgreich abgeschlossen. :-)");
+define('PRIMERA_MEMBER_PAYOUT_POINTS_DEPLETED', "Sie k&ouml;nnen nicht <u>%s</u> Primera auszahlen, da Sie nur <u>%s</u> &uuml;brig haben.");
+define('PRIMERA_MEMBER_STATUS', "&Uuml;berweisungsart");
+
+//
+?>
index d0b3f1fd49cdfb3abed8ebc51ef536ea8688cdf6..8e1d60718d8fdd314af967fc12fc5523e29d8c3f 100644 (file)
@@ -38,8 +38,8 @@ if (basename($_SERVER['PHP_SELF']) == basename(__FILE__)) {
 }
 
 // Language definitions
-define('TASK_ADMIN_LIST_WERNIS_ALL', "Alle {!POINTS!}-Ein-/Auszahlungen");
-define('TASK_ADMIN_LIST_WERNIS_ALL_TITLE', "Listet alle {!POINTS!}-Ein- und Auszahlungen auf.");
+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('WERNIS_ADMIN_CONFIG_TITLE', "Einstellungen zum WDS66-Hauptaccount:");
 define('WERNIS_ADMIN_MIN_PAYOUT', "Minimumguthaben f&uuml;r Auszahlungen.");
 define('WERNIS_ADMIN_MIN_WITHDRAW', "Minimumguthaben f&uuml;r Einzahlungen.");
@@ -47,19 +47,19 @@ 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', "<A href=\"http://www.wds66.com/ref.php?refid=10437\" target=\"_blank\">Hier</A> k&ouml;nnen Sie schon f&uuml;r <strong>5,00&euro;</strong>=<strong>25.000 Abfragen</strong> ein API-Account beantragen (dazu ist ein <strong>kostenloses</strong> {!POINTS!}-Account dennoch n&ouml;tig!) <strong>Geben Sie immer Ihren Usernamen von WDS66-Hauptaccount ein und &uuml;berpr&uuml;fen Sie diesen mehrmals! Er wird zum &Uuml;berweisen von {!POINTS!}/{!POINTS!} ben&ouml;tigt.");
-define('WERNIS_ADMIN_NO_TRANSFERS', "Derzeit keine {!POINTS!} transferiert!");
+define('WERNIS_ADMIN_CONFIG_NOTE', "<A href=\"http://www.wds66.com/ref.php?refid=10437\" target=\"_blank\">Hier</A> k&ouml;nnen Sie schon f&uuml;r <strong>5,00&euro;</strong>=<strong>25.000 Abfragen</strong> ein API-Account beantragen (dazu ist ein <strong>kostenloses</strong> Wernis-Account dennoch n&ouml;tig!) <strong>Geben Sie immer Ihren Usernamen von WDS66-Hauptaccount ein und &uuml;berpr&uuml;fen Sie diesen mehrmals! Er wird zum &Uuml;berweisen von Wernis/Wernis ben&ouml;tigt.");
+define('WERNIS_ADMIN_NO_TRANSFERS', "Derzeit keine Wernis transferiert!");
 define('WERNIS_ADMIN_WDS66_ACCOUNT', "Account bei WDS66-Portal");
-define('WERNIS_ADMIN_TRANSFERED', "{!POINTS!} transferiert");
+define('WERNIS_ADMIN_TRANSFERED', "Wernis transferiert");
 define('WERNIS_ADMIN_TIMESTAMP', "Zeitpunkt &Uuml;berweisung");
 define('WERNIS_ADMIN_TYPE', "&Uuml;berweisungsrichtung");
 define('WERNIS_ADMIN_API_MESSAGE', "Nachricht von WDS66-API");
 define('WERNIS_ADMIN_API_STATUS', "Status von WDS66-API");
-define('MEMBER_WERNIS_MODE_CHOOSE', "M&ouml;chten Sie {!POINTS!} zu Ihrem WDS66-Hauptaccount ausbezahlt bekommen oder {!POINTS!} hier einzahlen?");
+define('MEMBER_WERNIS_MODE_CHOOSE', "M&ouml;chten Sie Wernis zu Ihrem WDS66-Hauptaccount ausbezahlt bekommen oder Wernis hier einzahlen?");
 define('MEMBER_WERNIS_MODE_CHOOSE2', "Hier klicken um neue &Uuml;berweisung zu starten...");
-define('MEMBER_WERNIS_MODE_WITHDRAW', "{!POINTS!} einzahlen");
-define('MEMBER_WERNIS_MODE_PAYOUT', "{!POINTS!} auszahlen");
-define('WERNIS_STATUS_UNKNWOWN', "{!POINTS!}-Typ <u>%s</u> unbekannt.");
+define('MEMBER_WERNIS_MODE_WITHDRAW', "Wernis einzahlen");
+define('MEMBER_WERNIS_MODE_PAYOUT', "Wernis auszahlen");
+define('WERNIS_STATUS_UNKNWOWN', "Wernis-Typ <u>%s</u> unbekannt.");
 define('WERNIS_STATUS_WITHDRAW', "Einzahlung von WDS66");
 define('WERNIS_STATUS_PAYOUT', "Auszahlung an WDS66");
 define('WERNIS_STATUS_FAILED', "Fehlgeschlagen");
@@ -74,7 +74,7 @@ define('WERNIS_API_REQUEST_DATA_MISSING', "Interner Fehler: Abfragedaten sind ni
 define('WERNIS_API_REQUEST_ERROR', "Abfragefehler: <u>%s</u>");
 define('WERNIS_API_REQUEST_FAILED', "Unbekannter Fehler <u>%s</u> von API erhalten! Bitte im [<A href=\"http://forum.mxchange.org\" target=\"_blank\" title=\"Direktlink zum Forum\">Forum melden</A>], den Fehlercode nennen und wie es dazu gekommen ist.");
 define('WERNIS_API_REQUEST_FAILED_AUTH', "Authorisierung an API fehlgeschlagen! Bitte API-ID und Key &uuml;berpr&uuml;fen. [<A href=\"http://www.wds66.com/modules.php?module=export\" target=\"_blank\" title=\"Direkt zum WDS66-Exportaccount\">Hier</A>] direkt zum Export-Account. Sie ben&ouml;tigen Ihren Usernamen und Passwort!");
-define('WERNIS_API_REQUEST_FAILED_USER', "Useraccount nicht gefunden oder {!POINTS!}-Passwort ist ung&uuml;ltig!");
+define('WERNIS_API_REQUEST_FAILED_USER', "Useraccount nicht gefunden oder Wernis-Passwort ist ung&uuml;ltig!");
 define('WERNIS_API_REQUEST_FAILED_OWN', "&Uuml;berweisung an eigenes Account nicht m&ouml;glich.");
 define('WERNIS_API_REQUEST_FAILED_AMOUNT', "Konto weist nicht gen&uuml;gend Deckung auf.");
 define('WERNIS_API_REQUEST_FAILED_API_AMOUNT', "API-Konto weist nicht gen&uuml;gend Deckung auf.");
@@ -88,31 +88,31 @@ define('WERNIS_UNKNOWN_ERROR', "Unbekannter Fehler aufgetreten!");
 // Member messages
 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&uuml;ssen.");
-define('WERNIS_MEMBER_MIN_PAYOUT_PAYOUT', "Sie haben nicht gen&uuml;gend {!POINTS!} zum Auszahlen! Mindestens: <u>%s</u> {!POINTS!}.");
-define('WERNIS_MEMBER_WITHDRAW_TITLE', "{!POINTS!} bei {!MAIN_TITLE!} einzahlen:");
-define('WERNIS_MEMBER_WITHDRAW_POINTS_ACCOUNT', "{!POINTS!} hier im Account:");
-define('WERNIS_MEMBER_WITHDRAW_MIN_POINTS', "Mindest einzuzahlendes {!POINTS!}-Guthaben:");
-define('WERNIS_MEMBER_WITHDRAW_SUBMIT', "{!POINTS!} jetzt einzahlen");
-define('WERNIS_MEMBER_WITHDRAW_NOTE', "Ihr {!POINTS!}-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei {!POINTS!}-Betrag nur gerade Betr&auml;ge eingeben! Ihr WDS66-Konto sollte ausreichend Deckung aufweisen!");
-define('WERNIS_MEMBER_PAYOUT_TITLE', "{!POINTS!} auf Ihr WDS66-Hauptaccount auszahlen");
-define('WERNIS_MEMBER_PAYOUT_POINTS', "Auszahlf&auml;higes {!POINTS!}-Guthaben");
-define('WERNIS_MEMBER_PAYOUT_MIN_POINTS', "Mindestens auszuzahlendes {!POINTS!}-Guthaben");
+define('WERNIS_MEMBER_MIN_PAYOUT_PAYOUT', "Sie haben nicht gen&uuml;gend Wernis zum Auszahlen! Mindestens: <u>%s</u> 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:");
+define('WERNIS_MEMBER_WITHDRAW_SUBMIT', "Wernis jetzt einzahlen");
+define('WERNIS_MEMBER_WITHDRAW_NOTE', "Ihr Wernis-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei Wernis-Betrag nur gerade Betr&auml;ge eingeben! Ihr WDS66-Konto sollte ausreichend Deckung aufweisen!");
+define('WERNIS_MEMBER_PAYOUT_TITLE', "Wernis auf Ihr WDS66-Hauptaccount auszahlen");
+define('WERNIS_MEMBER_PAYOUT_POINTS', "Auszahlf&auml;higes Wernis-Guthaben");
+define('WERNIS_MEMBER_PAYOUT_MIN_POINTS', "Mindestens auszuzahlendes Wernis-Guthaben");
 define('WERNIS_MEMBER_PAYOUT_SUBMIT', "Auszahlung durchf&uuml;hren");
-define('WERNIS_MEMBER_PAYOUT_NOTE', "Ihr {!POINTS!}-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei {!POINTS!}-Betrag nur gerade Betr&auml;ge eingeben! &Uuml;berpr&uuml;fen Sie vor dem Absenden Ihren WDS66-Usernamen.");
+define('WERNIS_MEMBER_PAYOUT_NOTE', "Ihr Wernis-Passwort wird bei {!MAIN_TITLE!} nicht gespeichert. Bitte bei Wernis-Betrag nur gerade Betr&auml;ge eingeben! &Uuml;berpr&uuml;fen Sie vor dem Absenden Ihren WDS66-Usernamen.");
 define('WERNIS_MEMBER_WDS66_ID', "Username bei WDS66-Portal: [<A href=\"http://www.wds66.com/modules.php?module=wpass&amp;mode=new\" target=\"_blank\">Vergessen?</A>]");
-define('WERNIS_MEMBER_WDS66_PASSWORD', "{!POINTS!}-Passwort (nicht Accountpasswort!): [<A href=\"http://www.wds66.com/modules.php?module=wpass&amp;mode=new\" target=\"_blank\">Vergessen?</A>]");
+define('WERNIS_MEMBER_WDS66_PASSWORD', "Wernis-Passwort (nicht Accountpasswort!): [<A href=\"http://www.wds66.com/modules.php?module=wpass&amp;mode=new\" target=\"_blank\">Vergessen?</A>]");
 define('WERNIS_MEMBER_WDS66_AMOUNT', "Zu &uuml;berweisenden Betrag eingeben:");
 define('WERNIS_MEMBER_MODE_INVALID', "Ung&uuml;ltiger Modus <u>%s</u> erkannt! Bitte links im Men&uuml; fortfahren.");
 define('WERNIS_MEMBER_EMPTY_USERNAME', "Sie haben Ihren WDS66-Usernamen nicht eingegeben.");
-define('WERNIS_MEMBER_EMPTY_PASSWORD', "Sieh haben kein {!POINTS!}-Passwort eingegeben.");
+define('WERNIS_MEMBER_EMPTY_PASSWORD', "Sieh haben kein Wernis-Passwort eingegeben.");
 define('WERNIS_MEMBER_EMPTY_AMOUNT', "Sie haben keine zu &uuml;berweisende Betrag angegeben.");
 define('WERNIS_MEMBER_INVALID_USERNAME', "Bitte nur Zahlen f&uuml;r den WDS66-Usernamen eingeben!");
 define('WERNIS_MEMBER_INVALID_AMOUNT', "Bitte nur Zahlen f&uuml;r den zu &uuml;berweisenden Betrag eingeben!");
-define('WERNIS_MEMBER_AMOUNT_SMALLER_MIN', "Bitte geben Sie mindestens <u>%s</u> {!POINTS!} an!");
+define('WERNIS_MEMBER_AMOUNT_SMALLER_MIN', "Bitte geben Sie mindestens <u>%s</u> Wernis an!");
 define('WERNIS_MEMBER_WITHDRAW_FAILED', "Die Einzahlung hat nicht geklappt! R&uuml;ckmeldung f&uuml;r den Support: <em>%s</em>.");
 define('WERNIS_MEMBER_WITHDRAW_DONE', "Einzahlung auf Ihr {!MAIN_TITLE!} Konto erfolgreich abgeschlossen. :-)");
 define('WERNIS_MEMBER_PAYOUT_DONE', "Auszahlung auf WDS66-Hauptaccount erfolgreich abgeschlossen. :-)");
-define('WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED', "Sie k&ouml;nnen nicht <u>%s</u> {!POINTS!} auszahlen, da Sie nur <u>%s</u> &uuml;brig haben.");
+define('WERNIS_MEMBER_PAYOUT_POINTS_DEPLETED', "Sie k&ouml;nnen nicht <u>%s</u> Wernis auszahlen, da Sie nur <u>%s</u> &uuml;brig haben.");
 define('WERNIS_MEMBER_STATUS', "&Uuml;berweisungsart");
 
 //
diff --git a/inc/libs/primera_functions.php b/inc/libs/primera_functions.php
new file mode 100644 (file)
index 0000000..c28da8c
--- /dev/null
@@ -0,0 +1,218 @@
+<?php
+/**
+ * PrimusInterface
+ * -------------------------------------------
+ * Mit dieser Klasse ist ein einfacher Primeratransfer von Ihrem Account
+ * zu dem Account eines bei Primusportal.de registrierten Mitglieds möglich.
+ *
+ *------------------ Aenderungen durch Roland Haeder 09.08.2008 ----------------
+ * Klasse umbenannt nach PrimeraApi, damit sie in das Framework besser passt.
+ * Zudem sind alle oeffentlichen Attribute nun privat, der Konstruktor hat den
+ * neuen "magischen" Namen __construct() und "normale" Konstanten sind nach
+ * Klassenkonstanten umbenannt. Unsinnige else-Bloecke sind noch umgewandelt.
+ * Methodennamen fangen nun immer mit einem kleinen Buchstaben an. Zudem sind
+ * die Methoden Pay,Query und Parse umbenannt.
+ *------------------ Aenderungen durch Roland Haeder 09.08.2008 ----------------
+ *
+ * Die Einbindung des Interfaces geschieht folgendermaßen:
+ *  1. Einbindung der Klasse in Ihr PHP-Auszahlungsskript:
+ *     CODE:
+ *       require_once( "PFAD/ZU/DER/KLASSE/PrimusInterface.class.php" );
+ *       $PPUsername = "username"; // Ihr Username bei Primusportal
+ *       $PPPassword = "passwort"; // Ihr Passwort bei Primusportal
+ *
+ *       $Interface = new PrimusInterface($PPUsername, $PPPassword);
+ *  2. Durchführen einer Auszahlung:
+ *     CODE:
+ *       $Status = $Interface->payPrimera($PayReceiver, $PayAmount, $PayDescription);
+ *
+ *     Wobei $PayReicer der Username des Empfängers bei
+ *     Primusportal.de ist. $PayAmount ist der gerundete( !! ) Betrag an Primera,
+ *     die der Empfänger erhalten soll. $PayDescription ist eine von Ihnen 
+ *     festgelegte kurze Beschreibung. Die Länge dieses Textes darf 100 Zeichen
+ *     nicht überschreiten. Beispiel:
+ *       $status = $Interface->payPrimera("garbage", 10000, "Auszahlung IhreSeite.de - ID: 12345");
+ *  3. Überprüfung des Status (Rückgabecode):
+ *     CODE:
+ *       if (!$status) {
+ *         // Ein Fehler ist aufgetreten
+ *     // Fehlerbehandlung hier einfügen...
+ *       }else {
+ *         // Auszahlung erfolgreich durchgeführt
+ *         // Führen Sie hier Ihre Datenbankabfragen durch, um die Auszahlung zu
+ *         // bestätigen...
+ *       }
+ *
+ *     Die komplette Rückgabe des Interfaces wird als assoziatives Array in der Klassen-
+ *     variable __data gespeichert:
+ *     __data => array("status" => Rückgabecode (PI_DONE, PI_SENDER_ERROR, ...),
+ *                     "statustext" => Status in Worten (z.B.: "Transaktion erfolgreich durchgeführt"),
+ *                     ")
+ *
+ *
+ * @author             Andreas Schmidt <xxgarbagexx@web.de>
+ * @author             Roland Haeder <webmaster@ship-simu.org>
+ * @version            1.0 - beta
+ * @copyright  (c) 2007 by Primusportal.de
+ * @copyright  (c) 2008 by Roland Haeder
+ */
+class PrimeraApi {
+       /**
+        * Fehler - Interfacebenutzer
+        */
+       const PI_ERROR = -1;
+
+       /**
+        * Statuscode für erfolgreich ausgeführte Transaktion
+        */
+       const PI_DONE = 200;
+
+       /**
+        * Fehler - User existiert nicht oder ist gesperrt
+        */
+       const PI_RECEIVER_ERROR = 301;
+
+       /**
+        * Sender-Account Fehler (User nicht existent, gesperrt, ...)
+        */
+       const PI_SENDER_ERROR = 401;
+
+       /**
+        * Betrag fehler
+        */
+       const PI_AMOUNT_ERROR = 501;
+
+       /**
+        * Zu wenig Primera
+        */
+       const PI_TOO_LESS_PRIMERA = 502;
+
+       /**
+        * User nicht aktiv oder existiert nicht
+        */
+       const PI_USER_CHECK_ERROR = 601;
+
+       /**
+        * User aktiv
+        */
+       const PI_USER_CHECK_OK = 602;
+
+       /**
+        * Primerastand erfolgreich geholt
+        */
+       const PI_GET_PRIMERA_DONE = 701;
+
+       /**
+        * URL für das Interface auf dem Primusserver:
+        */
+       private $host = "www.primusportal.de";
+       private $path = "/transfer.interface.2.0.php";
+
+       private $errno = 0;
+       private $err = "";
+
+       private $seperator = ":";
+
+       private $username = "";
+       private $password = "";
+
+       private $data = array();
+
+       /**
+        * Konstruktor
+        */
+       public function PrimeraApi ($PPUsername, $PPPassword) {
+               // Set data
+               $this->username = $PPUsername;
+               $this->password = $PPPassword;
+       }
+
+       /**
+        * Anfrage senden und Rückgabecode in Variable speichern
+        */
+       function queryApi ( $data = array() ) {
+               $data["PrimusInterface_Username"] = base64_encode($this->username);
+               $data["PrimusInterface_Password"] = base64_encode(md5($this->password));
+
+               // Send POST request
+               $return = POST_URL($this->host.$this->path);
+
+               $content = explode("<!-- return-start -->", $return);
+               return $content[1];
+       }
+
+       /**
+        * Funktion parst die Rückgabe vom Transferskript:
+        */
+       function parseContent ( $content ) {
+               $x = explode("\n", $content);
+               $return = array();
+               foreach($x as $currentLine) {
+                       $line_exploded = explode(":", $currentLine,2);
+                       if (count($line_exploded) > 1) {
+                               $return[$line_exploded[0]] = $line_exploded[1];
+                       }
+               }
+               return $return;
+       }
+
+       /**
+        * @param int/string $Receiver UserID / Username des Empfängers
+        * @param int $Amount Betrag in ganzzahligen Primera
+        * @param string $Description Beschreibung (Sichtbar in Einzelauflistung)
+        */
+       public function payPrimera ($Receiver, $Amount, $Description = "") {
+               $valid = false;
+               $PostData = array("PrimusInterface_Action" => "Pay",
+                       "PrimusInterface_Receiver" => base64_encode($Receiver),
+                       "PrimusInterface_Amount" => base64_encode($Amount),
+                       "PrimusInterface_Description" => base64_encode($Description) );
+
+               $PostReturn = $this->parseContent( $this->queryApi($PostData) );
+
+               $this->data = $PostReturn;
+               if ($PostReturn["status"] == "200") {
+                       $valid = true;
+               }
+               return $valid;
+       }
+
+       /**
+        * Überprüft den Status eines Primus-Users
+        * - existiert der User
+        * - ist er aktiv
+        * @param string/int $User Userid / Username
+        */
+       function CheckPrimusUser($User) {
+               $valid = false;
+               $PostData = array("PrimusInterface_Action"=> "CheckPrimusUser",
+                       "PrimusInterface_CheckPrimusUser" => $User);
+
+               $PostReturn = $this->parseContent( $this->queryApi($PostData) );
+
+               $this->data = $PostReturn;
+
+               if ($PostReturn["status"] == self::PI_USER_CHECK_OK) {
+                       $valid = true;
+               }
+               return $valid;
+       }
+
+       /**
+        * Die Funktion liefer den aktuellen Primerastand
+        */
+       function getPrimera() {
+               $primera = false;
+               $PostData = array( "PrimusInterface_Action" => "GetPrimera" );
+               $PostReturn = $this->parseContent( $this->queryApi($PostData) );
+
+               $this->data = $PostReturn;
+               if ($PostReturn["status"] == self::PI_GET_PRIMERA_DONE) {
+                       $primera = $PostReturn["primera"];
+               }
+               return $primera;
+       }
+}
+
+// [EOF]
+?>
\ No newline at end of file
diff --git a/inc/modules/admin/action-primera.php b/inc/modules/admin/action-primera.php
new file mode 100644 (file)
index 0000000..2d94ead
--- /dev/null
@@ -0,0 +1,53 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 09/09/2008 *
+ * ===============                              Last change: 09/09/2008 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : action-primera.php                               *
+ * -------------------------------------------------------------------- *
+ * Short description : Main admin menu for Primera                      *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Hauptadminmenue fuer Primera                     *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) {
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+// Add description as navigation point
+ADD_DESCR("admin", basename(__FILE__));
+
+// Load the include file
+$INC = sprintf("%sinc/modules/admin/what-%s.php", PATH, $GLOBALS['what']);
+if (file_exists($INC)) {
+       // Ok, we finally load the admin action module
+       include($INC);
+} else {
+       ADD_FATAL(ADMIN_404_ACTION_1.$GLOBALS['what'].ADMIN_404_ACTION_2);
+}
+
+//
+?>
diff --git a/inc/modules/admin/what-config_primera.php b/inc/modules/admin/what-config_primera.php
new file mode 100644 (file)
index 0000000..f244c6e
--- /dev/null
@@ -0,0 +1,76 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 09/09/2008 *
+ * ================                             Last change: 09/09/2008 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : what-config_primera.php                          *
+ * -------------------------------------------------------------------- *
+ * Short description : Configure primera sub-system                     *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Auszahlungensarten editieren                     *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) {
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+// Add description as navigation point
+ADD_DESCR("admin", basename(__FILE__));
+
+if (isset($_POST['ok'])) {
+       // First merge temporarily the new API data into the current config
+       $_CONFIG = array_merge($_CONFIG, $_POST);
+
+       // Is the password set?
+       if (isset($_POST['pass'])) {
+               // Then hash and remove it
+               $_POST['primera_api_md5'] = md5($_POST['pass']);
+               unset($_POST['pass']);
+       } // END - if
+
+       // Let's test the API first (hold your horses here, cowboy! Thanks. :) )
+       if (PRIMERA_TEST_API()) {
+               // Save settings
+               ADMIN_SAVE_SETTINGS($_POST);
+       } else {
+               // Failed to test the API!
+               LOAD_TEMPLATE("admin_settings_saved", false, GET_PRIMERA_ERROR_MESSAGE());
+       }
+}  else {
+       // Prepare data for template output
+       $content = array(
+               'min_payout'    => bigintval($_CONFIG['primera_min_payout']),
+               'min_withdraw'  => bigintval($_CONFIG['primera_min_withdraw']),
+               'api_name'              => bigintval($_CONFIG['primera_api_name']),
+               'api_md5'               => $_CONFIG['primera_api_md5']
+       );
+
+       // Load template
+       LOAD_TEMPLATE("admin_config_primera", false, $content);
+}
+
+//
+?>
diff --git a/inc/modules/admin/what-list_primera.php b/inc/modules/admin/what-list_primera.php
new file mode 100644 (file)
index 0000000..d7ce0d6
--- /dev/null
@@ -0,0 +1,76 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 09/09/2008 *
+ * ================                             Last change: 09/09/2008 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : what-list_primera.php                            *
+ * -------------------------------------------------------------------- *
+ * Short description : List member's primera requests                   *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Auflistung der Wernis-Anfragen                   *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if ((ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) || (!IS_ADMIN())) {
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+// Add description as navigation point
+ADD_DESCR("admin", basename(__FILE__));
+
+// Check for entries
+$result = SQL_QUERY("SELECT id, userid, primera_account, primera_amount, primera_timestamp, primera_type, primera_api_message, primera_api_status FROM "._MYSQL_PREFIX."_user_primera ORDER BY primera_timestamp DESC, id DESC",
+       __FILE__, __LINE__);
+
+// Are there some entries to display?
+if (SQL_NUMROWS($result) > 0) {
+       // List all entries
+       $OUT = ""; $SW = 2;
+       while ($content = SQL_FETCHARRAY($result)) {
+               // Translate some data and add color
+               $content['sw']                                  = $SW;
+               $content['link']                                = ADMIN_USER_PROFILE_LINK($content['userid']);
+               $content['primera_amount']              = TRANSLATE_COMMA($content['primera_amount']);
+               $content['primera_timestamp']   = MAKE_DATETIME($content['primera_timestamp'], "2");
+               $content['raw_type']                    = strtolower($content['primera_type']);
+               $content['primera_type']                        = PRIMERA_TRANSFER_STATUS($content['primera_type']);
+
+               // Append it and switch colors
+               $OUT .= LOAD_TEMPLATE("admin_list_primera_row", true, $content);
+               $SW = 3 - $SW;
+       }
+
+       // Load main template
+       LOAD_TEMPLATE("admin_list_primera_main", false, $OUT);
+} else {
+       // Nothing to display!
+       LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_ADMIN_NO_TRANSFERS);
+}
+
+// Free the result
+SQL_FREERESULT($result);
+
+//
+?>
diff --git a/inc/modules/member/what-primera.php b/inc/modules/member/what-primera.php
new file mode 100644 (file)
index 0000000..6ba131b
--- /dev/null
@@ -0,0 +1,305 @@
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 09/09/2008 *
+ * ================                             Last change: 09/09/2008 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : what-primera.php                                 *
+ * -------------------------------------------------------------------- *
+ * Short description : Wernis requests                                  *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Auszahlungsanfragen                              *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (ereg(basename(__FILE__), $_SERVER['PHP_SELF'])) {
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+} elseif (!IS_LOGGED_IN()) {
+       // User is not logged in
+       LOAD_URL("modules.php?module=index");
+} elseif ((!EXT_IS_ACTIVE("primera")) && (!IS_ADMIN())) {
+       // Extension "primera" is not activated
+       ADD_FATAL(EXTENSION_PROBLEM_EXT_INACTIVE, "primera");
+       return;
+}
+
+// Add description as navigation point
+ADD_DESCR("member", basename(__FILE__));
+
+// Check if the admin has entered the data
+if ((empty($_CONFIG['primera_api_name'])) || (empty($_CONFIG['primera_api_md5']))) {
+       // Something important is missing...
+       LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_API_DATA_MISSING);
+       return;
+}
+
+// Init the content array and points
+$content = array(); $points = false;
+
+// 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['primera_refid']);
+
+       // Get WDS66 id
+       $result = SQL_QUERY_ESC("SELECT primera_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);
+       }
+
+       // Free result
+       SQL_FREERESULT($result);
+
+       // Is there an ID?
+       if ((!empty($content['wds66_id'])) && (!isset($_GET['mode']))) {
+               // Then use an other "mode"
+               $_GET['mode'] = "list";
+
+               // And load all rows!
+               $result = SQL_QUERY_ESC("SELECT `id`, `primera_account`, `primera_amount`, `primera_timestamp`, `primera_type` FROM "._MYSQL_PREFIX."_user_primera WHERE `userid` = %s ORDER BY `primera_timestamp` DESC",
+                       array($GLOBALS['userid']), __FILE__, __LINE__);
+
+               // Load all rows
+               $content['rows'] = ""; $SW = 2;
+               while ($data = SQL_FETCHARRAY($result)) {
+                       // Prepare data for output
+                       $rowContent = array(
+                               'stamp'                 => MAKE_DATETIME($data['primera_timestamp'], "2"),
+                               'points'                => TRANSLATE_COMMA($data['primera_amount']),
+                               'acc'                   => bigintval($data['primera_account']),
+                               'status'                => PRIMERA_TRANSFER_STATUS($data['primera_type']),
+                               'raw_type'              => strtolower($data['primera_type']),
+                               'sw'                    => $SW,
+                       );
+
+                       // Load row template
+                       $content['rows'] .= LOAD_TEMPLATE("member_primera_mode_list_row", true, $rowContent);
+                       $SW = 3 - $SW;
+               }
+
+               // Free result
+               SQL_FREERESULT($result);
+       } else {
+               // Mode chooser! ;-)
+               $_GET['mode'] = "choose";
+       }
+} elseif ($_GET['mode'] == "pay") {
+       // 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 this enougth for a payout?
+       if ($points < $_CONFIG['primera_min_payout']) {
+               // No, then abort here
+               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_MIN_PAYOUT_PAYOUT, TRANSLATE_COMMA($_CONFIG['primera_min_payout'])));
+               return;
+       }
+
+       // Add points to content array
+       $content['points']              = $points;
+       $content['min_points']  = TRANSLATE_COMMA($_CONFIG['primera_min_payout']);
+
+       // Get WDS66 id
+       $content['wds66_id'] = "";
+       $result = SQL_QUERY_ESC("SELECT primera_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);
+       }
+
+       // Free result
+       SQL_FREERESULT($result);
+} elseif ($_GET['mode'] == "withdraw") {
+       // 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['primera_min_withdraw']);
+       $content['wds66_id']    = "";
+
+       // Get WDS66 id
+       $result = SQL_QUERY_ESC("SELECT primera_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);
+       }
+
+       // Free result
+       SQL_FREERESULT($result);
+} else {
+       // Invalid mode!
+       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_MODE_INVALID, SQL_ESCAPE($_GET['mode'])));
+       return;
+}
+
+// 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 "withdraw": // Widthdraws WDS66 -> This exchange
+                       // Is the user ID and password set?
+                       if (empty($_POST['wds66_id'])) {
+                               // Nothing entered in WDS66 user ID
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_EMPTY_USERNAME);
+                               OUTPUT_HTML("<br />");
+                       } elseif (empty($_POST['wds66_password'])) {
+                               // Nothing entered in WDS66 password
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_EMPTY_PASSWORD);
+                               OUTPUT_HTML("<br />");
+                       } elseif (empty($_POST['amount'])) {
+                               // Nothing entered in amount
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_EMPTY_AMOUNT);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['wds66_id'] != bigintval($_POST['wds66_id'])) {
+                               // Only numbers in account ID!
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_INVALID_USERNAME);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['amount'] != bigintval($_POST['amount'])) {
+                               // Only numbers in amount!
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_INVALID_AMOUNT);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['amount'] < $_CONFIG['primera_min_withdraw']) {
+                               // Not enougth entered!
+                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_AMOUNT_SMALLER_MIN, bigintval($_CONFIG['primera_min_withdraw'])));
+                               OUTPUT_HTML("<br />");
+                       } else {
+                               // All is fine here so do the withdraw
+                               $success = PRIMERA_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");
+
+                                       // Update the user data as well..
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET `primera_userid`=%s WHERE userid=%s LIMIT 1",
+                                               array(bigintval($_POST['wds66_id']), $GLOBALS['userid']), __FILE__, __LINE__);
+
+                                       // All done!
+                                       LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_WITHDRAW_DONE);
+                                       return;
+                               } elseif ((GET_PRIMERA_ERROR_CODE() == "user_failed") || (GET_PRIMERA_ERROR_CODE() == "own_failed") || (GET_PRIMERA_ERROR_CODE() == "amount_failed")) {
+                                       // Wrong login data
+                                       LOAD_TEMPLATE("admin_settings_saved", false, GET_PRIMERA_ERROR_MESSAGE());
+                                       OUTPUT_HTML("<br />");
+                               } else {
+                                       // Something went wrong
+                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_WITHDRAW_FAILED, GET_PRIMERA_ERROR_MESSAGE()));
+                                       OUTPUT_HTML("<br />");
+                               }
+                       }
+                       break;
+
+               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, PRIMERA_MEMBER_EMPTY_USERNAME);
+                               OUTPUT_HTML("<br />");
+                       } elseif (empty($_POST['wds66_password'])) {
+                               // Nothing entered in WDS66 password
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_EMPTY_PASSWORD);
+                               OUTPUT_HTML("<br />");
+                       } elseif (empty($_POST['amount'])) {
+                               // Nothing entered in amount
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_EMPTY_AMOUNT);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['wds66_id'] != bigintval($_POST['wds66_id'])) {
+                               // Only numbers in account ID!
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_INVALID_USERNAME);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['amount'] != bigintval($_POST['amount'])) {
+                               // Only numbers in amount!
+                               LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_INVALID_AMOUNT);
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['amount'] < $_CONFIG['primera_min_payout']) {
+                               // Not enougth entered!
+                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_AMOUNT_SMALLER_MIN, bigintval($_CONFIG['primera_min_payout'])));
+                               OUTPUT_HTML("<br />");
+                       } elseif ($_POST['amount'] > $points) {
+                               // Not enougth points left!
+                               LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_PAYOUT_POINTS_DEPLETED, bigintval($_POST['amount']), bigintval($points)));
+                               OUTPUT_HTML("<br />");
+                       } else {
+                               // All is fine here so do the withdraw
+                               $success = PRIMERA_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;
+                                       }
+
+                                       // Remove the points from the account
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET `used_points` = `used_points` + %s, `primera_userid`=%s WHERE userid=%s LIMIT 1",
+                                               array(bigintval($_POST['amount']), bigintval($_POST['wds66_id']), $GLOBALS['userid']), __FILE__, __LINE__);
+
+                                       // All done!
+                                       LOAD_TEMPLATE("admin_settings_saved", false, PRIMERA_MEMBER_PAYOUT_DONE);
+                                       return;
+                               } elseif ((GET_PRIMERA_ERROR_CODE() == "user_failed") || (GET_PRIMERA_ERROR_CODE() == "own_failed") || (GET_PRIMERA_ERROR_CODE() == "amount_failed") || (GET_PRIMERA_ERROR_CODE() == "api_amount_failed")) {
+                                       // Wrong login data
+                                       LOAD_TEMPLATE("admin_settings_saved", false, GET_PRIMERA_ERROR_MESSAGE());
+                                       OUTPUT_HTML("<br />");
+                               } else {
+                                       // Something went wrong
+                                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_WITHDRAW_FAILED, GET_PRIMERA_ERROR_MESSAGE()));
+                                       OUTPUT_HTML("<br />");
+                               }
+                       }
+                       break;
+
+               default: // Invalid mode!
+                       LOAD_TEMPLATE("admin_settings_saved", false, sprintf(PRIMERA_MEMBER_MODE_INVALID, SQL_ESCAPE($_GET['mode'])));
+                       return;
+       }
+}
+
+// Prepare mode for template name
+$mode = sprintf("member_primera_mode_%s", SQL_ESCAPE($_GET['mode']));
+
+// Load the template
+LOAD_TEMPLATE($mode, false, $content);
+
+//
+?>
index dcc437eaab945045226ea704df6ecdb5c3ce69f9..5c4cf4cda99ce766af7c2e5a2b8ea96919508915 100644 (file)
@@ -25,7 +25,7 @@ An Konto: $_POST[account]
 
 Bitte ueberpruefen Sie diese Daten und ueberweisen Sie dann den geforderten Betrag.
 
-Die {!WERNIS_POINTS_VALUE!} {!POINTS!} wurden dem Mitglied bereits abgebucht.
+Die {!WERNIS_POINTS_VALUE!} Wernis wurden dem Mitglied bereits abgebucht.
 
 Bitte vergessen Sie nicht, das Mitglied ueber die Auszahlung zu informieren, da dies nicht automatisch erfolgt.
 
index b5264a63f4f2aace7c151903ad80e40b2b5d2fd4..037fcc4ecbd1be8f0d83ad2854fef8b47b2ed66a 100644 (file)
@@ -17,7 +17,7 @@ Nachricht vom Admin:
 $content
 ------------------------------
 
-Ihre Anfrage wurde hiermit abgelehnt! Bitte beachten Sie unsere AGBs. Ihre {!POINTS!} werden wir gesondert zurueckbuchen oder bei schwerwiegenden Faellen uns vorbehalten, dies nicht zu tun oder Ihren Account bei uns zu sperren.
+Ihre Anfrage wurde hiermit abgelehnt! Bitte beachten Sie unsere AGBs. Ihre Wernis werden wir gesondert zurueckbuchen oder bei schwerwiegenden Faellen uns vorbehalten, dies nicht zu tun oder Ihren Account bei uns zu sperren.
 
 Mit freundlichem Gruss,
   Ihr {!MAIN_TITLE!} Team
index cfc4c89c5f3ea6c72fec77f6bd6e5173f8620b2e..b0e3a59b46857a3ef0cc443e47d469b06bcec117 100644 (file)
@@ -15,7 +15,7 @@ Auszahlungshoehe: $_POST[payout]
 An Konto: $_POST[account]
 ------------------------------
 
-Die dazu noetigen {!WERNIS_POINTS_VALUE!} {!POINTS!} haben wir Ihnen bereits abgezogen.
+Die dazu noetigen {!WERNIS_POINTS_VALUE!} Wernis haben wir Ihnen bereits abgezogen.
 
 Sie sollten soeben eine Aufbuchung auf Ihrem WDS66-Hauptaccount erhalten haben!
 
diff --git a/templates/de/html/admin/admin_config_primera.tpl b/templates/de/html/admin/admin_config_primera.tpl
new file mode 100644 (file)
index 0000000..1cf7eee
--- /dev/null
@@ -0,0 +1,69 @@
+<FORM action="{!URL!}/modules.php?module=admin&amp;what=config_primera" method="POST">
+<TABLE border="0" cellspacing="0" cellpadding="0" width="580" class="admin_table dashed">
+       <TR>
+               <TD colspan="3" align="center" class="admin_title bottom2" height="30">
+               <STRONG>{--PRIMERA_ADMIN_CONFIG_TITLE--}</STRONG></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="300" align="right">{--PRIMERA_ADMIN_API_NAME--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD width="270"><INPUT type="text" name="primera_api_name"
+                       class="admin_normal" value="$content[api_name]" size="10"
+                       maxlength="255" /></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="300" align="right">{--PRIMERA_ADMIN_API_MD5--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD width="270"><INPUT type="password" name="pass"
+                       class="admin_normal" size="20"
+                       maxlength="255" /><br />
+               </TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator bottom2" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="admin_title bottom2" align="center">
+                       Gespeicherter Hash:<br />
+                       &raquo;<em>$content[api_md5]</em>&laquo;
+               </TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="300" align="right">{--PRIMERA_ADMIN_MIN_PAYOUT--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD width="270"><INPUT type="text" name="primera_min_payout"
+                       class="admin_normal" value="$content[min_payout]" size="5"
+                       maxlength="20" /> Wernis</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="300" align="right">{--PRIMERA_ADMIN_MIN_WITHDRAW--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD width="270"><INPUT type="text" name="primera_min_withdraw"
+                       class="admin_normal" value="$content[min_withdraw]" size="5"
+                       maxlength="20" /> Wernis</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="seperator bottom2" height="5">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" class="admin_footer"><INPUT
+                       type="reset" class="admin_reset" value="{--CLEAR_FORM--}">&nbsp;*&nbsp;<INPUT
+                       type="submit" name="ok" class="admin_submit"
+                       value="{--SAVE_SETTINGS--}"></TD>
+       </TR>
+</TABLE>
+</FORM>
+
+<DIV class="admin_note">{--PRIMERA_ADMIN_CONFIG_NOTE--}</DIV>
index 4139d5415690760219ab8c9a7a9b0492cf4217a0..6c875cb1044ac55eff381cd414bda862e63ebe2c 100644 (file)
@@ -55,7 +55,7 @@
                <TD class="seperator" width="10">&nbsp;</TD>
                <TD width="270"><INPUT type="text" name="wernis_min_payout"
                        class="admin_normal" value="$content[min_payout]" size="5"
-                       maxlength="20" /> {!POINTS!}</TD>
+                       maxlength="20" /> Wernis</TD>
        </TR>
        <TR>
                <TD colspan="3" class="seperator" height="5">&nbsp;</TD>
@@ -65,7 +65,7 @@
                <TD class="seperator" width="10">&nbsp;</TD>
                <TD width="270"><INPUT type="text" name="wernis_min_withdraw"
                        class="admin_normal" value="$content[min_withdraw]" size="5"
-                       maxlength="20" /> {!POINTS!}</TD>
+                       maxlength="20" /> Wernis</TD>
        </TR>
        <TR>
                <TD colspan="3" class="seperator bottom2" height="5">&nbsp;</TD>
diff --git a/templates/de/html/admin/admin_list_primera_main.tpl b/templates/de/html/admin/admin_list_primera_main.tpl
new file mode 100644 (file)
index 0000000..e9ab6d7
--- /dev/null
@@ -0,0 +1,16 @@
+<TABLE border="0" cellspacing="0" cellpadding="0" width="90%" class="admin_table dashed">
+<TR>
+       <TD class="admin_header bottom2 right2" align="center" width="60"><STRONG>{--ID_SELECT--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center" width="90"><STRONG>{--_UID--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center"><STRONG>{--PRIMERA_ADMIN_WDS66_ACCOUNT--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center"><STRONG>{--PRIMERA_ADMIN_TRANSFERED--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center" width="160"><STRONG>{--PRIMERA_ADMIN_TIMESTAMP--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center" width="160"><STRONG>{--PRIMERA_ADMIN_TYPE--}</STRONG></TD>
+       <TD class="admin_header bottom2 right2" align="center" width="160"><STRONG>{--PRIMERA_ADMIN_API_MESSAGE--}</STRONG></TD>
+       <TD class="admin_header bottom2" align="center" width="160"><STRONG>{--PRIMERA_ADMIN_API_STATUS--}</STRONG></TD>
+</TR>
+$content
+<TR>
+       <TD colspan="8" class="admin_footer seperator">&nbsp;</TD>
+</TR>
+</TABLE>
diff --git a/templates/de/html/admin/admin_list_primera_row.tpl b/templates/de/html/admin/admin_list_primera_row.tpl
new file mode 100644 (file)
index 0000000..f6ffce3
--- /dev/null
@@ -0,0 +1,10 @@
+<TR>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[id]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[link]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[primera_account]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[primera_amount]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[primera_timestamp]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2" align="center">$content[primera_type]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2" align="center">$content[primera_api_message]</TD>
+       <TD class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2" align="center">$content[primera_api_status]</TD>
+</TR>
diff --git a/templates/de/html/ext/ext_primera.tpl b/templates/de/html/ext/ext_primera.tpl
new file mode 100644 (file)
index 0000000..565f7bd
--- /dev/null
@@ -0,0 +1,10 @@
+Mit dieser Erweiterung k&ouml;nnen Sie Ihren Mitgliedern eine Auszahlung
+ihrer Internet-W&auml;hrung
+<A href="http://www.primusportal.de/r/Quix0r" target="_blank">Primera</A>
+auf ihr Primera-Account &uuml;berweisen lassen. Sie als Primera-Anbieter
+brauchen dazu selbstverst&auml;ndlich ein Primera-Account. Mehr dazu auf
+<A href="http://www.primusportal.de/r/Quix0r"
+ target="_blank">www.primusportal.de</A>. Damit Ihr System einheitlicher
+ist, sollten Sie unter <A  href="{!URL!}/modules.php?module=admin&amp;what=config_other"
+ target="_blank">Sonstige Einstellungen</A> die W&auml;hrung Ihres {!MT_WORD2!}
+von {!POINTS!} auf Primera umstellen.
index 45a67401a466fb00aaa7e6dc46c549e53dc8413f..908914395b33940c60f732eedb769db70ae00f8c 100644 (file)
@@ -1,10 +1,10 @@
 Mit dieser Erweiterung k&ouml;nnen Sie Ihren Mitgliedern eine Auszahlung
 ihrer Internet-W&auml;hrung
-<A href="http://www.wds66.com/ref.php?refid=10438" target="_blank">Wernis</A>
+<A href="http://www.wds66.com/ref.php?refid=10437" target="_blank">Wernis</A>
 auf ihr WDS66-Hauptaccount &uuml;berweisen lassen. Sie als
 Wernis-Anbieter brauchen dazu selbstverst&auml;ndlich ein Wernis-Account
 mit einem API-Account. Mehr dazu auf
-<A href="http://www.wds66.com/ref.php?refid=10438" target="_blank">www.wds66.com</A>
+<A href="http://www.wds66.com/ref.php?refid=10437" target="_blank">www.wds66.com</A>
 . Damit Ihr System einheitlicher ist, sollten Sie unter
 <A href="{!URL!}/modules.php?module=admin&amp;what=config_other"
        target="_blank">Sonstige Einstellungen</A>
diff --git a/templates/de/html/member/member_primera.tpl b/templates/de/html/member/member_primera.tpl
new file mode 100644 (file)
index 0000000..bf1a598
--- /dev/null
@@ -0,0 +1,17 @@
+<TABLE border="0" cellspacing="0" cellpadding="0" width="680"
+       class="member_table dashed" align="center">
+       <TR>
+               <TD colspan="4" align="center" class="member_title2" height="30">
+               <STRONG>{--PRIMERA_MEMBER_LIST_PRIMERA--}:</STRONG></TD>
+       </TR>
+       <TR>
+               <TD width="180" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_TOTAL_PRIMERA--}</STRONG></TD>
+               <TD width="130" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_TARGET_ACCOUNT2--}</STRONG></TD>
+               <TD width="150" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_TIMESTAMP--}</STRONG></TD>
+               <TD width="120" align="center" class="member_title2 bottom2"><STRONG>{--PRIMERA_MEMBER_STATUS--}</STRONG></TD>
+       </TR>
+       {!__PRIMERA_ROWS!}
+       <TR>
+               <TD colspan="4" class="seperator member_footer" height="10">&nbsp;</TD>
+       </TR>
+</TABLE>
diff --git a/templates/de/html/member/member_primera_form.tpl b/templates/de/html/member/member_primera_form.tpl
new file mode 100644 (file)
index 0000000..2a1e461
--- /dev/null
@@ -0,0 +1,51 @@
+<FORM
+       action="{!URL!}/modules.php?module=login&amp;what=primera&amp;primera=$_GET[primera]"
+       method="POST" style="margin-bottom: 0px">
+<TABLE border="0" cellspacing="0" cellpadding="0" width="440"
+       class="member_table dashed">
+       <TR>
+               <TD colspan="3" align="center" class="member_title2 bottom2"
+                       height="30"><STRONG>{--PRIMERA_NOW_TITLE--}</STRONG></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD height="25" align="right">{--PRIMERA_MAX_PRIMERA--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD><STRONG>{--PRIMERA_MAX_VALUE!}</STRONG></TD>
+       </TR>
+       <TR>
+               <TD height="25" align="right">{--PRIMERA_WANT_PRIMERA--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD><INPUT type="text" name="primera" class="member_normal"
+                       size="10" maxlength="255" value="{--PRIMERA_MAX_VALUE!}"></STRONG></TD>
+       </TR>
+       <TR>
+               <TD height="25" align="right">{--PRIMERA_TARGET_ACCOUNT--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD><INPUT type="text" name="account" class="member_normal"
+                       size="20" maxlength="255"></STRONG></TD>
+       </TR>
+       <TR>
+               <TD height="25" align="right">{--PRIMERA_OPTIONAL_PASSWORD--}:</TD>
+               <TD class="seperator" width="10">&nbsp;</TD>
+               <TD><INPUT type="password" name="pass" class="member_normal"
+                       size="10" maxlength="255"></STRONG></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator bottom2">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" align="center" class="member_footer"><INPUT
+                       type="reset" class="member_reset" value="{--CLEAR_FORM--}">&nbsp;*&nbsp;<INPUT
+                       type="submit" name="ok" class="member_submit"
+                       value="{--PRIMERA_SEND_NOW--}"></TD>
+       </TR>
+</TABLE>
+</FORM>
+
+<DIV class="member_note">{--PRIMERA_MEMBER_NOTE--}<br />
+<br />
+<A href="{!URL!}/agb.php" target="_blank">{--PRIMERA_REMEMBER_TERMS--}</A>
+</DIV>
diff --git a/templates/de/html/member/member_primera_mode_choose.tpl b/templates/de/html/member/member_primera_mode_choose.tpl
new file mode 100644 (file)
index 0000000..e0ed949
--- /dev/null
@@ -0,0 +1,18 @@
+<table border="0" cellspacing="0" cellpadding="0" class="member_table dashed">
+       <tr>
+               <td class="member_title2 bottom2" style="padding: 5px" colspan="2">
+               {--MEMBER_PRIMERA_MODE_CHOOSE--}</td>
+       </tr>
+       <tr>
+               <td width="50%" align="center" class="right2" height="40">
+                       <a class="menu_blur" style="height: 40px" href="{!URL!}/modules.php?module=login&amp;what=primera&amp;mode=withdraw"><div style="padding-top: 10px">{--MEMBER_PRIMERA_MODE_WITHDRAW--}</div></a>
+               </td>
+               <td width="50%" align="center">
+                       <a class="menu_blur" style="height: 40px" href="{!URL!}/modules.php?module=login&amp;what=primera&amp;mode=pay"><div style="padding-top: 3px">{--MEMBER_PRIMERA_MODE_PAYOUT--}</div></a>
+               </td>
+       </tr>
+</table>
+
+<p align="center">
+       <a href="http://www.wds66.com/ref.php?refid=$content[refid]" target="_blank">{--PRIMERA_MEMBER_NO_ACCOUNT--}</a>
+</p>
diff --git a/templates/de/html/member/member_primera_mode_list.tpl b/templates/de/html/member/member_primera_mode_list.tpl
new file mode 100644 (file)
index 0000000..fb2d39b
--- /dev/null
@@ -0,0 +1,20 @@
+<TABLE border="0" cellspacing="0" cellpadding="0" width="680"
+       class="member_table dashed" align="center">
+       <TR>
+               <TD colspan="4" align="center" class="member_title2" height="30">
+                       <STRONG>{--PRIMERA_MEMBER_LIST_PRIMERA--}</STRONG>
+               </TD>
+       </TR>
+       <TR>
+               <TD width="180" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_TOTAL_PRIMERA--}</STRONG></TD>
+               <TD width="130" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_ACCOUNT--}</STRONG></TD>
+               <TD width="150" align="center" class="member_title2 bottom2 right2"><STRONG>{--PRIMERA_TIMESTAMP--}</STRONG></TD>
+               <TD width="120" align="center" class="member_title2 bottom2"><STRONG>{--PRIMERA_MEMBER_STATUS--}</STRONG></TD>
+       </TR>
+       $content[rows]
+       <TR>
+               <TD colspan="4" class="member_footer" align="center">
+                       <a href="{!URL!}/modules.php?module=login&amp;what=primera&amp;mode=choose">{--MEMBER_PRIMERA_MODE_CHOOSE2--}</a>
+               </TD>
+       </TR>
+</TABLE>
diff --git a/templates/de/html/member/member_primera_mode_list_row.tpl b/templates/de/html/member/member_primera_mode_list_row.tpl
new file mode 100644 (file)
index 0000000..bcadbd8
--- /dev/null
@@ -0,0 +1,6 @@
+<TR>
+       <TD align="center" class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[points] Primera</TD>
+       <TD align="center" class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[acc]</TD>
+       <TD align="center" class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2 right2">$content[stamp]</TD>
+       <TD align="center" class="switch_sw$content[sw] primera_type_$content[raw_type] bottom2">$content[status]</TD>
+</TR>
diff --git a/templates/de/html/member/member_primera_mode_pay.tpl b/templates/de/html/member/member_primera_mode_pay.tpl
new file mode 100644 (file)
index 0000000..de1b264
--- /dev/null
@@ -0,0 +1,47 @@
+<FORM action="{!URL!}/modules.php?module=login&amp;what=primera&amp;mode=pay" method="POST" style="margin-bottom: 0px">
+<TABLE border="0" cellspacing="0" cellpadding="0" width="440" class="member_table dashed">
+       <TR>
+               <TD colspan="3" align="center" class="member_title2 bottom2"
+                       height="30"><STRONG>{--PRIMERA_MEMBER_PAYOUT_TITLE--}</STRONG></TD>
+       </TR>
+       <TR>
+               <TD width="315" class="bottom2" height="25" align="right">{--PRIMERA_MEMBER_PAYOUT_POINTS--}</TD>
+               <TD width="10" class="seperator bottom2">&nbsp;</TD>
+               <TD width="115" class="bottom2"><strong>$content[points]</strong> Primera</TD>
+       </TR>
+       <TR>
+               <TD width="315" class="bottom2" height="25" align="right">{--PRIMERA_MEMBER_PAYOUT_MIN_POINTS--}</TD>
+               <TD width="10" class="seperator bottom2">&nbsp;</TD>
+               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> Primera</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_ID--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="text" name="wds66_id" size="6" maxlength="5" value="$content[wds66_id]" /></TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_PASSWORD--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="password" name="wds66_password" size="10" maxlength="255" /></TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_AMOUNT--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="text" name="amount" size="10" maxlength="255" /></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator bottom2">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" align="center" class="member_footer">
+                       <INPUT type="reset" class="member_reset" value="{--CLEAR_FORM--}">&nbsp;*
+                       <INPUT type="submit" name="ok" class="member_submit" value="{--PRIMERA_MEMBER_PAYOUT_SUBMIT--}">
+               </TD>
+       </TR>
+</TABLE>
+<br />
+<STRONG class="member_note"> {--PRIMERA_MEMBER_PAYOUT_NOTE--}</STRONG>
+</FORM>
diff --git a/templates/de/html/member/member_primera_mode_withdraw.tpl b/templates/de/html/member/member_primera_mode_withdraw.tpl
new file mode 100644 (file)
index 0000000..e7f5dc0
--- /dev/null
@@ -0,0 +1,47 @@
+<FORM action="{!URL!}/modules.php?module=login&amp;what=primera&amp;mode=withdraw" method="POST" style="margin-bottom: 0px">
+<TABLE border="0" cellspacing="0" cellpadding="0" width="440" class="member_table dashed">
+       <TR>
+               <TD colspan="3" align="center" class="member_title2 bottom2"
+                       height="30"><STRONG>{--PRIMERA_MEMBER_WITHDRAW_TITLE--}</STRONG></TD>
+       </TR>
+       <TR>
+               <TD width="315" class="bottom2" height="25" align="right">{--PRIMERA_MEMBER_WITHDRAW_POINTS_ACCOUNT--}</TD>
+               <TD width="10" class="seperator bottom2">&nbsp;</TD>
+               <TD width="115" class="bottom2"><strong>$content[points]</strong> Primera</TD>
+       </TR>
+       <TR>
+               <TD width="315" class="bottom2" height="25" align="right">{--PRIMERA_MEMBER_WITHDRAW_MIN_POINTS--}</TD>
+               <TD width="10" class="seperator bottom2">&nbsp;</TD>
+               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> Primera</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_ID--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="text" name="wds66_id" size="6" maxlength="5" value="$content[wds66_id]" /></TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_PASSWORD--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="password" name="wds66_password" size="10" maxlength="255" /></TD>
+       </TR>
+       <TR>
+               <TD width="315" height="35" align="right">{--PRIMERA_MEMBER_WDS66_AMOUNT--}</TD>
+               <TD width="10" class="seperator">&nbsp;</TD>
+               <TD width="115"><INPUT type="text" name="amount" size="10" maxlength="255" /></TD>
+       </TR>
+       <TR>
+               <TD colspan="3" height="3" class="seperator bottom2">&nbsp;</TD>
+       </TR>
+       <TR>
+               <TD colspan="3" align="center" class="member_footer">
+                       <INPUT type="reset" class="member_reset" value="{--CLEAR_FORM--}">&nbsp;*
+                       <INPUT type="submit" name="ok" class="member_submit" value="{--PRIMERA_MEMBER_WITHDRAW_SUBMIT--}">
+               </TD>
+       </TR>
+</TABLE>
+<br />
+<STRONG class="member_note"> {--PRIMERA_MEMBER_WITHDRAW_NOTE--}</STRONG>
+</FORM>
index fd7cc2c4b0ae6c1513629b52010fd777e4d1ed55..976dcfb0a467716ba9e5b2309e6f752719807217 100644 (file)
@@ -1,5 +1,5 @@
 <TR>
-       <TD align="center" class="switch_sw$content[sw] wernis_type_$content[raw_type] bottom2 right2">$content[points] {!POINTS!}</TD>
+       <TD align="center" class="switch_sw$content[sw] wernis_type_$content[raw_type] bottom2 right2">$content[points] Wernis</TD>
        <TD align="center" class="switch_sw$content[sw] wernis_type_$content[raw_type] bottom2 right2">$content[acc]</TD>
        <TD align="center" class="switch_sw$content[sw] wernis_type_$content[raw_type] bottom2 right2">$content[stamp]</TD>
        <TD align="center" class="switch_sw$content[sw] wernis_type_$content[raw_type] bottom2">$content[status]</TD>
index 8122716ad77a476f69fc8e86ba297b0d1252d5cf..061c395197f38e3c4b125813aaa9a81eda49ef86 100644 (file)
@@ -7,12 +7,12 @@
        <TR>
                <TD width="315" class="bottom2" height="25" align="right">{--WERNIS_MEMBER_PAYOUT_POINTS--}</TD>
                <TD width="10" class="seperator bottom2">&nbsp;</TD>
-               <TD width="115" class="bottom2"><strong>$content[points]</strong> {!POINTS!}</TD>
+               <TD width="115" class="bottom2"><strong>$content[points]</strong> Wernis</TD>
        </TR>
        <TR>
                <TD width="315" class="bottom2" height="25" align="right">{--WERNIS_MEMBER_PAYOUT_MIN_POINTS--}</TD>
                <TD width="10" class="seperator bottom2">&nbsp;</TD>
-               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> {!POINTS!}</TD>
+               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> Wernis</TD>
        </TR>
        <TR>
                <TD colspan="3" height="3" class="seperator">&nbsp;</TD>
index 46787a1634c1f30cb95953948b2356e831b03065..d088f8e6fad5c758ac42dd0c99ce75dec1f4dc7f 100644 (file)
@@ -7,12 +7,12 @@
        <TR>
                <TD width="315" class="bottom2" height="25" align="right">{--WERNIS_MEMBER_WITHDRAW_POINTS_ACCOUNT--}</TD>
                <TD width="10" class="seperator bottom2">&nbsp;</TD>
-               <TD width="115" class="bottom2"><strong>$content[points]</strong> {!POINTS!}</TD>
+               <TD width="115" class="bottom2"><strong>$content[points]</strong> Wernis</TD>
        </TR>
        <TR>
                <TD width="315" class="bottom2" height="25" align="right">{--WERNIS_MEMBER_WITHDRAW_MIN_POINTS--}</TD>
                <TD width="10" class="seperator bottom2">&nbsp;</TD>
-               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> {!POINTS!}</TD>
+               <TD width="115" class="bottom2"><strong>$content[min_points]</strong> Wernis</TD>
        </TR>
        <TR>
                <TD colspan="3" height="3" class="seperator">&nbsp;</TD>
index 24ad219252a4f1058d4a4484a40a6f49f55315b9..49b2a77d18b3476b0c28e402d3d8d14e4598a14d 100644 (file)
@@ -1,5 +1,5 @@
 <TR>
-       <TD align="center" class="switch_sw$content[sw] bottom2 right2">$content[points] {!POINTS!}</TD>
+       <TD align="center" class="switch_sw$content[sw] bottom2 right2">$content[points] Wernis</TD>
        <TD align="center" class="switch_sw$content[sw] bottom2 right2">$content[acc]</TD>
        <TD align="center" class="switch_sw$content[sw] bottom2 right2">$content[stamp]</TD>
        <TD align="center" class="switch_sw$content[sw] bottom2">$content[status]</TD>