Subversion Repositories DevTools

Rev

Rev 5901 | Rev 5904 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5901 Rev 5902
Line 14... Line 14...
14
Dim anchorName
14
Dim anchorName
15
Dim filterInUse
15
Dim filterInUse
16
Dim hideRipple
16
Dim hideRipple
17
Dim rippleFilter
17
Dim rippleFilter
18
Dim DestroyPackage
18
Dim DestroyPackage
-
 
19
Dim CanDestroyProjectPackage
19
Dim CanDestroyPackage
20
Dim CanDestroyPackage
20
'------------ Constants Declaration -----------
21
'------------ Constants Declaration -----------
21
Const IMGBG_ROW_HI = "background='images/bg_row_hi.gif'"
22
Const IMGBG_ROW_HI = "background='images/bg_row_hi.gif'"
22
Const IMGBG_ROW = "bgcolor='#FFFFFF'"
23
Const IMGBG_ROW = "bgcolor='#FFFFFF'"
23
Const IMG_PONTER = "<img src='images/i_pointer.gif' width='6' height='11' hspace='3'>"
24
Const IMG_PONTER = "<img src='images/i_pointer.gif' width='6' height='11' hspace='3'>"
24
Const IMG_OFFICIAL = "<img src='images/i_locked.gif' width='7' height='10' hspace='5' vspace='2' title='Package has been Released'>"
25
Const IMG_OFFICIAL = "<img src='images/i_locked.gif' width='7' height='10' hspace='5' vspace='2' title='Package has been Released'>"
-
 
26
Const IMG_PENDING = "<img src='icons/i_pending.gif' width='7' height='10' hspace='5' vspace='2' title='Package pending autobuild'>"
25
Const IMG_NOT_OFFICIAL = "<img src='images/spacer.gif' width='7' height='10' hspace='5' vspace='2' title='Package not yet released'>"
27
Const IMG_NOT_OFFICIAL = "<img src='images/spacer.gif' width='7' height='10' hspace='5' vspace='2' title='Package not yet released'>"
26
Const IMG_DOWNLOAD = "<img src='images/i_download_small.gif' alt='Download full release notes.' width='16' height='16' hspace='2' border='0'>"
28
Const IMG_DOWNLOAD = "<img src='images/i_download_small.gif' alt='Download full release notes.' width='16' height='16' hspace='2' border='0'>"
27
'------------ Variable Init -------------------
29
'------------ Variable Init -------------------
28
If Request("filter_reset") <> "" Then 
30
If Request("filter_reset") <> "" Then 
29
	parFLpkg_version = "*"
31
	parFLpkg_version = "*"
Line 267... Line 269...
267
				
269
				
268
				
270
				
269
				' Sort versions
271
				' Sort versions
270
				Call objSortHelper.VersionSort( aVersions, 0, lastRow, rsVB.FieldIndex("pkg_version") )
272
				Call objSortHelper.VersionSort( aVersions, 0, lastRow, rsVB.FieldIndex("pkg_version") )
271
				
273
				
272
				CanDestroyPackage = canShowControlInProject ( "DestroyPackage" )
274
				CanDestroyProjectPackage = canShowControlInProject ( "DestroyPackage" )
273
				
275
				
274
			  	' Descending order
276
			  	' Descending order
275
				For i = lastRow To 0 Step -1
277
				For i = lastRow To 0 Step -1
276
 
278
 
277
				%>
279
				%>
Line 285... Line 287...
285
					
287
					
286
					' Official/Unofficial case
288
					' Official/Unofficial case
287
					imgLock = IMG_NOT_OFFICIAL
289
					imgLock = IMG_NOT_OFFICIAL
288
					'fieldRelease_Date = ""
290
					'fieldRelease_Date = ""
289
					'fieldReleased_By = ""
291
					'fieldReleased_By = ""
290
					If (aVersions( rsVB.FieldIndex("dlocked"), i ) = "Y")  OR (aVersions( rsVB.FieldIndex("dlocked"), i ) = "A") Then
292
					If (aVersions( rsVB.FieldIndex("dlocked"), i ) = "Y")  Then
