Rewritten overview-inc.php, internal TODO closed
authorRoland Häder <roland@mxchange.org>
Tue, 10 Mar 2009 23:55:36 +0000 (23:55 +0000)
committerRoland Häder <roland@mxchange.org>
Tue, 10 Mar 2009 23:55:36 +0000 (23:55 +0000)
.gitattributes
.gitignore
DOCS/TODOs.txt
DOCS/todo-builder.sh
inc/modules/admin/admin-inc.php
inc/modules/admin/overview-inc.php
templates/de/html/admin/admin_overview_footer.tpl
templates/de/html/admin/admin_overview_header.tpl
templates/de/html/admin/admin_overview_list.tpl
templates/de/html/admin/admin_overview_table.tpl [new file with mode: 0644]

index 7bcf57b..51f8117 100644 (file)
@@ -1139,6 +1139,7 @@ templates/de/html/admin/admin_overview_list.tpl -text
 templates/de/html/admin/admin_overview_list_ext_rows.tpl -text
 templates/de/html/admin/admin_overview_list_rows.tpl -text
 templates/de/html/admin/admin_overview_row.tpl -text
+templates/de/html/admin/admin_overview_table.tpl -text
 templates/de/html/admin/admin_overview_task.tpl -text
 templates/de/html/admin/admin_overview_task_extras.tpl -text
 templates/de/html/admin/admin_overview_task_rows.tpl -text
