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
'|				         DIFF					     |
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
 
15
<%
16
'To enable the script timeout to 20 mins
17
Server.ScriptTimeout=1200
18
%>
19
<!--#include file="common/conf.asp"-->
20
<!--#include file="common/globals.asp"-->
21
<!--#include file="common/formating.asp"-->
22
<!--#include file="common/qstr.asp"-->
23
<!--#include file="common/common_subs.asp"-->
24
<!--#include file="common/common_dbedit.asp"-->
25
<!--#include file="common/_form_window_common.asp"-->
26
<!--#include file="common/_rtree_common.asp"-->
27
<%
28
' Set rfile parameter. This is a return page after Login
29
'Call objPMod.StoreParameter ( "rfile", "rtree.asp" )
30
'objPMod.PersistInQryString("proj_id")
31
'------------ ACCESS CONTROL ------------------
32
%>
33
<!--#include file="_access_control_login.asp"-->
34
<!--#include file="_access_control_general.asp"-->
35
<%
36
'------------ Variable Definition -------------
37
Dim rsQry
38
Dim objRelCollectorA
39
Dim objRelCollectorB
40
Dim parRtagA
41
Dim parRtagB
42
Dim dDiffFilter
43
Dim colorA, colorB, ChangeTypeIcon
44
Dim btnMerge, btnRemove
45
Dim rowId
46
Dim email
47
Dim FSO
48
Dim NewTextFile
49
Dim pkgA, pkgB, pkgname, delimiter, rsQryA, rsQryB, rsQryCommentsA, rsQryCommentsB, sqlstrA, counterA, sqlstrB, counterB
50
Dim SSsql, retVal, rsCQ, DEVIiss, TDSEiss, VT5DMiss, VTSUPiss
51
Dim a, b, c, d, pkgversion, errormsg, source_change, ChangeASource, ChangeAUpdate, ChangeBSource, ChangeBUpdate, pvCollectionA, pvCollectionB
52
Dim changeType
53
 
54
'------------ Constants Declaration -----------
55
Const LIMG_UPDATED = "<img src='images/i_updated.gif' width='11' height='11' border='0' hspace='5' align='absmiddle' title='Updated'>"
56
Const LIMG_RIPPLED = "<img src='images/i_rippled.gif' width='11' height='11' border='0' hspace='5' align='absmiddle' title='Rippled'>"
57
Const LIMG_ADDED = "<img src='images/i_added.gif' width='11' height='11' border='0' hspace='5' align='absmiddle' title='Added'>"
58
Const LIMG_REMOVED = "<img src='images/i_removed.gif' width='11' height='11' border='0' hspace='5' align='absmiddle' title='Removed'>"
59
Const LIMG_FILTER_ON = "<img src='images/i_data_table.gif' border='0' align='absmiddle' hspace='0' title='Filter in use.'>"
60
Const LIMG_FILTER_OFF = "<img src='images/i_data_table_off.gif' border='0' align='absmiddle' hspace='0' title='Filter not in use.'>"
61
Const LIMG_DROP_DOWN_ARROW = "<img src='images/i_drop_down_arrow.gif' width='5' height='15' hspace='1' border='0' align='absmiddle'>"
62
Const LCOLOR_NOT_CHANGED = "#F5F5F5"
63
Const LCOLOR_CHANGED = "#d2f7c9"
64
Const LCOLOR_RIPPLED = "#D8F8F8"
65
Const LCOLOR_BLANK = "#FFFFFF"
66
Const LIMG_MERGE = "<img src='images/bt_move_all_right.gif' title='Click to merge.' border='0'>"
67
Const LIMG_MERGE_WARN = "<img src='images/bt_move_warn_right.gif' title='Right hand side version is newer.' border='0'>"
68
Const LIMG_REMOVE = "<img src='images/bt_remove.gif' title='Remove this version from release.' border='0'>"
69
Const LIMG_UNDO = "<img src='images/bt_undo.gif' title='Undo merge/remove.' border='0'>"
70
'------------ Variable Init -------------------
71
Set rsCQ = Server.CreateObject("ADODB.Recordset")
72
parRtagA = Request("rtagA")
73
parRtagB = Request("rtagB")
74
Set objRelCollectorA = CreateObject("Scripting.Dictionary")
75
Set objRelCollectorB = CreateObject("Scripting.Dictionary")
76
Set dDiffFilter = CreateObject("Scripting.Dictionary")
77
'----------------------------------------------
78
If Request("btn") = "Mail Me Report" Then
79
	email = true
80
End If
81
%>
82
<%
83
'--------------------------------------------------------------------------------------------------------------------------
84
Sub GetDiffFilterValues ( outDepFilter )
85
	Dim FilterVal, aFilterValues
86
 
87
	If Request.Cookies(enum_RELMGR_COOKIE_DOMAIN)(COOKIE_HIDE_DIFF_FILTER) <> "" Then
88
		aFilterValues = Split( Replace( Request.Cookies(enum_RELMGR_COOKIE_DOMAIN)(COOKIE_HIDE_DIFF_FILTER), " ", ""), ",")
89
 
90
		For Each FilterVal In aFilterValues
91
			outDepFilter.Item (CStr( FilterVal )) = ""
92
		Next
93
 
94
	End If
95
 
96
End Sub
97
'--------------------------------------------------------------------------------------------------------------------------
98
Sub GetFixedIssues(pv_id)
99
	Set sqlstrA = OraDatabase.DbCreateDynaset("SELECT iss_db, iss_id, iss_state, notes FROM CQ_ISSUES WHERE pv_id="& pv_id &"  AND iss_state = "& enumISSUES_STATE_FIXED &_
100
	" UNION SELECT iss_db, iss_id, iss_state, notes FROM ARCHIVE_MANAGER.CQ_ISSUES WHERE pv_id="& pv_id &"  AND iss_state = "& enumISSUES_STATE_FIXED, cint(0))
101
 
102
		If sqlstrA.RecordCount <> 0 Then
103
			NewTextFile.WriteLine()
104
			NewTextFile.WriteLine("<blockquote><blockquote>Fixed Issues:</blockquote></blockquote>")
105
		End If
106
 
107
		For counterA=1 to sqlstrA.RecordCount
108
			DEVIiss = "-1"
109
			TDSEiss = "-1"
110
			VT5DMiss = "-1"
111
			VTSUPiss = "-1"
112
 
113
			If CInt(sqlstrA("iss_db")) = CInt(enumCLEARQUEST_DEVI_ID) Then
114
				DEVIiss = DEVIiss &","& sqlstrA("iss_id")
115
			ElseIf CInt(sqlstrA("iss_db")) = CInt(enumCLEARQUEST_TDSE_ID) Then
116
				TDSEiss = TDSEiss &","& sqlstrA("iss_id")
117
			ElseIf CInt(sqlstrA("iss_db")) = CInt(enumCLEARQUEST_VT5DM_ID) Then
118
				VT5DMiss = VT5DMiss &","& sqlstrA("iss_id")
119
			ElseIf CInt(sqlstrA("iss_db")) = CInt(enumCLEARQUEST_VTSUP_ID) Then
120
				VTSUPiss = VTSUPiss &","& sqlstrA("iss_id")
121
			End If
122
 
123
			SSsql = ReadFile( rootPath & "queries\cq_issues.sql" )
124
			SSsql = Replace( SSsql, "/*enumCLEARQUEST_DEVI_ID*/", enumCLEARQUEST_DEVI_ID)
125
			SSsql = Replace( SSsql, "/*enumCLEARQUEST_TDSE_ID*/", enumCLEARQUEST_TDSE_ID)
126
			SSsql = Replace( SSsql, "/*enumCLEARQUEST_VT5DM_ID*/", enumCLEARQUEST_VT5DM_ID)
127
			SSsql = Replace( SSsql, "/*enumCLEARQUEST_VTSUP_ID*/", enumCLEARQUEST_VTSUP_ID)
128
			SSsql = Replace( SSsql, "/*DEVIiss*/", DEVIiss)
129
			SSsql = Replace( SSsql, "/*TDSEiss*/", TDSEiss)
130
			SSsql = Replace( SSsql, "/*VT5DMiss*/", VT5DMiss)
131
			SSsql = Replace( SSsql, "/*VTSUPiss*/", VTSUPiss)
132
			retVal = Get_CQ_Issues ( SSsql, rsCQ )
133
 
134
			If rsCQ("iss_num") <> "" Then
135
  				NewTextFile.Write("<blockquote><blockquote><blockquote>"&rsCQ("iss_num")&": ")
136
	    	End If
137
 
138
	     	If rsCQ("summary") <> "" Then
139
				NewTextFile.WriteLine(rsCQ("summary")&"</blockquote></blockquote></blockquote>")
140
			End If
141
 
142
			sqlstrA.MoveNext
143
		Next
144
			sqlstrA.Close()
145
 
146
 
147
End Sub
148
'--------------------------------------------------------------------------------------------------------------------------
149
Sub LastPvIdA(a)
150
 
151
	Dim qryA
