Subversion Repositories DevTools

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
119 ghuddy 1
<%@LANGUAGE="VBSCRIPT"%>
2
<%
3
'=====================================================
4
'|                                                   |
5
'|				    	Edit Project View Details    |
6
'|                                                   |
7
'=====================================================
8
%>
9
<%
10
Option explicit
11
' Good idea to set when using redirect
12
Response.Expires = 0	' always load the page, dont store
13
%>
14
<!--#include file="common/conf.asp"-->
15
<!--#include file="common/globals.asp"-->
16
<!--#include file="common/formating.asp"-->
17
<!--#include file="common/qstr.asp"-->
18
<!--#include file="common/common_subs.asp"-->
19
<!--#include file="common/_form_window_common.asp"-->
20
<!--#include file="_action_buttons.asp"-->
21
 
22
<!--#include file="class/classActionButtonControl.asp"-->
23
<%
24
' Set rfile parameter. This is a return page after Login
25
Call objPMod.StoreParameter ( "rfile", "rtree.asp" )
26
objPMod.PersistInQryString("proj_id")
27
'------------ ACCESS CONTROL ------------------
28
%>
29
<!--#include file="_access_control_login.asp"-->
30
<!--#include file="_access_control_general.asp"-->
31
<!--#include file="_access_control_project.asp"-->
32
<%
33
'------------ Variable Definition -------------
34
Dim objSortHelper
35
Dim rsQry
36
Dim parRtagId
37
Dim parSourceRtagId
38
Dim query_string
39
Dim objBtnControl
40
Dim	rcon_id
41
'------------ Constants Declaration -----------
42
'------------ Variable Init -------------------
43
parRtagId = Request("rtag_id")
44
objPMod.PersistInQryString("rtag_id")
45
Set objBtnControl = New ActionButtonControl
46
'----------------------------------------------
47
%>
48
<%
49
'--------------------------------------------------------------------------------------------------------------------------
50
Sub GetFormDetails ( parRtagId, ByRef outobjDetails )
51
	Dim rsQry, query
52
 
53
 
54
	OraDatabase.Parameters.Add "RTAG_ID", 	parRtagId,		ORAPARM_INPUT, ORATYPE_NUMBER 
55
 
56
	query = _
57
	" SELECT * "&_
58
	"  FROM RELEASE_TAGS rt"&_
59
	" WHERE rt.RTAG_ID = :RTAG_ID"
60
 
61
	Set rsQry = OraDatabase.DbCreateDynaset( query, ORADYN_DEFAULT )
62
 
63
	OraDatabase.Parameters.Remove "RTAG_ID"
64
 
65
 
66
 
67
	If rsQry.RecordCount > 0 Then
68
		outobjDetails.Item ("rtag_id") = rsQry("rtag_id")
69
		outobjDetails.Item ("rtag_name") = rsQry("rtag_name")
70
		'outobjDetails.Item ("description") = rsQry("description")
71
		'outobjDetails.Item ("parent_rtag_id") = rsQry("parent_rtag_id")
72
		'outobjDetails.Item ("config_spec_branch") = rsQry("config_spec_branch")
73
		'outobjDetails.Item ("owner_email") = rsQry("owner_email")
74
		'If rsQry("assoc_mass_ref") <> "" Then
75
		'outobjDetails.Item ("massref_rtag_id") = rsQry("assoc_mass_ref")
76
		'End If
77
	Else
78
		Err.Raise 8, "Sub GetFormDetails in "& ScriptName, "Empty record set returned. parRtagId="& parRtagId
79
 
80
	End If
81
 
82
 
83
	rsQry.Close
84
	Set rsQry = Nothing
85
End Sub
86
'--------------------------------------------------------------------------------------------------------------------------
87
Sub DeleteDaemon(rcon_id_list)
88
 
89
	objEH.Try()
90
 
91
	OraDatabase.Parameters.Add "RCON_ID_LIST",	rcon_id_list, 	ORAPARM_INPUT, ORATYPE_VARCHAR2 
92
 
93
	OraSession.BeginTrans
94
 
95
	OraDatabase.ExecuteSQL _
96
	"BEGIN  PK_BUILDAPI.DELETE_DAEMON(:RCON_ID_LIST);  END;"	
97
	OraSession.CommitTrans
98
 
99
	objEH.Catch()
100
	OraDatabase.Parameters.Remove "RCON_ID_LIST"
101
 
102
End Sub
103
'--------------------------------------------------------------------------------------------------------------------------
104
%>
105
<%
106
'------------ RUN BEFORE PAGE RENDER ----------
107
' --- Get Form details from DB ---
108
Call GetFormDetails ( Request("rtag_id"), objFormCollector )
109
 
110
' --- Load Validation Rules ---
111
'Call objForm.LoadValidationRules ( Array("rtag_name","rtag_description", "config_spec_branch"), OraDatabase )		' Load Validation Rules
112
 
