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
'|				    	RTREE					     |
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/_rtree_common.asp"-->
20
<%
21
' Make sure rtag_id is always present
22
If Request("proj_id") = "" Then
23
	Response.Redirect("index.asp")
24
End If
25
'------------ ACCESS CONTROL ------------------
26
%>
27
<!--#include file="_access_control_general.asp"-->
28
<%
29
'------------ Variable Definition -------------
30
Dim objSortHelper
31
Dim ViewType
32
Dim rsQry
33
Dim parProjId
34
Dim nProjTreeVersion
35
Dim objBtnControl
36
Dim currLevel, lastLevel, lastRow, aVersions, i
37
'------------ Constants Declaration -----------
38
'Const LIMG_TREE_I_HALF = "<img src='images/spacer.gif' width='5' height='1'><img src='icons/tree_i_half.gif' align='absmiddle'>"
39
'Const LIMG_TREE_I_FULL = "<img src='images/spacer.gif' width='5' height='1'><img src='icons/tree_i.gif' align='absmiddle'>"
40
'Const LIMG_TREE_T = "<img src='images/spacer.gif' width='5' height='1'><img src='icons/tree_t.gif' align='absmiddle'>"
41
Const LIMG_TREE_I_HALF = "<img src='images/spacer.gif' width='20' height='1'>"
42
Const LIMG_TREE_I_FULL = "<img src='images/dot1.gif' width='30' height='15'>"
43
Const LIMG_TREE_T = "<img src='images/dot1.gif' width='30' height='15'>"
44
Const LIMG_LIST_VIEW = "<img src='images/abtn_list_view.gif' border='0' align=absmiddle' name='imgviewtype' usemap='#mapviewtype' id='imgviewtype'>"
45
Const LIMG_TREE_VIEW = "<img src='images/abtn_tree_view.gif' border='0' align=absmiddle' name='imgviewtype' usemap='#mapviewtype' id='imgviewtype'>"
46
Const LCONST_LIST_VIEW = 1
47
Const LCONST_TREE_VIEW = 2
48
'------------ Variable Init -------------------
49
parProjId = Request("proj_id")
50
nProjTreeVersion = GetProjTreeVersion( parProjId )
51
Set objBtnControl = New ActionButtonControl
52
objPMod.PersistInQryString("proj_id")
53
'----------------------------------------------
54
%>
55
<%
56
'----------------------------------------------------------------------------------------------------------------------------------------------
57
Function GetProjTreeVersion ( nProjId )
58
	Dim rsTemp, QueryString
59
 
60
	QueryString = _
61
	" SELECT rt.RTAG_VERSION "&_
62
	"   FROM RELEASE_TAGS rt "&_
63
	"  WHERE rt.PROJ_ID = :PROJ_ID "&_
64
	"    AND rt.RTAG_ID = rt.PARENT_RTAG_ID"
65
 
66
	OraDatabase.Parameters.Add "PROJ_ID", 	nProjId, 	ORAPARM_INPUT, ORATYPE_NUMBER
67
 
68
	Set rsTemp = OraDatabase.DbCreateDynaset( QueryString, cint(0))
69
 
70
	OraDatabase.Parameters.Remove "PROJ_ID"
71
 
72
 
73
 
74
	If ((NOT rsTemp.BOF) AND (NOT rsTemp.EOF)) Then
75
		GetProjTreeVersion = rsTemp("rtag_version")
76
	Else
77
		GetProjTreeVersion = NULL
78
	End If
79
 
80
	rsTemp.Close
81
	Set rsTemp = nothing
82
End Function
83
'----------------------------------------------------------------------------------------------------------------------------------------------
84
Sub RenderRowConnectors ( nLastLevel, nCurrLevel )
85
	Dim i, LastLine
86
 
87
	'-- Initial Draw --
88
	If nLastLevel = 0 Then
89
		nLastLevel = nCurrLevel
90
		Exit Sub
91
	End If
92
 
93
	'-- Calculate number of half lines rendered
94
	If nLastLevel < nCurrLevel Then
95
		LastLine = nLastLevel
96
	Else
97
		LastLine = nCurrLevel
98
	End If
99
 
100
 
101
	'-- Render half lines
102
	For i = 1 To LastLine
103
		Response.write LIMG_TREE_I_HALF
104
	Next
105
 
