[POST] .../v1/docinout/lock
Locks cash in/out document for editing. Use this method to lock one or more cash in/out documents before editing, changing rows, posting, cancelling posting or deletion workflows that follow the document lock contract. The stock receipt/expense tariff option must be enabled; the body must contain a non-empty ids array with positive document IDs and the RBAC permission check for Lock is currently disabled in this controller. The response reports how many document lock rows changed and locked documents expose current_user_blocked in DocInOut/Get for the current request user. Business errors such as missing body, missing ids, invalid IDs, disabled tariff option, lock conflicts, database failures or persistent lock errors are returned as HTTP 200 ErrorResult.
Request Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| ids | Array of Int64 | Required | Required non-empty array of positive stock receipt/write-off document IDs. |
Request Example
{
"ids": [
42
]
}
Response Parameters
| Name | Type | Description |
|---|---|---|
| ok | Boolean | Indicates whether the request completed successfully. |
| result | Update | Update operation result. |
Response Example
{
"ok": true,
"result": {
"row_affected": 1
}
}