Author: magnuse
Date: 2006-04-02 20:23:08 +0200 (Sun, 02 Apr 2006)
New Revision: 2690

Modified:
   
trunk/src/java/no/schibstedsok/front/searchportal/command/AbstractSimpleFastSearchCommand.java
   
trunk/src/java/no/schibstedsok/front/searchportal/configuration/FastConfiguration.java
Log:
Added posibility to set a fast filter in tabs.xml


Modified: 
trunk/src/java/no/schibstedsok/front/searchportal/command/AbstractSimpleFastSearchCommand.java
===================================================================
--- 
trunk/src/java/no/schibstedsok/front/searchportal/command/AbstractSimpleFastSearchCommand.java
      2006-03-31 14:05:35 UTC (rev 2689)
+++ 
trunk/src/java/no/schibstedsok/front/searchportal/command/AbstractSimpleFastSearchCommand.java
      2006-04-02 18:23:08 UTC (rev 2690)
@@ -663,7 +663,13 @@
             filter.append(getAdditionalFilter());
         }
 
+        if (getFastConfiguration().getFilter() != null) {
+            filter.append(" ");
+            filter.append(getFastConfiguration().getFilter());
+        }
+
         // Init dynamic filters
+        // TODO: Is the following used anywhere?
         String dynamicLanguage = getDynamicParams(getParameters(), "language", 
"");
         String dynamicFilterType = getDynamicParams(getParameters(), 
"filtertype", "any");
         String dynamicType = getDynamicParams(getParameters(), "type", "all");
@@ -673,6 +679,7 @@
             superFilter = "";
         }
 
+
         if (LOG.isDebugEnabled()) {
             LOG.debug("createQuery: superFilter=" + superFilter);
         }

Modified: 
trunk/src/java/no/schibstedsok/front/searchportal/configuration/FastConfiguration.java
===================================================================
--- 
trunk/src/java/no/schibstedsok/front/searchportal/configuration/FastConfiguration.java
      2006-03-31 14:05:35 UTC (rev 2689)
+++ 
trunk/src/java/no/schibstedsok/front/searchportal/configuration/FastConfiguration.java
      2006-04-02 18:23:08 UTC (rev 2690)
@@ -34,6 +34,7 @@
     private int offensiveScoreLimit = 0;
     private int spamScoreLimit = 0;
 
+    private String filter;
 
     private boolean synonymsEnabled = false;
 
@@ -213,4 +214,8 @@
     public boolean isSynonymsEnabled() {
         return synonymsEnabled;
     }
+
+    public String getFilter() {
+        return filter;
+    }
 }

_______________________________________________
Kernel-commits mailing list
[email protected]
http://sesat.no/mailman/listinfo/kernel-commits

Reply via email to