Dotclear


Ignore:
Timestamp:
10/03/13 00:57:41 (12 years ago)
Author:
Denis Jean-Chirstian <contact@…>
Branch:
dcRepo
Message:

Enhance repository search engine (and some fix)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • inc/admin/lib.moduleslist.php

    r2221 r2222  
    269269                    'tags'                   => '', 
    270270                    'details'                => '', 
    271                     'sshot'             => '' 
     271                    'sshot'             => '', 
     272                    'score'                  => 0 
    272273               ), 
    273274               # Module's values 
     
    314315          } 
    315316 
     317          if (in_array('score', $cols) && $this->getSearchQuery() !== null && defined('DC_DEBUG') && DC_DEBUG) { 
     318               echo  
     319               '<th class="nowrap">'.__('Score').'</th>'; 
     320          } 
     321 
    316322          if (in_array('version', $cols)) { 
    317323               echo  
     
    381387                    html::escapeHTML($module['name']) 
    382388               ).'</td>'; 
     389 
     390               # Display score only for debug purpose 
     391               if (in_array('score', $cols) && $this->getSearchQuery() !== null && defined('DC_DEBUG') && DC_DEBUG) { 
     392                    echo  
     393                    '<td class="module-version nowrap count"><span class="debug">'.$module['score'].'</span></td>'; 
     394               } 
    383395 
    384396               if (in_array('version', $cols)) { 
     
    863875               } 
    864876 
     877               # Display score only for debug purpose 
     878               if (in_array('score', $cols) && $this->getSearchQuery() !== null && defined('DC_DEBUG') && DC_DEBUG) { 
     879                    $line .=  
     880                    '<p class="module-score debug">'.sprintf(__('Score: %s'), $module['score']).'</p>'; 
     881               } 
     882 
    865883               if (in_array('sshot', $cols)) { 
    866884                    # Screenshot from url 
     
    901919               } 
    902920 
     921               if (in_array('current_version', $cols)) { 
     922                    $line .=  
     923                    '<span class="module-current-version">'.sprintf(__('(current version %s)'),html::escapeHTML($module['current_version'])).'</span> '; 
     924               } 
     925 
    903926               if (in_array('parent', $cols) && $has_parent) { 
    904927                    if ($is_parent_present) { 
     
    910933                         '<span class="module-parent-missing">'.sprintf(__('(requires "%s")'),html::escapeHTML($parent)).'</span> '; 
    911934                    } 
    912                } 
    913  
    914                if (in_array('version', $cols)) { 
    915                     $line .=  
    916                     '<span class="module-version">'.sprintf(__('version %s'),html::escapeHTML($module['version'])).'</span> '; 
    917935               } 
    918936 
Note: See TracChangeset for help on using the changeset viewer.

Sites map