src/web/js/acsimpleconfig.js
/**
 * This method stores the configuration.
 *
 * @param nConfigNode The current configuration node.
 */
This method stores the configuration.

@param nConfigNode The current configuration node.
This method stores the configuration . @param nConfigNode The current configuration node .
function createConnectorConfiguration(nConfigNode)
{
	if (DEBUG_USERS.indexOf(system.getUser().name) > -1)
	{
		debugger;
	}
    var nData = mdlConfiguration.getData();
    if (nData != null)
    {
        var nClonedData = nData.cloneNode(true);
        var nInbound = nClonedData.selectSingleNode("inbound");
        storeXMLFromTextArea(taEmailBoxes, nInbound, "emailboxes");
        var nOutbound = nClonedData.selectSingleNode("outbound");
        storeXMLFromTextArea(taKeyManagers, nOutbound, "keymanagers");
        storeXMLFromTextArea(taSMTPServers, nOutbound, "smtpservers");
        encodePasswords(nClonedData, "//emailbox/password");
        encodePasswords(nClonedData, "//keymanager/password");
        encodePasswords(nClonedData, "//smtpserver/password");
        encodePasswords(nClonedData, "//parameter[@name='password']");
        encodePasswords(nClonedData, "//certificate/password");
        var alNodes = nClonedData.selectNodes("//*[@inserted]");
        for (var iCount = 0; alNodes != null && iCount < alNodes.length; iCount++)
        {
            alNodes[iCount].removeAttribute("inserted");
        }
        var alNodes = nClonedData.selectNodes("//*[@sync_id]");
        for (var iCount = 0; alNodes != null && iCount < alNodes.length; iCount++)
        {
            alNodes[iCount].removeAttribute("sync_id");
        }
        var alNodes = nClonedData.selectNodes("//*[@clientattr:sync_id]");
        for (var iCount = 0; alNodes != null && iCount < alNodes.length; iCount++)
        {
            alNodes[iCount].removeAttribute("clientattr:sync_id");
        }
        var nGeneral = nClonedData.selectSingleNode("general");
        createStorageConfiguration(nGeneral);
        nConfigNode.appendChild(nClonedData);
    }
    return true;
}
function createConnectorConfiguration ( nConfigNode ) { if ( DEBUG_USERS . indexOf ( system . getUser ( ) . name ) > - 1 ) { debugger ; } var nData = mdlConfiguration . getData ( ) ; if ( nData != null ) { var nClonedData = nData . cloneNode ( true ) ; var nInbound = nClonedData . selectSingleNode ( "inbound" ) ; storeXMLFromTextArea ( taEmailBoxes , nInbound , "emailboxes" ) ; var nOutbound = nClonedData . selectSingleNode ( "outbound" ) ; storeXMLFromTextArea ( taKeyManagers , nOutbound , "keymanagers" ) ; storeXMLFromTextArea ( taSMTPServers , nOutbound , "smtpservers" ) ; encodePasswords ( nClonedData , "//emailbox/password" ) ; encodePasswords ( nClonedData , "//keymanager/password" ) ; encodePasswords ( nClonedData , "//smtpserver/password" ) ; encodePasswords ( nClonedData , "//parameter[@name='password']" ) ; encodePasswords ( nClonedData , "//certificate/password" ) ; var alNodes = nClonedData . selectNodes ( "//*[@inserted]" ) ; for ( var iCount = 0 ; alNodes != null && iCount < alNodes . length ; iCount ++ ) { alNodes [ iCount ] . removeAttribute ( "inserted" ) ; } var alNodes = nClonedData . selectNodes ( "//*[@sync_id]" ) ; for ( var iCount = 0 ; alNodes != null && iCount < alNodes . length ; iCount ++ ) { alNodes [ iCount ] . removeAttribute ( "sync_id" ) ; } var alNodes = nClonedData . selectNodes ( "//*[@clientattr:sync_id]" ) ; for ( var iCount = 0 ; alNodes != null && iCount < alNodes . length ; iCount ++ ) { alNodes [ iCount ] . removeAttribute ( "clientattr:sync_id" ) ; } var nGeneral = nClonedData . selectSingleNode ( "general" ) ; createStorageConfiguration ( nGeneral ) ; nConfigNode . appendChild ( nClonedData ) ; } return true ; }
This method stores the configuration.
This method stores the configuration .
//Replace the email boxes with the one from the edit
 //Do the same for the key managers and SMTP servers
 //Encode all the passwords.
 //Remove the inserted attribute
 //Remove the sync_id attribute
 // Now we need to store the storage configuration. This is done based on the existing tab.
