bind_unit_trailer

The bind_unit_trailer function is used to assign trailers to units or to separate them from units.

Copied!
svc=resource/bind_unit_trailer&params={"resourceId":<long>,
				       				   "unitId":<long>,
				       				   "trailerId":<long>,
				       				   "time":<uint>,
				       				   "mode":<bool>
									  }

Parameters

Name Description
resourceId Resource ID.
unitId Unit ID.
trailerId Trailer ID.
time Time (0 — current time).
mode Modes:
  • 1/true — assign;
  • 0/false — separate.

Returned result

If the request is successful, an empty JSON is returned.

Copied!
{ }

If not, an error code is returned. Possible error codes:

Code Description
7 Failed to fetch the resource with the desired ACL (ADF_ACL_AVL_RES_EDIT_TRAILERS) or failed to fetch the unit with the desired ACL (ADF_ACL_ITEM_VIEW).
6 Failed to assign the trailer.
4 Failed to fetch the trailer with the desired trailerId or wrong input parameters.

If you find a mistake in the text, please select it and press Ctrl+Enter.