106
End Sub
107
'----------------------------------------------------------------------------------------------------------------------------------------------
108
Sub RenderIndent ( nLastLevel, nCurrLevel )
109
	Dim i
110
 
111
	If nCurrLevel <= 1 Then Exit Sub
112
 
113
 
114
	'-- Render half lines
115
	If nCurrLevel > 2 Then
116
		For i = 1 To nCurrLevel - 2
117
			Response.write LIMG_TREE_I_FULL
118
		Next
119
	End If
120
 
121
 
122
	'-- Render branch or line
123
	If nLastLevel < nCurrLevel Then
124
		Response.write LIMG_TREE_T
125
	Else
126
		Response.write LIMG_TREE_I_FULL
127
	End If
128
 
129
 
130
 
131
 
132
End Sub
133
'----------------------------------------------------------------------------------------------------------------------------------------------
134
Function GetLevel ( sRtagVersion )
135
	Dim tempArr
136
 
137
	If InStr( sRtagVersion, "." ) > 0 Then
138
		'-- Dot separator found --
139
 
140
		'-- Split version --
141
		tempArr = Split( sRtagVersion, "." )
142
 
143
		GetLevel = UBound( tempArr ) + 1
144
 
145
	Else
146
		GetLevel = 1
147
 
148
	End If
149
 
150
End Function
151
'----------------------------------------------------------------------------------------------------------------------------------------------
152
Sub NewRelease ()
153
	On Error Resume Next
154
 
155
	objEH.Try
156
		If NOT IsNumeric(Request("rtag_id_list")) Then
157
			Err.Raise 8, "Please select one release only.", "No further details available."
158
 
159
		Else
160
			Call OpenInWindow ( "new_release.asp?rtag_id_list="& Replace( Request("rtag_id_list"), " ","" ) &"&"& objPMod.ComposeURL() )
161
 
162
		End If
163
 
164
	objEH.Catch
165
 
166
End Sub
167
'----------------------------------------------------------------------------------------------------------------------------------------------
168
Sub DestroyRelease ()
169
	On Error Resume Next
170
 
171
	objEH.Try
172
		If NOT IsNumeric(Request("rtag_id_list")) Then
173
			Err.Raise 8, "Please select one release only.", "No further details available."
174
 
175
		Else
176
			If Request("rtag_id_list") = "" Then
177
				Err.Raise 8, "Please select one release.", "No further details available."
178
			Else
179
				Call OpenInWindow ( "_destroy_release.asp?rtag_id_list="& Replace( Request("rtag_id_list"), " ","" ) &"&"& objPMod.ComposeURL() )
180
			End If
181
 
182
		End If
183
 
184
	objEH.Catch
185
 
186
End Sub
187
'----------------------------------------------------------------------------------------------------------------------------------------------
188
Sub EditRelease ()
189
	On Error Resume Next
190
 
191
	objEH.Try
192
		If NOT IsNumeric(Request("rtag_id_list")) Then
193
			Err.Raise 8, "Please select one release only.", "No further details available."
194
 
195
		Else
196
			If Request("rtag_id_list") = "" Then
197
				Err.Raise 8, "Please select one release.", "No further details available."
198
			Else
199
				Call OpenInWindow ( "form_edit_release.asp?rtag_id_list="& Replace( Request("rtag_id_list"), " ","" ) &"&"& objPMod.ComposeURL() )
200
			End If
201
 
202
		End If
203
 
204
	objEH.Catch
205
 
206
End Sub
207
'----------------------------------------------------------------------------------------------------------------------------------------------
208
Sub MoveRelease ()
209
	On Error Resume Next
210
 
211
	objEH.Try
212
		If NOT IsNumeric(Request("rtag_id_list")) Then
213
			Err.Raise 8, "Please select one release only.", "No further details available."
214
 
215
		Else
216
			If Request("rtag_id_list") = "" Then
217
				Err.Raise 8, "Please select one release.", "No further details available."
218
			Else
219
				Call OpenInWindow ( "form_move_release.asp?rtag_id_list="& Replace( Request("rtag_id_list"), " ","" ) &"&"& objPMod.ComposeURL() )
220
			End If
221
 
222
		End If
223
 
224
	objEH.Catch
225
 
226
End Sub
227
'----------------------------------------------------------------------------------------------------------------------------------------------
228
Sub MergeManager ()
229
	Dim aReleases
