]> SALOME platform Git repositories - tools/siman.git/commitdiff
Salome HOME
Fix of wrong search results after logout.
authorrkv <rkv@opencascade.com>
Thu, 18 Apr 2013 05:37:49 +0000 (05:37 +0000)
committerrkv <rkv@opencascade.com>
Thu, 18 Apr 2013 05:37:49 +0000 (05:37 +0000)
Workspace/Siman/src/org/splat/simer/AbstractSearchBaseAction.java
Workspace/Siman/src/org/splat/simer/ConnectionAction.java
Workspace/Siman/src/struts.xml

index a2c12dcaade99511cb40743f944811f032a209d2..0ddb11e28bce992a64cc002ab33a10327ceb3b23 100644 (file)
@@ -24,6 +24,8 @@ import org.splat.wapp.Constants;
 /**
  * Base search action class used for searching studies and knowledge.
  * 
+ * @param <FilterClass>
+ *            search filter class
  * @author <a href="mailto:roman.kozlov@opencascade.com">Roman Kozlov (RKV)</a>
  */
 public abstract class AbstractSearchBaseAction<FilterClass extends SearchFilterDTO>
index 484e3548c86d11c6848c6741210be31c8a6a9bdb..4970e14aa0e84e6a48f7e761683ec435f427de73 100644 (file)
@@ -108,6 +108,7 @@ public class ConnectionAction extends Action {
                                if (logged.canContributeToStudy() || logged.canValidate()) {
                                        // TODO: Set the search filter according to user preferences
                                        Map<String, Object> session = getSession();
+                                       session.remove(AbstractSearchBaseAction.RESULT_KEY); // The current result is obsolete
                                        // Map<String,Object> kfilter = (Map<String, Object>)session.get("knowledge.filter");
                                        Map<String, Object> sfilter = (Map<String, Object>) session
                                                        .get("study.filter");
@@ -152,6 +153,7 @@ public class ConnectionAction extends Action {
                try {
                        Map<String, Object> session = getSession();
                        // Map<String,Object> kfilter = (Map<String, Object>)session.get("knowledge.filter");
+                       session.remove(AbstractSearchBaseAction.RESULT_KEY); // The current result is obsolete
                        Map<String, Object> sfilter = (Map<String, Object>) session
                                        .get("study.filter");
                        LoginContext context = (LoginContext) session.get("login.context");
index d3ced39ead3c860d17d154c28ed5763eba1aed03..12a20f32886521e2e478081675805245df5ea651 100644 (file)
                        method="logout">
                        <result name="none" type="tiles">page.home</result>
                        <result name="create" type="tiles">page.home</result>
-                       <result name="open" type="tiles">page.home</result>
+                       <result name="open" type="redirectAction">
+                               select?menu=search
+                       </result>
                        <result name="study" type="tiles">page.home</result>
                        <result name="knowledge" type="tiles">page.home</result>
                        <result name="datadmin" type="tiles">page.home</result>