<%@LANGUAGE="VBSCRIPT"%> <% '===================================================== '| | '| RequestProductLocation | '| | '===================================================== %> <% Option explicit Response.Expires = 0 %> <% '------------ VARIABLE DEFINITION ------------- Dim IsProductInNewBom Dim QueryName ' parameters refering to production BOM items Dim parProdBomId Dim parProdBomProdId ' parameters refering this BOM items Dim parThisBomId Dim parThisProdId Dim parThisPkgId Dim parThisVersion '------------ CONSTANTS DECLARATION ----------- '------------ VARIABLE INIT ------------------- parProdBomId = Request("bom_id") parProdBomProdId = Request("prod_id") parThisBomId = Request("compare_bom_id") parThisProdId = Request("new_prod_id") parThisPkgId = Request("pkg_id") parThisVersion = Request("new_version") '------------ CONDITIONS ---------------------- '---------------------------------------------- %> <% '-------------------------------------------------------------------------------------------------------------- '-------------------------------------------------------------------------------------------------------------- %> <% '------------ RUN BEFORE PAGE RENDER ---------- 'If (Request("change_type") = "R") Then ' QueryName = "BomRemovedProductLocation.sql" ' IsProductInNewBom = FALSE 'ElseIf (Request("change_type") = "U") Then ' QueryName = "BomUpdatedProductLocation.sql" ' IsProductInNewBom = FALSE 'Else QueryName = "BomAddedProductLocation.sql" ' IsProductInNewBom = TRUE 'End If '---------------------------------------------- %> <% ' parThisBomId is the ID of the BOM under which exists the package version that was clicked that led to this file being processed. ' It is not the production BOM, which is referred to by parProdBomId. ' parThisProdId is the ID of the product in the BOM refered to by parThisBomId ' parThisPkgId is the ID of the package of which the product is just one instance (version) of. OraDatabase.Parameters.Add "BOM_ID", parThisBomId, ORAPARM_INPUT, ORATYPE_NUMBER OraDatabase.Parameters.Add "PROD_ID", parThisProdId, ORAPARM_INPUT, ORATYPE_NUMBER OraDatabase.Parameters.Add "PKG_ID", parThisPkgId, ORAPARM_INPUT, ORATYPE_NUMBER Dim rsQryThisBom Set rsQryThisBom = OraDatabase.DbCreateDynaset( GetQuery ( QueryName ), ORADYN_DEFAULT ) Dim bgColor bgColor = NULL If rsQryThisBom.RecordCount < 1 Then %> <% End If While (NOT rsQryThisBom.BOF) AND (NOT rsQryThisBom.EOF) If IsNull( bgColor ) Then bgColor = "bgcolor='#F5F5F5'" Else bgColor = NULL End If If parProdBomId <> "" AND parThisProdId <> "" Then ' Get information from package_versions table for this product Dim rsQryThisBomPkgVer, ThisBomPkgName, ThisBomPkgVersion, ThisBomPkgId Set rsQryThisBomPkgVer = OraDatabase.DbCreateDynaset( "select * from package_versions pv, packages pkg where pv.pv_id = "&parThisProdId&" and pkg.pkg_id = pv.pkg_id", cint(0)) ThisBomPkgName = rsQryThisBomPkgVer("pkg_name") ThisBomPkgVersion = rsQryThisBomPkgVer("pkg_version") ThisBomPkgId = rsQryThisBomPkgVer("pkg_id") rsQryThisBomPkgVer.Close() Set rsQryThisBomPkgVer = nothing ' Get the project and branch name for the production BOM Dim rsQryProdBom, ProdBomProjName, ProdBomBranchName Set rsQryProdBom = OraDatabase.DbCreateDynaset( "select br.branch_name, prj.proj_name from boms bm, branches br, dm_projects prj where bm.bom_id = "&parProdBomId&" and br.BRANCH_ID = bm.RTAG_ID_FK and prj.PROJ_ID = br.PROJ_ID", cint(0)) ProdBomProjName = rsQryProdBom("proj_name") ProdBomBranchName = rsQryProdBom("branch_name") rsQryProdBom.Close() Set rsQryProdBom = nothing ' Get the OS name Dim rsOS, OSName Set rsOS = OraDatabase.DbCreateDynaset( "select bt.bos_type from os_base_env obe, base_env be, bos_types bt where obe.OS_ID = "&rsQryThisBom("os_id")&" and be.BASE_ENV_ID = obe.BASE_ENV_ID and bt.BOS_ID = be.BOS_ID", cint(0)) OSName = rsOS("bos_type") If OSName = "Windows" OR OSName = "MOS" Then OSName = "win32" Else OSName = "sparc" End If rsOS.Close() Set rsOS = nothing End If ' Now display the information we have gathered %> <% rsQryThisBom.MoveNext WEnd OraDatabase.Parameters.Remove "BOM_ID" OraDatabase.Parameters.Remove "PROD_ID" OraDatabase.Parameters.Remove "PKG_ID" rsQryThisBom.Close Set rsQryThisBom = Nothing %>
Product Notes
nowrap valign="top" class="body_row" colspan="2">Product not found.
nowrap valign="top" class="body_row" colspan="2">     <%'If IsProductInNewBom Then%> " align="absmiddle" border="0">&bom_id=<%=parThisBomId%>" class="body_link"><%=rsQryThisBom("node_name")%>  / &bom_id=<%=parThisBomId%>" class="body_link"><%=rsQryThisBom("os_name") %>  / <%=rsQryThisBom("pkg_name") &" "& rsQryThisBom("pkg_version")%> <%'Else%> <%If InStr(APP_ROOT, "DEPLOYMAN_WWW") > 0 Then%>   Download Version: <%=Request("new_version") %>   <%Else%>   Download Version: <%=parThisVersion %>   <%End If%> <%'End If%>
<% '------------ RUN AFTER PAGE RENDER ----------- '---------------------------------------------- %>