230
	On Error Resume Next
231
 
232
	objEH.Try
233
 
234
		If Request("rtag_id_list") <> "" Then
235
			aReleases = Split ( Replace( Request("rtag_id_list"), " ", ""), "," )
236
 
237
			If UBound(aReleases) = 0 Then
238
				' Open Merge Manager
239
				Call OpenInWindow ( "diff.asp?rtagA="& aReleases(0)  )
240
 
241
 
242
			ElseIf UBound(aReleases) = 1 Then
243
				' Open Merge Manager
244
				Call OpenInWindow ( "diff.asp?rtagA="& aReleases(0) &"&rtagB="& aReleases(1) )
245
 
246
 
247
			Else
248
				Err.Raise 8, "Please select maximum two release.", "No further details available."
249
 
250
			End If
251
 
252
		Else
253
			' Open Merge Manager without parameters
254
			Call OpenInWindow ( "diff.asp" )
255
 
256
		End If
257
 
258
	objEH.Catch
259
 
260
End Sub
261
'----------------------------------------------------------------------------------------------------------------------------------------------
262
Function GetViewType ()
263
	Dim CookieViewType
264
 
265
	CookieViewType = Request.Cookies (COOKIE_RELEASE_MANAGER_MEMORY)("RELEASE_VIEW") 
266
 
267
	If CookieViewType <> "" Then
268
		' Get current view type from cookie
269
		GetViewType = CInt(CookieViewType)
270
 
271
	Else
272
		' Set current view to list view
273
		Response.Cookies (COOKIE_RELEASE_MANAGER_MEMORY)("RELEASE_VIEW") = LCONST_LIST_VIEW
274
		GetViewType = LCONST_LIST_VIEW
275
 
276
	End If
277
 
278
End Function
279
'----------------------------------------------------------------------------------------------------------------------------------------------
280
Sub SetViewType ()
281
 
282
	If Request("viewtype") = "" Then Exit Sub 	' Nothing to do
283
 
284
	Response.Cookies (COOKIE_RELEASE_MANAGER_MEMORY)("RELEASE_VIEW") = Request("viewtype")	
285
 
286
End Sub
287
'----------------------------------------------------------------------------------------------------------------------------------------------
288
%>
289
<%
290
'------------ RUN BEFORE PAGE RENDER ----------
291
If (Request("action") <> "") Then
292
	'-- Select Action
293
 
294
	Select Case Request("action")
295
		Case "btnNewRelease"
296
			Call NewRelease()
297
 
298
		Case "btnDestroyRelease"
299
			Call DestroyRelease()
300
 
301
		Case "btnEditRelease"
302
			Call EditRelease()
303
 
304
		Case "btnMoveRelease"
305
			Call MoveRelease()
306
 
307
		Case "btnMergeManager"
308
			Call MergeManager()
309
 
310
		Case "btnAdminView"	
121 hknight 311
      Dim Query_String
312
      Query_String = _
313
      "	SELECT DISTINCT vi.view_id, vi.view_name"&_
314
      "	FROM VIEWS vi"&_
315
      "	WHERE vi.view_name = 'PROJECT WIDE'"
316
      Set rsQry = OraDatabase.DbCreateDynaset( Query_String , cint(0) )
317
 
318
      Dim viewRecordCount
319
      Dim id
320
      viewRecordCount=0
321
      viewRecordCount = rsQry.RecordCount
322
 
323
      While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
324
        id=rsQry.Fields("view_id")
325
        rsQry.MoveNext
326
      WEnd
327
 
328
	    rsQry.Close()
329
      Set rsQry = nothing
330
 
331
      If viewRecordCount = 0 Then
332
        OraDatabase.Parameters.Add "PROJ_ID", parProjId, 	ORAPARM_INPUT, ORATYPE_NUMBER
333
        Query_String = _
334
        " SELECT DISTINCT vi.view_id, vi.view_name"&_
335
        " FROM VIEWS vi, RELEASE_CONTENT rc, RELEASE_TAGS rt"&_
336
        " WHERE rc.BASE_VIEW_ID = vi.VIEW_ID AND rt.proj_id = "& parProjId &"AND rc.rtag_id = rt.rtag_id"&_
337
        " ORDER BY ( vi.view_name )"
338
 