152
	Set qryA = OraDatabase.DbCreateDynaset("SELECT LAST_PV_ID FROM PACKAGE_VERSIONS WHERE PV_ID="&a &_
153
	" UNION SELECT LAST_PV_ID FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&a, cint(0))
154
 
155
	'If a <> qryA("last_pv_id") Then
156
		a = qryA("last_pv_id")
157
	'Else
158
	'	errormsg = true
159
	'End If
160
 
161
	If pvCollectionA.Exists(CStr(a)) Then
162
		errormsg = true
163
		Exit Sub
164
	End If
165
 
166
	qryA.Close()
167
End Sub
168
'--------------------------------------------------------------------------------------------------------------------------
169
Sub LastPvIdB(b)
170
	Dim qryB
171
	Set qryB = OraDatabase.DbCreateDynaset("SELECT LAST_PV_ID FROM PACKAGE_VERSIONS WHERE PV_ID="&b &_
172
	" UNION SELECT LAST_PV_ID FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&b, cint(0))
173
 
174
	'If b <> qryB("last_pv_id") Then
175
		b = qryB("last_pv_id")
176
	'Else
177
	'	errormsg = true
178
	'End If
179
 
180
	If pvCollectionB.Exists(CStr(b)) Then
181
		errormsg = true
182
		Exit Sub
183
	End If
184
 
185
 
186
	qryB.Close()
187
 
188
End Sub
189
'--------------------------------------------------------------------------------------------------------------------------
190
Sub pkg_Version(pv)
191
	Dim qry
192
	Set qry = OraDatabase.DbCreateDynaset("SELECT PKG_VERSION FROM PACKAGE_VERSIONS WHERE PV_ID="&pv &_
193
	" UNION SELECT PKG_VERSION FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&pv, cint(0))
194
	pkgversion = qry("pkg_version")
195
	qry.Close()
196
End Sub
197
'--------------------------------------------------------------------------------------------------------------------------
198
Sub LastPvIdAa(a)
199
	Dim qryA
200
	Set qryA = OraDatabase.DbCreateDynaset("SELECT LAST_PV_ID FROM PACKAGE_VERSIONS WHERE PV_ID="&a &_
201
	" UNION SELECT LAST_PV_ID FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&a, cint(0))
202
	c = qryA("last_pv_id")
203
	qryA.Close()
204
End Sub
205
'--------------------------------------------------------------------------------------------------------------------------
206
Sub LastPvIdBb(b)
207
	Dim qryB
208
	Set qryB = OraDatabase.DbCreateDynaset("SELECT LAST_PV_ID FROM PACKAGE_VERSIONS WHERE PV_ID="&b &_
209
	" UNION SELECT LAST_PV_ID FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&b, cint(0))
210
	d = qryB("last_pv_id")
211
	qryB.Close()
212
End Sub
213
'--------------------------------------------------------------------------------------------------------------------------
214
Sub Comments(Pv_Id)
215
	Dim comments
216
	Set comments = OraDatabase.DbCreateDynaset("SELECT COMMENTS, PKG_VERSION FROM PACKAGE_VERSIONS WHERE PV_ID="&Pv_id &_
217
	" UNION SELECT COMMENTS, PKG_VERSION FROM ARCHIVE_MANAGER.PACKAGE_VERSIONS WHERE PV_ID="&Pv_id, cint(0))
218
 
219
	If comments("comments") <> "Rippled Build." Then
220
		NewTextFile.WriteLine("<blockquote><blockquote><font color="&chr(34)&"blue"&chr(34)&">Version: "& comments("pkg_version")&"</font></blockquote></blockquote>")
221
		If comments("comments") <> "" Then
222
			NewTextFile.WriteLine("<blockquote><blockquote>Comments: </blockquote></blockquote>")
223
			NewTextFile.WriteLine("<blockquote><blockquote><blockquote>"& TextToHTML(comments("comments")) &"</blockquote></blockquote></blockquote>")
224
			source_change = true
225
		End If
226
	End If
227
 
228
End Sub
229
'--------------------------------------------------------------------------------------------------------------------------
230
Sub Release(pvId)
231
	Dim release
232
	Set release = OraDatabase.DbCreateDynaset("SELECT INSERT_STAMP FROM RELEASE_CONTENT WHERE PV_ID="&pvId &_
233
	" UNION SELECT INSERT_STAMP FROM ARCHIVE_MANAGER.RELEASE_CONTENT WHERE PV_ID="&pvId, cint(0))
234
 
235
	If release("insert_stamp") <> "" Then
236
		NewTextFile.Write(release("insert_stamp"))
237
	Else
238
		NewTextFile.Write("Version Not Used.")
239
	End If
240
 
241
End Sub
242
'--------------------------------------------------------------------------------------------------------------------------
243
Sub Header()
244
	NewTextFile.WriteLine("<html>")
245
End Sub
246
'--------------------------------------------------------------------------------------------------------------------------
247
Sub Footer()
248
	NewTextFile.WriteLine("</html>")
249
End Sub
250
'--------------------------------------------------------------------------------------------------------------------------
251
Sub Javascript()
252
	NewTextFile.WriteLine("<script language=""JavaScript"" type=""text/javascript"">")
253
	NewTextFile.WriteLine("function MM_findObj(n, d) { //v4.0")
254
	NewTextFile.WriteLine("  var p,i,x;")
255
	NewTextFile.WriteLine("  if(!d) d=document; ")
256
	NewTextFile.WriteLine("  if((p=n.indexOf(""?""))>0&&parent.frames.length) {")
257
	NewTextFile.WriteLine("  	d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);")
258
	NewTextFile.WriteLine("  }")
259
	NewTextFile.WriteLine("  if(!(x=d[n])&&d.all) x=d.all[n]; ")
260
	NewTextFile.WriteLine("  for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];")
261
	NewTextFile.WriteLine("  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);")
262
	NewTextFile.WriteLine("  if(!x && document.getElementById) x=document.getElementById(n); ")
263
	NewTextFile.WriteLine("  return x;")
264
	NewTextFile.WriteLine("}")
265
	NewTextFile.WriteLine("function DisplaySPAN(show, x) {")
266
	NewTextFile.WriteLine("	if (show) {")
267
	NewTextFile.WriteLine("		MM_findObj(""spanHideDetails"" + x).style.display = ""block"";")
268
	NewTextFile.WriteLine("		MM_findObj(""spanPkgInfo"" + x).style.display = ""block"";")
269
	NewTextFile.WriteLine("		MM_findObj(""spanShowDetails"" + x).style.display = ""none"";")
270
	NewTextFile.WriteLine("	} else {")
271
	NewTextFile.WriteLine("		MM_findObj(""spanHideDetails"" + x).style.display = ""none"";")
272
	NewTextFile.WriteLine("		MM_findObj(""spanPkgInfo"" + x).style.display = ""none"";")
273
	NewTextFile.WriteLine("		MM_findObj(""spanShowDetails"" + x).style.display = ""block"";")
274
	NewTextFile.WriteLine("	}")
275
	NewTextFile.WriteLine("}")
276
	NewTextFile.WriteLine("</script>")
277
End Sub
278
'--------------------------------------------------------------------------------------------------------------------------
279
Function GetIsDiffFilterInUseIcon()
280
	GetIsDiffFilterInUseIcon = LIMG_FILTER_OFF & LIMG_DROP_DOWN_ARROW
281
 
282
	If dDiffFilter.Count > 0 Then
283
		GetIsDiffFilterInUseIcon = LIMG_FILTER_ON & LIMG_DROP_DOWN_ARROW
284
	End If
285
 
286
End Function
287
'--------------------------------------------------------------------------------------------------------------------------
288
Function GetIsDiffFilterChecked( nFilterId )
289
 
290
	If dDiffFilter.Exists ( CStr(nFilterId)  ) Then
291
		GetIsDiffFilterChecked = "checked"
292
	End If
293
 
294
End Function
295
'---------------------------------------------------------------------------------------------------------------------------
296
Function  Get_CQ_Issues ( SSsql, OOrsCQ )
297
 
298
	If OOrsCQ.State = 1 Then
299
		OOrsCQ.Close
300
	End If
301
 
302
	On Error Resume Next
303
	OOrsCQ.ActiveConnection = CQ_conn
304
	OOrsCQ.Source = SSsql
305
	OOrsCQ.CursorType = 0
306
	OOrsCQ.CursorLocation = 2
307
	OOrsCQ.LockType = 3
308
	OOrsCQ.Open()
309
	Get_CQ_Issues = Err.Number
310
 
311
End Function
312
'--------------------------------------------------------------------------------------------------------------------------
313
Public Function TextToHTML ( sString )
314
	Dim mString
315
 
316
	If (sString = "") OR IsNull(sString) Then Exit Function
317
 
318
	mString = Server.HTMLEncode( sString )
319
	mString = Replace(mString, VBNewLine, "<br>")
320
 
321
	TextToHTML = mString
322
End Function
323
'--------------------------------------------------------------------------------------------------------------------------
324
 
325
Sub GetFormDetails ( nSourceRtagId, ByRef outobjDetails )
326
	Dim rsQry, query
327
 
328
	' Exit if nSourceRtagId is empty
329
	If nSourceRtagId = "" Then Exit Sub
330
 
331
	OraDatabase.Parameters.Add "SOURCE_RTAG_ID", 	nSourceRtagId,		ORAPARM_INPUT, ORATYPE_NUMBER
332
 
333
	query = _
334
	" SELECT pr.PROJ_NAME ||' &gt; '|| rt.RTAG_NAME   AS LOCATION, "&_
335
	"        rt.OFFICIAL, pr.PROJ_ID, rt.RTAG_ID"&_
336
	"  FROM RELEASE_TAGS rt,"&_
337
	"  	    PROJECTS pr"&_
338
	" WHERE rt.PROJ_ID = pr.PROJ_ID"&_
339
	"   AND rt.RTAG_ID = :SOURCE_RTAG_ID"
340
 
341
	Set rsQry = OraDatabase.DbCreateDynaset( query, ORADYN_DEFAULT )
342
 
343
	OraDatabase.Parameters.Remove "SOURCE_RTAG_ID"
344
 
345
	If rsQry.RecordCount > 0 Then
346
		outobjDetails.Item ("location") = rsQry("location")
347
		outobjDetails.Item ("official") = rsQry("official")
348
		outobjDetails.Item ("proj_id") = rsQry("proj_id")
349
		outobjDetails.Item ("rtag_id") = rsQry("rtag_id")
350
	Else
351
		Err.Raise 8, "Sub GetFormDetails in "& ScriptName, "Empty record set returned. nSourceRtagId="& nSourceRtagId
352
	End If
353
 
354
	rsQry.Close
355
	Set rsQry = Nothing
356
 
357
End Sub
358
'--------------------------------------------------------------------------------------------------------------------------
359
Sub GetDiffStateIcon( nDiffState, outIcon )
360
 
361
	Select Case nDiffState
362
		Case "U"
363
			outIcon  = LIMG_UPDATED
364
		Case "UW"
365
			outIcon  = LIMG_UPDATED
366
		Case "A"
367
			outIcon = LIMG_ADDED
368
		Case "R"
369
			outIcon = LIMG_REMOVED
370
		Case "UR"
371
			outIcon = LIMG_RIPPLED
372
		Case Else
373
			outIcon = ""
374
	End Select
375
 
376
End Sub
377
'--------------------------------------------------------------------------------------------------------------------------
378
Sub MergePackages (releaseMode)
379
	Dim aFullList, aAddPkgList, aRemovePkgList, dAddPkgList, dRemovePkgList, PvId
380
	Dim OraParameter
381
 
382
	' Business Rules restricting the use of the merge feature...
383
	' Bypass merge if the destination release is in closed or archive mode, or if user does not have
384
	' merge permissions
385
	If releaseMode <> enumDB_RELEASE_IN_CLOSED_MODE  AND releaseMode <> enumDB_RELEASE_IN_ARCHIVE_MODE _
386
	AND (objAccessControl.IsActive("MergeRelease")) THEN
387
 
388
		Set dAddPkgList = CreateObject("Scripting.Dictionary")
389
		Set dRemovePkgList = CreateObject("Scripting.Dictionary")
390
 
391
		'--- Get Add Packages ---
392
		' Get full list of "addpkg" parameter
393
		aFullList = Split ( Replace( Request("addpkg"), " ", "" ), "," )
394
 
395
		' Clean empty parameters
396
		For Each PvId In aFullList
397
			If PvId <> "" Then
398
				dAddPkgList.Add CStr( PvId ), Empty
399
			End If
400
		Next
401
 
402
		aFullList = NULL
403
		aAddPkgList = dAddPkgList.Keys
404
 
405
		'--- Get Remove Packages ---
406
		' Get full list of "removepkg" parameter
407
		aFullList = Split ( Replace( Request("removepkg"), " ", "" ), "," )
408
 
409
		' Clean empty parameters
410
		For Each PvId In aFullList
411
			If PvId <> "" Then
412
				dRemovePkgList.Add CStr( PvId ), Empty
413
			End If
414
		Next
415
 
416
		aFullList = NULL
417
		aRemovePkgList = dRemovePkgList.Keys
418
 
419
		'-- Add package List to release --
420
		OraDatabase.Parameters.Add "PV_ID",    NULL, ORAPARM_INPUT, ORATYPE_NUMBER
421
		OraDatabase.Parameters.Add "VIEW_ID",  NULL, ORAPARM_BOTH, ORATYPE_NUMBER
422
		OraDatabase.Parameters.Add "RTAG_A",   Request("rtagA"), ORAPARM_INPUT, ORATYPE_NUMBER
423
		OraDatabase.Parameters.Add "RTAG_B",   Request("rtagB"), ORAPARM_INPUT, ORATYPE_NUMBER
424
		OraDatabase.Parameters.Add "PROJB",    objRelCollectorB.Item("proj_id"), ORAPARM_INPUT, ORATYPE_NUMBER
425
		OraDatabase.Parameters.Add "COMMENTS", "Merging from "& objRelCollectorA.Item("location") &" to "& objRelCollectorB.Item("location"), ORAPARM_INPUT, ORATYPE_VARCHAR2
426
		OraDatabase.Parameters.Add "USER_ID",  objAccessControl.UserId, ORAPARM_INPUT, ORATYPE_NUMBER
427
		OraDatabase.Parameters.Add "OPERATION",NULL, ORAPARM_INPUT, ORATYPE_CHAR
428
 
429
		Set OraParameter = OraDatabase.Parameters
430
 
431
 
432
		On Error Resume Next
433
 
434
 
435
		' Begin Database entry
436
		objEH.TryORA ( OraSession )
437
 
438
		OraSession.BeginTrans
439
 
440
		'-- Add Packages --
441
		OraParameter("OPERATION").Value = "A"
442
		For Each PvId In aAddPkgList
443
			OraParameter("PV_ID").Value = PvId
444
			' DEVI-45275, Merge into Planned (pending) table instead of release_content table.
445
			OraDatabase.ExecuteSQL _
446
			"BEGIN  "&_
447
			"  :VIEW_ID := PK_RELEASE.GET_PACKAGE_VIEW ( :PV_ID, :RTAG_A ); "&_
448
			"  PK_PLANNED.MERGE_PACKAGE ( :PV_ID, :VIEW_ID, :RTAG_B, :USER_ID, :OPERATION );  "&_
449
			"END;"
450
		Next
451
 
452
		'-- Remove Packages --
453
		OraParameter("OPERATION").Value = "S"
454
		For Each PvId In aRemovePkgList
455
			OraParameter("PV_ID").Value = PvId
456
			' DEVI-45275, Merge into Planned (pending) table instead of release_content table.
457
			OraDatabase.ExecuteSQL _
458
			"BEGIN  "&_
459
			"  :VIEW_ID := PK_RELEASE.GET_PACKAGE_VIEW ( :PV_ID, :RTAG_B ); "&_
460
			"  PK_PLANNED.MERGE_PACKAGE ( :PV_ID, :VIEW_ID, :RTAG_B, :USER_ID, :OPERATION );  "&_
461
			"END;"
462
		Next
463
 
464
		'-- Log Project Merge Action
465
		OraDatabase.ExecuteSQL _
466
		"BEGIN  LOG_PROJECT_ACTION ( :PROJB, 'merge_release', :USER_ID, :COMMENTS, :RTAG_B );  END;"
467
 
468
		'-- Force package state recalculate
469
		OraDatabase.ExecuteSQL _
470
		"BEGIN  "&_
471
		"  TOUCH_RELEASE ( :RTAG_B );  "&_
472
		"END;"
473
 
474
		OraSession.CommitTrans
475
 
476
		objEH.CatchORA ( OraSession )
477
 
478
		Set OraParameter = Nothing
479
		OraDatabase.Parameters.Remove "PV_ID"
480
		OraDatabase.Parameters.Remove "VIEW_ID"
481
		OraDatabase.Parameters.Remove "RTAG_A"
482
		OraDatabase.Parameters.Remove "RTAG_B"
483
		OraDatabase.Parameters.Remove "USER_ID"
484
		OraDatabase.Parameters.Remove "PROJB"
485
		OraDatabase.Parameters.Remove "COMMENTS"
486
		OraDatabase.Parameters.Remove "OPERATION"
487
		'Response.write "<br>"& sAddPkgList &"-"& dAddPkgList.Count &"-"& UBound( aFullList )
488
	End If
489
End Sub
490
'--------------------------------------------------------------------------------------------------------------------------
491
Function AddTrailingZeros(byval n, byval count)
492
	if len(n) >= count then
493
		AddTrailingZeros = n
494
		exit function
495
	end if
496
 
497
	dim c, s, i
498
	c = count - len(n)
499
 
500
	for i = 1 to c
501
		s = s & "0"
502
	next
503
	s = cstr(n) & s
504
 
505
	AddTrailingZeros = s
506
End function
507
'--------------------------------------------------------------------------------------------------------------------------
508
%>
509
<%
510
'------------ RUN BEFORE PAGE RENDER ----------
511
If Request("btn") = "Exit" Then
512
	Call OpenInWindow ( "index.asp" )
513
End If
514
 
515
' Get release details
516
Call GetFormDetails ( parRtagA, objRelCollectorA )
517
Call GetFormDetails ( parRtagB, objRelCollectorB )
518
 
519
 
520
 
521
 
522
If (Request("btn") = "Merge") Then
523
	Call MergePackages ( objRelCollectorB.Item("official") )
524
End If
525
 
526
If Request("btn") = "Swap Compare" Then
527
	Call OpenInWindow ( ScriptName &"?rtagA="& parRtagB &"&rtagB="& parRtagA )
528
End If
529
 
530
If Request("btn") = "Hide" Then
531
	' Store filter in cookie
532
	Response.Cookies(enum_RELMGR_COOKIE_DOMAIN)(COOKIE_HIDE_DIFF_FILTER) = Request("difilter")
533
End If
534
 
535
 
536
Call GetDiffFilterValues ( dDiffFilter )
537
'----------------------------------------------
538
%>
539
<html>
540
<head>
541
<title>Release Manager</title>
542
<meta HTTP-EQUIV="Pragma" CONTENT="no-cache">
543
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
544
<link rel="stylesheet" href="images/release_manager_style.css" type="text/css">
545
<link rel="stylesheet" href="images/navigation.css" type="text/css">
546
<script language="JavaScript" src="images/common.js"></script>
547
<script language="JavaScript" src="scripts/remote_scripting.js"></script>
548
<script language="JavaScript" type="text/javascript">
549
<!--
550
 
551
function RequestReleaseCombo( paramString, rowId ){
552
	var requestURL = 'RequestReleaseCombo.asp';
553
 
554
	// Set ajax divname
555
	ajaxdivname = rowId;
556
 
557
	//Append the name to search for to the requestURL
558
	var url = requestURL + paramString;
559
 
560
	//Progress
561
	//alert(MM_findObj( rowId ));
562
 
563
	//MM_findObj( rowId ).options[0] = new Option('Loading...','');
564
	//MM_findObj( rowId ).selectedIndex = 0;
565
	rowId.options[0] = new Option('Loading...','');
566
	rowId.selectedIndex = 0;
567
 
568
 
569
	//Create the xmlHttp object to use in the request
570
	//stateChangeHandler will fire when the state has changed, i.e. data is received back
571
	// This is non-blocking (asynchronous)
572
	xmlHttp = GetXmlHttpObject(stateComboChangeHandler);
573
 
574
	//Send the xmlHttp get to the specified url
575
	xmlHttp_Get(xmlHttp, url);
576
 
577
 
578
}
579
 
580
 
581
function MergePackage ( pkga, pkgb, rowId )
582
{
583
 
584
	// Set merge hidden field with new value
585
	MM_findObj( 'ADDPKG_' + rowId ).value = pkga;
586
 
587
	var divA = MM_findObj( 'PVA' + rowId );
588
	var divB = MM_findObj( 'PVB' + rowId );
589
 
590
	// Set text equal
591
	divB.innerHTML = divA.innerHTML;
592
 
593
	// Set highlight to blank
594
	divA.style.backgroundColor = '<%=LCOLOR_NOT_CHANGED%>';
595
	divB.style.backgroundColor = '<%=LCOLOR_NOT_CHANGED%>';
596
 
597
    // Set Change state icon to blank
598
	MM_findObj( 'IMGSTATE' + rowId ).style.display = 'none';
599
 
600
	// Remove Merge Button
601
	MM_findObj( 'IMGMERGE' + rowId ).style.display = 'none';
602
	MM_findObj( 'IMGREMOVE' + rowId ).style.display = 'none';
603
 
604
	// Show undo button
605
	MM_findObj( 'IMGUNDO' + rowId ).style.display = 'block';
606
 
607
 
608
}
609
 
610
 
611
function RemovePackage ( pkga, pkgb, rowId )
612
{
613
 
614
	// Set remove hidden field with new value
615
	MM_findObj( 'REMOVEPKG_' + rowId ).value = pkgb;
616
 
617
	var divA = MM_findObj( 'PVA' + rowId );
618
	var divB = MM_findObj( 'PVB' + rowId );
619
 
620
	// Set text equal
621
	divB.style.textDecoration = 'line-through';
622
 
623
	// Set highlight to blank
624
	if (MM_findObj( 'CHANGETYPE_' + rowId ).value != "A")
625
	{
626
		divA.style.backgroundColor = '<%=LCOLOR_NOT_CHANGED%>';
627
	}
628
	divB.style.backgroundColor = '<%=LCOLOR_NOT_CHANGED%>';
629
 
630
    // Set Change state icon to blank
631
	MM_findObj( 'IMGSTATE' + rowId ).style.display = 'none';
632
 
633
	// Remove Merge Button
634
	MM_findObj( 'IMGMERGE' + rowId ).style.display = 'none';
635
	MM_findObj( 'IMGREMOVE' + rowId ).style.display = 'none';
636
 
637
	// Show undo button
638
	MM_findObj( 'IMGUNDO' + rowId ).style.display = 'block';
639
 
640
 
641
}
642
 
643
 
644
 
645
function UndoPackage ( rowId )
646
{
647
 
648
	// Set merge/remove hidden field with new value
649
	MM_findObj( 'ADDPKG_' + rowId ).value = '';
650
	MM_findObj( 'REMOVEPKG_' + rowId ).value = '';
651
 
652
	var divA = MM_findObj( 'PVA' + rowId );
653
	var divB = MM_findObj( 'PVB' + rowId );
654
 
655
	// Set text equal
656
	divB.innerHTML = MM_findObj( 'UNDOPKG_' + rowId ).value;
657
	divB.style.textDecoration = 'none';
658
 
659
 
660
	// Set highlight to blank
661
	divA.style.backgroundColor = MM_findObj( 'UNDOCOLORA_' + rowId ).value;
662
	divB.style.backgroundColor = MM_findObj( 'UNDOCOLORB_' + rowId ).value;
663
 
664
 
665
    // Set Change state icon to blank
666
	MM_findObj( 'IMGSTATE' + rowId ).style.display = 'block';
667
 
668
 
669
	// Remove Merge Button
670
	var cht = MM_findObj( 'CHANGETYPE_' + rowId );
671
 
672
	if (cht.value == "R")
673
	{
674
		MM_findObj( 'IMGMERGE' + rowId ).style.display = 'block';
675
	}
676
	else if ( (cht.value == "A") || (cht.value == "") )
677
	{
678
		MM_findObj( 'IMGREMOVE' + rowId ).style.display = 'block';
679
	}
680
	else
681
	{
682
		MM_findObj( 'IMGMERGE' + rowId ).style.display = 'block';
683
		MM_findObj( 'IMGREMOVE' + rowId ).style.display = 'block';
684
	}
685
 
686
	// Show undo button
687
	MM_findObj( 'IMGUNDO' + rowId ).style.display = 'none';
688
 
689
}
690
 
691
 
692
function MergeAll()
693
{
694
	var elem
695
 
696
	if (document.all)
697
	{
698
		// Run this for IE
699
		elem = document.all;
700
	} else {
701
		// Run this for other browsers
702
		elem = document.getElementsByTagName('div');
703
	}
704
 
705
	for (i in elem)
706
	{
707
		if (elem[i].id)
708
		{
709
			if (elem[i].id.indexOf('SHORT_') == 0) elem[i].style.display = 'none';
710
			if (elem[i].id.indexOf('LONG_') == 0) elem[i].style.display = 'block';
711
		}
712
	}
713
 
714
}
715
 
716
//-->
717
</script>
718
 
719
</head>
720
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0">
721
<form name="FormName" method="post" action="<%=ScriptName%>">
722
<!-- HEADER -->
723
<table width="100%" border="0" cellspacing="0" cellpadding="0">
724
  <tr>
725
    <td><a href="index.asp" alt="Home" title="Home"><img src="images/b_release_manager.jpg" width="467" height="50" border="0"></a></td>
726
    <td valign="bottom" align="right">&nbsp;</td>
727
  </tr>
728
  <tr>
729
    <td align=left noWrap valign=center width=150 background="images/h_dot.gif" height="1"></td>
730
    <td background="images/h_dot.gif" height="1"></td>
731
  </tr>
732
</table>
733
<!-- BODY ---->
734
<table width="100%" border="0" cellspacing="0" cellpadding="0">
735
  <tr>
736
    <td width="1%" background="images/bg_home_orange.gif" valign="top">
737
 
738
 
739
	<!-- SELECT RELEASE A ---------------------------------------------->
740
 
741
	<br>
742
      <table width="100%"  border="0" cellspacing="10" cellpadding="0">
743
 
744
		<tr>
745
          <td align="left" class="body_col"><img src="images/i_rtag_open_mode.gif" border="0" align="absmiddle" width="15" height="13">&nbsp;Select Release A<hr size="1px" color="Olive" noshade></td>
746
        </tr>
747
        <tr>
748
          <td align="left">
749
		  <select name="projA" class="form_item" onChange="RequestReleaseCombo( '?proj_id='+ this.value, FormName.rtagA );">
750
              <option value="">-- Select Project --</option>
751
			  <%
752
			  OraDatabase.Parameters.Add "PROJ_ID", 	objRelCollectorA.Item("proj_id"),	ORAPARM_INPUT, ORATYPE_NUMBER
753
 
754
			  Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("ProjectsCombo.sql"), cint(0))
755
 
756
			  OraDatabase.Parameters.Remove "PROJ_ID"
757
 
758
			  While ((NOT rsQry.BOF) AND (NOT rsQry.EOF))%>
759
                <option value="<%=rsQry("proj_id")%>" <%=rsQry("selected")%>><%=rsQry("proj_name")%></option>
760
              <%rsQry.MoveNext
761
			  WEnd
762
 
763
			  rsQry.Close
764
			  Set rsQry = Nothing
765
			%>
766
          </select></td>
767
        </tr>
768
        <tr>
769
          <td align="left">
770
 
771
		  <select name="rtagA" id="rtagA" class="form_item">
772
			  <%
773
			  OraDatabase.Parameters.Add "PROJ_ID", 	objRelCollectorA.Item("proj_id"),	ORAPARM_INPUT,  ORATYPE_NUMBER
774
			  OraDatabase.Parameters.Add "RTAG_ID", 	objRelCollectorA.Item("rtag_id"),	ORAPARM_INPUT, ORATYPE_NUMBER
775
 
776
			  Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("ReleasesCombo.sql"), cint(0))
777
 
778
			  OraDatabase.Parameters.Remove "PROJ_ID"
779
			  OraDatabase.Parameters.Remove "RTAG_ID"
780
 
781
			  While ((NOT rsQry.BOF) AND (NOT rsQry.EOF))%>
782
                <option value="<%=rsQry("rtag_id")%>" <%=rsQry("selected")%>><%=rsQry("rtag_name")%></option>
783
              <%rsQry.MoveNext
784
			  WEnd
785
 
786
			  rsQry.Close
787
			  Set rsQry = Nothing
788
			  %>
789
		  </select>
790
 
791
		  </td>
792
        </tr>
793
		<%If (parRtagA <> "") Then%>
794
		<tr>
795
          <td align="left"><a href="dependencies.asp?rtag_id=<%=parRtagA%>" class="body_txt_drk">Go To Release A &raquo;</a></td>
796
        </tr>
797
		<%End If%>
798
    </table>
799
 
800
    <!-- SELECT RELEASE A END ---------------------------------------------->
801
 
802
 
803
	</td>
804
    <td width="1%" valign="top" background="images/bg_lght_gray.gif">&nbsp;</td>
805
    <td rowspan="2" valign="top" width="100%" background="images/bg_lght_gray.gif" align="center">
806
      <!-- DIFF -------------------------------------------------------->
807
      <br>
808
 
809
 
810
 
811
 
812
      <table width="100%" border="0" cellspacing="10" cellpadding="0">
813
        <tr>
814
          <td>
815
 
816
 
817
 
818
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
819
			  <tr>
820
                <td width="1%"></td>
821
                <td width="100%" align="left" class="form_ttl">DIFF / MERGE RELEASE</td>
822
                <td width="1%"></td>
823
              </tr>
824
              <tr>
825
                <td align="left" valign="top" background="images/lbox_bg_blue.gif"><img src="images/lbox_tl_cnr_b.gif" width="13" height="13"></td>
826
                <td background="images/lbox_bg_blue.gif" align="left" class="wform_ttl">&nbsp;
827
                </td>
828
                <td align="right" valign="top" background="images/lbox_bg_blue.gif"><img src="images/lbox_tr_cnr_b.gif" width="13" height="13"></td>
829
              </tr>
830
              <tr>
831
                <td width="1%" bgcolor="#FFFFFF"><img src="images/h_trsp_dot.gif" width="10" height="100"></td>
832
                <td bgcolor="#FFFFFF" valign="top" class="form_item">
833
 
834
 
835
 
836
				<table width="100%"  border="0" cellspacing="0" cellpadding="5">
837
                  <tr>
838
                    <td width="100%" bgcolor="#DAD7C8">
839
					<input type="submit" name="btn" value="Compare" class="form_btn_comp" style="margin-right:5px;">
840
					<input type="submit" name="btn" value="Swap Compare" class="form_btn_comp">
841
					<span class="body_txt">
842
					<input name="btn" type="submit" class="form_btn" value="Mail Me Report">
843
					</span>					</td>
844
                    <td width="1" align="right" bgcolor="#DAD7C8" nowrap>
845
					<table width="100%"  border="0" cellspacing="0" cellpadding="0">
846
                      <tr>
847
                        <td><%If (objRelCollectorB.Item("official") <> "Y" AND objRelCollectorB.Item("official") <> "C" ) AND (objAccessControl.IsActive("MergeRelease")) Then%><input type="submit" name="btn" value="Merge" class="form_btn_comp" style="margin-right:10px;" <%If (parRtagA = "") OR (parRtagB = "")Then%>disabled<%End If%>><%End If%></td>
848
                        <td><%If (objRelCollectorB.Item("official") = "C" ) AND (objAccessControl.IsActive("MergeReleaseForCCB")) Then%><input type="submit" name="btn" value="Merge" class="form_btn_comp" style="margin-right:10px;" <%If (parRtagA = "") OR (parRtagB = "")Then%>disabled<%End If%>><%End If%></td>
849
						<td><input type="submit" name="btn" value="Exit" class="form_btn_comp"></td>
850
                      </tr>
851
                    </table></td>
852
                  </tr>
853
				  <tr>
854
                    <td>
855
					<%If (parRtagA <> "") AND (parRtagB <> "")Then%>
856
					<!-- DIFF FILTER +++++++++++++++++++++++++++++++++++++++++++ -->
857
					<fieldset style="width:150px;">
858
					<legend><a href="javascript:;" class="body_scol" onClick="ToggleDisplay('divDiffFilter');" ><%=GetIsDiffFilterInUseIcon() %>&nbsp;Filter&nbsp;Results...</a></legend>
859
					<div name="divDiffFilter" id="divDiffFilter" class="body_txt" style="display:none;">
860
					<br>
861
					<table width="100%"  border="0" cellspacing="1" cellpadding="3">
862
					    <tr>
863
					      <td width="1" background="images/bg_action_norm.gif"><input name="difilter" type="checkbox" value="<%=enumDB_NUM_DIFF_UPDATED%>" <%=GetIsDiffFilterChecked(enumDB_NUM_DIFF_UPDATED)%>></td>
864
					      <td width="50" nowrap background="images/bg_action_norm.gif" class="form_field"><%=LIMG_UPDATED%>Updated</td>
865
					    </tr>
866
					    <tr>
867
					      <td background="images/bg_action_norm.gif"><input type="checkbox" name="difilter" value="<%=enumDB_NUM_DIFF_NEW%>" <%=GetIsDiffFilterChecked(enumDB_NUM_DIFF_NEW)%>></td>
868
					      <td nowrap background="images/bg_action_norm.gif" class="form_field"><%=LIMG_ADDED%>Added</td>
869
					    </tr>
870
					    <tr>
871
					      <td background="images/bg_action_norm.gif"><input type="checkbox" name="difilter" value="<%=enumDB_NUM_DIFF_REMOVED%>" <%=GetIsDiffFilterChecked(enumDB_NUM_DIFF_REMOVED)%>></td>
872
					      <td nowrap background="images/bg_action_norm.gif" class="form_field"><%=LIMG_REMOVED%>Removed</td>
873
					    </tr>
874
					    <tr>
875
					      <td background="images/bg_action_norm.gif"><input type="checkbox" name="difilter" value="<%=enumDB_NUM_DIFF_RIPPLE%>" <%=GetIsDiffFilterChecked(enumDB_NUM_DIFF_RIPPLE)%>></td>
876
					      <td nowrap background="images/bg_action_norm.gif" class="form_field"><%=LIMG_RIPPLED%>Rippled</td>
877
					    </tr>
878
					    <tr>
879
					      <td background="images/bg_action_norm.gif"><input type="checkbox" name="difilter" value="<%=enumDB_NUM_DIFF_NO_CHANGE%>" <%=GetIsDiffFilterChecked(enumDB_NUM_DIFF_NO_CHANGE)%>></td>
880
					      <td nowrap background="images/bg_action_norm.gif" class="form_field">Unchanged</td>
881
					    </tr>
882
					    <tr>
883
					      <td background="images/bg_action_norm.gif">&nbsp;</td>
884
					      <td background="images/bg_action_norm.gif"><input name="btn" type="submit" class="form_btn" value="Hide"></td>
885
					    </tr>
886
					  </table>
887
					</div>
888
					</fieldset>
889
					<!-- +++++++++++++++++++++++++++++++++++++++++++++++++++++++ -->
890
					<%End If%>
891
					</td>
892
                    <td></td>
893
                  </tr>
894
                </table>
895
 
896
				<%
897
				' Successfull Merge
898
				If (Request("btn") = "Merge") Then
899
					Call Messenger ( "Merge has completed successfully.", 3, "100%" )
900
				End If
901
 
902
				Set FSO=Server.CreateObject("Scripting.FileSystemObject")
903
				Set NewTextFile=FSO.CreateTextFile(Server.MapPath("docs\compareReleases_"&objAccessControl.UserName&".html"), true)
904
 
905
				Call Header()
906
 
907
				If (parRtagA <> "") AND (parRtagB <> "")Then%>
908
                <table width="100%"  border="0" cellspacing="1" cellpadding="0">
909
                  <tr>
910
                    <td width="50%" bgcolor="#E4E9EC" class="body_row" nowrap><%= ReleaseIcon(objRelCollectorA.Item("official")) & objRelCollectorA.Item("location")%> </td>
911
                    <td width="1" bgcolor="#E4E9EC"><img src="images/spacer.gif" width="20" height="1"></td>
912
                    <td width="1" bgcolor="#E4E9EC"><img src="images/spacer.gif" width="20" height="20"></td>
913
                    <td width="1" bgcolor="#E4E9EC"><img src="images/spacer.gif" width="20" height="1"></td>
914
                    <td width="50%" bgcolor="#E4E9EC" class="body_row" nowrap><%= ReleaseIcon(objRelCollectorB.Item("official")) & objRelCollectorB.Item("location")%></td>
915
                    <td width="1" bgcolor="#E4E9EC"><img src="images/spacer.gif" width="20" height="1"></td>
916
                  </tr>
917
			    <%
918
 
919
 
920
				OraDatabase.Parameters.Add "RTAG_A", 	parRtagA,	ORAPARM_INPUT, ORATYPE_NUMBER
921
				OraDatabase.Parameters.Add "RTAG_B", 	parRtagB,	ORAPARM_INPUT, ORATYPE_NUMBER
922
				OraDatabase.Parameters.Add "NO_CHANGE", GetIsDiffFilterChecked(enumDB_NUM_DIFF_NO_CHANGE),		ORAPARM_INPUT, ORATYPE_VARCHAR2
923
				OraDatabase.Parameters.Add "ADDED", 	GetIsDiffFilterChecked(enumDB_NUM_DIFF_NEW),		ORAPARM_INPUT, ORATYPE_VARCHAR2
924
				OraDatabase.Parameters.Add "UPDATED", 	GetIsDiffFilterChecked(enumDB_NUM_DIFF_UPDATED),		ORAPARM_INPUT, ORATYPE_VARCHAR2
925
				OraDatabase.Parameters.Add "REMOVED", 	GetIsDiffFilterChecked(enumDB_NUM_DIFF_REMOVED),		ORAPARM_INPUT, ORATYPE_VARCHAR2
926
 
927
				Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("ReleaseDiff.sql"), cint(0))
928
 
929
				OraDatabase.Parameters.Remove "RTAG_A"
930
				OraDatabase.Parameters.Remove "RTAG_B"
931
				OraDatabase.Parameters.Remove "NO_CHANGE"
932
				OraDatabase.Parameters.Remove "ADDED"
933
				OraDatabase.Parameters.Remove "UPDATED"
934
				OraDatabase.Parameters.Remove "REMOVED"
935
 
936
				Set rsQryA = OraDatabase.DbCreateDynaset( "SELECT RT.RTAG_NAME, PRJ.PROJ_NAME FROM RELEASE_TAGS RT, PROJECTS PRJ WHERE RTAG_ID="& parRtagA &" AND RT.PROJ_ID=PRJ.PROJ_ID", cint(0))
937
				Set rsQryB = OraDatabase.DbCreateDynaset( "SELECT RT.RTAG_NAME, PRJ.PROJ_NAME FROM RELEASE_TAGS RT, PROJECTS PRJ WHERE RTAG_ID="& parRtagB &" AND RT.PROJ_ID=PRJ.PROJ_ID", cint(0))
938
 
939
				Call Javascript()
940
 
941
				NewTextFile.WriteLine("<title>Difference Report Between "&rsQryA("proj_name")&" "&rsQryA("rtag_name")&" and "&rsQryB("proj_name")&" "&rsQryB("rtag_name")&"</title>")
942
				NewTextFile.WriteLine("<div align="&chr(34)&"center"&chr(34)&"><font color="&chr(34)&"red"&chr(34)&" size="&chr(34)&"4"&chr(34)&" face="&chr(34)&"Verdana, Arial, Helvetica, sans-serif"&chr(34)&">Difference Report Between "&rsQryA("proj_name")&" "&rsQryA("rtag_name")&" and "&rsQryB("proj_name")&" "&rsQryB("rtag_name")&"</font></div><br>")
943
				NewTextFile.WriteLine("<b>Key:</b><br><blockquote><font style="&chr(34)&"background-color:red"&chr(34)&"><b> SOURCE CODE CHANGES</b></font><font color="&chr(34)&"red"&chr(34)&"> Indicates Changes to a Package in "& rsQryA("rtag_name") &"</font>. <br><font style="&chr(34)&"background-color:#FF9933"&chr(34)&"><b> SOURCE CODE CHANGES</b></font><font color="&chr(34)&"#FF9933"&chr(34)&"> Indicates Changes to a Package in "& rsQryB("rtag_name") &"</font>. <br><font color="&chr(34)&"#999999"&chr(34)&">Grey Text Indicates No Source Code Changes to a Package in either Release</font>.</blockquote>")
944
 
945
				Dim currView_id
946
				currView_id = -1
947
 
948
				While ((NOT rsQry.BOF) AND (NOT rsQry.EOF))
949
				errormsg = false
950
					rowId = rsQry("pv_id_a") &"_"& rsQry("pv_id_b")
951
 
952
					btnMerge = LIMG_MERGE
953
					btnRemove = LIMG_REMOVE
954
					colorA = LCOLOR_NOT_CHANGED
955
					colorB = LCOLOR_NOT_CHANGED
956
 
957
					changeType = rsQry("change_type")
958
 
959
					Select Case changeType
960
						Case "U"
961
							colorA = LCOLOR_CHANGED
962
							colorB = LCOLOR_CHANGED
963
						Case "UW"
964
							colorA = LCOLOR_CHANGED
965
							colorB = LCOLOR_CHANGED
966
							btnMerge = LIMG_MERGE_WARN
967
						Case "UR"
968
							colorA = LCOLOR_RIPPLED
969
							colorB = LCOLOR_RIPPLED
970
						Case "A"
971
							colorA = LCOLOR_BLANK
972
						Case "R"
973
							colorB = LCOLOR_BLANK
974
					End Select
975
 
976
					Call GetDiffStateIcon ( changeType, ChangeTypeIcon )
977
 
978
					If changeType = "U" OR changeType = "UW" OR changeType = "UR" Then
979
						Dim MajorA, MajorB, MinorA, MinorB, PatchA, PatchB, BuildA, BuildB, pos, pkgVersionA, pkgVersionB, majMinA, majMinB
980
						MajorA = NULL
981
						MajorB = NULL
982
						MinorA = NULL
983
						MinorB = NULL
984
 
985
						pkgVersionA = rsQry("pkg_version_a")
986
						pkgVersionB = rsQry("pkg_version_b")
987
 
988
						PatchA = rsQry("patch_number_a")
989
						PatchB = rsQry("patch_number_b")
990
						BuildA = rsQry("build_number_a")
991
						BuildB = rsQry("build_number_b")
992
 
993
 
994
						' Find the first occurence of the dot in package version A
995
						pos = InStr(pkgVersionA, ".")
996
						If pos <> 0 Then
997
							' Extract the Major Version for A
998
							MajorA = Mid(pkgVersionA, 1, pos - 1)
999
							' Delete the Major Version Value from the string to get the minor and patch version
1000
							pkgVersionA = Mid(pkgVersionA, pos + 1, Len(pkgVersionA))
1001
							' Find the second occurence of the dot in package version A
1002
							pos = InStr(pkgVersionA, ".")
1003
							' Extract the Minor Version for A
1004
							If pos <> 0 Then
1005
								MinorA = Mid(pkgVersionA, 1, pos - 1)
1006
							End If
1007
						End If
1008
 
1009
						' Find the first occurence of the dot in package version B
1010
						pos = InStr(pkgVersionB, ".")
1011
						If pos <> 0 Then
1012
							' Extract the Major Version for B
1013
							MajorB = Mid(pkgVersionB, 1, pos - 1)
1014
							' Delete the Major Version Value from the string to get the minor and patch version
1015
							pkgVersionB = Mid(pkgVersionB, pos + 1, Len(pkgVersionB))
1016
							' Find the second occurence of the dot in package version B
1017
							pos = InStr(pkgVersionB, ".")
1018
							' Extract the Minor Version for B
1019
							If pos <> 0 Then
1020
								MinorB = Mid(pkgVersionB, 1, pos - 1)
1021
							End If
1022
						End If
1023
 
1024
						If MajorA = MajorB Then
1025
							If MinorA = MinorB Then
1026
								If IsNumeric(PatchA) AND IsNumeric(PatchB) Then
1027
									If CInt(PatchB) > CInt(PatchA) Then
1028
										btnMerge = LIMG_MERGE_WARN
1029
									Else
1030
										btnMerge = LIMG_MERGE
1031
									End If
1032
								End If
1033
							Else
1034
								If IsNumeric(MinorA) AND IsNumeric(MinorB) Then
1035
									If CInt(MinorB) > CInt(MinorA) Then
1036
										btnMerge = LIMG_MERGE_WARN
1037
									Else
1038
										btnMerge = LIMG_MERGE
1039
									End If
1040
								End If
1041
							End If
1042
						Else
1043
							If IsNumeric(MajorA) AND IsNumeric(MajorB) Then
1044
								If 	CInt(MajorB) > CInt(MajorA) Then
1045
									btnMerge = LIMG_MERGE_WARN
1046
								Else
1047
									btnMerge = LIMG_MERGE
1048
								End If
1049
							End If
1050
						End If
1051
					End If
1052
 
1053
 
1054
					' -------- FILTERS RIPPLE BUILDS WHEN CHECKED -----------------
1055
					If NOT (GetIsDiffFilterChecked(enumDB_NUM_DIFF_RIPPLE) = "checked" AND changeType = "UR") THEN
1056
 
1057
 
1058
					' -------- GROUP BY BASE VIEW  -----------------
1059
		  			If CDbl(currView_id) <> CDbl(rsQry("view_id")) Then
1060
 
1061
					%>
1062
       				<tr>
1063
       				 <td valign="top" nowrap class="form_ttl"><b><%=rsQry("view_name")%></b></td>
1064
       				 <td class="form_ttl">&nbsp;</td>
1065
					 <td class="form_ttl">&nbsp;</td>
1066
         			 <td class="form_ttl">&nbsp;</td>
1067
					 <td class="form_ttl">&nbsp;</td>
1068
        			 <td class="form_ttl">&nbsp;</td>
1069
     				</tr>
1070
     			 <%
1071
		 		 	currView_id = CDbl(rsQry("view_id"))
1072
		  			End If
1073
		  			' -------- END GROUP ------------------------
1074
		 		 %>
1075
				  <tr>
1076
                    <td class="body_row" nowrap>
1077
						<DIV id="PVA<%=rowId%>" style="background:<%=colorA%>; padding:5px;">
1078
						<%=rsQry("pkg_name_a") &" "& rsQry("pkg_version_a")%>
1079
						</DIV>
1080
						<input type="hidden" id="UNDOCOLORA_<%=rowId%>" value="<%=colorA%>">
1081
					</td>
1082
                    <td bgcolor="#F5F5F5"><%If objRelCollectorB.Item("official") <> "Y" Then%><DIV id="IMGMERGE<%=rowId%>" <%If (changeType = "A")  OR IsNull( changeType ) Then%>style="display:none;"<%End If%>><a href="javascript:;" onClick="MergePackage( '<%=rsQry("pv_id_a")%>', '<%=rsQry("pv_id_b")%>', '<%=rowId%>' );"><%=btnMerge%></a></DIV><%End If%></td>
1083
                    <td bgcolor="#E4E9EC"><DIV id="IMGSTATE<%=rowId%>" ><%=ChangeTypeIcon%></DIV><input type="hidden" id="CHANGETYPE_<%=rowId%>" value="<%=changeType%>"></td>
1084
                    <td bgcolor="#F5F5F5"><%If objRelCollectorB.Item("official") <> "Y" Then%><DIV id="IMGREMOVE<%=rowId%>" <%If changeType = "R" Then%>style="display:none;"<%End If%>><a href="javascript:;" onClick="RemovePackage( '<%=rsQry("pv_id_a")%>', '<%=rsQry("pv_id_b")%>', '<%=rowId%>' );"><%=btnRemove%></a></DIV><%End If%></td>
1085
                    <td class="body_row" nowrap>
1086
						<DIV id="PVB<%=rowId%>" style="background:<%=colorB%>; padding:5px;">
1087
						<%=rsQry("pkg_name_b") &" "& rsQry("pkg_version_b")%>
1088
						</DIV>
1089
						<input type="hidden" id="UNDOCOLORB_<%=rowId%>" value="<%=colorB%>">
1090
						<input type="hidden" name="addpkg" id="ADDPKG_<%=rowId%>" value="">
1091
						<input type="hidden" name="removepkg" id="REMOVEPKG_<%=rowId%>" value="">
1092
						<input type="hidden" id="UNDOPKG_<%=rowId%>" value="<%=rsQry("pkg_name_b") &" "& rsQry("pkg_version_b")%>">
1093
					</td>
1094
                    <td bgcolor="#F5F5F5"><DIV id="IMGUNDO<%=rowId%>" style="display:none;" ><a href="javascript:;" onClick="UndoPackage( '<%=rowId%>' );"><%=LIMG_UNDO%></a></DIV></td>
1095
                  </tr>
1096
 
1097
 
1098
<%
1099
	If email then
1100
		If rsQry("pv_id_a") Then
1101
			Set rsQryCommentsA = OraDatabase.DbCreateDynaset( "SELECT COMMENTS FROM PACKAGE_VERSIONS WHERE PV_ID="& rsQry("pv_id_a"), cint(0))
1102
		End If
1103
 
1104
		If rsQry("pv_id_b") Then
1105
			Set rsQryCommentsB = OraDatabase.DbCreateDynaset( "SELECT COMMENTS FROM PACKAGE_VERSIONS WHERE PV_ID="& rsQry("pv_id_b"), cint(0))
1106
		End If
1107
 
1108
		pkgA = rsQry("pkg_name_a")
1109
		pkgB = rsQry("pkg_name_b")
1110
 
1111
		If pkgA <> "" then
1112
			pkgname = pkgA
1113
		Else
1114
			pkgname = pkgB
1115
		End If
1116
 
1117
		If changeType = "U" OR  changeType = "UW" Then
1118
				ChangeASource = false
1119
				ChangeAUpdate = false
1120
				ChangeBSource = false
1121
				ChangeBUpdate = false
1122
 
1123
				'NewTextFile.WriteLine("<br><b><font face="&chr(34)&"arial"&chr(34)&">"&pkgname&"</font></b>")
1124
				NewTextFile.Write("<SPAN id=""spanShowDetails"& rowId &""" name=""spanShowDetails""><a href=""javascript:;"" class=""body_scol"" onClick=""DisplaySPAN(true,'"& rowId &"');"">"& pkgname &"</a></SPAN>")
1125
				NewTextFile.Write("<SPAN id=""spanHideDetails"& rowId &""" name=""spanHideDetails"" style=""display:none;""><a href=""javascript:;"" class=""body_scol"" onClick=""DisplaySPAN(false,'"& rowId &"');"">"& pkgname &"</a></SPAN>")
1126
				NewTextFile.WriteLine("<SPAN id=""spanPkgInfo"& rowId &""" name=""spanPkgInfo"" style=""display:none;"">")
1127
				NewTextFile.Write(rsQryA("rtag_name")&" uses: "&rsQry("pkg_version_a")&" (")
1128
				Call Release(rsQry("pv_id_a"))
1129
				NewTextFile.WriteLine(")<br>")
1130
				NewTextFile.Write(rsQryB("rtag_name")&" uses: "&rsQry("pkg_version_b")&" (")
1131
				Call Release(rsQry("pv_id_b"))
1132
				NewTextFile.WriteLine(")<br>")
1133
 
1134
				a = rsQry("pv_id_a")
1135
				b = rsQry("pv_id_b")
1136
				c = rsQry("pv_id_a")
1137
				d = rsQry("pv_id_b")
1138
 
1139
				Set pvCollectionA = CreateObject("Scripting.Dictionary")
1140
				Set pvCollectionB = CreateObject("Scripting.Dictionary")
1141
				On Error Resume Next
1142
					While CLng(a) <> CLng(b) and NOT errormsg
1143
 
1144
						'NewTextFile.WriteLine("A: "&a)
1145
						'NewTextFile.WriteLine("B: "&b)
1146
						pvCollectionA.Add CStr(a), Empty
1147
						pvCollectionB.Add CStr(b), Empty
1148
						If CLng(a) > CLng(b) Then
1149
							'NewTextFile.WriteLine("TestA")
1150
							Call LastPvIdA(a)
1151
						ElseIf CLng(b) > CLng(a) Then
1152
							'NewTextFile.WriteLine("TestB")
1153
							Call LastPvIdB(b)
1154
						End If
1155
					Wend
1156
					Set pvCollectionA = Nothing
1157
					Set pvCollectionB = Nothing
1158
 
1159
				Call pkg_Version(a)
1160
					NewTextFile.Write("Common PARENT package version: "&pkgversion&" (")
1161
					Call Release(a)
1162
					NewTextFile.WriteLine(")<br><br>")
1163
					NewTextFile.WriteLine()
1164
					NewTextFile.WriteLine("<b>"&rsQryA("rtag_name")&"</b>")
1165
 
1166
					If pkgversion <> rsQry("pkg_version_a") Then
1167
						NewTextFile.WriteLine("<blockquote><b><i>Versions between "& pkgversion &" and "& rsQry("pkg_version_a")&"</i></b></blockquote>")
1168
 
1169
						If errormsg Then
1170
							NewTextFile.WriteLine("Error determining root!<br>")
1171
							NewTextFile.WriteLine()
1172
						End If
1173
 
1174
						source_change = false
1175
 
1176
 
1177
						While CLng(a) <> CLng(c) and NOT errormsg
1178
							Call Comments(c)
1179
							Call GetFixedIssues(c)
1180
 							Call LastPvIdAa(c)
1181
							NewTextFile.WriteLine()
1182
						Wend
1183
 
1184
						If source_change = false Then
1185
							NewTextFile.WriteLine("<blockquote><b><i>No source changes to "& rsQryA("rtag_name")&". Only Rippled Builds.</i></b></blockquote><br>")
1186
							ChangeASource = true
1187
						End If
1188
 
1189
						Call pkg_Version(b)
1190
						NewTextFile.WriteLine()
1191
						NewTextFile.WriteLine()
1192
 
1193
					ElseIf pkgversion = rsQry("pkg_version_a") Then
1194
						NewTextFile.WriteLine("<blockquote><b><i>No updates to "& rsQryA("rtag_name")&"</i></b></blockquote><br>")
1195
						ChangeAUpdate = true
1196
						NewTextFile.WriteLine()
1197
					End If
1198
 
1199
					NewTextFile.WriteLine("<b>"&rsQryB("rtag_name")&"</b>")
1200
 
1201
					If pkgversion <> rsQry("pkg_version_b") Then
1202
						NewTextFile.WriteLine("<blockquote><b><i>Versions between "& pkgversion &" and "& rsQry("pkg_version_b")&"</i></b></blockquote>")
1203
 
1204
						If errormsg Then
1205
							NewTextFile.WriteLine("Error determining root!<br>")
1206
							NewTextFile.WriteLine()
1207
						End If
1208
 
1209
						source_change = false
1210
 
1211
 
1212
						While CLng(b) <> CLng(d) and NOT errormsg
1213
							Call Comments(d)
1214
							Call GetFixedIssues(d)
1215
 							Call LastPvIdBb(d)
1216
							NewTextFile.WriteLine()
1217
						Wend
1218
 
1219
						If source_change = false Then
1220
							NewTextFIle.WriteLine("<blockquote><b><i>No source changes to "& rsQryB("rtag_name")&". Only Rippled Builds.</i></b></blockquote><br>")
1221
							ChangeBSource = true
1222
						End If
1223
 
1224
					ElseIf pkgversion = rsQry("pkg_version_b") Then
1225
						NewTextFile.WriteLine("<blockquote><b><i>No updates to "& rsQryB("rtag_name")&"</i></b></blockquote><br>")
1226
						ChangeBUpdate = true
1227
						NewTextFile.WriteLine()
1228
					End If
1229
 
1230
					NewTextFile.WriteLine("</SPAN>")
1231
 
1232
				If ChangeASource Then
1233
					If ChangeBSource Then
1234
						NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &": .</b><font color="&chr(34)&"#999999"&chr(34)&"> Ripple Builds Only.</font></td>	<td width=""349""><b>"& Ucase(rsQryB("rtag_name")) &": </b><font color="&chr(34)&"#999999"&chr(34)&"> Ripple Builds Only.</font></td>  </tr></table></blockquote>")
1235
					ElseIf ChangeBUpdate Then
1236
						NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &": </b><font color="&chr(34)&"#999999"&chr(34)&">Ripple Builds Only.</font></td>	<td width=""349""><b>"& Ucase(rsQryB("rtag_name")) &": </b><font color="&chr(34)&"#999999"&chr(34)&">No Updates.</font></td>  </tr></table></blockquote>")
1237
					ElseIf NOT ChangeBSource AND NOT ChangeBUpdate Then
1238
						NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &":</b> <font color="&chr(34)&"999999"&chr(34)&">Ripple Builds Only.</font></td>	<td width=""349"">	<b>"& Ucase(rsQryB("rtag_name")) &":</b> <b><font style="&chr(34)&"background-color:#FF9933"&chr(34)&">SOURCE CODE CHANGES.</b></font></td>  </tr></table></blockquote>")
1239
					End If
1240
				End If
1241
 
1242
				If ChangeBSource Then
1243
					If NOT ChangeAUpdate Then
1244
						If NOT ChangeASource AND NOT ChangeBUpdate Then
1245
							NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &": </b><b><font style="&chr(34)&"background-color:red"&chr(34)&"> SOURCE CODE CHANGES</font></b>.</td>	<td width=""349""> <b>"& Ucase(rsQryB("rtag_name")) &":</b> <font color="&chr(34)&"#999999"&chr(34)&">Ripple Builds Only.</font></td>  </tr></table></blockquote>")
1246
						End If
1247
					End If
1248
				End If
1249
 
1250
				If NOT ChangeASource Then
1251
					If NOT ChangeAUpdate Then
1252
						If NOT ChangeBSource AND NOT ChangeBUpdate Then
1253
							NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &": </b><b><font style="&chr(34)&"background-color:red"&chr(34)&"> SOURCE CODE CHANGES</font></b>.</td>	<td width=""349""> <b>"& Ucase(rsQryB("rtag_name")) &":</b> <b><font style="&chr(34)&"background-color:#FF9933"&chr(34)&">SOURCE CODE CHANGES.</b></font></td>  </tr></table></blockquote>")
1254
						ElseIf ChangeBUpdate Then
1255
							NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &":</b> <b><font style="&chr(34)&"background-color:red"&chr(34)&">SOURCE CODE CHANGES.</font></b></td> <td width=""349""><b>"& Ucase(rsQryB("rtag_name")) &":</b><font color="&chr(34)&"#999999"&chr(34)&">No Updates.</font></td>  </tr></table></blockquote>")
1256
						End If
1257
					ElseIf ChangeAUpdate Then
1258
						If NOT ChangeBSource AND NOT ChangeBUpdate Then
1259
							NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &":</b> <font color="&chr(34)&"#999999"&chr(34)&">No Updates.</td> <td width=""349"">  <b></font>"& Ucase(rsQryB("rtag_name")) &":</b> <b><font style="&chr(34)&"background-color:#FF9933"&chr(34)&">SOURCE CODE CHANGES.</font></b></td>  </tr></table></blockquote>")
1260
						ElseIf ChangeBSource Then
1261
							NewTextFile.WriteLine("<blockquote><table width=""700"" border=""0"">  <tr><td width=""335""><b>"& Ucase(rsQryA("rtag_name")) &":</b> <font color="&chr(34)&"#999999"&chr(34)&">No Updates.</td> <td width=""349""> </font><b>"& Ucase(rsQryB("rtag_name")) &":</b> <font color="&chr(34)&"#999999"&chr(34)&">Ripple Builds Only.</font></td>  </tr></table></blockquote>")
1262
						End If
1263
					End If
1264
				End If
1265
 
1266
		End If
1267
 
1268
	End If
1269
	End If
1270
 
1271
	rsQry.MoveNext
1272
	WEnd
1273
 
1274
	rsQry.Close
1275
	Set rsQry = Nothing
1276
%>
1277
<%
1278
	Call Footer()
1279
	NewTextFile.Close
1280
	Set NewTextFile=Nothing
1281
%>
1282
                </table>
1283
                <br>
1284
			<%Else%>
1285
				<br>
1286
				<%
1287
				If (parRtagB <> "") Then
1288
					Call Messenger ( "Select <b>Release A</b> to compare.", 3, "100%" )
1289
				ElseIf (parRtagA <> "") Then
1290
					Call Messenger ( "Select <b>Release B</b> to compare.", 3, "100%" )
1291
				Else
1292
					Call Messenger ( "Select <b>Release A</b> and <b>Release B</b> to compare.", 3, "100%" )
1293
				End If
1294
				%>
1295
 
1296
			<%End If%>
1297
 
1298
				</td>
1299
                <td width="1%" background="images/lbox_bgside_white.gif">&nbsp;</td>
1300
              </tr>
1301
              <tr>
1302
                <td width="1%" background="images/lbox_bg_blue.gif" valign="bottom"><img src="images/lbox_bl_cnr_b.gif" width="13" height="13"></td>
1303
                <td background="images/lbox_bg_blue.gif"></td>
1304
                <td width="1%" background="images/lbox_bg_blue.gif" valign="bottom" align="right"><img src="images/lbox_br_cnr_b.gif" width="13" height="13"></td>
1305
              </tr>
1306
            </table>
1307
          </td>
1308
        </tr>
1309
      </table>
1310
    <!-- DIFF END ---------------------------------------------------->
1311
    </td>
1312
	<td valign="top" width="1%" background="images/bg_home_orange.gif">
1313
 
1314
 
1315
	  <!-- SELECT RELEASE B ---------------------------------------------->
1316
      <br>
1317
      <table width="100%"  border="0" cellspacing="10" cellpadding="0">
1318
		<tr>
1319
          <td align="left" class="body_col"><img src="images/i_rtag_open_mode.gif" border="0" align="absmiddle" width="15" height="13">&nbsp;Select Release B<hr size="1px" color="Olive" noshade></td>
1320
        </tr>
1321
        <tr>
1322
          <td align="left">
1323
		  <select name="projB" class="form_item" onChange="RequestReleaseCombo( '?proj_id='+ this.value, FormName.rtagB );">
1324
              <option value="">-- Select Project --</option>
1325
			  <%
1326
			  OraDatabase.Parameters.Add "PROJ_ID", 	objRelCollectorB.Item("proj_id"),	ORAPARM_INPUT, ORATYPE_NUMBER
1327
 
1328
			  Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("ProjectsCombo.sql"), cint(0))
1329
 
1330
			  OraDatabase.Parameters.Remove "PROJ_ID"
1331
 
1332
			  While ((NOT rsQry.BOF) AND (NOT rsQry.EOF))%>
1333
                <option value="<%=rsQry("proj_id")%>" <%=rsQry("selected")%>><%=rsQry("proj_name")%></option>
1334
              <%rsQry.MoveNext
1335
			  WEnd
1336
 
1337
			  rsQry.Close
1338
			  Set rsQry = Nothing
1339
			%>
1340
          </select></td>
1341
        </tr>
1342
        <tr>
1343
          <td align="left">
1344
 
1345
		  <select name="rtagB" id="rtagB" class="form_item">
1346
			  <%
1347
			  OraDatabase.Parameters.Add "PROJ_ID", 	objRelCollectorB.Item("proj_id"),	ORAPARM_INPUT,  ORATYPE_NUMBER
1348
			  OraDatabase.Parameters.Add "RTAG_ID", 	objRelCollectorB.Item("rtag_id"),	ORAPARM_INPUT, ORATYPE_NUMBER
1349
 
1350
			  Set rsQry = OraDatabase.DbCreateDynaset( GetQuery("ReleasesCombo.sql"), cint(0))
1351
 
1352
			  OraDatabase.Parameters.Remove "PROJ_ID"
1353
			  OraDatabase.Parameters.Remove "RTAG_ID"
1354
 
1355
			  While ((NOT rsQry.BOF) AND (NOT rsQry.EOF))%>
1356
                <option value="<%=rsQry("rtag_id")%>" <%=rsQry("selected")%>><%=rsQry("rtag_name")%></option>
1357
              <%rsQry.MoveNext
1358
			  WEnd
1359
 
1360
			  rsQry.Close
1361
			  Set rsQry = Nothing
1362
			  %>
1363
		  </select>
1364
 
1365
		  </td>
1366
        </tr>
1367
		<%If (parRtagB <> "") Then%>
1368
		<tr>
1369
          <td align="left"><a href="dependencies.asp?rtag_id=<%=parRtagB%>" class="body_txt_drk">Go To Release B &raquo;</a></td>
1370
        </tr>
1371
		<%End If%>
1372
      </table>
1373
      <!-- SELECT RELEASE B END ---------------------------------------------->
1374
 
1375
	  </td>
1376
  </tr>
1377
  <tr>
1378
    <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>
1379
    <td background="images/bg_lght_gray.gif" valign="top"><img src="images/h_trsp_dot.gif" width="1" height="500"></td>
1380
	<td valign="bottom" background="images/bg_home_orange.gif" align="center"><img src="images/img_vtree.gif" width="86" height="99" vspace="20" hspace="30"></td>
1381
  </tr>
1382
</table>
1383
</form>
1384
<!-- FOOTER -->
1385
<!--#include file="_footer.asp"-->
1386
<%
1387
	If email Then
1388
 
1389
		Dim myMail, LocalPath
1390
		Set myMail=Server.CreateObject("Persits.MailSender")
1391
		LocalPath = Server.MapPath("docs\compareReleases_"&objAccessControl.UserName&".html")
1392
 
1393
		myMail.Host = SMTP_HOST
1394
		myMail.Subject="Release Comparisons from Release Manager"
1395
		myMail.From="releasem@erggroup.com"
1396
		myMail.AddAddress objAccessControl.UserEmail
1397
		' Attach the file
1398
		myMail.AddAttachment LocalPath
1399
		myMail.Body = "Your requested report..."
1400
		myMail.Send
1401
 
1402
		set myMail=nothing
1403
 
1404
	End If
1405
%>
1406
</body>
1407
</html>
1408
<%
1409
Call Destroy_All_Objects
1410
%>