feat: additional confirmation cycle and status for groups inquiries
This commit is contained in:
@@ -94,6 +94,14 @@ class AccommodationBooking implements BlameableEntityInterface, TimestampableEnt
|
||||
#[ORM\Column(type: Types::DATETIME_IMMUTABLE, nullable: true)]
|
||||
private ?\DateTimeImmutable $acceptedAt = null;
|
||||
|
||||
/**
|
||||
* When the office validated the requested services and capacities and released the
|
||||
* booking confirmation to the customer — deliberately distinct from acceptedAt, which
|
||||
* only records that the customer committed.
|
||||
*/
|
||||
#[ORM\Column(type: Types::DATETIME_IMMUTABLE, nullable: true)]
|
||||
private ?\DateTimeImmutable $confirmedAt = null;
|
||||
|
||||
#[ORM\Column(length: 255, nullable: true)]
|
||||
#[Assert\NotBlank(groups: ['edit'])]
|
||||
private ?string $groupName = null;
|
||||
@@ -373,9 +381,14 @@ class AccommodationBooking implements BlameableEntityInterface, TimestampableEnt
|
||||
return AccommodationBookingStatus::Open === $this->status;
|
||||
}
|
||||
|
||||
public function isAccepted(): bool
|
||||
public function isReceived(): bool
|
||||
{
|
||||
return AccommodationBookingStatus::Accepted === $this->status;
|
||||
return AccommodationBookingStatus::Received === $this->status;
|
||||
}
|
||||
|
||||
public function isConfirmed(): bool
|
||||
{
|
||||
return AccommodationBookingStatus::Confirmed === $this->status;
|
||||
}
|
||||
|
||||
public function isDiscarded(): bool
|
||||
@@ -429,6 +442,18 @@ class AccommodationBooking implements BlameableEntityInterface, TimestampableEnt
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getConfirmedAt(): ?\DateTimeImmutable
|
||||
{
|
||||
return $this->confirmedAt;
|
||||
}
|
||||
|
||||
public function setConfirmedAt(?\DateTimeImmutable $confirmedAt): self
|
||||
{
|
||||
$this->confirmedAt = $confirmedAt;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getGroupName(): ?string
|
||||
{
|
||||
return $this->groupName;
|
||||
|
||||
Reference in New Issue
Block a user