339
      	Set rsQry = OraDatabase.DbCreateDynaset( Query_String , cint(0) )
340
 
341
        OraDatabase.Parameters.Remove "PROJ_ID"
342
        viewRecordCount = rsQry.RecordCount
343
 
344
        While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
345
          id=rsQry.Fields("view_id")
346
          rsQry.MoveNext
347
        WEnd
348
 
349
        rsQry.Close()
350
        Set rsQry = nothing
351
      End If
352
      If viewRecordCount = 0 Then
353
        Call OpenInWindow ( "form_edit_project_view.asp?proj_id="&Request("proj_id"))
354
      Else
355
	    	Call OpenInWindow ( "form_edit_project_view.asp?proj_id="&Request("proj_id")&"&FRview_id="&id)
356
	    End If
357
 
119 ghuddy 358
	End Select
359
 
360
End If
361
 
362
' Set view type if required
363
Call SetViewType ()
364
 
365
' Get current view type
366
ViewType = GetViewType()
367
'----------------------------------------------
368
%>
369
 
370
<html>
371
<head>
372
<%
373
	Set rsQry = OraDatabase.DbCreateDynaset( "SELECT PROJ_NAME FROM PROJECTS WHERE PROJ_ID="& Request("proj_id"), ORADYN_DEFAULT )
374
%>
375
<title><%=rsQry("proj_name")%></title>
376
<%
377
	rsQry.Close
378
	Set rsQry = Nothing
379
%>
380
<meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
381
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
382
<link rel="stylesheet" href="images/release_manager_style.css" type="text/css">
383
<link rel="stylesheet" href="images/navigation.css" type="text/css">
384
<script language="JavaScript" src="images/common.js"></script>
385
 
386
<!-- DROPDOWN MENUS -->
387
<!--#include file="_menu_def.asp"-->
388
<script language="JavaScript1.2" src="images/popup_menu.js"></script>
389
 
390
</head>
391
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" >
392
<!-- MENU LAYERS -------------------------------------->
393
<div id="popmenu" class="menuskin" onMouseover="clearhidemenu();highlightmenu(event,'on')" onMouseout="highlightmenu(event,'off');dynamichide(event)"> 
394
</div>
395
<!-- TIPS LAYERS -------------------------------------->
396
<div id="formTipsLayer" style="position: absolute; z-index: 1000; visibility: hidden; left:0; top: 0; width: 10">&nbsp;</div>
397
<!----------------------------------------------------->
398
<!-- HEADER -->
399
<!--#include file="_header.asp"-->
400
<!-- BODY ---->
401
 
402
<table width="100%" border="0" cellspacing="0" cellpadding="0">
403
  <tr> 
404
    <td width="1" background="images/bg_home_orange.gif" valign="top">
405
	</td>
406
	<td rowspan="2" valign="top" width="100%">
407
 
408
	<!-- ACTION BUTTONS ---------------------------------------------->
409
	<table width="100%"  border="0" cellspacing="0" cellpadding="7">
410
	  <tr>
411
	    <td width="1" bgcolor="#DAD7C8">
412
		<%
413
		If ViewType = LCONST_TREE_VIEW Then
414
			Response.write LIMG_TREE_VIEW
415
		Else
416
			Response.write LIMG_LIST_VIEW
417
		End If
418
 
419
		%>
420
	    </td>
421
        <td width="100%" bgcolor="#DAD7C8">
422
		<%
423
		Dim aBtnsDef
424
			' Define action buttons
425
			aBtnsDef = Array("btnNewRelease", "btnEditRelease", "btnMoveRelease", "width=20", "btnDestroyRelease", "width=20", "btnMergeManager", "width=20", "btnAdminView")
426
 
427
		' Load action buttons from database
428
		Call objBtnControl.LoadActionButtons ( aBtnsDef, OraDatabase )
429
 
430
		' Set spacing to minimum between buttons
431
		objBtnControl.ButtonSpacer = 0
432
		objBtnControl.ImageHspace = 2
433
 
434
		' Access Control
435
		If NOT objAccessControl.IsActive("CreateNewRelease") Then Call objBtnControl.Active ( "btnNewRelease", "N" )
436
		If NOT objAccessControl.IsActive("CreateNewRelease") Then Call objBtnControl.Active ( "btnEditRelease", "N" )
