]> git.proxmox.com Git - pmg-api.git/blobdiff - PMG/API2/Quarantine.pm
register and use standard options for starttime and endtime
[pmg-api.git] / PMG / API2 / Quarantine.pm
index 4d81d690e28b7781c3c75a34350ba0f98fb567d8..52f36b0b42102177bf8f26f53d1b5ced2939719a 100644 (file)
@@ -377,18 +377,8 @@ __PACKAGE__->register_method ({
     parameters => {
        additionalProperties => 0,
        properties => {
-           starttime => {
-               description => "Only consider entries newer than 'starttime' (unix epoch). Default is 'now - 1day'.",
-               type => 'integer',
-               minimum => 0,
-               optional => 1,
-           },
-           endtime => {
-               description => "Only consider entries older than 'endtime' (unix epoch). This is set to '<start> + 1day' by default.",
-               type => 'integer',
-               minimum => 1,
-               optional => 1,
-           },
+           starttime => get_standard_option('pmg-starttime'),
+           endtime => get_standard_option('pmg-endtime'),
        },
     },
     returns => {
@@ -525,18 +515,8 @@ __PACKAGE__->register_method ({
     parameters => {
        additionalProperties => 0,
        properties => {
-           starttime => {
-               description => "Only consider entries newer than 'starttime' (unix epoch). This is set to 'now - 1day' by default.",
-               type => 'integer',
-               minimum => 0,
-               optional => 1,
-           },
-           endtime => {
-               description => "Only consider entries older than 'endtime' (unix epoch). This is set to '<start> + 1day' by default.",
-               type => 'integer',
-               minimum => 1,
-               optional => 1,
-           },
+           starttime => get_standard_option('pmg-starttime'),
+           endtime => get_standard_option('pmg-endtime'),
            pmail => $pmail_param_type,
        },
     },
@@ -627,18 +607,8 @@ __PACKAGE__->register_method ({
     parameters => {
        additionalProperties => 0,
        properties => {
-           starttime => {
-               description => "Only consider entries newer than 'starttime' (unix epoch). This is set to 'now - 1day' by default.",
-               type => 'integer',
-               minimum => 0,
-               optional => 1,
-           },
-           endtime => {
-               description => "Only consider entries older than 'endtime' (unix epoch). This is set to '<start> + 1day' by default.",
-               type => 'integer',
-               minimum => 1,
-               optional => 1,
-           },
+           starttime => get_standard_option('pmg-starttime'),
+           endtime => get_standard_option('pmg-endtime'),
        },
     },
     returns => {