]> git.proxmox.com Git - pve-manager.git/commitdiff
pvesh: add standard_output_properties to set/create/delete
authorDietmar Maurer <dietmar@proxmox.com>
Fri, 27 Jul 2018 05:34:49 +0000 (07:34 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Fri, 27 Jul 2018 05:34:49 +0000 (07:34 +0200)
Most of those API calls return simple strings, so it does not really matter.
Nethertheless, some calls return complex data structures and we want to set
output format for them.

PVE/CLI/pvesh.pm

index 6808e77a49a8fe170a8cfa63310364236dcb5d84..ccfb5c20e2d4f7ad40fd4da18890e7105051dbc1 100755 (executable)
@@ -379,7 +379,7 @@ __PACKAGE__->register_method ({
     description => "Call API PUT on <api_path>.",
     parameters => {
        additionalProperties => 0,
-       properties => $path_properties,
+       properties => PVE::RESTHandler::add_standard_output_properties($path_properties),
     },
     returns => { type => 'null' },
     code => sub {
@@ -397,7 +397,7 @@ __PACKAGE__->register_method ({
     description => "Call API POST on <api_path>.",
     parameters => {
        additionalProperties => 0,
-       properties => $path_properties,
+       properties => PVE::RESTHandler::add_standard_output_properties($path_properties),
     },
     returns => { type => 'null' },
     code => sub {
@@ -415,7 +415,7 @@ __PACKAGE__->register_method ({
     description => "Call API DELETE on <api_path>.",
     parameters => {
        additionalProperties => 0,
-       properties => $path_properties,
+       properties => PVE::RESTHandler::add_standard_output_properties($path_properties),
     },
     returns => { type => 'null' },
     code => sub {