437
		If NOT objAccessControl.IsActive("DestroyRelease") Then Call objBtnControl.Active ( "btnDestroyRelease", "N" )
438
		If NOT objAccessControl.IsActive("CreateNewRelease") Then Call objBtnControl.Active ( "btnMoveRelease", "N" )
439
 
440
		' -- Render Buttons
441
		Call objBtnControl.Render  ( aBtnsDef, objAccessControl )
442
		%>
443
		</td>
444
      </tr>
445
    </table>
446
	<!-- ACTION BUTTONS END  ------------------------------------------>
447
 
448
	<table width="100%"  border="0" cellspacing="10" cellpadding="0">
449
	<form name="FormName" method="post" action="<%=ScriptName%>">
450
	  <tr>
451
	    <td>
452
 
453
<!-- TREE VIEW ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
454
<%If ViewType = LCONST_TREE_VIEW Then%>
455
 
456
		<table width="100%"  border="0" cellspacing="1" cellpadding="1">		  
457
		  <tr>
458
 
459
 
460
			<td width="40%" bgcolor="#E4E9EC" class="body_txt">Release Name </td>
461
 
462
            <%If parProjId <> 2 Then %>
463
			<td width="15%" bgcolor="#E4E9EC" class="body_txt">Associated MASS_REF </td>
464
            <td width="45%" bgcolor="#E4E9EC" class="body_txt">Comments</td>			
465
			<%Else%>
466
			<td width="30%" bgcolor="#E4E9EC" class="body_txt">Used By </td>
467
            <td width="30%" bgcolor="#E4E9EC" class="body_txt">Comments</td>						
468
			<%End If%>
469
 
470
          </tr>
471
 
472
 
473
 
474
		<%
475
		'OraDatabase.Parameters.Add "TREE_VERSION", 	nProjTreeVersion, 	ORAPARM_INPUT, ORATYPE_NUMBER
476
		OraDatabase.Parameters.Add "PROJ_ID", 	parProjId, 	ORAPARM_INPUT, ORATYPE_NUMBER
477
 
478
		Set rsQry = OraDatabase.DbCreateDynaset( GetQuery ("ReleaseVersionTree.sql") , ORADYN_DEFAULT )
479
		lastLevel = 0
480
 
481
		'OraDatabase.Parameters.Remove "TREE_VERSION"
482
		OraDatabase.Parameters.Remove "PROJ_ID"
483
 
484
		Dim lastRtagId, parentRtag_id
485
 
486
		If rsQry.RecordCount > 0 Then
487
 
488
			'aVersions = rsQry.GetRows()
489
			'lastRow = UBound( aVersions, 2 )
490
 
491
			'Set objSortHelper = New SortHelper
492
 
493
			' Sort versions
494
			'Call objSortHelper.VersionSort( aVersions, 0, lastRow, rsQry.FieldIndex("version") )
495
 
496
 
497
 
498
			'For i = 0 To lastRow	' Ascending order
499
			While (NOT rsQry.BOF) AND (NOT rsQry.EOF)
500
 
501
				'currLevel = GetLevel (  aVersions( rsQry.FieldIndex("rtag_version"), i )  )
502
				currLevel = CInt(rsQry("hierarchy"))
503
				'lastLevel = currLevel - 1
504
			%>
505
 
506
 
507
				<tr> 
508
				  <td bgcolor="#F5F5F5" class="body_rowg"><%Call RenderIndent( lastLevel, currLevel )%><input type="checkbox" name="rtag_id_list" value="<%=rsQry("rtag_id")%>" style="vertical-align:middle;">
509
				  <%If rsQry("official") <> "A" Then%><a href="dependencies.asp?rtag_id=<%=rsQry("rtag_id")%>" class="body_link" title="<%=HTMLEncode( rsQry("description") ) %>" ><%End If%><%=ReleaseIcon( rsQry("official") )%>&nbsp;<%=rsQry("rtag_name")%></a>
510
 
511
			<%
512
			If parProjId <> 2 Then
513
				Dim assocMASSREF, rsQryAssoc, assocMASSREFName, link 
514
				assocMASSREF =  rsQry("assoc_mass_ref")
515
				If assocMASSREF <> "" Then
516
				Set rsQryAssoc = OraDatabase.DbCreateDynaset("SELECT RTAG_NAME, RTAG_ID FROM RELEASE_TAGS WHERE RTAG_ID="&assocMASSREF , ORADYN_DEFAULT) 				
