Add project deadline cases

This commit is contained in:
2025-03-05 13:36:06 +01:00
parent cbb7234aa8
commit b83cbddee2
2 changed files with 26 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
<?php
namespace App\Dto;
enum ProjectDeadline: string
{
/**
* A single deadline means the Project will only remain in campaing
* for the minimum budget deadline.
*/
case Minimum = 'minimum';
/**
* A double deadline means the Project can remain in campaing
* past the minimum budget deadline until the optimum budget deadline,
* if it did raise the minimum in the first deadline.
*/
case Optimum = 'optimum';
}
+7
View File
@@ -52,6 +52,13 @@ class ProjectEditDto
#[Assert\NotBlank()]
public string $description;
/**
* Every campaign must raise the minimum before the minimum deadline.\
* Optionally, a Project can choose to remain in campaign for a second deadline
* if it did reach the minimum in the first place.
*/
public ProjectDeadline $deadlines = ProjectDeadline::Minimum;
/**
* A URL to a video showcasing the Project.
*/