예제 #1
0
 def Args(parser):
   resources = [
       resource_args.CreateAlertPolicyResourceArg('to be updated.')]
   resource_args.AddResourceArgs(parser, resources)
   flags.AddMessageFlags(parser, 'policy')
   flags.AddFieldsFlagsWithMutuallyExclusiveSettings(
       parser,
       fields_help=('The list of fields to update. Must specify `--policy` or '
                    '`--policy-from-file` if using this flag.'),
       add_settings_func=flags.AddPolicySettingsFlags,
       fields_choices=['disabled', 'notificationChannels'],
       update=True)
예제 #2
0
 def Args(parser):
     condition_arg = resource_args.CreateAlertPolicyResourceArg(
         'to add a condition to.')
     resource_args.AddResourceArgs(parser, [condition_arg])
     flags.AddMessageFlags(parser, 'condition')
     flags.AddConditionSettingsFlags(parser)