517
				assocMASSREFName = rsQryAssoc("RTAG_NAME")
518
				link = "dependencies.asp?rtag_id="&rsQryAssoc("rtag_id") 
519
				rsQryAssoc.Close
520
				Set rsQryAssoc = Nothing
521
				Else
522
				assocMASSREFName = "None."
523
				End If
524
			End If%> 
525
			<%If parProjId <> 2 Then%>
526
				<%If assocMASSREFName <> "None." Then%>
527
				<td bgcolor="#F5F5F5" class="body_rowg"><a href=<%=link%>><%=assocMASSREFName%></a></td>
528
				<%Else%>
529
				<td bgcolor="#F5F5F5" class="body_rowg"><%=assocMASSREFName%></td>
530
				<%End If%>
531
			<%Else
532
			Dim UsedBy, rsQryUse, comment, linkB
533
			UsedBy =  rsQry("rtag_id")
534
			If UsedBy <> "" Then
535
			Set rsQryUse = OraDatabase.DbCreateDynaset("SELECT * FROM RELEASE_TAGS RT, PROJECTS P WHERE RT.ASSOC_MASS_REF="&rsQry("rtag_id")&" AND RT.PROJ_ID=P.PROJ_ID", ORADYN_DEFAULT) 				
536
 
537
 
538
				While ((NOT rsQryUse.BOF) AND (NOT rsQryUse.EOF))			
539
					If rsQryUse("assoc_mass_ref") = UsedBy Then		
540
					linkB = "dependencies.asp?rtag_id="&rsQryUse("rtag_id")
541
						If comment = "" Then
542
							comment = rsQryUse("proj_name") & " -> <a href="&linkB&">"& rsQryUse("rtag_name") &"</a>"
543
						Else
544
						comment = comment &" <br> " & rsQryUse("proj_name") & " -> <a href="&linkB&">"& rsQryUse("rtag_name") &"</a>"	
545
						End If
546
						rsQryUse.MoveNext
547
					End If
548
				WEnd			
549
			End If
550
			%>
551
				<%If comment <> "" Then %> 
552
					<td bgcolor="#F5F5F5" class="body_rowg"><%=comment%></td>
553
				<%Else%>
554
					<td bgcolor="#F5F5F5" class="body_rowg">None.</td>
555
				<%End If%>
556
			<%End If%>
557
            <td bgcolor="#F5F5F5" class="body_rowg"><%=NewLine_To_BR(rsQry("description"))%></td>				  
558
 
559
 
560
 
561
 
562
				</tr>
563
 
564
 
565
			<%
566
				lastLevel = currLevel
567
				rsQry.MoveNext
568
				comment = ""
569
			WEnd
570
			'Next
571
 
572
		End If
573
 
574
 
575
		rsQry.Close
576
		Set rsQry = Nothing
577
		%>
578
		</table>
579
 
580
<!-- LIST VIEW ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
581
<%Else%>
582
 
583
 
584
		<table width="100%"  border="0" cellspacing="1" cellpadding="3">
585
		  <tr>
586
            <td width="1" bgcolor="#E4E9EC">&nbsp;</td>
587
			<td width="30%" bgcolor="#E4E9EC" class="body_txt">Release Name </td>
588
 
589
            <%If parProjId <> 2 Then %>
590
			<td width="1" bgcolor="#E4E9EC">&nbsp;</td>
591
			<td width="15%" bgcolor="#E4E9EC" class="body_txt">Associated MASS_REF </td>
592
			<td width="55%" bgcolor="#E4E9EC" class="body_txt">Comments</td>
593
			<%Else%>
594
			<td width="1" bgcolor="#E4E9EC">&nbsp;</td>
595
			<td width="30%" bgcolor="#E4E9EC" class="body_txt">Used By </td>			
596
			<td width="40%" bgcolor="#E4E9EC" class="body_txt">Comments</td>
597
			<%End If%>
598
 
599
          </tr>
600
		<%
601
		OraDatabase.Parameters.Add "PROJ_ID", 	parProjId, 	ORAPARM_INPUT, ORATYPE_NUMBER
602
 
603
		Set rsQry = OraDatabase.DbCreateDynaset( GetQuery ("ReleaseVersionList.sql") , ORADYN_DEFAULT )
