manifoldcf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From piergior...@apache.org
Subject svn commit: r1210101 - in /incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main: java/org/apache/manifoldcf/crawler/connectors/alfresco/ resource/org/apache/manifoldcf/crawler/connectors/alfresco/
Date Sun, 04 Dec 2011 12:31:44 GMT
Author: piergiorgio
Date: Sun Dec  4 12:31:44 2011
New Revision: 1210101

URL: http://svn.apache.org/viewvc?rev=1210101&view=rev
Log:
added a specific Server tab for Alfresco-related configuration information

Modified:
    incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
    incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/resource/org/apache/manifoldcf/crawler/connectors/alfresco/editConfiguration.js

Modified: incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java?rev=1210101&r1=1210100&r2=1210101&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
(original)
+++ incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/java/org/apache/manifoldcf/crawler/connectors/alfresco/AlfrescoRepositoryConnector.java
Sun Dec  4 12:31:44 2011
@@ -98,6 +98,8 @@ public class AlfrescoRepositoryConnector
 
   /** Read activity */
   protected final static String ACTIVITY_READ = "read document";
+  
+  private static final String ALFRESCO_SERVER_TAB_NAME = "Server";
 
   /**
    * Constructor
@@ -504,6 +506,7 @@ public class AlfrescoRepositoryConnector
   public void outputConfigurationHeader(IThreadContext threadContext,
       IHTTPOutput out, ConfigParams parameters, List<String> tabsArray)
       throws ManifoldCFException, IOException {
+    tabsArray.add(ALFRESCO_SERVER_TAB_NAME);
     outputResource(EDIT_CONFIG_HEADER_FORWARD, out, parameters);
   }
 
@@ -547,8 +550,10 @@ public class AlfrescoRepositoryConnector
     parameters.setParameter(AlfrescoConfig.SERVER_PARAM, server);
     parameters.setParameter(AlfrescoConfig.PORT_PARAM, port);
     parameters.setParameter(AlfrescoConfig.PATH_PARAM, path);
-
-    outputResource(EDIT_CONFIG_FORWARD, out, parameters);
+    
+    if(ALFRESCO_SERVER_TAB_NAME.equals(tabName)){
+      outputResource(EDIT_CONFIG_FORWARD, out, parameters);  
+    }
   }
 
   /**

Modified: incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/resource/org/apache/manifoldcf/crawler/connectors/alfresco/editConfiguration.js
URL: http://svn.apache.org/viewvc/incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/resource/org/apache/manifoldcf/crawler/connectors/alfresco/editConfiguration.js?rev=1210101&r1=1210100&r2=1210101&view=diff
==============================================================================
--- incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/resource/org/apache/manifoldcf/crawler/connectors/alfresco/editConfiguration.js
(original)
+++ incubator/lcf/branches/CONNECTORS-287/connectors/alfresco/connector/src/main/resource/org/apache/manifoldcf/crawler/connectors/alfresco/editConfiguration.js
Sun Dec  4 12:31:44 2011
@@ -19,45 +19,6 @@
 <!--
 function checkConfig()
 {
-  if (editconnection.username.value == "")
-  {
-    alert("The username must be not null");
-    editconnection.username.focus();
-    return false;
-  }
-  if (editconnection.password.value == "")
-  {
-    alert("The password must be not null");
-    editconnection.password.focus();
-    return false;
-  }
-  
-  if (editconnection.server.value ==""){
-	  alert("Server name must be not null");
-	  editconnection.server.focus();
-	  return false;
-  } else if(!editconnection.server.value.indexOf('/')==-1) {
-	  alert("Server name can't contain the character '/'");
-	  editconnection.server.focus();
-	  return false;
-  }
-  
-  if (editconnection.port.value == "")
-  {
-	alert("The port must be not null");
-	editconnection.port.focus();
-	return false;
-  } else if (!isInteger(editconnection.port.value)){
-	alert("The server port must be a valid integer");
-	editconnection.port.focus();
-	return false;
-  }
-  
-  if(editconnection.path.value == ""){
-	  alert("Path must be not null");
-	  editconnection.path.focus();
-	  return false;
-  }
 
   return true;
 }



Mime
View raw message