dpeuscher / lib-absence-io
1.0.1
2018-07-01 16:30 UTC
Requires
- php: ^7.1
- dflydev/hawk: ^0.0.0
- dpeuscher/alfred-symfony-tools: ^2.0
Requires (Dev)
- phpunit/phpunit: ^7.2
This package is auto-updated.
Last update: 2024-09-18 19:46:14 UTC
README
lib-absence-io
一个库,用于通过成员识别特定团队规模下的团队容量
$absenceEndPoint = 'https://app.absence.io/api/v2/'; $absenceKey = '012345678901234567890123'; $absenceId = '0123456789012345678901234567890123456789012345678901234567890123'; $absenceService = new AbsenceService($absenceEndPoint, $absenceKey, $absenceId); $team = ["John Doe", "Johny Doey"]; $from = \DateTime::createFromFormat('Y-m-d', '2018-07-01'); $to = \DateTime::createFromFormat('Y-m-d', '2018-10-01'); var_dump($absenceService->calculateWorkdays($from, $to, 'München', $team));
结果看起来像这样
array(2) { 'Johny Doey' => int(46) 'John Doe' => int(55) }