604
		lastLevel = 0
605
 
606
		OraDatabase.Parameters.Remove "PROJ_ID"
607
 
608
 
609
		If rsQry.RecordCount > 0 Then
610
 
611
			aVersions = rsQry.GetRows()
612
			lastRow = UBound( aVersions, 2 )
613
 
614
			'Set objSortHelper = New SortHelper
615
 
616
			' Sort versions
617
			'Call objSortHelper.VersionSort( aVersions, 0, lastRow, rsQry.FieldIndex("version") )
618
 
619
 
620
 
621
			For i = 0 To lastRow	' Ascending order
622
 
623
				'currLevel = GetLevel (  aVersions( rsQry.FieldIndex("rtag_version"), i )  )
624
			%>
625
          <tr>
626
            <td bgcolor="#F5F5F5" class="body_txt" valign="top">
627
              <input type="checkbox" name="rtag_id_list" value="<%=aVersions( rsQry.FieldIndex("rtag_id"), i )%>">
628
            </td>
629
            <td bgcolor="#F5F5F5" valign="top"><a href="dependencies.asp?rtag_id=<%=aVersions( rsQry.FieldIndex("rtag_id"), i )%>" class="body_link" title="Open Release..."><%=ReleaseIcon( aVersions( rsQry.FieldIndex("official"), i ) )%>&nbsp;<%=aVersions( rsQry.FieldIndex("rtag_name"), i )%></a></td>
630
 
631
			<%
632
			If parProjId <> 2 Then
633
				assocMASSREF = aVersions( rsQry.FieldIndex("assoc_mass_ref"), i )
634
				If assocMASSREF <> "" Then
635
				Set rsQryAssoc = OraDatabase.DbCreateDynaset("SELECT RTAG_NAME, RTAG_ID FROM RELEASE_TAGS WHERE RTAG_ID="&assocMASSREF , ORADYN_DEFAULT) 				
636
				assocMASSREFName = rsQryAssoc("RTAG_NAME")
637
				link = rsQryAssoc("rtag_id") 
638
				rsQryAssoc.Close
639
				Set rsQryAssoc = Nothing
640
				Else
641
				assocMASSREFName = "None."
642
				End If
643
			End If%> 
644
			<%If parProjId <> 2 Then%>
645
				<%If assocMASSREFName <> "None." Then%>
646
					<td bgcolor="#F5F5F5" class="body_txt" valign="top">
647
              		<input type="checkbox" name="rtag_id_list" value="<%=link%>">
648
            		</td>
649
					<td bgcolor="#F5F5F5" class="body_rowg"><a href=dependencies.asp?rtag_id=<%=link%>><%=assocMASSREFName%></a></td>
650
				<%Else%>
651
					<td width="1" bgcolor="#E4E9EC">&nbsp;</td>
652
					<td bgcolor="#F5F5F5" class="body_rowg"><%=assocMASSREFName%></td>
653
				<%End If%>
654
			<%Else
655
 
656
			UsedBy = aVersions( rsQry.FieldIndex("rtag_id"), i )
657
			If UsedBy <> "" Then
658
			Set rsQryUse = OraDatabase.DbCreateDynaset("SELECT * FROM RELEASE_TAGS RT, PROJECTS P WHERE RT.ASSOC_MASS_REF="&aVersions( rsQry.FieldIndex("rtag_id"), i )&" AND RT.PROJ_ID=P.PROJ_ID", ORADYN_DEFAULT) 				
659
 
660
				While ((NOT rsQryUse.BOF) AND (NOT rsQryUse.EOF))			
661
					If rsQryUse("assoc_mass_ref") = UsedBy Then		
662
					linkB = rsQryUse("rtag_id")
663
						If comment = "" Then
664
							comment = rsQryUse("proj_name") & " -> <a href=dependencies.asp?rtag_id="&linkB&">"& rsQryUse("rtag_name") &"</a>"
665
						Else
666
						comment = comment &" <br> " & rsQryUse("proj_name") & " -> <a href=dependencies.asp?rtag_id="&linkB&">"& rsQryUse("rtag_name") &"</a>"
667
						End If
668
						rsQryUse.MoveNext
669
					End If
670
				WEnd			
671
			End If
672
			%>
673
				<%If comment <> "" Then %> 
674
					<td bgcolor="#F5F5F5" class="body_txt" valign="top">
