Changes for page get_personnel.php
Last modified by YellowFox_RD on 2025/01/23 10:16
To version 4.1
edited by Dominic Lippmann
on 2025/01/23 10:15
on 2025/01/23 10:15
Change comment:
There is no comment for this version
Summary
-
Page properties (2 modified, 0 added, 0 removed)
Details
- Page properties
-
- Author
-
... ... @@ -1,1 +1,1 @@ 1 -XWiki. YellowFox_RD1 +XWiki.yf-dominic - Content
-
... ... @@ -1,28 +1,32 @@ 1 1 (% class="box" %) 2 -(((Table of Contents))) 2 +((( 3 +Table of Contents 4 +))) 5 + 3 3 {{toc/}} 4 4 5 5 Getting data for personnel set in personnel administration 6 -=== Description === 7 -//**(% class="green mark" %)GET(%%) get_personnel.php?company**=RTI_COMPANYKEY**&import**=RTI_VEHICLEKEY&**format=**csv// 9 + 10 += Description = 11 + 12 +(% class="green mark" %)//**GET**//(%%)//** get_personnel.php?company**=RTI_COMPANYKEY**&import**=RTI_VEHICLEKEY&**format=**csv// 13 + 8 8 = Parameters = 15 + 9 9 |=Parameter|=Description|=Type|=Note|=Mandatory 10 -|company|RTI company key|string||yes 11 -|import|RTI import key|string||yes 12 -|format|export format for list|string|supported output formats: 13 -((( 17 +|company|RTI company key|string| |yes 18 +|import|RTI import key|string| |yes 19 +|format|export format for list|string|supported output formats:((( 14 14 * csv - export as csv formatted file 15 15 * json - export as json 16 16 * xml - export as xml 17 -))) 18 -default: csv|no 23 +)))default: csv|no 19 19 |history|show only latest personnel key for each person or all keys for each person|int|((( 20 20 * 0 - return only latest key 21 21 * 1 - return all keys((( 22 22 * will return one entry per key 23 23 ))) 24 -))) 25 -default: 0|no 29 +)))default: 0|no 26 26 |id|limit exported persons list to given id|string|see //strict// parameter|no 27 27 |name|limit exported persons list to given name|string|see //strict// parameter|no 28 28 |pkey|limit exported persons list to given personnel key|string|see //strict// parameter|no ... ... @@ -30,43 +30,47 @@ 30 30 |strict|switch search between finding the exact given value or return all results where the search string is part of the result|int|((( 31 31 * 0 - return all results containing the searched string 32 32 * 1 - return only results matching exactly the searched string 33 -))) 34 -default: 1 35 -this setting modifies the behaviour for parameters:// id, name, pkey, group//|no 37 +)))default: 1 38 +this setting modifies the behaviour for parameters:~/~/ id, name, pkey, group|no 36 36 37 37 = Return = 38 -Returning a string in selected format. On error returning "**(% class="error" %)403 - Verboten: Zugriff verweigert.(%%)**" as HTTP-Header. 41 + 42 +Returning a string in selected format. On error returning "(% class="error" %)**403 - Verboten: Zugriff verweigert.**(%%)" as HTTP-Header. 43 + 39 39 == Column == 40 -|=CSV Column name|=JSON/XML key name|=Name in personnel administration|=Description|=Note|= 41 -|ID|id|employee number|self defined employee number|| 42 -|NAME|name|Name|complete name of the person|| 43 -|KEY|key[id]|personnel key|personnel key (for bookings via YellowFox)|| 44 -|VALID_FROM|key[valid_from]|personnel key valid from|validity start for the personnel key||format: YYYY-MM-DD HH:MM:SS 45 -|VALID_TO|key[valid_to]|personnel key valid to|validity end for the personnel key||format: YYYY-MM-DD HH:MM:SS 46 -|GROUPS|groups[group]|personnel groups|comma separated list with all personnel groups assigned to the person|| 47 -|CARD_NR|card_nr|employee licence number|optional licence number to assign bookings to ReinerSCT|| 48 -|DRV_LICENCE_NR|drv_licence[id]|driver licence|driver licence number|only filled, if tacho archive active| 45 + 46 +|=CSV Column name|=JSON/XML key name|=Name in personnel administration|=Description|=Note|= 47 +|ID|id|employee number|self defined employee number| | 48 +|NAME|name|Name|complete name of the person| | 49 +|KEY|key[id]|personnel key|personnel key (for bookings via YellowFox)| | 50 +|VALID_FROM|key[valid_from]|personnel key valid from|validity start for the personnel key| |format: YYYY-MM-DD HH:MM:SS 51 +|VALID_TO|key[valid_to]|personnel key valid to|validity end for the personnel key| |format: YYYY-MM-DD HH:MM:SS 52 +|GROUPS|groups[group]|personnel groups|comma separated list with all personnel groups assigned to the person| | 53 +|CARD_NR|card_nr|employee licence number|optional licence number to assign bookings to ReinerSCT| | 54 +|DRV_LICENCE_NR|drv_licence[id]|driver licence|driver licence number|only filled, if tacho archive active| 49 49 |DRV_LICENCE_VALID_TO|drv_licence[valid_to]|driver licence valid to|expiration date of driver licence|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 50 -|IDENTITY_CARD_NR|identity_card[id]|identity card|identity card number|only filled, if tacho archive active| 56 +|IDENTITY_CARD_NR|identity_card[id]|identity card|identity card number|only filled, if tacho archive active| 51 51 |IDENTITY_CARD_VALID_TO|identity_card[valid_to]|identity card valid to|expiration date of identity card|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 52 -|PASSPORT_NR|passport[id]|passport|passport number|only filled, if tacho archive active| 58 +|PASSPORT_NR|passport[id]|passport|passport number|only filled, if tacho archive active| 53 53 |PASSPORT_VALID_TO|passport[valid_to]|passport valid to|expiration date of passort|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 54 -|ADR_CERTIFICATE_NR|adr_certificate[id]|ADR certificate|number of ADR certificate (carriage of dangerous goods by road)|only filled, if tacho archive active| 60 +|ADR_CERTIFICATE_NR|adr_certificate[id]|ADR certificate|number of ADR certificate (carriage of dangerous goods by road)|only filled, if tacho archive active| 55 55 |ADR_CERTICATE_VALID_TO|adr_certificate[valid_to]|ADR cetificate valid to|expiration date of ADR certificate|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 56 56 |BKRFQG_VALID_TO|bkrfqg[valid_to]|qualification by keynumber 95 valid to|expiration date of german "**B**erufs**kr**aft**f**ahrer**q**ualifikations**g**esetz"|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 57 57 |BIRTHDATE|birthdate|date of birth|date of birth of person|only filled, if tacho archive active 58 58 If day and/or month are unknown, the birthdate is filled up with "XX" for the unknown values according to german passport law 59 - 60 60 (example: 1980-06-XX or 1980-XX-XX)|format: YYYY-MM-DD HH:MM:SS 61 61 |JOB_START_DATE|job_start_date|employee since|start date of beeing an employee at this company|only filled, if tacho archive active|format: YYYY-MM-DD HH:MM:SS 62 -|DRV_LICENCE_CHECK_TAG_ID|drv_licence_check[tag_id]|NFC tag id|id of nfc tag for driver licence check|| 63 -|DRV_LICENCE_CHECK_LAST_CHECK|drv_licence_check[last_check]|last [driver licence] check|date of latest driver licence check||format: YYYY-MM-DD HH:MM:SS 64 -|DRV_LICENCE_CHECK_NEXT_CHECK|drv_licence_check[next_check]|next [driver licence] check|date of next driver licence check||format YYYY-MM-DD 65 -|DRV_LICENCE_CHECK_INTERVAL|drv_licence_check[interval]|[driver licence] check interval|timerange between 2 driver licence checks in seconds|| 67 +|DRV_LICENCE_CHECK_TAG_ID|drv_licence_check[tag_id]|NFC tag id|id of nfc tag for driver licence check| | 68 +|DRV_LICENCE_CHECK_LAST_CHECK|drv_licence_check[last_check]|last [driver licence] check|date of latest driver licence check| |format: YYYY-MM-DD HH:MM:SS 69 +|DRV_LICENCE_CHECK_NEXT_CHECK|drv_licence_check[next_check]|next [driver licence] check|date of next driver licence check| |format YYYY-MM-DD 70 +|DRV_LICENCE_CHECK_INTERVAL|drv_licence_check[interval]|[driver licence] check interval|timerange between 2 driver licence checks in seconds| | 66 66 67 67 == CSV Format == 73 + 68 68 Sending a correct request will return a csv formatted file with a headline as first line containing column names. The data itself will be returned in following rows. 75 + 69 69 === Meta informations === 77 + 70 70 |=Separator|semicolon ( ; ) 71 71 |=text limiter|double quote ( " ) 72 72 |=line brak|0x0D 0x0A (CarriageReturn LineFeed) ... ... @@ -73,6 +73,7 @@ 73 73 |=header|row 1 74 74 75 75 === Header === 84 + 76 76 **header informationen** 77 77 {{code language="java"}}"ID";"NAME";"KEY";"VALID_FROM";"VALID_TO";"GROUPS";"CARD_NR";"DRV_LICENCE_NR";"DRV_LICENCE_VALID_TO";"IDENTITY_CARD_NR";"IDENTITY_CARD_VALID_TO";"PASSPORT_NR";"PASSPORT_VALID_TO";"ADR_CERTIFICATE_NR";"ADR_CERTIFICATE_VALID_TO";"BKRFQG_VALID_TO";"BIRTHDATE";"JOB_START_DATE"{{/code}} 78 78 ... ... @@ -82,93 +82,99 @@ 82 82 "0012";"Max Mustermann";"DF1234567890";"2018-01-01 06:43:00";"";"Fahrer,Dresden";"";"YFDD9876";"2021-11-10 23:59:59";"";"";"";"2023-04-30 23:59:59";"";"2020-07-31 23:59:59";"2021-11-30 23:59:59";"1990-02-19 00:00:00";"2014-09-01 00:00:00";""4729000A3341";"2020-03-01 10:43:00";"2020-03-15";"1209600"{{/code}} 83 83 84 84 == JSON Format == 94 + 85 85 Retrun a json formatted string with all the available data matching the request parameters. The entries will be returned as key - value relation. Some data such as personnel key or personnel groups are grouped in a sub object. 96 + 86 86 === Beispiel === 98 + 87 87 **example** 88 88 {{code language="js"}}[ 89 - 90 - 91 - 92 - 93 - 94 - 95 - 96 - 97 - 98 - 99 - 100 - 101 - 102 - 103 - 104 - 105 - 106 - 107 - 108 - 109 - 110 - 111 - 112 - 113 - 114 - 115 - 116 - 117 - 118 - 119 - 120 - 121 - 122 - 123 - 124 - 125 - 126 - 127 - 128 - 129 - 130 - 131 - 132 - 133 - 134 - 135 - 136 - 137 - 138 - 139 - 140 - 141 - 142 - 143 - 144 - 145 - 146 - 147 - 148 - 149 - 150 - 151 - 152 - 153 - 154 - 155 - 156 - 157 - 158 - 159 - 160 - 101 + { 102 + "id":"0013", 103 + "name":"Marion Musterfrau", 104 + "key":{ 105 + "id":"DF9876543210", 106 + "valid_from":"2016-01-01 00:00:00", 107 + "valid_to":null 108 + }, 109 + "card_nr":null, 110 + "groups":[ 111 + "Fahrer", 112 + "Berlin" 113 + ], 114 + "deleted":null, 115 + "drv_licence":{ 116 + "id":"asd09472845", 117 + "valid_to":"2017-02-24 23:59:59" 118 + }, 119 + "identity_card":{ 120 + "id":"hal2001", 121 + "valid_to":"2017-01-11 23:59:59" 122 + }, 123 + "passport":{ 124 + "id":null, 125 + "valid_to":null 126 + }, 127 + "adr_certificate":{ 128 + "id":null, 129 + "valid_to":"2019-05-23 23:59:59" 130 + }, 131 + "bkfqg":{ 132 + "valid_to":null 133 + }, 134 + "birthdate":"1998-05-13 00:00:00", 135 + "job_start_date":"2016-09-01 00:00:00" 136 + }, 137 + { 138 + "id":"0014", 139 + "name":"Patrick Berger", 140 + "key":{ 141 + "id":"00047392", 142 + "valid_from":"2017-07-05 13:20:00", 143 + "valid_to":null 144 + }, 145 + "card_nr":"7937102", 146 + "groups":[ 147 + "B\u00fcro", 148 + "Berlin" 149 + ], 150 + "deleted":null, 151 + "drv_licence":{ 152 + "id":jvg7820185", 153 + "valid_to":"2014-07-18 23:59:59" 154 + }, 155 + "identity_card":{ 156 + "id":"ppa4711", 157 + "valid_to":"2014-07-19 23:59:59" 158 + }, 159 + "passport":{ 160 + "id":null, 161 + "valid_to":null 162 + }, 163 + "adr_certificate":{ 164 + "id":null, 165 + "valid_to":null 166 + }, 167 + "bkfqg":{ 168 + "valid_to":"2019-07-18 25:59:59" 169 + }, 170 + "birthdate":"1996-07-17 00:00:00", 171 + "job_start_date":"2014-07-17 00:00:00", 172 + "drv_licence_check": { 161 161 "tag_id": "4729000A3341", 162 162 "last_check": "2020-03-01 10:43:00", 163 163 "next_check": "2019-03-15", 164 164 "interval": 1209600 165 165 } 166 - 178 + } 167 167 ]{{/code}} 168 168 169 169 = XML Format = 182 + 170 170 Return an xml formatted string with main key "<persons>" and data for each single person then grouped in a "<person>" object. Some data such as personnel key or personnel groups are grouped in a sub object. 184 + 171 171 === Beispiel === 186 + 172 172 **example** 173 173 {{code language="xml"}}<?xml version="1.0"?> 174 174 <persons> ... ... @@ -185,7 +185,7 @@ 185 185 <group>Fahrer</group> 186 186 <group>Dresden</group> 187 187 </groups> 188 - 203 + <deleted/> 189 189 <drv_licence> 190 190 <id>asd09472845</id> 191 191 <valid_to>2020-04-23 23:59:59</valid_to> ... ... @@ -221,7 +221,7 @@ 221 221 <group>Fahrer</group> 222 222 <group>Berlin</group> 223 223 </groups> 224 - 239 + <deleted/> 225 225 <drv_licence> 226 226 <id>asd09472845</id> 227 227 <valid_to>2020-04-23 23:59:59</valid_to> ... ... @@ -243,7 +243,7 @@ 243 243 </bkfqg> 244 244 <birthdate/> 245 245 <job_start_date>2012-05-01 00:00:00</job_start_date> 246 - 261 + <drv_licence_check> 247 247 <tag_id>4729000A3341</tag_id> 248 248 <last_check>2020-03-01 10:43:00</last_check> 249 249 <next_check>2020-03-15</next_check> ... ... @@ -253,6 +253,7 @@ 253 253 </persons>{{/code}} 254 254 255 255 == Examples == 271 + 256 256 **Abfrage aller Personen im CSV Format** 257 257 {{code language="xml"}}https://map.yellowfox.de/rti/get_personnel.php?company=COMPANY_RTIKEY&import=IMPORT_RTIKEY&format=csv{{/code}} 258 258