291
						imgLock = IMG_OFFICIAL
293
						imgLock = IMG_OFFICIAL
-
 
294
                    ElseIf (aVersions( rsVB.FieldIndex("dlocked"), i ) = "A") Then 
-
 
295
						imgLock = IMG_PENDING
292
					End If
296
					End If
293
					
297
					
294
					fieldRelease_Date = DisplayShortDateTime ( aVersions( rsVB.FieldIndex("modified_stamp"), i ) )
298
					fieldRelease_Date = DisplayShortDateTime ( aVersions( rsVB.FieldIndex("modified_stamp"), i ) )
295
					fieldReleased_By = "<a href='mailto:"& aVersions( rsVB.FieldIndex("user_email"), i ) &"' class='txt_linked'><img src='images/i_user.gif' width='10' height='13' hspace='2' border='0' align='absmiddle' alt='"& aVersions( rsVB.FieldIndex("full_name"), i ) &" &lt;"& aVersions( rsVB.FieldIndex("user_email"), i ) &"&gt;'>"& aVersions( rsVB.FieldIndex("user_name"), i ) &"</a>"
299
					fieldReleased_By = "<a href='mailto:"& aVersions( rsVB.FieldIndex("user_email"), i ) &"' class='txt_linked'><img src='images/i_user.gif' width='10' height='13' hspace='2' border='0' align='absmiddle' alt='"& aVersions( rsVB.FieldIndex("full_name"), i ) &" &lt;"& aVersions( rsVB.FieldIndex("user_email"), i ) &"&gt;'>"& aVersions( rsVB.FieldIndex("user_name"), i ) &"</a>"
296
					
300
					
Line 308... Line 312...
308
					End If
312
					End If
309
					
313
					
310
                    ' User can try to delete package iff
314
                    ' User can try to delete package iff
311
                    '   Have suffiecient access (unusual)
315
                    '   Have suffiecient access (unusual)
312
                    '   They created it or own it
316
                    '   They created it or own it
313
                    '   The version is not in use by any release (allow to be in pendinf or WIP)
317
                    '   The version is not in use by any release (allow to be in pending or WIP)
314
                    '   [Not at the moment] The package was created less than xxxx days ago
318
                    '   [Not at the moment] The package was created less than xxxx days ago
315
                    '   Is not locked or Approved for Autobuild
319
                    '   Is not locked or [Not at the moment] Approved for Autobuild
-
 
320
                    CanDestroyPackage = CanDestroyProjectPackage
316
                    If CanDestroyPackage = false Then
321
                    If NOT CanDestroyPackage Then
317
                        If  objAccessControl.UserId = aVersions( rsVB.FieldIndex("CREATOR_ID"), i ) OR objAccessControl.UserId = aVersions( rsVB.FieldIndex("OWNER_ID"), i )Then
322
                        If (objAccessControl.UserId = aVersions( rsVB.FieldIndex("CREATOR_ID"), i )) OR (objAccessControl.UserId = aVersions( rsVB.FieldIndex("OWNER_ID"), i ))Then
318
                            If aVersions( rsVB.FieldIndex("inuse"), i ) = 0 Then
323
                            If aVersions( rsVB.FieldIndex("inuse"), i ) = 0 Then
319
                                'If aVersions( rsVB.FieldIndex("age") , i ) < 1000 Then
324
                                'If aVersions( rsVB.FieldIndex("age") , i ) < 1000 Then
320
                                    If aVersions( rsVB.FieldIndex("dlocked"), i ) <> "Y" Then
325
                                    If aVersions( rsVB.FieldIndex("dlocked"), i ) <> "Y" Then
321
                                        If aVersions( rsVB.FieldIndex("dlocked"), i ) <> "A" Then
326
                                        'If aVersions( rsVB.FieldIndex("dlocked"), i ) <> "A" Then
322
                                            CanDestroyPackage = true
327
                                            CanDestroyPackage = true
323
                                        End If
328
                                        'End If
324
                                    End If
329
                                    End If
325
                                'End If
330
                                'End If
326
                            End If
331
                            End If
327
                        End If
332
                        End If
328
                    End If
333
                    End If