Add osc support to update plan description

Change-Id: Ibc661594342a89cc5f89084972a4fb9844da1a84
This commit is contained in:
liushuai 2018-12-02 23:25:47 +08:00
parent 262799e3c0
commit c2e7441444
1 changed files with 7 additions and 0 deletions

View File

@ -210,6 +210,11 @@ class UpdatePlan(command.ShowOne):
metavar="<name>", metavar="<name>",
help=_("A name to which the plan will be renamed.") help=_("A name to which the plan will be renamed.")
) )
parser.add_argument(
"--description",
metavar="<description>",
help=_("Description to which the plan will be updated.")
)
parser.add_argument( parser.add_argument(
"--resources", "--resources",
metavar="<id=type=name,id=type=name>", metavar="<id=type=name,id=type=name>",
@ -227,6 +232,8 @@ class UpdatePlan(command.ShowOne):
data = {} data = {}
if parsed_args.name is not None: if parsed_args.name is not None:
data['name'] = parsed_args.name data['name'] = parsed_args.name
if parsed_args.description is not None:
data['description'] = parsed_args.description
if parsed_args.resources is not None: if parsed_args.resources is not None:
plan_resources = utils.extract_resources(parsed_args) plan_resources = utils.extract_resources(parsed_args)
data['resources'] = plan_resources data['resources'] = plan_resources