Sidebar

zh:manual:api:reference:trigger:delete

删除

Description 说明

object trigger.delete(array triggerIds)

This method allows to delete triggers. 此方法允许删除触发器。

Parameters 参数

(array) IDs of the triggers to delete. (array)需要删除的触发器ID。

Return values 返回值

(object) Returns an object containing the IDs of the deleted triggers under the triggerids property. (object)返回一个对象,该对象包含在triggerids属性中已删除触发器的ID。

Examples 范例

Delete multiple triggers 删除多个触发器

Delete two triggers. 删除两个触发器。

Request 请求:

{
    "jsonrpc": "2.0",
    "method": "trigger.delete",
    "params": [
        "12002",
        "12003"
    ],
    "auth": "3a57200802b24cda67c4e4010b50c065",
    "id": 1
}

Response 响应:

{
    "jsonrpc": "2.0",
    "result": {
        "triggerids": [
            "12002",
            "12003"
        ]
    },
    "id": 1
}

Source 源码

CTrigger::delete() in frontends/php/include/classes/api/services/CTrigger.php. CTrigger::delete()方法可在frontends/php/include/classes/api/services/CTrigger.php中参考。