Email quick sale receipts and send them again from the sales list

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
This commit is contained in:
2026-11-26 16:00:15 +02:00
co-authored by Claude Sonnet 5.5
parent 3faa4cfbc6
commit d160854b79
29 changed files with 679 additions and 34 deletions
@@ -5,6 +5,7 @@ declare(strict_types=1);
namespace App\Modules\Sales\Domain\Contracts;
use App\Modules\Sales\Domain\Entities\QuickSale;
use App\Modules\Shared\Domain\ValueObjects\EmailAddress;
use DateTimeImmutable;
interface QuickSaleRepository
@@ -24,4 +25,14 @@ interface QuickSaleRepository
* @return list<QuickSale>
*/
public function forDay(DateTimeImmutable $day): array;
/**
* Sets the address the receipt is emailed to and clears the earlier
* sending result, before the receipt is sent again.
*/
public function changeReceiptEmail(int $saleId, EmailAddress $email): void;
public function markReceiptSent(int $saleId, DateTimeImmutable $at): void;
public function markReceiptFailed(int $saleId, DateTimeImmutable $at): void;
}