Wiki source code of vehicle_groups/manage_assignments.php
Last modified by YellowFox_RD on 2024/12/19 10:11
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | (% class="box" %) | ||
2 | (((Table of Contents))) | ||
3 | {{toc/}} | ||
4 | |||
5 | Management of vehicle group assignments. | ||
6 | Assign a single vehicle to a vehicle group or remove it from there. | ||
7 | |||
8 | = Description = | ||
9 | //**(% class="green mark" %)GET(%%) vehicle_groups/manage_assignments.php?company**=COMPANY_RTIKEY**&vehicle**=VEHICLE_RTIKEY**&group**=GROUP_RTIKEY**&task**=assign | ||
10 | // | ||
11 | = Parameter = | ||
12 | |=Parameter|=Description|=Type|=Note|=Mandatory | ||
13 | |company|RTI company key|string||yes | ||
14 | |vehicle|RTI vehicle key|string||yes | ||
15 | |group|RTI group key|string||yes | ||
16 | |task|order to assign or remove|string|Possible values: | ||
17 | ((( | ||
18 | * assign | ||
19 | * remove | ||
20 | )))|yes | ||
21 | |||
22 | = Return = | ||
23 | A **string** will be returned. If the request was successful "**OK**". If the request failed "(% class="error" %)**ERROR:Description**(%%)". | ||
24 | |||
25 | == Possible error values == | ||
26 | |=error|=description | ||
27 | |MISSING_COMPANY|company key is missing | ||
28 | |INVALID_COMPANY|Company not found. Company key or import key might be faulty. | ||
29 | |ERROR_MAINTENANCE|Your company is under maintenance, no RTI request are possible at the moment. | ||
30 | |MISSING_GROUP|group key is missing | ||
31 | |INVALID_GROUP_KEY|group key does not match any group | ||
32 | |MISSING_TASK|no task given | ||
33 | |MISSING_VEHICLE|vehicle key is missing | ||
34 | |INVALID_KEY(VEHICLE~|GROUP~|IMPORT)|vehicle key does not match structure of a rti key | ||
35 | |INVALID_VEHICLE_KEY|vehicle key does not match any vehicle | ||
36 | |CAR_ALREADY_IN_GROUP|vehicle is already in given group | ||
37 | |CAR_IS_NOT_IN_GROUP|vehicle is not in given group | ||
38 | |UNKNOWN_TASK([TASK])|task has an invalid value | ||
39 | |ERROR_WHILE_[TASK]|error while saving assignment | ||
40 | |||
41 | = Example calls = | ||
42 | **Assign a vehicle to a group** | ||
43 | {{code language="java"}}https://map.yellowfox.de/rti/vehicle_groups/manage_assignments.php?company=COMPANY_RTIKEY&vehicle=VEHICLE_RTIKEY&group=GROUP_RTIKEY&task=assign | ||
44 | |||
45 | https://map.yellowfox.de/rti/vehicle_groups/manage_assignments.php?company=COMPANY_RTIKEY&vehicle={"type":"car_ident","groupKey":"GROUP_RTIKEY","ident":"VEHICLE_IDENT"}&group=GROUP_RTIKEY&task=assign{{/code}} | ||
46 |