2 /************************************************************************
3 * Mailer v0.2.1-FINAL Start: 07/10/2004 *
4 * =================== Last change: 09/29/2004 *
6 * -------------------------------------------------------------------- *
7 * File : ext-task.php *
8 * -------------------------------------------------------------------- *
9 * Short description : Task management *
10 * -------------------------------------------------------------------- *
11 * Kurzbeschreibung : Aufgabenverwaltung *
12 * -------------------------------------------------------------------- *
15 * $Tag:: 0.2.1-FINAL $ *
17 * -------------------------------------------------------------------- *
18 * Copyright (c) 2003 - 2009 by Roland Haeder *
19 * Copyright (c) 2009, 2010 by Mailer Developer Team *
20 * For more information visit: http://www.mxchange.org *
22 * This program is free software; you can redistribute it and/or modify *
23 * it under the terms of the GNU General Public License as published by *
24 * the Free Software Foundation; either version 2 of the License, or *
25 * (at your option) any later version. *
27 * This program is distributed in the hope that it will be useful, *
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
30 * GNU General Public License for more details. *
32 * You should have received a copy of the GNU General Public License *
33 * along with this program; if not, write to the Free Software *
34 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, *
36 ************************************************************************/
38 // Some security stuff...
39 if (!defined('__SECURITY')) {
44 setThisExtensionVersion('0.3.2');
46 // Version history array (add more with , '0.1.0' and so on)
47 setExtensionVersionHistory(array('0.0', '0.0.1', '0.0.2', '0.0.3', '0.0.4', '0.0.5', '0.0.6', '0.0.7', '0.0.8', '0.0.9', '0.1.0', '0.1.1', '0.1.2', '0.1.3', '0.1.4', '0.1.5', '0.1.6', '0.1.7', '0.1.8', '0.1.9', '0.2.0', '0.2.1', '0.2.2', '0.2.3', '0.2.4', '0.2.5', '0.2.6', '0.2.7', '0.2.8', '0.2.9', '0.3.0', '0.3.1', '0.3.2'));
49 // Keep this extension always active!
50 setExtensionAlwaysActive('Y');
52 switch (getExtensionMode()) {
53 case 'register': // Do stuff when installation is running (modules.php?module=admin is called)
54 // SQL commands to run
55 addAdminMenuSql('task', NULL, 'Aufgaben-Management','Erweitertes Aufgaben-Management zur leichten verwaltung der vom System erzeugten Aufgaben.',1);
56 addAdminMenuSql('task','list_task','Aufgaben auflisten','Alle Ihnen zugewiesenen Aufgaben auflisten (keine Updates).',1);
57 addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_task_system` SET `status`='SOLVED' WHERE `status`='CLOSED'");
60 case 'remove': // Do stuff when removing extension
61 // SQL commands to run
62 addExtensionSql("DELETE LOW_PRIORITY FROM `{?_MYSQL_PREFIX?}_admin_menu` WHERE `action`='task'");
65 case 'activate': // Do stuff when admin activates this extension
66 // SQL commands to run
70 case 'deactivate': // Do stuff when admin deactivates this extension
71 // SQL commands to run
75 case 'update': // Update an extension
76 switch (getCurrentExtensionVersion()) {
77 case '0.0.1': // SQL queries for v0.0.1
78 addExtensionSql("UPDATE `{?_MYSQL_PREFIX?}_extensions` SET ext_has_css='Y' WHERE `ext_name`='task' AND ext_has_css='N' LIMIT 1");
80 // This update depends on sql_patches update!
81 addExtensionDependency('sql_patches');
83 // Update notes (these will be set as task text!)
84 setExtensionUpdateNotes("CSS-Datei kann per Admin-Bereich ein- und ausgeschaltet werden.");
87 case '0.0.1': // SQL queries for v0.0.1
88 // Update notes (these will be set as task text!)
89 setExtensionUpdateNotes("Unnötige Script-Teile aus what-list_tasks.php herausgelöscht; beim Anzeigen einer Extension-Update, oder -Register Aufgabe werden bei eingeschaltetem Verbose-Modus alle SQL-Anweisungen aufgelistet.");
92 case '0.0.4': // SQL queries for v0.0.4
93 // Update notes (these will be set as task text!)
94 setExtensionUpdateNotes("Fehler <div class=\"notice\">Warning: Missing argument 2 for create_timestamp_from_selections() in {?PATH?}inc/libs/pro_functions.php on line 227</div> behoben.");
97 case '0.0.5': // SQL queries for v0.0.5
98 // Update notes (these will be set as task text!)
99 setExtensionUpdateNotes("&admin= in &amp;admin= umgewandelt.");
102 case '0.0.6': // SQL queries for v0.0.6
103 // Update notes (these will be set as task text!)
104 setExtensionUpdateNotes("Wegen des Theme-Supportes hat sich die URL zur CSS-Datei geändert.");
107 case '0.0.7': // SQL queries for v0.0.7
108 // Update notes (these will be set as task text!)
109 setExtensionUpdateNotes("Erstellung der Extra-Übersichten verbessert.");
112 case '0.0.8': // SQL queries for v0.0.8
113 // Update notes (these will be set as task text!)
114 setExtensionUpdateNotes("Fehler beseitigt, wenn error_reporting=E_ALL gesetzt ist.");
117 case '0.0.9': // SQL queries for v0.0.9
118 // Update notes (these will be set as task text!)
119 setExtensionUpdateNotes("Fehler bei Abfrage der payout-Erweiterung beseitigt.");
122 case '0.1.0': // SQL queries for v0.2.1
123 // Update notes (these will be set as task text!)
124 setExtensionUpdateNotes("Task-Liste ausgelagert als Template");
127 case '0.1.1': // SQL queries for v0.1.1
128 // Update notes (these will be set as task text!)
129 setExtensionUpdateNotes("Design "Solid-Business" eingebaut.");
132 case '0.1.2': // SQL queries for v0.1.2
133 // Update notes (these will be set as task text!)
134 setExtensionUpdateNotes("Seit <strong>Patch 340</strong> überflüssige HTML-Tags entfernt.");
137 case '0.1.3': // SQL queries for v0.1.3
138 // Update notes (these will be set as task text!)
139 setExtensionUpdateNotes("Link zum Mitgliedsprofil in Funktion <u>generateUserProfileLink()</u> ausgelagert.");
142 case '0.1.4': // SQL queries for v0.1.4
143 // Update notes (these will be set as task text!)
144 setExtensionUpdateNotes("Wörter <strong>{?mt_word?}</strong>, <strong>{?mt_word2?}</strong> und <strong>{?mt_word3?}</strong> sind austauschbar.");
147 case '0.1.5': // SQL queries for v0.1.5
148 // Update notes (these will be set as task text!)
149 setExtensionUpdateNotes("Links wegen <strong>what=admins_contct</strong> geändert.");
152 case '0.1.6': // SQL queries for v0.1.6
153 // Update notes (these will be set as task text!)
154 setExtensionUpdateNotes("Weitere Direkt-Links eingebaut:<br />
156 <li>Ländercodes</li>
157 <li>Wartende Verdopplungen</li>
158 <li><strong>Geändert:</strong> Wartende Auszahlungen</li>
159 <li>Teilnehmer an der Aktiv-Rallye</li>
160 <li>Nett hinweisende Linktitel hinzugefügt. :-)</li>
164 case '0.1.7': // SQL queries for v0.1.7
165 // Update notes (these will be set as task text!)
166 setExtensionUpdateNotes("Direkt Links zum Sponsorenbereich vorbereitend eingebaut.");
169 case '0.1.8': // SQL queries for v0.1.8
170 // Update notes (these will be set as task text!)
171 setExtensionUpdateNotes("Es werden alle installierten und aktivierten Themes angezeigt und verlinkt.");
174 case '0.1.9': // SQL queries for v0.1.9
175 // Update notes (these will be set as task text!)
176 setExtensionUpdateNotes("CSS-Datei in general.css verschmolzen (Patch 435!)");
179 case '0.2.0': // SQL queries for v0.2.0
180 // Update notes (these will be set as task text!)
181 setExtensionUpdateNotes("Alle Administratoren, Referal-Banner und aktivierte Referal-Banner werden nun eingeblendet.");
184 case '0.2.1': // SQL queries for v0.2.1
185 // Update notes (these will be set as task text!)
186 setExtensionUpdateNotes("Problem mit überlanger Textbreite beseitigt.");
189 case '0.2.2': // SQL queries for v0.2.2
190 // Update notes (these will be set as task text!)
191 setExtensionUpdateNotes("Link zum Freischalten von Sponoren-Accounts korregiert.");
194 case '0.2.3': // SQL queries for v0.2.3
195 // Update notes (these will be set as task text!)
196 setExtensionUpdateNotes("Sortierungsreihenfolge grundlegend geändert: Es wird jetzt nach Mitglieder-Id, Aufgabenbereich, Infos und nach dem Erstellunsdatum sortiert.");
199 case '0.2.4': // SQL queries for v0.2.4
200 // Update notes (these will be set as task text!)
201 setExtensionUpdateNotes("Abspeichern von Einstellungen repariert.");
204 case '0.2.5': // SQL queries for v0.2.5
205 // Update notes (these will be set as task text!)
206 setExtensionUpdateNotes("<strong>Nur mit bonus v0.6.9 oder höher:</strong> Zuschaltbare Bonis werden auch bei der Ermittlung Anzahl teilnehmender Mitglieder mit ber&uumk;cksichtigt.");
209 case '0.2.6': // SQL queries for v0.2.6
210 // Update notes (these will be set as task text!)
211 setExtensionUpdateNotes("Teilnehmer der Bettel-Rallye werden angezeigt.");
214 case '0.2.7': // SQL queries for v0.2.7
215 // Update notes (these will be set as task text!)
216 setExtensionUpdateNotes("Link zum direkten Aufheben einer Urlaubsschaltung eines Mitgliedes korregiert.");
219 case '0.2.8': // SQL queries for v0.2.8
220 // Update notes (these will be set as task text!)
221 setExtensionUpdateNotes("Sicherheitsupdate für die Include-Befehle.");
224 case '0.2.9': // SQL queries for v0.2.9
225 // Update notes (these will be set as task text!)
226 setExtensionUpdateNotes("if-Anweisungen auf Funktion <strong>empty()</strong> umgestellt. Update-Aufgaben werden nach "Bearbeitung" nicht mehr als <strong>Erledigt</strong> gesetzt. Dies hatte sonst den Anschein, die Update-Aufgaben müssten erledigt werden, um die Erweiterungs-Updates einzuspielen, was aber automatisch geschieht.");
229 case '0.3.0': // SQL queries for v0.3.0
230 // Update notes (these will be set as task text!)
231 setExtensionUpdateNotes("Export-Accounts werden in Task-Übersicht aufgelistet.");
234 case '0.3.1': // SQL queries for v0.3.1
235 // Update notes (these will be set as task text!)
236 setExtensionUpdateNotes("Diverse Fixes an den Templates (Notice-Hinweise vom PHP-Interpreter entfernt).");
239 case '0.3.2': // SQL queries for v0.3.2
240 // This update depends on user update
241 addExtensionDependency('sql_patches');
243 // Update notes (these will be set as task text!)
244 setExtensionUpdateNotes("Hängt nun von <u>ext-user</u> ab.");
249 case 'modify': // When the extension got modified
252 case 'test': // For testing purposes. For details see file inc/modules/admin/what-extensions.php, arround line 305.
255 case 'init': // Do stuff when extension is initialized
258 default: // Unknown extension mode
259 logDebugMessage(__FILE__, __LINE__, sprintf("Unknown extension mode %s in extension %s detected.", getExtensionMode(), getCurrentExtensionName()));