POST api/Dev/Type/Trg/New
添加一个新的型号触发器。
Request Information
URI Parameters
None.
Body Parameters
型号触发器的内容。
DevTypeTrgParm| Name | Description | Type | Additional information |
|---|---|---|---|
| typeid |
型号ID |
string |
Required Max length: 4 |
| dataid |
数据项ID |
string |
Required Max length: 10 |
| trgid |
触发器ID |
integer |
Required |
| usable |
触发器是否启用,1表示启用,0表示停用。 |
string |
Required |
| desfieldname |
目标字段名 |
string |
Max length: 64 |
| levelvalue |
自定义阀值 |
decimal number |
None. |
Request Formats
application/json, text/json
Sample:
{
"typeid": "sample string 1",
"dataid": "sample string 2",
"trgid": 3,
"usable": "sample string 4",
"desfieldname": "sample string 5",
"levelvalue": 6.0
}
application/xml, text/xml
Sample:
<DevTypeTrgParm xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DigitalScience.DataTransfer.Dosimeter"> <dataid>sample string 2</dataid> <desfieldname>sample string 5</desfieldname> <levelvalue>6</levelvalue> <trgid>3</trgid> <typeid>sample string 1</typeid> <usable>sample string 4</usable> </DevTypeTrgParm>
application/x-www-form-urlencoded
Sample:
Sample not available.
application/bson
Sample:
Binary JSON content. See http://bsonspec.org for details.
Response Information
Resource Description
添加一个新的型号触发器。
CommonOperationResultWithTagOfInt64| Name | Description | Type | Additional information |
|---|---|---|---|
| errcode | integer |
None. |
|
| errmsg | string |
None. |
|
| tag | integer |
None. |
Response Formats
application/json, text/json
Sample:
{
"errcode": 1,
"errmsg": "sample string 2",
"tag": 3
}
application/xml, text/xml
Sample:
<CommonOperationResultWithTagOflong xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DigitalScience.DataTransfer"> <errcode>1</errcode> <errmsg>sample string 2</errmsg> <tag>3</tag> </CommonOperationResultWithTagOflong>
application/bson
Sample:
Binary JSON content. See http://bsonspec.org for details.