POST api/AgrTech/Plant/Variety/LifeCycle/DataSet/Add
添加一个新的物理量设置数据。
Request Information
URI Parameters
None.
Body Parameters
AgrTec_Plant_LifeCycle_DataSetTableItem| Name | Description | Type | Additional information |
|---|---|---|---|
| PlantVarietyId |
作物品种ID PlantVarietyId char(6) PK FK |
string |
Required Max length: 6 Min length: 6 |
| GrowthStageId |
生长阶段ID GrowthStageId PK char(1) |
string |
Required Max length: 1 Min length: 1 |
| StartTimeSeg |
起始时段 StartTimeSeg tinyint PK 依据大棚所在的时区,0表示第零(0:00-0:59),1表示第一时(1:00-1:59),以此类推 |
byte |
Required |
| EndTimeSeg |
截至时段 EndTimeSeg tinyint NN |
byte |
Required |
| DataId |
物理量ID DataId int |
integer |
Required |
| MinValue |
最小值 MinValue varchar(10) NN 低于此值时,将会触发告警和动作执行。 |
string |
Required Max length: 10 |
| MaxValue |
最大值 MaxValue varchar(10) NN 高于此值时,将会触发告警和动作执行。 |
string |
Required Max length: 10 |
| BestValue |
最佳值 BestValue varchar(10) NN |
string |
Required Max length: 10 |
| DownStopValue |
下行动作终止值 DownStopValue varchar(10) 物理量达到这个值时,下行动作会停止。 |
string |
Required Max length: -1 |
| UpStopValue |
上行动作终止值 UpStopValue varchar(10) 物理量达到这个值时,上行动作会停止。 |
string |
Required Max length: 10 |
Request Formats
application/json, text/json
{
"PlantVarietyId": "sample string 1",
"GrowthStageId": "sample string 2",
"StartTimeSeg": 64,
"EndTimeSeg": 64,
"DataId": 5,
"MinValue": "sample string 6",
"MaxValue": "sample string 7",
"BestValue": "sample string 8",
"DownStopValue": "sample string 9",
"UpStopValue": "sample string 10"
}
application/xml, text/xml
<AgrTec_Plant_LifeCycle_DataSetTableItem xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/DigitalScience.DataTransfer.CleverFarmer"> <BestValue>sample string 8</BestValue> <DataId>5</DataId> <DownStopValue>sample string 9</DownStopValue> <EndTimeSeg>64</EndTimeSeg> <GrowthStageId>sample string 2</GrowthStageId> <MaxValue>sample string 7</MaxValue> <MinValue>sample string 6</MinValue> <PlantVarietyId>sample string 1</PlantVarietyId> <StartTimeSeg>64</StartTimeSeg> <UpStopValue>sample string 10</UpStopValue> </AgrTec_Plant_LifeCycle_DataSetTableItem>
application/x-www-form-urlencoded
application/bson
Binary JSON content. See http://bsonspec.org for details.
Response Information
Resource Description
添加一个新的物理量设置数据。
CommonOperationResult| Name | Description | Type | Additional information |
|---|---|---|---|
| errcode |
错误代码,通常0表示成功,其他值表示错误。 |
integer |
None. |
| errmsg |
错误描述,当errcode不为零时,此值可以用于呈现给用户。 |
string |
None. |
| tag |
操作同时,服务器端需要返回的其他值。 |
string |
None. |
Response Formats
application/json, text/json
{
"errcode": 1,
"errmsg": "sample string 2",
"tag": "sample string 3"
}
application/xml, text/xml
<CommonOperationResult 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>sample string 3</tag> </CommonOperationResult>
application/bson
Binary JSON content. See http://bsonspec.org for details.