7187989003
Auto Tag Develop / tag (push) Successful in 12s
Le libellé sous le nom de l'employé affiche en suffixe les jours du planning workDaysHours au format court (ex. BUREAU — CDI — LU,JE) pour les contrats CUSTOM. Résolu à la date filtrée et exposé via WorkHourDayContext.workDaysHours ; formaté front par formatWorkedDaysShort. Limité aux CUSTOM (35h/39h/forfait/intérim sans planning → rien affiché) et à l'écran Heures (pas Heures Conducteurs). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
50 lines
1.2 KiB
PHP
50 lines
1.2 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\ApiResource;
|
|
|
|
use ApiPlatform\Metadata\ApiResource;
|
|
use ApiPlatform\Metadata\Get;
|
|
use App\State\WorkHourDayContextProvider;
|
|
|
|
#[ApiResource(
|
|
operations: [
|
|
new Get(
|
|
uriTemplate: '/work-hours/day-context',
|
|
security: "is_granted('ROLE_USER')",
|
|
provider: WorkHourDayContextProvider::class
|
|
),
|
|
],
|
|
paginationEnabled: false
|
|
)]
|
|
final class WorkHourDayContext
|
|
{
|
|
public string $workDate = '';
|
|
|
|
/**
|
|
* @var list<array{
|
|
* employeeId:int,
|
|
* hasContractAtDate:bool,
|
|
* absenceLabel:?string,
|
|
* absenceColor:?string,
|
|
* absenceHalf:?string,
|
|
* absentMorning:bool,
|
|
* absentAfternoon:bool,
|
|
* creditedMinutes:int,
|
|
* creditedPresenceUnits:float,
|
|
* isDriverContract:bool,
|
|
* hasFormation:bool,
|
|
* formationLabel:?string,
|
|
* virtualHolidayMinutes:int,
|
|
* contractNature:?string,
|
|
* trackingMode:?string,
|
|
* weeklyHours:?int,
|
|
* contractType:?string,
|
|
* contractName:?string,
|
|
* workDaysHours:?array<int, int>
|
|
* }>
|
|
*/
|
|
public array $rows = [];
|
|
}
|