Subversion Repositories DevTools

Rev

Rev 119 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 119 Rev 129
Line 1... Line 1...
1
<%@LANGUAGE="VBSCRIPT"%>
1
<%@LANGUAGE="VBSCRIPT"%>
2
<%
2
<%
3
Option explicit
3
Option explicit
4
Response.Expires = 0	' always load the page, dont store
4
Response.Expires = 0   ' always load the page, dont store
5
%>
5
%>
6
<%
6
<%
7
'=====================================================
7
'=====================================================
8
'					New Category
8
'               New Category
9
'=====================================================
9
'=====================================================
10
%>
10
%>
11
<!--#include file="common/conf.asp"-->
11
<!--#include file="common/conf.asp"-->
12
<!--#include file="common/globals.asp"-->
12
<!--#include file="common/globals.asp"-->
13
<!--#include file="common/qstr.asp"-->
13
<!--#include file="common/qstr.asp"-->
Line 38... Line 38...
38
parMovePkg = Request("movepkg")
38
parMovePkg = Request("movepkg")
39
'----------------------------------------------
39
'----------------------------------------------
40
%>
40
%>
41
<%
41
<%
42
Function Create_New_Base_View( SSvname )
42
Function Create_New_Base_View( SSvname )
43
	' Return new Base View
43
   ' Return new Base View
44
	Dim SEQ_view_id
44
   Dim SEQ_view_id
45
	SEQ_view_id = Get_From_DUAL("SEQ_VIEW_ID.nextval")
45
   SEQ_view_id = Get_From_DUAL("SEQ_VIEW_ID.nextval")
-
 
46
 
-
 
47
   objEH.TryORA ( OraSession )
46
	OraSession.BeginTrans
48
   On Error Resume Next
-
 
49
 
47
	OraDatabase.ExecuteSQL _
50
   OraDatabase.ExecuteSQL _
48
		" INSERT INTO views (view_id, view_name, owner_id, base_view, public_read)"&_
51
      " INSERT INTO views (view_id, view_name, owner_id, base_view, public_read)"&_
49
		" VALUES ("& SEQ_view_id &", '"& UCase(SSvname) &"', 0,'Y','Y')"
52
      " VALUES ("& SEQ_view_id &", '"& UCase(SSvname) &"', 0,'Y','Y')"
-
 
53
 
50
  	OraSession.CommitTrans
54
   objEH.CatchORA ( OraSession )
51
	Create_New_Base_View = SEQ_view_id
55
   Create_New_Base_View = SEQ_view_id
52
End Function
56
End Function
53
 
57
 
54
 
58
 
55
Function BaseViewExists ( SSbname )
59
Function BaseViewExists ( SSbname )
56
	' RETURN -1 if baseview not found, else return VIEW_ID
60
   ' RETURN -1 if baseview not found, else return VIEW_ID
57
	Dim rsTemp, Query_String
61
   Dim rsTemp, Query_String
58
	Query_String = _
62
   Query_String = _
59
	" SELECT view_id FROM views"&_
63
   " SELECT view_id FROM views"&_
60
	" WHERE view_name ='"& UCase(SSbname)&"'"&_
64
   " WHERE view_name ='"& UCase(SSbname)&"'"&_
61
	" AND owner_id = 0  AND base_view = 'Y'  AND public_read = 'Y'"
65
   " AND owner_id = 0  AND base_view = 'Y'  AND public_read = 'Y'"
62
	Set rsTemp = OraDatabase.CreateDynaset( Query_String, cint(0))
66
   Set rsTemp = OraDatabase.CreateDynaset( Query_String, cint(0))
63
	
67
 
64
	If rsTemp.RecordCount > 0 Then
68
   If rsTemp.RecordCount > 0 Then
65
		BaseViewExists = rsTemp.Fields("view_id")
69
      BaseViewExists = rsTemp.Fields("view_id")
66
	Else
70
   Else
67
		BaseViewExists = -1
71
      BaseViewExists = -1
68
	End If
72
   End If
69
	
73
 
70
	rsTemp.Close
74
   rsTemp.Close
71
	Set rsTemp = nothing
75
   Set rsTemp = nothing
72
End Function
76
End Function
73
%>
77
%>
74
<%
78
<%
75
'Process submition
79
'Process submition
76
If CBool(QStrPar("action")) AND  objAccessControl.UserLogedIn Then
80
If CBool(QStrPar("action")) AND  objAccessControl.UserLogedIn Then
77
	NEWBase_view_id = BaseViewExists ( Request("base_view_name") )
81
   NEWBase_view_id = BaseViewExists ( Request("base_view_name") )
78
	If NEWBase_view_id = -1 Then