113
' --- Enter Form Validation Rule Changes here... ----
114
'----------------------------------------------------
115
 
116
' --- RUN onPostBack ---
117
If Request("action") <> "" Then
118
	If objForm.IsValidOnPostBack Then
119
 
120
		Call DeleteDaemon(Request("rcon_id_list"))
121
 
122
		If objEH.Finally Then
123
			Call OpenInWindow ( "release_config.asp?rtag_id="& parRtagId )
124
		End If
125
 
126
	End If
127
 
128
End If
129
 
130
'----------------------------------------------
131
%>
132
 
133
<html>
134
<head>
135
<title>Release Manager</title>
136
<meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
137
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
138
<link rel="stylesheet" href="images/release_manager_style.css" type="text/css">
139
<link rel="stylesheet" href="images/navigation.css" type="text/css">
140
<script language="JavaScript" src="images/common.js"></script>
141
 
142
<!-- DROPDOWN MENUS -->
143
 
144
 
145
<!--#include file="_menu_def.asp"-->
146
<script language="JavaScript1.2" src="images/popup_menu.js"></script>
147
 
148
</head>
149
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0">
150
<!-- MENU LAYERS -------------------------------------->
151
<div id="popmenu" class="menuskin" onMouseover="clearhidemenu();highlightmenu(event,'on')" onMouseout="highlightmenu(event,'off');dynamichide(event)"> 
152
</div>
153
<!-- TIPS LAYERS -------------------------------------->
154
<div id="formTipsLayer" style="position: absolute; z-index: 1000; visibility: hidden; left:0; top: 0; width: 10">&nbsp;</div>
155
<!----------------------------------------------------->
156
<!-- HEADER -->
157
<!--#include file="_header.asp"-->
158
<!-- BODY ---->
159
 
160
<table width="100%" border="0" cellspacing="0" cellpadding="0">
161
<%
162
'-- FROM START ---------------------------------------------------------------------------------------------------------
163
objFormComponent.FormName = "FormName"
164
objFormComponent.Action = ScriptName
165
Call objFormComponent.FormStart()
166
%>
167
  <tr> 
168
    <td width="1" background="images/bg_home_orange.gif" valign="top">
169
	</td>
170
	<td width="100%" rowspan="2" align="center" valign="top" bgcolor="#EEEFEF"><table width="10" border="0" cellspacing="0" cellpadding="0">
171
      <tr>
172
        <td width="1%"></td>
173
        <td width="100%">
174
<table width="100%"  border="0" cellspacing="0" cellpadding="0">
175
            <tr>
176
              <td nowrap class="body_txt">
177
 
178
			  </td>
179
 
180
            </tr>
181
          </table>
182
          <table width="100%" border="0" cellspacing="0" cellpadding="0">
183
            <tr>
184
              <td nowrap class="form_ttl"><p>&nbsp;</p>
185
                <p>ADMINISTER BUILD CONFIGURATION </p></td>
186
              <td align="right" valign="bottom"></td>
187
            </tr>
188
        </table></td>
189
        <td width="1%"></td>
190
      </tr>
191
      <tr>
192
        <td align="left" valign="top" background="images/lbox_bg_blue.gif"><img src="images/lbox_tl_cnr_b.gif" width="13" height="13"></td>
193
        <td background="images/lbox_bg_blue.gif" class="lbox_ttl_w"><img src="images/h_trsp_dot.gif" width="600" height="15"></td>
194
        <td align="right" valign="top"  background="images/lbox_bg_blue.gif"><img src="images/lbox_tr_cnr_b.gif" width="13" height="13"></td>
195
      </tr>
196
      <tr>
197
        <td bgcolor="#FFFFFF"><img src="images/h_trsp_dot.gif" width="10" height="100"></td>
198
        <td bgcolor="#FFFFFF" valign="top">
199
		<!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->	
200
		<!--#include file="messages/_msg_inline.asp"-->
201
		<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
202
		<br>
203
		<!-- BUTTONS CONTROL +++++++++++++++++++ -->
204
		<%Call Action_Buttons ( "Add Daemon" )
205
 
206
		 ' Load some action buttons
207
		 Call objBtnControl.LoadActionButtons ( Array("btnEditDaemon", "btnDeleteDaemon"), OraDatabase )
208
		 objBtnControl.ButtonSpacer = 1
209
 
210
		%>
211
 
212
		<!-- +++++++++++++++++++++++++++++++++++ -->		
213
 
214
		<table width="100%"  border="0" cellspacing="2" cellpadding="0">    
215
			</td>
216
			<td width="9%" valign="top"></td>
217
		  </tr>
218
		  		  <tr>
219
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col"></td>				  
220
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">DAEMON HOSTNAME</td>
221
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">DAEMON MODE</td>
222
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">GBE_MACHTYPE</td>
223
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">GBE_BUILDFILTER</td>
224
			<td valign="top" nowrap background="images/bg_table_col.gif" class="body_col">ACTION</td>
