31 lines
743 B
PHP
31 lines
743 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Modules\Machines\Application\DTOs;
|
|
|
|
/**
|
|
* A row of a machine's work list: a task (with its details) or a step of
|
|
* a quick sale order line. $plannedOn is Y-m-d; a late row was planned on
|
|
* an earlier day and is still open.
|
|
*/
|
|
final readonly class QueueRow
|
|
{
|
|
public function __construct(
|
|
public int $entryId,
|
|
public int $machineId,
|
|
public string $plannedOn,
|
|
public int $position,
|
|
public bool $isLate,
|
|
public ?int $taskId,
|
|
public ?int $orderLineId,
|
|
public ?int $stepPosition,
|
|
public ?MachineTaskInfo $task = null,
|
|
) {}
|
|
|
|
public function isOrder(): bool
|
|
{
|
|
return $this->orderLineId !== null;
|
|
}
|
|
}
|