You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Insights] Removing Tag from the Activity Log Alert Enable and Disable cmdlets, fixing the arguments attributes for Set-AzureRmActivityLogAlerts, updating the help files accordingly.
Copy file name to clipboardExpand all lines: src/ResourceManager/Insights/Commands.Insights.Test/ActivityLogAlerts/DisableAzureRmActivityLogAlertTests.cs
+1-3Lines changed: 1 addition & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -80,16 +80,14 @@ public void DisableActivityLogAlertCommandParametersProcessing()
Copy file name to clipboardExpand all lines: src/ResourceManager/Insights/Commands.Insights.Test/ActivityLogAlerts/EnableAzureRmActivityLogAlertTests.cs
+1-3Lines changed: 1 addition & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -80,16 +80,14 @@ public void EnableActivityLogAlertCommandParametersProcessing()
Copy file name to clipboardExpand all lines: src/ResourceManager/Insights/Commands.Insights/ActivityLogAlert/DisableAzureRmActivityLogAlertCommand.cs
+2-11Lines changed: 2 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -46,15 +46,6 @@ public class DisableAzureRmActivityLogAlertCommand : ManagementCmdletBase
46
46
[ValidateNotNullOrEmpty]
47
47
publicstringResourceGroupName{get;set;}
48
48
49
-
/// <summary>
50
-
/// Gets or sets the Tags of the activity log alert resource
51
-
/// </summary>
52
-
[Parameter(ParameterSetName=DisableActivityLogAlertDeafultParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
53
-
[Parameter(ParameterSetName=DisableActivityLogAlertFromPipeParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
54
-
[Parameter(ParameterSetName=DisableActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
55
-
[ValidateNotNullOrEmpty]
56
-
publicDictionary<string,string>Tag{get;set;}
57
-
58
49
/// <summary>
59
50
/// Gets or sets the InputObject parameter of the cmdlet
Copy file name to clipboardExpand all lines: src/ResourceManager/Insights/Commands.Insights/ActivityLogAlert/EnableAzureRmActivityLogAlertCommand.cs
+2-11Lines changed: 2 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -46,15 +46,6 @@ public class EnableAzureRmActivityLogAlertCommand : ManagementCmdletBase
46
46
[ValidateNotNullOrEmpty]
47
47
publicstringResourceGroupName{get;set;}
48
48
49
-
/// <summary>
50
-
/// Gets or sets the Tags of the activity log alert resource
51
-
/// </summary>
52
-
[Parameter(ParameterSetName=EnableActivityLogAlertDeafultParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
53
-
[Parameter(ParameterSetName=EnableActivityLogAlertFromPipeParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
54
-
[Parameter(ParameterSetName=EnableActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
55
-
[ValidateNotNullOrEmpty]
56
-
publicDictionary<string,string>Tag{get;set;}
57
-
58
49
/// <summary>
59
50
/// Gets or sets the InputObject parameter of the cmdlet
Copy file name to clipboardExpand all lines: src/ResourceManager/Insights/Commands.Insights/ActivityLogAlert/SetAzureRmActivityLogAlertCommand.cs
+52-43Lines changed: 52 additions & 43 deletions
Original file line number
Diff line number
Diff line change
@@ -35,45 +35,48 @@ public class SetAzureRmActivityLogAlertCommand : ManagementCmdletBase
35
35
/// <summary>
36
36
/// Gets or sets the Location parameter of the cmdlet
37
37
/// </summary>
38
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipeline=true,HelpMessage="The location of the activity log rule resource")]
38
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipelineByPropertyName=true,HelpMessage="The location of the activity log rule resource")]
39
39
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The location of the activity log rule resource")]
40
40
[ValidateNotNullOrEmpty]
41
41
publicstringLocation{get;set;}
42
42
43
43
/// <summary>
44
44
/// Gets or sets the alert name parameter of the cmdlet
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipeline=true,HelpMessage="The resource group name of the activity log rule resource")]
53
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipelineByPropertyName=true,HelpMessage="The resource group name of the activity log rule resource")]
54
54
[ValidateNotNullOrEmpty]
55
55
publicstringResourceGroupName{get;set;}
56
56
57
57
/// <summary>
58
58
/// Gets or sets the scopes of the activity log alert
59
59
/// </summary>
60
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipeline=true,HelpMessage="The list scopes")]
60
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipelineByPropertyName=true,HelpMessage="The list scopes")]
61
+
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,HelpMessage="The list scopes")]
61
62
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The list scopes")]
62
63
[ValidateNotNullOrEmpty]
63
64
publicList<string>Scope{get;set;}
64
65
65
66
/// <summary>
66
67
/// Gets or sets the conditions of the activity log alert
67
68
/// </summary>
68
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipeline=true,HelpMessage="The list of leaf conditions of the activity log alert")]
69
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipelineByPropertyName=true,HelpMessage="The list of leaf conditions of the activity log alert")]
70
+
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,HelpMessage="The list of leaf conditions of the activity log alert")]
69
71
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The list of leaf conditions of the activity log alert")]
/// Gets or sets the actions of the activity log alert
75
77
/// </summary>
76
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipeline=true,HelpMessage="The list actions of the activity log alert")]
78
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=true,ValueFromPipelineByPropertyName=true,HelpMessage="The list actions of the activity log alert")]
79
+
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,HelpMessage="The list actions of the activity log alert")]
77
80
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The list actions of the activity log alert")]
@@ -89,17 +92,17 @@ public class SetAzureRmActivityLogAlertCommand : ManagementCmdletBase
89
92
/// <summary>
90
93
/// Gets or set the alert description
91
94
/// </summary>
92
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=false,ValueFromPipeline=true,HelpMessage="The description of the activity log rule resource")]
93
-
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,ValueFromPipeline=true,HelpMessage="The description of the activity log rule resource")]
95
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The description of the activity log rule resource")]
96
+
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,HelpMessage="The description of the activity log rule resource")]
94
97
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The description of the activity log rule resource")]
95
98
[ValidateNotNullOrEmpty]
96
99
publicstringDescription{get;set;}
97
100
98
101
/// <summary>
99
102
/// Gets or sets the Tags of the activity log alert resource
100
103
/// </summary>
101
-
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=false,ValueFromPipeline=true,HelpMessage="The tags of the activity log alert resource")]
102
-
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,ValueFromPipeline=true,HelpMessage="The tags of the activity log alert resource")]
104
+
[Parameter(ParameterSetName=SetActivityLogAlertDefaultParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
105
+
[Parameter(ParameterSetName=SetActivityLogAlertFromPipeParamGroup,Mandatory=false,HelpMessage="The tags of the activity log alert resource")]
103
106
[Parameter(ParameterSetName=SetActivityLogAlertFromResourceIdParamGroup,Mandatory=false,ValueFromPipelineByPropertyName=true,HelpMessage="The tags of the activity log alert resource")]
This command changes the tags property of the activity log alert called alert1. For this it uses a PSActivityLogAlertResource object as input argument.
41
+
This command disables an activity log alert called alert1. For this it uses a PSActivityLogAlertResource object as input argument.
55
42
56
-
### Example 4: Disable the ActivityLogAlert using the ResourceId parameter
43
+
### Example 3: Disable the ActivityLogAlert using the ResourceId parameter
0 commit comments