From 76d6665baae1d1485b99323cc4dd2836661295aa Mon Sep 17 00:00:00 2001 From: hernani Date: Fri, 10 Sep 2010 11:16:14 +0000 Subject: [PATCH] Some more changes in node management. Fixed filter reset after action. Added inverse sortings. Added node summary. Removed sort by title. Made descending sort by addedt_at as the default sort. git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@586 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- forum/settings/__init__.py | 1 + .../default/templates/osqaadmin/nodeman.html | 64 +++++++++++++++---- forum/utils/pagination.py | 14 +++- forum/views/admin.py | 22 +++++-- 4 files changed, 81 insertions(+), 20 deletions(-) diff --git a/forum/settings/__init__.py b/forum/settings/__init__.py index ae09261..9b0cbed 100644 --- a/forum/settings/__init__.py +++ b/forum/settings/__init__.py @@ -13,6 +13,7 @@ MAINTAINANCE_MODE = Setting('MAINTAINANCE_MODE', None) SETTINGS_PACK = Setting('SETTINGS_PACK', "default") DJSTYLE_ADMIN_INTERFACE = Setting('DJSTYLE_ADMIN_INTERFACE', True) +NODE_MAN_FILTERS = Setting('NODE_MAN_FILTERS', []) APP_URL = djsettings.APP_URL FORUM_SCRIPT_ALIAS = djsettings.FORUM_SCRIPT_ALIAS diff --git a/forum/skins/default/templates/osqaadmin/nodeman.html b/forum/skins/default/templates/osqaadmin/nodeman.html index 174d8bf..18d3a47 100644 --- a/forum/skins/default/templates/osqaadmin/nodeman.html +++ b/forum/skins/default/templates/osqaadmin/nodeman.html @@ -98,7 +98,20 @@ $form.submit(); } }); - + + $('#filter-name-box').one('focus', function() { + $(this).val(''); + $(this).css('color', 'black'); + }); + + + $('#save-filter-button').click(function() { + var name = $('#filter-name-box').val(); + $.ajax({type:'POST', url: window.location, data: {filtername: name}, success: function() { + $('#pre-filter-container').append('
  • ' + name +'
  • '); + }}); + return false; + }); });