index 9160c0a..e14734f 100644 (file)
@@ -6,4 +6,3 @@ inc/.secret/dummy.php
 inc/cache/*.cache
 inc/cache/*.log
 inc/cache/.revision
-inc/config.php
index 61cdc9f..19370da 100644 (file)
@@ -4,24 +4,24 @@
 ./inc/extensions/ext-sql_patches.php:755:                      // @TODO Rewrite this to a filter!
 ./inc/extensions/ext-sql_patches.php:793:              // @TODO Can we remove this? setConfigEntry('verbose_sql'        , "N");
 ./inc/extensions/ext-sql_patches.php:95:       /* @TODO SQL_ALTER_TABLE() should work now properly
-./inc/extensions.php:317:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) )
-./inc/extensions.php:386:              // @TODO Extension is loaded, what next?
-./inc/functions.php:1241:      // @TODO Rewrite this unnice code
-./inc/functions.php:1302:      // @TODO Remove this if() block if all is working fine
-./inc/functions.php:1602:              // @TODO This can be, somehow, rewritten
-./inc/functions.php:2327:// @TODO Rewrite all language constants to this function.
-./inc/functions.php:2574:                      $GLOBALS['cache_instance']->destroyCacheFile(); // @TODO isn't it better to do $GLOBALS['cache_instance']->destroyCacheFile('revision')?
-./inc/functions.php:2576:                      // @TODO shouldn't do the unset and the reloading $GLOBALS['cache_instance']->destroyCacheFile() Or a new methode like forceCacheReload('revision')?
-./inc/functions.php:259:                       // @TODO Fine all templates which are using these direct variables and rewrite them.
-./inc/functions.php:260:                       // @TODO After this step is done, this else-block is history
-./inc/functions.php:2653:      // @TODO What does this loop/regex do? Document it, please.
-./inc/functions.php:2746:              // @TODO Add a little more infos here
-./inc/functions.php:2756:      // @TODO This cannot be rewritten to mxchange_die(), try to find a solution for this.
-./inc/functions.php:2861:// @TODO Implement $compress
-./inc/functions.php:2868:// @TODO Implement $decompress
-./inc/functions.php:2971:      // @TODO We may want to switch over to UTF-8 here!
-./inc/functions.php:2979:// @TODO Rewrite this function to use READ_FILE() and WRITE_FILE()
-./inc/functions.php:475:// @TODO Rewrite this to an extension 'smtp'
+./inc/extensions.php:324:// @TODO Change from ext_id to ext_name (not just even the variable! ;-) )
+./inc/extensions.php:400:              // @TODO Extension is loaded, what next?
+./inc/functions.php:1229:      // @TODO Rewrite this unnice code
+./inc/functions.php:1290:      // @TODO Remove this if() block if all is working fine
+./inc/functions.php:1590:              // @TODO This can be, somehow, rewritten
+./inc/functions.php:2315:// @TODO Rewrite all language constants to this function.
+./inc/functions.php:246:                       // @TODO Fine all templates which are using these direct variables and rewrite them.
+./inc/functions.php:247:                       // @TODO After this step is done, this else-block is history
+./inc/functions.php:2563:                      $GLOBALS['cache_instance']->destroyCacheFile(); // @TODO isn't it better to do $GLOBALS['cache_instance']->destroyCacheFile('revision')?
+./inc/functions.php:2565:                      // @TODO shouldn't do the unset and the reloading $GLOBALS['cache_instance']->destroyCacheFile() Or a new methode like forceCacheReload('revision')?
+./inc/functions.php:2637:      searchDirsRecursive($next_dir, $last_changed); // @TODO small change to API to $last_changed = searchDirsRecursive($next_dir, $time);
+./inc/functions.php:2749:              // @TODO Add a little more infos here
+./inc/functions.php:2760:      // @TODO This cannot be rewritten to mxchange_die(), try to find a solution for this.
+./inc/functions.php:2865:// @TODO Implement $compress
+./inc/functions.php:2872:// @TODO Implement $decompress
+./inc/functions.php:2975:      // @TODO We may want to switch over to UTF-8 here!
+./inc/functions.php:2983:// @TODO Rewrite this function to use READ_FILE() and WRITE_FILE()
+./inc/functions.php:462:// @TODO Rewrite this to an extension 'smtp'
 ./inc/language/de.php:1154:// @TODO Rewrite these two constants
 ./inc/language/de.php:1170:// @TODO Rewrite these five constants
 ./inc/language/de.php:756:// @TODO The template 'admin_extensions_installed' is using this. But the template is no longer used.
@@ -43,9 +43,9 @@
 ./inc/libs/surfbar_functions.php:917:  // @TODO Invalid salt should be refused
 ./inc/libs/task_functions.php:261:             // @TODO These can be rewritten to filter
 ./inc/libs/task_functions.php:53:// @TODO Move all extension-dependent queries into filters
-./inc/libs/user_functions.php:311:                     // @TODO Make this filter working: $ADDON = runFilterChain('post_login_update', array('login' => $login, 'online' => $online));
-./inc/libs/user_functions.php:335:                     // @TODO Make this filter working: $URL = runFilterChain('do_login', array('uid' => $uid, 'hash' => $hash, 'addon' => $ADDON));
-./inc/libs/user_functions.php:370:             // @TODO Can this query be merged with above query?
+./inc/libs/user_functions.php:317:                     // @TODO Make this filter working: $ADDON = runFilterChain('post_login_update', $content);
+./inc/libs/user_functions.php:342:                     // @TODO Make this filter working: $URL = runFilterChain('do_login', array('content' => $content, 'addon' => $ADDON));
+./inc/libs/user_functions.php:377:             // @TODO Can this query be merged with above query?
 ./inc/libs/yoomedia_functions.php:65:  $response = YOOMEDIA_QUERY_API("out_textmail.php", true); // @TODO Ask Yoo!Media for test script
 ./inc/load_extensions.php:13: * @TODO Rewrite this whole file to load_cache-extensions.php           *
 ./inc/mails/birthday_mails.php:85:                     // @TODO 4 is hard-coded here, should we move it out in config?
@@ -57,9 +57,8 @@
 ./inc/modules/admin/overview-inc.php:268:                                      // @TODO This may also be rewritten to include files
 ./inc/modules/admin/overview-inc.php:271:                                      default: // @TODO Unknown support mode
 ./inc/modules/admin/overview-inc.php:389:              // @TODO Rewrite this to one template and use $OUT = ...
-./inc/modules/admin/overview-inc.php:419:                      // @TODO Rewritings: admin->assigned_admin,uid->userid,type->task_type_msg in template
-./inc/modules/admin/overview-inc.php:431:                              // @TODO Rewrite this to $OUT .= ..., true, ...
-./inc/modules/admin/overview-inc.php:435:                              // @TODO Rewrite this to $OUT .= ..., true, ...
+./inc/modules/admin/overview-inc.php:418:                      // @TODO Rewritings: admin->assigned_admin,uid->userid,type->task_type_msg in template
+./inc/modules/admin.php:257:   // @TODO Rewrite all these constants
 ./inc/modules/admin.php:94:                            // @TODO Why is this set to 'done'?
 ./inc/modules/admin/what-add_points.php:120:                   // @TODO Rewrite these both constants
 ./inc/modules/admin/what-add_points.php:54:            // @TODO Rewrite this constant
 ./inc/modules/member/what-transfer.php:364:    // @TODO Rewrite these constants
 ./inc/modules/member/what-transfer.php:451:    // @TODO Rewrite all these constants
 ./inc/modules/member/what-unconfirmed.php:134: // @TODO Try to rewrite this to $content = SQL_FETCHARRAY()
-./inc/mysql-manager.php:1516:                  // @TODO Try to rewrite this to $content = SQL_FETCHARRAY()
-./inc/mysql-manager.php:1725:                          // @TODO Find a way for updating $_CONFIG here
+./inc/mysql-manager.php:1523:                  // @TODO Try to rewrite this to $content = SQL_FETCHARRAY()
+./inc/mysql-manager.php:1738:                          // @TODO Find a way for updating $_CONFIG here
 ./inc/mysql-manager.php:173:                   // @TODO Nothing helped???
-./inc/mysql-manager.php:1749:          // @TODO Find a way for updating $_CONFIG here
-./inc/mysql-manager.php:1833:                  // @TODO Rewrite this to $content = SQL_FETCHARRAY()
-./inc/mysql-manager.php:2127:          // @TODO This can be somehow rewritten
+./inc/mysql-manager.php:1762:          // @TODO Find a way for updating $_CONFIG here
+./inc/mysql-manager.php:1846:                  // @TODO Rewrite this to $content = SQL_FETCHARRAY()
+./inc/mysql-manager.php:2140:          // @TODO This can be somehow rewritten
 ./inc/mysql-manager.php:617:   // @TODO Why is this global??? #100
 ./inc/mysql-manager.php:945:                   // @TODO Why does this lead into an endless loop but we still need it???
 ./inc/mysql-manager.php:946:                   // @TODO Commented out LOAD_URL("admin.php");
 ./mailid_top.php:211:                                                                  // @TODO Rewrite these blocks to filter
 ./surfbar.php:65:              // @TODO Display quick login form here or redirect as configured
+### ### DEPRECATION FOLLOWS: ### ###
+./inc/extensions/ext-sql_patches.php:587:              // @DEPRECATED ADD_EXT_SQL("UPDATE `{!_MYSQL_PREFIX!}_user_data` SET gender=sex WHERE sex != 'M'");
+./inc/extensions/ext-sql_patches.php:588:              // @DEPRECATED ADD_EXT_SQL("ALTER TABLE `{!_MYSQL_PREFIX!}_user_data` DROP sex");
+./inc/functions.php:231:       // @DEPRECATED Try to rewrite the if() condition
+./inc/functions.php:2325:              // @DEPRECATED Language array element found in BIG_LETTERS
+./inc/functions.php:2328:              // @DEPRECATED Deprecated constant found
+./inc/functions.php:245:                       // @DEPRECATED
+./inc/modules/admin/what-user_online.php:2:// @DEPRECATED
index a005c9b..cabf20a 100644 (file)
@@ -12,7 +12,7 @@ echo "$0: Generating TODOs.txt..."
 echo "### WARNING: THIS FILE IS AUTO-GENERATED BY $0 ###" > DOCS/TODOs.txt
 echo "### DO NOT EDIT THIS FILE. ###" >> DOCS/TODOs.txt
 find -type f -name "*.php" -exec grep -Hin "@TODO" {} \; | sort >> DOCS/TODOs.txt
-echo "### ### DEPRECATION FOLLOWS: ### ###" >> docs/TODOs.txt
+echo "### ### DEPRECATION FOLLOWS: ### ###" >> DOCS/TODOs.txt
 find -type f -name "*.php" -exec grep -Hin "@DEPRECATED" {} \; | sort >> DOCS/TODOs.txt
 echo "$0: Done."
 exit 0
index abb5ba5..7fbc404 100644 (file)
@@ -357,7 +357,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                }
                                $OUT .= "<tr>
        <td class=\"admin_menu\" colspan=\"2\">
-               <nobr>&nbsp;<strong>&middot;</strong>&nbsp;";
+               <div class=\"nobr\">&nbsp;<strong>&middot;</strong>&nbsp;";
 
                                if (($menu == $act) && (empty($wht))) {
                                        $OUT .= "<strong>";
@@ -373,7 +373,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                        $OUT .= "</a>]";
                                }
 
-                               $OUT .= "</nobr></td>
+                               $OUT .= "</div></td>
 </tr>\n";
 
                                // Check for menu entries
@@ -384,7 +384,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                setAdminMenuHasEntries($menu, ((SQL_NUMROWS($result_what) > 0) && ($act == $menu)));
 
                                // Do we have entries?
-                               if (ifAdminMenuHasEntries($menu)) {
+                               if ((ifAdminMenuHasEntries($menu)) && (SQL_NUMROWS($result_what) > 0)) {
                                        $GLOBALS['menu']['description'] = array();
                                        $GLOBALS['menu']['title'] = array(); $SUB = true;
                                        $OUT .= "<tr>
@@ -412,7 +412,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                                        $GLOBALS['menu']['description'][$wht_sub] = $desc_what;
                                                        $OUT .= "<tr>
        <td class=\"admin_menu\" colspan=\"2\">
-               <nobr>&nbsp;<strong>--&gt;</strong>&nbsp;";
+               <div class=\"nobr\">&nbsp;<strong>--&gt;</strong>&nbsp;";
                                                        if ($readable === true) {
                                                                if ($wht == $wht_sub) {
                                                                        $OUT .= "<strong>";
@@ -434,7 +434,7 @@ function ADD_ADMIN_MENU ($act, $wht, $return=false) {
                                                        } else {
                                                                $OUT .= "</em>";
                                                        }
-                                                       $OUT .= "</nobr></td>
+                                                       $OUT .= "</div></td>
 </tr>\n";
                                                }
                                        }
index aff833a..54f0fbf 100644 (file)
@@ -387,7 +387,6 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
 
                // There are uncompleted jobs!
                // @TODO Rewrite this to one template and use $OUT = ...
-               LOAD_TEMPLATE("admin_overview_header");
                $OUT = ""; $SW = 2;
                while ($content = SQL_FETCHARRAY($result_tasks)) {
                        // Init infos
@@ -428,12 +427,10 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                        // Do we have extension task?
                        if (($content['task_type'] == "EXTENSION") && (GET_EXT_VERSION($content['infos']) == "")) {
                                // Load extension row template
-                               // @TODO Rewrite this to $OUT .= ..., true, ...
-                               LOAD_TEMPLATE("admin_overview_list_ext_rows", false, $content);
+                               $OUT .= LOAD_TEMPLATE("admin_overview_list_ext_rows", true, $content);
                        } else {
                                // Load default row template
-                               // @TODO Rewrite this to $OUT .= ..., true, ...
-                               LOAD_TEMPLATE("admin_overview_list_rows", false, $content);
+                               $OUT .= LOAD_TEMPLATE("admin_overview_list_rows", true, $content);
                        }
 
                        // Switch color
@@ -444,7 +441,7 @@ function OUTPUT_SELECTED_TASKS ($POST, $result_tasks) {
                SQL_FREERESULT($result_tasks);
 
                // Load footer template
-               LOAD_TEMPLATE("admin_overview_footer");
+               LOAD_TEMPLATE("admin_overview_table", false, $OUT);
        }
 }
 //
index ec0a459..11f5d85 100644 (file)
@@ -1,12 +1 @@
-<tr>
-       <td colspan="7" align="center" class="admin_footer bottom2 left2 right2">
-               <input type="reset" value="{--ADMIN_UNSELECT_ALL--}" class="admin_reset" />
-               <input type="submit" name="assign" value="{--ADMIN_ASSIGN_TASKS--}" class="admin_submit" />
-               <input type="submit" name="unassign" value="{--ADMIN_UNASSIGN_TASKS--}" class="admin_submit" />
-               <input type="submit" name="redir" value="{--ADMIN_REDIRECT_TASKS--}" class="admin_submit" />
-               <input type="submit" name="del" value="{--ADMIN_DELETE_ENTRIES--}" class="admin_delete" />
-       </td>
-</tr>
-</table>
-</div>
-</form>
+<!-- @DEPRECATED //-->
index f203017..11f5d85 100644 (file)
@@ -1,16 +1 @@
-<form action="{!URL!}/modules.php?module=admin&amp;action=login" method="post" style="margin-bottom: 0px">
-<table border="0" cellspacing="0" cellpadding="0" width="95%" align="center" class="admin_table">
-<tr>
-       <td colspan="7" align="center" class="admin_task_header top2 left2 right2">
-               <div class="admin_welcome">{--ADMIN_TASK_SYSTEM_WELCOME--}</div>
-       </td>
-</tr>
-<tr>
-       <td align="center" class="top2 bottom2 right2 left2 admin_header"><strong>{--ID_SELECT--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_ASSIGNED_ADMIN--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_REGISTER_EXTENSION--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_INFOS--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_MEMBER_UID--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_TYPE--}</strong></td>
-       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_CREATED--}</strong></td>
-</tr>
+<!-- @DEPRECATED //-->
index 4a6eb98..1d8ddd1 100644 (file)
@@ -1,9 +1,8 @@
-<table border="0" cellspacing="0" cellpadding="0" width="95%"
-       align="center" class="admin_table">
-       <tr>
-               <td colspan="3" align="center"
-                       class="admin_task_header top2 bottom2 left2 right2"><strong
-                       class="admin_welcome">{--ADMIN_SELECTED_TASKS_ASSIGN--}:</strong></td>
-       </tr>
-       {!__TASK_ROWS!}
+<table border="0" cellspacing="0" cellpadding="0" width="95%" align="center" class="admin_table">
+<tr>
+       <td colspan="3" align="center" class="admin_task_header top2 bottom2 left2 right2">
+               <strong class="admin_welcome">{--ADMIN_SELECTED_TASKS_ASSIGN--}:</strong>
+       </td>
+</tr>
+{!__TASK_ROWS!}
 </table>
diff --git a/templates/de/html/admin/admin_overview_table.tpl b/templates/de/html/admin/admin_overview_table.tpl
new file mode 100644 (file)
index 0000000..40cf164
--- /dev/null
@@ -0,0 +1,30 @@
+<div align="center">
+<form action="{!URL!}/modules.php?module=admin&amp;action=login" method="post" style="margin-bottom: 0px">
+<table border="0" cellspacing="0" cellpadding="0" width="95%" align="center" class="admin_table">
+<tr>
+       <td colspan="7" align="center" class="admin_task_header top2 left2 right2">
+               <div class="admin_welcome">{--ADMIN_TASK_SYSTEM_WELCOME--}</div>
+       </td>
+</tr>
+<tr>
+       <td align="center" class="top2 bottom2 right2 left2 admin_header"><strong>{--ID_SELECT--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_ASSIGNED_ADMIN--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_REGISTER_EXTENSION--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_INFOS--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_MEMBER_UID--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_TYPE--}</strong></td>
+       <td align="center" class="top2 bottom2 right2 admin_header"><strong>{--ADMIN_TASK_CREATED--}</strong></td>
+</tr>
+$content
+<tr>
+       <td colspan="7" align="center" class="admin_footer bottom2 left2 right2">
+               <input type="reset" value="{--ADMIN_UNSELECT_ALL--}" class="admin_reset" />
+               <input type="submit" name="assign" value="{--ADMIN_ASSIGN_TASKS--}" class="admin_submit" />
+               <input type="submit" name="unassign" value="{--ADMIN_UNASSIGN_TASKS--}" class="admin_submit" />
+               <input type="submit" name="redir" value="{--ADMIN_REDIRECT_TASKS--}" class="admin_submit" />
+               <input type="submit" name="del" value="{--ADMIN_DELETE_ENTRIES--}" class="admin_delete" />
+       </td>
+</tr>
+</table>
+</form>
+</div>