From 52aca2c6e3dfd8bfa59423a75f55b74aba60855a Mon Sep 17 00:00:00 2001 From: Sebastian Riedel Date: Thu, 21 Oct 2004 18:36:44 +0000 Subject: [PATCH] ordering goodness for search results git-svn-id: http://svn.maypole.perl.org/Maypole/trunk@253 48953598-375a-da11-a14b-00016c27c3ee --- templates/factory/list | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/templates/factory/list b/templates/factory/list index b8f4fb8..ac3635f 100644 --- a/templates/factory/list +++ b/templates/factory/list @@ -18,7 +18,15 @@ IF pager; SET additional = additional _ "&o2=desc" IF col == request.query.order and request.query.o2 != "desc"; - link(classmetadata.table, "list", additional, + SET action = "list"; + FOR col = classmetadata.columns.list; + IF request.query.$col; + SET additional = + additional _ "&" _ col _ "=" _ request.query.$col; + SET action = "search"; + END; + END; + link(classmetadata.table, action, additional, classmetadata.colnames.$col); IF col == request.query.order; IF request.query.o2 != "desc"; -- 2.39.5