Subversion Repositories DevTools

Rev

Rev 6793 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

<%@LANGUAGE="VBSCRIPT"%>
<%
'=====================================================
'|                                                   |
'|                 ADMIN licences                    |
'|                                                   |
'=====================================================
%>
<%
Option explicit
' Good idea to set when using redirect
Response.Expires = 0    ' always load the page, dont store
%>
<!--#include file="common/conf.asp"-->
<!--#include file="common/globals.asp"-->
<!--#include file="common/formating.asp"-->
<!--#include file="common/qstr.asp"-->
<!--#include file="common/common_subs.asp"-->
<!--#include file="sec/Crypt.asp"-->
<!--#include file="common/_form_window_common.asp"-->
<!--#include file="_action_buttons.asp"-->

<!--#include file="class/classActionButtonControl.asp"-->

<%
'------------ ACCESS CONTROL ------------------
%>
<!--#include file="_access_control_login_optional.asp"-->
<!--#include file="_access_control_general.asp"-->
<%
'------------ Variable Definition -------------
Dim canEdit, canDelete, canCreate
'------------ Constants Declaration -----------
'------------ Variable Init -------------------
canEdit = canActionControl("EditBaseViews")
canDelete = canActionControl("DeleteBaseViews")
canCreate = canActionControl("CreateBaseViews")
'----------------------------------------------
%>
<html>
<head>
<title>BaseView Administration</title>
<link rel="shortcut icon" href="<%=FavIcon%>"/>
<meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="images/release_manager_style.css?ver=<%=VixVerNum%>" type="text/css">
<link rel="stylesheet" href="images/navigation.css?ver=<%=VixVerNum%>" type="text/css">
<script language="JavaScript" src="images/common.js?ver=<%=VixVerNum%>"></script>
<!--#include file="_jquery_includes.asp"-->
<!-- DROPDOWN MENUS -->
<!--#include file="_menu_def.asp"-->
<script language="JavaScript1.2" src="images/popup_menu.js?ver=<%=VixVerNum%>"></script>
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" >
<!-- HEADER -->
<!--#include file="_header.asp"-->

  <%
  '-- FROM START ---------------------------------------------------------------------------------------------------------
  objFormComponent.FormName = "VCSTYPE"
  objFormComponent.Action = ScriptName
  objFormComponent.OnSubmit = "ShowProgress();"
  Call objFormComponent.FormStart()
  %>   
  <div class="div_table">
    <table class="center_table" >
      <tr>
        <td background="images/bg_bage_0a.gif">
            <div align="center" class=" body_col">Package Base Views</div>
            <table width="100%"  border="0" cellspacing="1" cellpadding="2">
            <tr>
            <!-- BASE VIEW DETAILS +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
            <td background="images/bg_bage_0.gif" align="center"></td>
            <td align="left" nowrap background="images/bg_table_col.gif" class="body_col">BASE VIEW NAME</td>
            <td align="left" nowrap background="images/bg_table_col.gif" class="body_col">Count</td>
            <td align="left" nowrap background="images/bg_table_col.gif" class="body_col">Edit</td>
            </tr>

          <%
           Dim view_id, name, count, rsQry, SqlQry, rmText

           SqlQry = "select vv.VIEW_ID, vv.VIEW_NAME, count from ( " &_
                    "select rc.base_view_id, count(pv.pkg_id) as count from release_content rc, views v, package_versions pv " &_
                    "where rc.base_view_id = v.view_id " &_
                    "AND rc.pv_id = pv.pv_id " &_
                    "and v.BASE_VIEW = 'Y' " &_
                    "group by rc.base_view_id " &_
                    ") t1 " &_
                    "join views vv on t1.base_view_id(+) = vv.view_id where vv.BASE_VIEW = 'Y' " &_
                    "order by upper(view_name)"

           Set rsQry = OraDatabase.DbCreateDynaset( SqlQry, ORADYN_DEFAULT )
           While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
              view_id = rsQry("view_id")
              name = rsQry("view_name")
              count = rsQry("count")
              %>
              <tr>  
                <td background="images/bg_bage_0.gif"></td>
                <td bgcolor="#FFFFFF" class="body_row" nowrap><%=name%></td>
                <td bgcolor="#FFFFFF" class="body_row" nowrap><%=count%></td>
                <td bgcolor="#FFFFFF" class="body_row" nowrap style="padding-right:0px">
                  <%If canEdit Then%>
                        <a href="javascript:;" onclick="MM_openVixIFrame('_wform_edit_baseview.asp?view_id=<%=view_id%>','Edit Base Name')"><img src="icons/i_edit.gif" width="16" height="16" hspace="2" border="0" align="absmiddle"></a>
                  <%Else%>
                        <img class ="lessOpacity" src="icons/i_edit.gif" width="16" height="16" hspace="2" border="0" align="absmiddle">
                  <%End If%>
                  <%If canDelete and isNull(count) Then%>
                        <a href='javascript:;' onclick="vixConfirm('Delete the \'Base View\' named \'<%=name%>\'',{title : 'Delete Base View', button:'Delete', url: '_DeleteBaseView.asp?view_id=<%=view_id%>'});"><img src="icons/i_remove.gif" hspace="2" border="0" align="absmiddle"></a>

                  <%Else%>
                        <img class ="lessOpacity" src="icons/i_remove.gif" hspace="2" border="0" align="absmiddle">
                  <%End If%>
                </td>
              </tr> 
              <%
              rsQry.MoveNext()
          Wend
          rsQry.Close()
          Set rsQry = nothing
          %>
        <tr>
            <td background="images/bg_bage_0.gif"></td>
            <td bgcolor="#FFFFFF" nowrap colspan="3" class="abtnItem"  align=right>
            <%If canCreate Then%>
              <a href="javascript:;"
                 onclick="MM_openVixIFrame('_wform_new_group.asp?noFrame=1','New Base View Name')">
                <img src="images/i_new_group.gif" width="20" height="20" align="absmiddle" border="0" title="Create New Base View Group">&nbsp;Create New Base View</a>
            <%Else%>
                <img class ="lessOpacity" src="images/i_new_group.gif" hspace="2" border="0" align="absmiddle"> &nbsp;Create New Base View
            <%End If%>
            </td>
        </tr>
    </table>
    <%=objPMod.ComposeHiddenTags()%>
    <input type="hidden" name="action" value="true">
    <%Call objFormComponent.FormEnd()%>
    </table>
    </div>
<!-- FOOTER -->
<!--#include file="_footer.asp"-->
</body>
</html>