Changeset 853


Ignore:
Timestamp:
Sep 11, 2006, 6:26:57 PM (15 years ago)
Author:
Dominic Hargreaves
Message:

Temporary fix to make admin page not blow up on large guides: only list 100 most recently modified nodes.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Changes

    r849 r853  
    55        Nodes missing metadata interface
    66        Moderation support (based on Wiki::Toolkit moderation)
     7        Please note: the above three functions should be considered unstable,
     8          and may change over future releases.
    79        Four new config file options: moderation_requires_password,
    810          enable_node_image, enable_common_categories, enable_common_locales
  • trunk/lib/OpenGuides.pm

    r852 r853  
    14251425    my $script_name = $self->config->script_name;
    14261426
    1427     # Grab all the nodes
    1428     my @all_nodes = $wiki->list_all_nodes(with_details=>1);
    1429     @all_nodes = sort { $a->{'name'} cmp $b->{'name'} } @all_nodes;
    1430 
     1427    # Grab all the recent nodes
     1428    my @all_nodes = $wiki->list_recent_changes(last_n_changes => 100);
    14311429
    14321430    # Split into nodes, Locales and Categories
  • trunk/templates/admin_home.tt

    r852 r853  
    1010<h2>Site Administration</h2>
    1111<ul>
    12         <li><a href="#nodes">Nodes</a></li>
    13         <li><a href="#locales">Locales</a></li>
    14         <li><a href="#categories">Categories</a></li>
     12        <li><a href="#nodes">Recent nodes</a></li>
     13        <li><a href="#locales">Recent locales</a></li>
     14        <li><a href="#categories">Recent categories</a></li>
    1515        <li><a href="[% cgi_url %]?action=show_needing_moderation">Pages needing moderation</a>
    1616        <li><a href="[% cgi_url %]?action=show_missing_metadata">Pages missing metadata</a>
    1717</ul>
    1818
     19<p>The lists below show the 100 most recently modified nodes.</p>
     20
    1921<a name="nodes"></a>
    2022<table id="nodes">
    21 <tr><th>Node name</th><th>Current Version</th><th>Moderation</th><th>Actions</th></tr>
     23<tr><th>Node name</th><th>Current Version</th><th>Last modified</th><th>Moderation</th><th>Actions</th></tr>
    2224  [% FOREACH node = nodes %]
    2325     <tr>
    2426     <td class="admin_name"><a href="[% node.view_url %]">[% node.name %]</a></td>
    2527     <td class="admin_version">[% node.version %]</td>
     28     <td class="admin_lastmode">[% node.last_modified %]</td>
    2629     <td class="admin_moderate">[% IF node.moderate %]yes[% ELSE %]no[% END %]</td>
    2730     <td class="admin_action">
     
    3740<a name="locales"></a>
    3841<table id="locales">
    39 <tr><th>Locale name</th><th>Current Version</th><th>Moderation</th><th>Actions</th></tr>
     42<tr><th>Locale name</th><th>Current Version</th><th>Last modified</th><th>Moderation</th><th>Actions</th></tr>
    4043  [% FOREACH locale = locales %]
    4144     <tr>
    4245     <td class="admin_name"><a href="[% locale.view_url %]">[% locale.name %]</a></td>
    4346     <td class="admin_version">[% locale.version %]</td>
     47     <td class="admin_lastmode">[% locale.last_modified %]</td>
    4448     <td class="admin_moderate">[% IF node.moderate %]yes[% ELSE %]no[% END %]</td>
    4549     <td class="admin_action">
     
    5559<a name="categories"></a>
    5660<table id="categories">
    57 <tr><th>Category name</th><th>Current Version</th><th>Moderation</th><th>Actions</th></tr>
     61<tr><th>Category name</th><th>Current Version</th><th>Last modified</th><th>Moderation</th><th>Actions</th></tr>
    5862  [% FOREACH cat = categories %]
    5963     <tr>
    6064     <td class="admin_name"><a href="[% cat.view_url %]">[% cat.name %]</a></td>
    6165     <td class="admin_version">[% cat.version %]</td>
     66     <td class="admin_lastmode">[% cat.last_modified %]</td>
    6267     <td class="admin_moderate">[% IF node.moderate %]yes[% ELSE %]no[% END %]</td>
    6368     <td class="admin_action">
Note: See TracChangeset for help on using the changeset viewer.