675
              		<input type="checkbox" name="rtag_id_list" value="<%=linkB%>">
676
            		</td>
677
					<td bgcolor="#F5F5F5" class="body_rowg"><%=comment%></td>
678
				<%Else%>
679
					<td width="1" bgcolor="#E4E9EC">&nbsp;</td>
680
					<td bgcolor="#F5F5F5" class="body_rowg">None.</td>
681
				<%End If%>
682
			<%End If%>
683
            <td bgcolor="#F5F5F5" class="body_rowg"><%=NewLine_To_BR(  aVersions( rsQry.FieldIndex("description"), i )   )%></td>
684
          </tr>
685
			<%
686
				'lastLevel = currLevel
687
			comment = ""
688
			Next
689
 
690
		End If
691
 
692
 
693
		rsQry.Close
694
		Set rsQry = Nothing
695
		%>
696
        </table>
697
		<br>
698
		<%
699
		Call Messenger ( "Note that Closed releases are not shown in this view.<br>Switch to Tree View to see all release for this project.", 3, "400" )
700
		%>
701
		<!-- MESSAGE +++++++++++++++++++++++++++++++++++++++++++++++++++ -->	
702
		<!--#include file="messages/_msg_inline.asp"-->
703
		<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
704
 
705
<%End If%>		
706
<!-- LIST VIEW END ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
707
 
708
		<hr noshade color="#CAC5B8" width="100%" size="1">
709
		</td>
710
	  </tr>
711
	  <%=objPMod.ComposeHiddenTags()%>
712
	  <input type="hidden" name="action" value="true">
713
	</form>
714
    </table>
715
 
716
	<table width="118" border="0" align="left">
717
      <tr>
718
        <td bgcolor="#E4E9EC" width="26"><span class="body_txt">Icon</span></td>
719
        <td bgcolor="#E4E9EC" width="82"><span class="body_txt">Release State </span></td>
720
      </tr>
721
      <tr>
722
        <td bgcolor="#F5F5F5"><img src="images/i_rtag_open_mode.gif" width="15" height="13"></td>
723
        <td bgcolor="#F5F5F5"><span class="body_txt">Open Mode</span></td>
724
      </tr>
725
      <tr>
726
        <td bgcolor="#F5F5F5"><img src="images/i_rtag_restrictive_mode.gif" width="15" height="15"></td>
727
        <td bgcolor="#F5F5F5"><span class="body_txt">Restrictive Mode</span></td>
728
      </tr>
729
      <tr>
730
        <td bgcolor="#F5F5F5"><img src="images/i_rtag_ccb_mode.gif" width="15" height="15"></td>
731
        <td bgcolor="#F5F5F5"><span class="body_txt">CCB Mode</span></td>
732
      </tr>
733
      <tr>
734
        <td bgcolor="#F5F5F5"><img src="images/i_rtag_closed_mode.gif" width="15" height="14"></td>
735
        <td bgcolor="#F5F5F5"><span class="body_txt">Closed Mode</span></td>
736
      </tr>
737
      <tr>
738
        <td bgcolor="#F5F5F5"><img src="images/i_rtag_archive_mode.gif" width="15" height="14"></td>
739
        <td bgcolor="#F5F5F5"><span class="body_txt">Archive Mode</span></td>
740
      </tr>	  
741
    </table>
742
	<p>&nbsp;</p></td>
743
	<td width="1" valign="top"><img src="images/h_trsp_dot.gif" width="1" height="1"></td>
744
  </tr>
745
  <tr> 
746
    <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>
747
    <td background="images/bg_lght_gray.gif" valign="top"><img src="images/h_trsp_dot.gif" width="1" height="500"></td>
748
  </tr>
749
</table>
750
 
751
 
752
<!-- FOOTER -->
753
<!--#include file="_footer.asp"-->
754
<map name="mapviewtype">
755
  <area shape="rect" coords="2,2,69,23" href="<%=ScriptName%>?viewtype=1&<%=objPMod.ComposeURL()%>" title="Switch to List View">
756
  <area shape="rect" coords="73,2,143,23" href="<%=ScriptName%>?viewtype=2&<%=objPMod.ComposeURL()%>" title="Switch to Tree View">
757
</map>
758
</body>
759
</html>
760
<%
761
Call Destroy_All_Objects
762
%>