This method allows to update existing maintenances. 此方法允许更新已存在的维护模式。

    Parameters 参数

    (object/array) Maintenance properties to be updated. (object/array)要更新的维护模式的属性。

    Additionally to the , the method accepts the following parameters. 另外见standard maintenance properties,此方法接受如下参数。

    At least one host or host group must be defined for each maintenance. 每一个维护模式至少一个主机或者一个主机组被定义。

    Examples 示例

    Assigning different hosts 指定不同的主机

    Replace the hosts currently assigned to maintenance “3” with two different ones. 用两个不同的主机替换当前分配给维护“3”的主机。

    Request:

    1. {
    2. "jsonrpc": "2.0",
    3. "result": {
    4. ]
    5. },
    6. "id": 1
    7. }

    Source

    CMaintenance::update() in frontends/php/include/classes/api/services/CMaintenance.php.