feat(pos): add editable showcase creation date for kits

- Add showcase_created_at field to ProductKit model
- Display days ago as badge in product card (0 дней, 1 день, etc.)
- Add date input field in edit modal
- Auto-set current date/time for new showcase kits

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-01-24 01:37:27 +03:00
parent fce8d9eb6e
commit 977ee91fee
6 changed files with 184 additions and 42 deletions

View File

@@ -93,6 +93,14 @@ class ProductKit(BaseProductEntity):
help_text="Временные комплекты не показываются в каталоге и создаются для конкретного заказа"
)
# Showcase creation date - editable date for when the bouquet was put on display
showcase_created_at = models.DateTimeField(
null=True,
blank=True,
verbose_name="Дата размещения на витрине",
help_text="Дата создания букета для витрины (редактируемая)"
)
order = models.ForeignKey(
'orders.Order',
on_delete=models.SET_NULL,