<%@LANGUAGE="VBSCRIPT"%> <% '===================================================== '| | '| wFTP | '| | '===================================================== %> <% Option explicit Response.Expires = 0 %> <% '------------ ACCESS CONTROL ------------------ %> <% '------------ VARIABLE DEFINITION ------------- Dim objTabControl Dim objTemplateManager Dim rsQry Dim OsTab '------------ CONSTANTS DECLARATION ----------- '------------ VARIABLE INIT ------------------- Call GetMainDBParameters ( dbPARproj_id, dbPARbranch_id, dbPARbom_id, dbPARnode_id, dbPARos_id, dbPARprod_id ) parNode_id = dbPARnode_id parOs_id = dbPARos_id '------------ CONDITIONS ---------------------- '---------------------------------------------- %> <% '-------------------------------------------------------------------------------------------------------------------------- Function GenerateFTPscript ( nOsId ) Dim rsQry, query, returnString Dim projName, branchName, osName Dim PkgName, PkgVersion, Ext, Description, PkgHealthTag, CmdInterface, Owner, IsInterface, PkgFlag, VersionFlag OraDatabase.Parameters.Add "OS_ID", nOsId, ORAPARM_INPUT, ORATYPE_NUMBER Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("NodeSpecDetails.sql"), ORADYN_DEFAULT ) 'returnString = NULL projName = rsQry("proj_name") branchName = rsQry("branch_name") osName = rsQry("os_name") If osName = "Solaris" Then osName = "sparc" Else osName = "win32" End If OraDatabase.Parameters.Remove "OS_ID" rsQry.Close Set rsQry = Nothing OraDatabase.Parameters.Add "OS_ID", nOsId, ORAPARM_INPUT, ORATYPE_NUMBER Set rsQry = OraDatabase.DbCreateDynaset( GetQuery ("ProductsList.sql"), ORADYN_DEFAULT ) returnString = returnString + "#FTP Script for WIN32" + VBNewLine returnString = returnString + "#ftp -s:" + VBNewLine returnString = returnString + "open auperaunx26" + VBNewLine returnString = returnString + "" + VBNewLine returnString = returnString + "" + VBNewLine returnString = returnString + "binary" + VBNewLine returnString = returnString + "prompt" + VBNewLine returnString = returnString + "cd /export" + VBNewLine returnString = returnString + "cd deploy" + VBNewLine returnString = returnString + "cd releases" + VBNewLine returnString = returnString + "cd "&chr(34)&projName&chr(34) + VBNewLine returnString = returnString + "cd "&chr(34)&branchName&chr(34) + VBNewLine While (NOT rsQry.BOF) AND (NOT rsQry.EOF) If osName = "win32" Then returnString = returnString + "mget "&chr(34)&rsQry("pkg_name")&"/"&osName&"/"&rsQry("pkg_version")&"/release/"&rsQry("pkg_name")&"-"&rsQry("pkg_version")&".exe"&chr(34)&""& VbNewLine Else returnString = returnString + "mget "&chr(34)&rsQry("pkg_name")&"/"&osName&"/"&rsQry("pkg_version")&"/release/"&rsQry("pkg_name")&"-"&rsQry("pkg_version")&".pkg.gz"&chr(34)&""& VbNewLine End If rsQry.MoveNext() WEnd returnString = returnString + "bye" + VBNewLine rsQry.Close Set rsQry = Nothing Set rsQry = OraDatabase.DbCreateDynaset( GetQuery ("ProductsList.sql"), ORADYN_DEFAULT ) projName = Replace(projName, " ", "\ ") projName = Replace(projName, "(", "\(") projName = Replace(projName, ")", "\)") branchName = Replace(branchName, " ", "\ ") returnString = returnString + VBNewLine + VBNewLine + VBNewLine returnString = returnString + "#FTP script for SPARC" + VBNewLine returnString = returnString + "#ftp -n -v auperaunx26 < " + VBNewLine returnString = returnString + "user" + VBNewLine returnString = returnString + "" + VBNewLine returnString = returnString + "binary" + VBNewLine returnString = returnString + "prompt" + VBNewLine returnString = returnString + "cd /export" + VBNewLine returnString = returnString + "cd deploy" + VBNewLine returnString = returnString + "cd releases" + VBNewLine returnString = returnString + "cd "&projName + VBNewLine returnString = returnString + "cd "&branchName + VBNewLine While (NOT rsQry.BOF) AND (NOT rsQry.EOF) returnString = returnString + "cd "&rsQry("pkg_name") + VBNewLine returnString = returnString + "cd "&osName + VBNewLine returnString = returnString + "cd "&rsQry("pkg_version") + VBNewLine returnString = returnString + "cd release" + VBNewLine If osName = "win32" Then returnString = returnString + "get "&rsQry("pkg_name")&"-"&rsQry("pkg_version")&".exe" + VBNewLine Else returnString = returnString + "get "&rsQry("pkg_name")&"-"&rsQry("pkg_version")&".pkg.gz" + VBNewLine End If returnString = returnString + "cd .." + VBNewLine returnString = returnString + "cd .." + VBNewLine returnString = returnString + "cd .." + VBNewLine returnString = returnString + "cd .." + VBNewLine rsQry.MoveNext() WEnd OraDatabase.Parameters.Remove "OS_ID" returnString = returnString + "bye" + VBNewLine rsQry.Close Set rsQry = Nothing ' Return string GenerateFTPscript = returnString End Function '-------------------------------------------------------------------------------------------------------------------------- %> <% '------------ RUN BEFORE PAGE RENDER ---------- '---------------------------------------------- %> Deployment Manager
 FTP Script Export
Click on the text to select.
<% '[1] Tab Name '[2] Tab Link '[3] JavaScript Event e.g. "onClick='...'" '[4] Tab Image Selected '[5] Tab Image Diselected '[6] Tab Image Disabled '[7] Tab Hint '[8] Force Disable. Values: Y, N(default) OraDatabase.Parameters.Add "NODE_ID", parNode_id, ORAPARM_INPUT, ORATYPE_NUMBER Set rsQry = OraDatabase.DbCreateDynaset( GetQuery ("OsList.sql"), ORADYN_DEFAULT ) OraDatabase.Parameters.Remove "NODE_ID" Set objTabControl = New TabControl objTabControl.TemplateDoc = ReadFile( Server.MapPath("controls/ERGTabStyleWinXP/tab_style.html") ) ' Supply tab style definition objTabControl.TabStyle = "StyleWinXP" If Request("ostab") <> "" Then OsTab = CDbl( Request("ostab") ) Else OsTab = 0 End If While (NOT rsQry.BOF) AND (NOT rsQry.EOF) objTabControl.Add ( Array( rsQry("os_name"), SCRIPT_NAME &"?ostab="& rsQry("os_id") &"&"& objPMod.ComposeURL() , "", "", "", "", "", "" ) ) If OsTab = 0 Then OsTab = CDbl( rsQry("os_id")) objTabControl.SelectByName rsQry("os_name") ElseIf OsTab = CDbl(rsQry("os_id")) Then OsTab = rsQry("os_id") objTabControl.SelectByName rsQry("os_name") End If rsQry.MoveNext() WEnd rsQry.Close() Set rsQry = nothing objTabControl.Render () %>
 
 
<% '------------ RUN AFTER PAGE RENDER ----------- '---------------------------------------------- %>