51 lines
1.2 KiB
PHP
51 lines
1.2 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Modules\Dashboard\Application\Contracts;
|
|
|
|
/**
|
|
* What the management panel needs from Billing, Sales, Users, Machines,
|
|
* Inventory and the holiday calendar. Days are Y-m-d.
|
|
*/
|
|
interface DashboardAdmin
|
|
{
|
|
/**
|
|
* The billing material draft being prepared, if there is one.
|
|
*/
|
|
public function openDraftId(): ?int;
|
|
|
|
/**
|
|
* Days before the day with quick sales whose cash day is not closed.
|
|
*
|
|
* @return list<string>
|
|
*/
|
|
public function unclosedCashDaysBefore(string $day): array;
|
|
|
|
/**
|
|
* Active users who do the work, subcontractors left out, by name.
|
|
*
|
|
* @return array<int, string>
|
|
*/
|
|
public function staff(): array;
|
|
|
|
/**
|
|
* Public holidays in use and company days off between the days.
|
|
*
|
|
* @return list<string>
|
|
*/
|
|
public function holidaysBetween(string $from, string $to): array;
|
|
|
|
/**
|
|
* Machine maintenance that is late (maintenance requests), by machine.
|
|
*
|
|
* @return list<array{machineId: int, machine: string, item: string}>
|
|
*/
|
|
public function lateMaintenance(): array;
|
|
|
|
/**
|
|
* How many stock items are at or below their reorder level.
|
|
*/
|
|
public function stockItemsToOrder(): int;
|
|
}
|