Wiki source code of address_management/get_areas.php
Last modified by YellowFox_RD on 2025/01/23 09:09
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | (% class="box" %) | ||
2 | ((( | ||
3 | Table of Contents | ||
4 | ))) | ||
5 | |||
6 | {{toc/}} | ||
7 | |||
8 | This function allows you to retrieve a list of all server-based areas. | ||
9 | |||
10 | = Description = | ||
11 | |||
12 | (% class="green mark" %)**GET**(%%)** **/**address_management**/**get_areas.php?company**=RTI_COMPANYKEY**&import=**RTI_IMPORTKEY**&displayDeleted**=0 | ||
13 | |||
14 | = Parameter = | ||
15 | |||
16 | |=Parameter|=Beschreibung|=Typ|=Hinweis|=Pflicht | ||
17 | |company|RTI company key|string| |yes | ||
18 | |import|RTI import key (all vehicles)|string| |yes | ||
19 | |displayDeleted|Should deleted areas be displayed?|string|Optional parameter((( | ||
20 | * 0 (default) =Display only non-deleted areas | ||
21 | * 1 =Display deleted areas as well | ||
22 | )))|no | ||
23 | |format|Output format|string|json (Standard)|yes | ||
24 | |||
25 | = Return = | ||
26 | |||
27 | A **string **is returned. Otherwise an "(% class="error" %)**ERROR:Description**(%%)" is returned | ||
28 | |||
29 | == Parameter == | ||
30 | |||
31 | |==== Parameter ===|=Description|=Type | ||
32 | |uuid|For the unique identification of the area data|string | ||
33 | |name|Area name|string | ||
34 | |type|Area type(polygon,polyline )|string | ||
35 | |costCenter|Cost center|integer | ||
36 | |coordinates|Latitude/Longitude|float | ||
37 | |radius|Route width|integer | ||
38 | |changeDate|Date of change of the data|Format YYYY-MM-dd'T'HH:MM:SS.SSSZ | ||
39 | |createDate|Date of creation of the data|Format YYYY-MM-dd'T'HH:MM:SS.SSSZ | ||
40 | |deleteDate|Date of deletion of the data|Format YYYY-MM-dd'T'HH:MM:SS.SSSZ | ||
41 | |useInTimeRecording|should the area be displayed in the time recording?|boolean | ||
42 | |useInMap|should the area be displayed on the map?|boolean | ||
43 | |assignedVehicles|List of assigned vehicles (active)|array | ||
44 | |_links|Links (IFrameMapEditor, Delete)| | ||
45 | |||
46 | == JSON Format == | ||
47 | |||
48 | {{code language="js"}} | ||
49 | [{ | ||
50 | "uuid": "ABC-123-DEF", | ||
51 | "name": "100 test", | ||
52 | "type": "polygon", | ||
53 | "costCenter": "100", | ||
54 | "coordinates": [ | ||
55 | { | ||
56 | "lat": 2.33867, | ||
57 | "lon": 48.8554 | ||
58 | }, | ||
59 | { | ||
60 | "lat": 2.33867, | ||
61 | "lon": 48.859 | ||
62 | }, | ||
63 | { | ||
64 | "lat": 2.34413, | ||
65 | "lon": 48.859 | ||
66 | }, | ||
67 | { | ||
68 | "lat": 2.34413, | ||
69 | "lon": 48.8554 | ||
70 | } | ||
71 | ], | ||
72 | "radius": 0, | ||
73 | "changeDate": "2023-02-22T14:02:21+0100", | ||
74 | "createDate": "2023-02-21T12:51:12+0100", | ||
75 | "deleteDate": null, | ||
76 | "useInTimeRecording": true, | ||
77 | "useInMap": true, | ||
78 | "assignedVehicles": [ | ||
79 | { | ||
80 | "vehicleSign ": "vehicleSign 1" | ||
81 | }, | ||
82 | { | ||
83 | "vehicleSign ": "vehicleSign 2" | ||
84 | }, | ||
85 | { | ||
86 | "vehicleSign ": "vehicleSign 3" | ||
87 | } | ||
88 | |||
89 | ], | ||
90 | "_links": { | ||
91 | "editor": { | ||
92 | "href": "https://map.yellowfox.de/rti/address_management/area_editor.php?company=RTI_COMPANYKEY&import=RTI_IMPORTKEY&uuid=123-ABC-345-DEF&category=passive" | ||
93 | } | ||
94 | } | ||
95 | }], | ||
96 | {{/code}} | ||
97 | |||
98 | |||
99 | |||
100 | = Example Calls = | ||
101 | |||
102 | {{code language="js"}}http://map.yellowfox.de/rti/address_management/get_areas.php?company=COMPANY_KEY&import=IMPORT_KEY&displayDeleted=1{{/code}} | ||
103 |