diff --git a/CHANGELOG.md b/CHANGELOG.md index 9631bd5..7b4eff4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -41,6 +41,8 @@ Ajouter dans le fichier .env du frontend * [#256] Créer une nouvelle réception (étape 3 - bovin) * [#314] Création d'une page d'administration : listing des utilisateurs * [#313] Admin modification creation fournisseur +* [#275] Lister les expéditions en attente +* [#276] Lister les expéditions terminées ### Changed diff --git a/frontend/pages/index.vue b/frontend/pages/index.vue index 52d3da7..67079c2 100644 --- a/frontend/pages/index.vue +++ b/frontend/pages/index.vue @@ -6,10 +6,10 @@ - + - + diff --git a/frontend/pages/shipment/finish-shipment.vue b/frontend/pages/shipment/finish-shipment.vue new file mode 100644 index 0000000..59c340b --- /dev/null +++ b/frontend/pages/shipment/finish-shipment.vue @@ -0,0 +1,81 @@ + + + diff --git a/frontend/pages/shipment/waiting-shipment.vue b/frontend/pages/shipment/waiting-shipment.vue new file mode 100644 index 0000000..4a35459 --- /dev/null +++ b/frontend/pages/shipment/waiting-shipment.vue @@ -0,0 +1,73 @@ + + + diff --git a/frontend/services/dto/shipment-data.ts b/frontend/services/dto/shipment-data.ts index a78016a..8a5dbfd 100644 --- a/frontend/services/dto/shipment-data.ts +++ b/frontend/services/dto/shipment-data.ts @@ -1,6 +1,7 @@ import type {CarrierData} from '~/services/dto/carrier-data' import type {TruckData} from '~/services/dto/truck-data' import type {CustomerData} from '~/services/dto/customer-data' +import type {AddressData} from "~/services/dto/address-data"; export interface ShipmentTypeData { id: number @@ -21,6 +22,7 @@ export type ShipmentData = { shipmentDate: string currentStep: number isValid: boolean + address?: AddressData | null carrier?: CarrierData | null truck?: TruckData | null customer?: CustomerData | null diff --git a/src/Entity/Shipment.php b/src/Entity/Shipment.php index 8bcaed4..91b6f4e 100644 --- a/src/Entity/Shipment.php +++ b/src/Entity/Shipment.php @@ -4,6 +4,8 @@ declare(strict_types=1); namespace App\Entity; +use ApiPlatform\Doctrine\Orm\Filter\BooleanFilter; +use ApiPlatform\Metadata\ApiFilter; use ApiPlatform\Metadata\ApiProperty; use ApiPlatform\Metadata\ApiResource; use ApiPlatform\Metadata\Get; @@ -26,6 +28,7 @@ use Symfony\Component\Serializer\Normalizer\DateTimeNormalizer; #[ORM\Entity] #[ORM\HasLifecycleCallbacks] #[ORM\Table(name: 'shipment')] +#[ApiFilter(BooleanFilter::class, properties: ['isValid'])] #[ApiResource( operations: [ new Get(