From f05fcc5c151d0ba65cefbd391082ce214df35818 Mon Sep 17 00:00:00 2001 From: tristan Date: Fri, 24 Apr 2026 07:53:06 +0000 Subject: [PATCH] feat: inventaire bovins (!49) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit | Numéro du ticket | Titre du ticket | |------------------|-----------------| | | | ## Description de la PR ## Modification du .env ## Check list - [ ] Pas de régression - [ ] TU/TI/TF rédigée - [ ] TU/TI/TF OK - [ ] CHANGELOG modifié Reviewed-on: https://gitea.malio.fr/MALIO-DEV/Ferme/pulls/49 Co-authored-by: tristan Co-committed-by: tristan --- frontend/components/ui/UiDataTable.vue | 17 +- frontend/components/ui/UiDateMaskedInput.vue | 108 +++++++++ frontend/pages/index.vue | 4 +- frontend/pages/infrastructure/case.vue | 2 +- frontend/pages/inventory.vue | 217 ++++++++++++++++++ frontend/pages/reception/finish-reception.vue | 5 +- .../pages/reception/waiting-reception.vue | 4 +- frontend/pages/shipment/finish-shipment.vue | 2 +- frontend/pages/shipment/waiting-shipment.vue | 4 +- frontend/services/dto/bovine-data.ts | 14 +- frontend/utils/bovine-age.ts | 10 + migrations/Version20260422155300.php | 33 +++ migrations/Version20260423062250.php | 31 +++ migrations/Version20260424074454.php | 31 +++ src/ApiResource/BovineSyncInventoryResult.php | 42 ++++ src/Entity/Bovine.php | 90 +++++++- src/Entity/Building.php | 2 +- src/Entity/BuildingCase.php | 4 +- .../Bovin/BovineSyncInventoryProcessor.php | 105 +++++++++ 19 files changed, 704 insertions(+), 21 deletions(-) create mode 100644 frontend/components/ui/UiDateMaskedInput.vue create mode 100644 frontend/pages/inventory.vue create mode 100644 frontend/utils/bovine-age.ts create mode 100644 migrations/Version20260422155300.php create mode 100644 migrations/Version20260423062250.php create mode 100644 migrations/Version20260424074454.php create mode 100644 src/ApiResource/BovineSyncInventoryResult.php create mode 100644 src/State/Bovin/BovineSyncInventoryProcessor.php diff --git a/frontend/components/ui/UiDataTable.vue b/frontend/components/ui/UiDataTable.vue index e385879..b3a4eee 100644 --- a/frontend/components/ui/UiDataTable.vue +++ b/frontend/components/ui/UiDataTable.vue @@ -19,7 +19,10 @@ v-for="(item, index) in paginatedItems" :key="item.id ?? index" class="grid gap-6 px-4 py-3 text-sm border-t border-slate-200" - :class="rowClickable ? 'hover:bg-slate-50 cursor-pointer' : ''" + :class="[ + rowClickable ? 'hover:bg-slate-50 cursor-pointer' : '', + rowClass ? rowClass(item) : '' + ]" :style="{ gridTemplateColumns: gridCols }" :role="rowClickable ? 'button' : undefined" :tabindex="rowClickable ? 0 : undefined" @@ -83,12 +86,12 @@