82
   If NEWBase_view_id = -1 Then
79
		'Group not found i.e. create it
83
      'Group not found i.e. create it
80
		NEWBase_view_id = Create_New_Base_View( Request("base_view_name") )
84
      NEWBase_view_id = Create_New_Base_View( Request("base_view_name") )
81
	End If
85
   End If
82
	
86
 
83
	If parMovePkg = "true" Then
87
   If parMovePkg = "true" Then
84
		' Call is comming from dependencies page to move package to other base view
88
      ' Call is comming from dependencies page to move package to other base view
85
		Call Update_Pkg_Category ( parRtag_id, parPv_id, NEWBase_view_id )
89
      Call Update_Pkg_Category ( parRtag_id, parPv_id, NEWBase_view_id )
86
		Call OpenInParentWindow ("dependencies.asp?pv_id="& parPv_id &"&rtag_id="& parRtag_id)
90
      Call OpenInParentWindow ("dependencies.asp?pv_id="& parPv_id &"&rtag_id="& parRtag_id)
87
		Call CloseWindow
91
      Call CloseWindow
88
	Else
92
   Else
89
		Call OpenInParentWindow ( parRFile &"?base_view_id="& NEWBase_view_id &_
93
      Call OpenInParentWindow ( parRFile &"?base_view_id="& NEWBase_view_id &_
90
		                          "&pkg_list="& parPkg_list &_
94
                                "&pkg_list="& parPkg_list &_
91
								  "&add_type="& parAdd_type &_
95
                          "&add_type="& parAdd_type &_
92
								  "&pv_id="& parPv_id &_
96
                          "&pv_id="& parPv_id &_
93
								  "&rtag_id="& parRtag_id )
97
                          "&rtag_id="& parRtag_id )
94
		Call CloseWindow
98
      Call CloseWindow
95
	End If
99
   End If
96
End If
100
End If
97
%>
101
%>
98
<html>
102
<html>
99
<head>
103
<head>
100
<title>Release Manager</title>
104
<title>Release Manager</title>
Line 105... Line 109...
105
<script language="JavaScript" src="images/common.js"></script>
109
<script language="JavaScript" src="images/common.js"></script>
106
</head>
110
</head>
107
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" onload="self.focus();window.document.newbaseview.base_view_name.focus();">
111
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" onload="self.focus();window.document.newbaseview.base_view_name.focus();">
108
<form name="newbaseview" method="post" action="<%=scriptName%>" onSubmit="MM_validateForm('base_view_name','Base View','RisCleanStr');return document.MM_returnValue">
112
<form name="newbaseview" method="post" action="<%=scriptName%>" onSubmit="MM_validateForm('base_view_name','Base View','RisCleanStr');return document.MM_returnValue">
109
  <table width="100%" border="0" cellspacing="0" cellpadding="2" height="100%">
113
  <table width="100%" border="0" cellspacing="0" cellpadding="2" height="100%">
110
    <tr> 
114
    <tr>
111
      <td background="images/lbox_bg_orange.gif" width="1%" height="1%"><img src="images/i_change_group_off.gif" width="22" height="25" hspace="5"></td>
115
      <td background="images/lbox_bg_orange.gif" width="1%" height="1%"><img src="images/i_change_group_off.gif" width="22" height="25" hspace="5"></td>
112
      <td background="images/lbox_bg_blue.gif" nowrap width="50%" class="wform_ttl">&nbsp;Create NEW Base View</td>
116
      <td background="images/lbox_bg_blue.gif" nowrap width="50%" class="wform_ttl">&nbsp;Create NEW Base View</td>
113
      <td background="images/lbox_bg_blue.gif" align="right" width="50%"> 
117
      <td background="images/lbox_bg_blue.gif" align="right" width="50%">
114
        <input type="submit" name="btn" value="Create" class="form_btn_comp">
118
        <input type="submit" name="btn" value="Create" class="form_btn_comp">
115
        <input type="reset" name="btn" value="Cancel" class="form_btn_comp" onclick="self.close()">
119
        <input type="reset" name="btn" value="Cancel" class="form_btn_comp" onclick="self.close()">
116
      </td>
120
      </td>
117
      <td background="images/lbox_bg_blue.gif" align="right" width="1%%" nowrap> 
121
      <td background="images/lbox_bg_blue.gif" align="right" width="1%%" nowrap>
118
        <img src="images/h_trsp_dot.gif" width="5" height="22"> </td>
122
        <img src="images/h_trsp_dot.gif" width="5" height="22"> </td>
119
    </tr>
123
    </tr>
120
    <tr> 
124
    <tr>
