Can I use workflow script in ALM to rearrange the fields displayed in the Requirements Module?
Question ID: 106123
0
0
Marked as spam
Posted by (Questions: 239, Answers: 31)
Asked on May 29, 2015 8:25 pm
77 views
Answers (1)
0
Private answer

The following example uses a Select Case Statement that is set up by the Requirement Type for each of the User Groups in ALM. You may want to change the Requirement Type, or any of the other settings in the script to suite your specific needs. Place the first six lines of script into the 'Req_SetFieldApp' action, then the remaining script will go into the 'RequireFieldCust_Add' action within the 'Requirements module script' in the Workflow Script Editor.

Sub Req_SetFieldApp (FieldName, Vis, Req, PNo, VOrder)
'Sets a field's appearance
With Req_Fields (FieldName)
.IsVisible = Vis
.IsRequired = Req
.PageNo = PNo
.ViewOrder = VOrder
End With
End Sub

Sub RequireFieldCust_Add
If User.IsInGroup (''Developer'') Then
Select Case Req_Fields (''RQ_TYPE_ID'').Value
Case ''Performance''
Req_SetFieldApp ''RQ_USER_02'', True, True, 0, 1
Req_SetFieldApp ''Req ID'', True, false, 0, 2 'Req ID
Req_SetFieldApp ''RQ_USER_04'', True, True, 0, 3
Req_SetFieldApp ''RQ_USER_05'', True, True, 0, 4
Req_SetFieldApp ''RQ_USER_06'', True, True, 0, 5
Req_SetFieldApp ''RQ_USER_03'', True, false, 0, 6
Req_SetFieldApp ''RQ_USER_07'', True, False, 0, 7
Req_SetFieldApp ''RQ_USER_08'', True, True, 0, 8
Req_SetFieldApp ''RQ_USER_09'', True, true, 0, 9
Req_SetFieldApp ''RQ_USER_11'', True, False, 0, 10
Req_SetFieldApp ''RQ_USER_10'', True, false, 0, 11
Req_SetFieldApp ''RQ_USER_12'', True, False, 0, 12
Req_SetFieldApp ''RQ_USER_13'', True, true, 0, 13
Req_SetFieldApp ''RQ_USER_14'', True, true, 0, 14
Req_SetFieldApp ''RQ_USER_15'', True, False, 0, 15
Req_SetFieldApp ''RQ_USER_16'', True, False, 0, 16
Req_SetFieldApp ''RQ_USER_17'', True, False, 0, 17
Req_SetFieldApp ''RQ_USER_18'', True, False, 0, 18
Req_SetFieldApp ''RQ_USER_20'', True, True, 0, 19
Req_SetFieldApp ''RQ_USER_21'', True, False, 0, 20
Req_SetFieldApp ''RQ_USER_24'', True, False, 0, 21
Req_SetFieldApp ''RQ_USER_22'', True, False, 0, 22
Req_SetFieldApp ''RQ_USER_25'', True, False, 0, 23
Req_SetFieldApp ''RQ_USER_26'', True, False, 0, 24
Req_SetFieldApp ''RQ_USER_27'', True, False, 0, 25
Req_SetFieldApp ''RQ_USER_28'', True, False, 0, 26
Req_SetFieldApp ''RQ_USER_29'', True, False, 0, 27
Req_SetFieldApp ''RQ_USER_23'', True, False, 0, 28
Req_SetFieldApp ''RQ_USER_30'', True, False, 0, 29
Req_SetFieldApp ''RQ_USER_31'', True, False, 0, 30
Req_SetFieldApp ''RQ_USER_32'', True, False, 0, 31
Req_SetFieldApp ''RQ_USER_34'', True, False, 0, 32
Req_SetFieldApp ''RQ_USER_33'', True, False, 0, 33
Req_SetFieldApp ''RQ_USER_35'', True, False, 0, 34
Req_SetFieldApp ''RQ_USER_39'', True, False, 0, 35
Req_SetFieldApp ''RQ_USER_37'', True, False, 0, 36
Req_SetFieldApp ''RQ_USER_36'', True, False, 0, 37
Req_SetFieldApp ''RQ_USER_38'', True, True, 0, 38
Req_SetFieldApp ''RQ_REQ_TYPE'', False, False, 0, 39 'Old Type (obsolete)
Req_SetFieldApp ''RQ_REQ_AUTHOR'', False, False, 0, 40 'Author
Req_SetFieldApp ''RQ_REQ_TIME'', False, False, 0, 41 'Creation Time
Req_SetFieldApp ''RQ_VTS'', False, False, 0, 42 'Modified
Req_SetFieldApp ''RQ_REQ_PRIORITY'', False, False, 0, 43 'Priority
Req_SetFieldApp ''RQ_REQ_REVIEWED'', False, False, 0, 44 'Reviewed
Req_SetFieldApp ''RQ_TARGET_REL'', False, False, 0, 45 'Target Release
Req_SetFieldApp ''RQ_REQ_DATE'', False, False, 0,

Marked as spam
Posted by (Questions: 2, Answers: 300)
Answered on May 29, 2015 8:28 pm
EyeOnTesting

Welcome back to "EyeOnTesting" brought to you by Orasi Software, Inc.

X
Scroll to Top