225
			<td valign="top">
226
		  </tr>
227
			<%
228
			query_string = "select * from release_config rc, gbe_machtype gbe "&_
229
			" where rc.rtag_id = "& parRtagId &" and gbe.gbe_id = rc.gbe_id order by daemon_mode"
230
			Set rsQry = OraDatabase.DbCreateDynaset( query_string, ORADYN_DEFAULT )
231
 
232
			Dim daemon_mode, daemon
233
 
234
			'--- Render rows ---
235
			 Do While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
236
			rcon_id = rsQry("rcon_id")
237
			daemon	=	rsQry("daemon_hostname")
238
 
239
			 If rsQry("daemon_mode") = "M" Then
240
				daemon_mode = "MASTER"
241
			 Else
242
				daemon_mode = "SLAVE"
243
			 End If
244
 
245
 
246
			%>
247
      <tr>
248
        <td colspan="5" background="images/bg_rep_line.gif"><img src="images/spacer.gif" width="1" height="1"></td>
249
      </tr>	  			
250
		 <tr>
251
		<%If rsQry("daemon_mode") = "M" AND rsQry.RecordCount <> 1 Then%>
252
		 <td align="center"><input type="checkbox" name="rcon_id_list" value="<%=rsQry("rcon_id")%>" disabled></td>
253
		<%Else%>
254
		 <td align="center"><input type="checkbox" name="rcon_id_list" value="<%=rsQry("rcon_id")%>"></td>
255
		<%End If%>
256
		 <td nowrap class="body_rowg"><%=rsQry("daemon_hostname")%></td>
257
		 <td nowrap class="body_rowg"><%=daemon_mode%></td>
258
		 <td nowrap class="body_rowg"><%=rsQry("gbe_value")%></td>
259
		 <td nowrap class="body_rowg"><%=rsQry("gbe_buildfilter")%></td>
260
		 <td nowrap class="body_rowg"><%Call objBtnControl.Render  ( Array("btnEditDaemon", "btnDeleteDaemon"), objAccessControl )%></td>
261
		 </tr>
262
		 <%
263
		 	rsQry.MoveNext
264
		 Loop	
265
		 		rsQry.Close()
266
				Set rsQry = nothing	
267
		  %>		  
268
 
269
 
270
 
271
		  <tr>
272
		    <td class="form_iname">&nbsp;</td>
273
		    <td>&nbsp;</td>
274
		    <td class="val_err"></td>
275
		    </tr>
276
		</table>
277
 
278
 
279
		</td>
280
        <td background="images/lbox_bgside_white.gif">&nbsp;</td>
281
      </tr>
282
	  <tr>
283
        <td background="images/bg_action_norm.gif" ></td>
284
        <td align="right" background="images/bg_action_norm.gif" >
285
 
286
		<%=objFormComponent.CancelButton ( "OK", "class='form_btn'", "dependencies.asp?rtag_id="& parRtagId )%>
287
		<%=objPMod.ComposeHiddenTags()%>
288
		<%If objAccessControl.IsActive("AdminView") Then%>
289
		<input name="btn" type="submit" class="form_btn" value="Delete">
290
		<%End If%>
291
		<input type="hidden" name="rcon_id_list" value="<%=Request("rcon_id_list")%>">
292
		<input type="hidden" name="action" value="true">
293
		</td>
294
        <td background="images/bg_action_norm.gif" ><img src="images/h_trsp_dot.gif" width="5" height="30"></td>
295
      </tr>
296
      <tr>
297
        <td background="images/lbox_bg_blue.gif" valign="bottom"><img src="images/lbox_bl_cnr_b.gif" width="13" height="13"></td>
298
        <td background="images/lbox_bg_blue.gif"></td>
299
        <td background="images/lbox_bg_blue.gif" valign="bottom" align="right"><img src="images/lbox_br_cnr_b.gif" width="13" height="13"></td>
300
      </tr>
301
    </table>
302
 
303
	<!-- ACTION BUTTONS ---------------------------------------------->
304
	<!-- ACTION BUTTONS END  ------------------------------------------></td>
305
	<td width="1" valign="top"><img src="images/h_trsp_dot.gif" width="1" height="1"></td>
306
  </tr>
307
  <tr> 
308
    <td valign="bottom" align="center" background="images/bg_home_orange.gif"><img src="images/img_vtree.gif" width="86" height="99" vspace="20" hspace="30"></td>
309
    <td background="images/bg_lght_gray.gif" valign="top"><img src="images/h_trsp_dot.gif" width="1" height="500"></td>
310
  </tr>
311
<%
312
Call objFormComponent.FormEnd()
313
'-- FROM END ----------------------------------------------------------------------------------------------------------------
314
%>   
315
</table>
316
 
317
 
318
<!-- FOOTER -->
319
<!--#include file="_footer.asp"-->
320
</body>
321
</html>
322
<%
323
Call Destroy_All_Objects
324
%>