121
      <td height="100%" width="1%">&nbsp;</td>
125
      <td height="100%" width="1%">&nbsp;</td>
122
      <td valign="top" nowrap colspan="3" class="wform_ttl" background="images/bg_form_lightgray.gif"> 
126
      <td valign="top" nowrap colspan="3" class="wform_ttl" background="images/bg_form_lightgray.gif">
123
        <table width="100%" border="0" cellspacing="1" cellpadding="2">
127
        <table width="100%" border="0" cellspacing="1" cellpadding="2">
124
          <tr> 
128
          <tr>
125
            <td width="1%"><img src="images/h_trsp_dot.gif" width="10" height="30"></td>
129
            <td width="1%"><img src="images/h_trsp_dot.gif" width="10" height="30"></td>
126
            <td width="1%" nowrap class="form_group" valign="bottom"></td>
130
            <td width="1%" nowrap class="form_group" valign="bottom"></td>
127
            <td nowrap width="100%">&nbsp; </td>
131
            <td nowrap width="100%">&nbsp; </td>
128
          </tr>
132
          </tr>
129
          <tr> 
133
          <tr>
130
            <td width="1%">&nbsp;</td>
134
            <td width="1%">&nbsp;</td>
131
            <td width="1%" nowrap class="form_field" background="images/bg_form_lightbluedark.gif">Base View</td>
135
            <td width="1%" nowrap class="form_field" background="images/bg_form_lightbluedark.gif">Base View</td>
132
            <td nowrap width="100%" background="images/bg_form_lightbluedark.gif" class="form_txt"> 
136
            <td nowrap width="100%" background="images/bg_form_lightbluedark.gif" class="form_txt">
133
              <input type="text" name="base_view_name" maxlength="30" class="form_item">
137
              <input type="text" name="base_view_name" maxlength="30" class="form_item">
134
            </td>
138
            </td>
135
          </tr>
139
          </tr>
136
          <tr> 
140
          <tr>
137
            <td width="1%">&nbsp;</td>
141
            <td width="1%">&nbsp;</td>
138
            <td width="1%" nowrap class="form_field"><img src="images/h_trsp_dot.gif" width="100" height="10"></td>
142
            <td width="1%" nowrap class="form_field"><img src="images/h_trsp_dot.gif" width="100" height="10"></td>
139
            <td nowrap width="100%"> 
143
            <td nowrap width="100%">
140
              <p>&nbsp;</p>
144
              <p>&nbsp;</p>
141
            </td>
145
            </td>
142
          </tr>
146
          </tr>
143
        </table>
147
        </table>
144
      </td>
148
      </td>
Line 146... Line 150...
146
    <tr>
150
    <tr>
147
      <td height="1%" width="1%"><img src="images/h_trsp_dot.gif" width="5" height="5"></td>
151
      <td height="1%" width="1%"><img src="images/h_trsp_dot.gif" width="5" height="5"></td>
148
      <td valign="top" nowrap colspan="3" class="wform_ttl" background="images/lbox_bg_blue.gif"></td>
152
      <td valign="top" nowrap colspan="3" class="wform_ttl" background="images/lbox_bg_blue.gif"></td>
149
    </tr>
153
    </tr>
150
  </table>
154
  </table>
151
	<input type="hidden" name="rfile" value="<%=parRFile%>">
155
   <input type="hidden" name="rfile" value="<%=parRFile%>">
152
	<input type="hidden" name="movepkg" value="<%=parMovePkg%>">
156
   <input type="hidden" name="movepkg" value="<%=parMovePkg%>">
153
	<input type="hidden" name="add_type" value="<%=parAdd_type%>">
157
   <input type="hidden" name="add_type" value="<%=parAdd_type%>">
154
	<input type="hidden" name="pv_id" value="<%=parPv_id%>">
158
   <input type="hidden" name="pv_id" value="<%=parPv_id%>">
155
	<input type="hidden" name="pkg_list" value="<%=parPkg_list%>">
159
   <input type="hidden" name="pkg_list" value="<%=parPkg_list%>">
156
	<input type="hidden" name="rtag_id" value="<%=parRtag_id%>">
160
   <input type="hidden" name="rtag_id" value="<%=parRtag_id%>">
157
	<input type="hidden" name="action" value="true">
161
   <input type="hidden" name="action" value="true">
158
</form>
162
</form>
159
</body>
163
</body>
160
</html>
164
</html>
161
 
165
 
162
 
166
 
163
<!-- DESTRUCTOR ------->
167
<!-- DESTRUCTOR ------->
164
<!--#include file="common/destructor.asp"-->
-
 
165
168
<!--#include file="common/destructor.asp"-->
-
 
169