trigger.adddependencies
Description说明
object trigger.adddependencies(object/array triggerDependencies)
This method allows to create new trigger dependencies此方法允许创建新的触发器依赖关系.
Parameters参数
(object/array)
Trigger dependencies to create触发依赖关系创建.
Each trigger dependency has the following parameters每个触发器依赖关系具有以下参数:
Parameter参数 | Type类型 | Description说明 |
---|---|---|
triggerid(required) | string | ID of the dependent trigger依赖触发器的ID. |
dependsOnTriggerid(required) | string | ID of the trigger that the trigger depends on触发依赖的触发器的ID. |
Return values返回值
(object)
Returns an object containing the IDs of the dependent triggers under the triggerids
property.(object)
返回一个对象,该对象包含triggerids
属性下的依赖触发器的ID。
Examples范例
Add a trigger dependency添加触发器依赖关系
Make trigger “14092” dependent on trigger “13565.”触发器“14092”依赖于触发器“13565.”。
Request请求:
- {
- "jsonrpc": "2.0",
- "method": "trigger.adddependencies",
- "params": {
- "triggerid": "14092",
- "dependsOnTriggerid": "13565"
- },
- "auth": "038e1d7b1735c6a5436ee9eae095879e",
- "id": 1
- }
Response响应:
- {
- "jsonrpc": "2.0",
- "result": {
- "triggerids": [
- "14092"
- ]
- },
- "id": 1
- }
See also参考
Source来源
CTrigger::addDependencies() in frontends/php/include/classes/api/services/CTrigger.php.