TableRebuildCheck
Check the Application for Rebuilding Tables
Request address
POST
http://OmsAddress/app/newoms.php/webservice/business/table/rebuild/check?cmd=10023&ip-type=webservicerest&access-token=AccessTokenVal
POST request parameter description
| Parameter name | Data type | Description | Whether the field is required | Remarks |
|---|---|---|---|---|
| uid | integer | id of the application form for rebuilding tables | Yes | |
| auto_exec_trans | Integer (0 or 1) | Whether to generate a table-rebuilding transaction after approving the table-rebuilding application (the set where the table is located allows automatic execution of the table-rebuilding transactions) | No, the default is not auto-execution |
Data Parameters
Use json format to represent the record related information. The following is an example:
{
"uid": 116
}
Return Syntax
Return Parameter Description
- When the returned status code is not 200, it indicates that the check was unsuccessful, and the returned data is the transaction failure message
- When the returned status code is 200, it indicates that the transaction was successfully created, and the data structure returned is as follows
| Field name | Data type | Description | Remarks |
|---|---|---|---|
| trans_id | integer | id of the generated corresponding transaction | |
| set_id | integer | Set of the transaction |
Request Example
Send A Request through the Curl Method
For the parameters in the command, please refer to the "Description of POST Request Parameters" on this page. For the method to obtain access-token, see: Get access-token
curl -H "Content-type: application/json" -X "POST" -d '{
"uid": 116
}' http://omsaddress/app/newoms.php/webservice/business/table/rebuild/check?cmd=10023&ip-type=webservicerest&access-token=\
Return Example
Successful Return Example
Status of http request = 200
{
"set_id": 126,
"trans_id": 411
}
Failed Return Example
Status of http request != 200
{
"name": "Unauthorized",
"message": "You are requesting with an invalid credential.",
"code": 0,
"status": 401,
"type": "yii\\web UnauthorizedHttpException"
}
{
"uid": [
"apply not in pending status(id:243)"
]
}