WebVIEP Plugin

ContactRequest

FinalYes

Aggregate representing a contact request sent to a booth or booth item owner.

Table of Contents

Properties

$boothId  : BoothId
$boothItemId  : BoothItemId|null
$consentGiven  : bool
$createdAt  : DateTimeImmutable
$fromEmail  : string
$fromName  : string
$id  : ContactRequestId
$message  : string
$senderUserId  : WebviepUserId|null
$status  : ContactRequestStatus

Methods

archive()  : void
Archive the request.
boothId()  : BoothId
Target booth identifier.
boothItemId()  : BoothItemId|null
Target booth item identifier (optional).
consentGiven()  : bool
Whether the sender gave consent (e.g. GDPR).
createdAt()  : DateTimeImmutable
Creation timestamp.
createNew()  : self
Factory for new contact requests (sets createdAt/status automatically).
fromEmail()  : string
Sender email address.
fromExisting()  : self
Rehydrate an existing contact request.
fromName()  : string
Sender display name.
id()  : ContactRequestId
Identifier of the contact request.
markAsDelivered()  : void
Mark the request as delivered.
markAsRead()  : void
Mark the request as read.
message()  : string
Message body.
senderUserId()  : WebviepUserId|null
Optional sender user id.
status()  : ContactRequestStatus
Current contact request status.
__construct()  : mixed
ContactRequest constructor.

Properties

Methods

consentGiven()

Whether the sender gave consent (e.g. GDPR).

public consentGiven() : bool
Return values
bool

createdAt()

Creation timestamp.

public createdAt() : DateTimeImmutable
Return values
DateTimeImmutable

createNew()

Factory for new contact requests (sets createdAt/status automatically).

public static createNew(ContactRequestId $id, BoothId $boothId, BoothItemId|null $boothItemId, string $fromName, string $fromEmail, string $message, WebviepUserId|null $senderUserId, bool $consentGiven[, DateTimeImmutable|null $createdAt = null ]) : self
Parameters
$id : ContactRequestId
$boothId : BoothId
$boothItemId : BoothItemId|null
$fromName : string
$fromEmail : string
$message : string
$senderUserId : WebviepUserId|null
$consentGiven : bool
$createdAt : DateTimeImmutable|null = null
Return values
self

fromEmail()

Sender email address.

public fromEmail() : string
Return values
string

fromExisting()

Rehydrate an existing contact request.

public static fromExisting(ContactRequestId $id, BoothId $boothId, BoothItemId|null $boothItemId, string $fromName, string $fromEmail, string $message, WebviepUserId|null $senderUserId, DateTimeImmutable $createdAt, ContactRequestStatus $status, bool $consentGiven) : self
Parameters
$id : ContactRequestId
$boothId : BoothId
$boothItemId : BoothItemId|null
$fromName : string
$fromEmail : string
$message : string
$senderUserId : WebviepUserId|null
$createdAt : DateTimeImmutable
$status : ContactRequestStatus
$consentGiven : bool
Return values
self

fromName()

Sender display name.

public fromName() : string
Return values
string

markAsDelivered()

Mark the request as delivered.

public markAsDelivered() : void

markAsRead()

Mark the request as read.

public markAsRead() : void

message()

Message body.

public message() : string
Return values
string

__construct()

ContactRequest constructor.

private __construct(ContactRequestId $id, BoothId $boothId, BoothItemId|null $boothItemId, string $fromName, string $fromEmail, string $message, WebviepUserId|null $senderUserId, DateTimeImmutable $createdAt, ContactRequestStatus $status, bool $consentGiven) : mixed
Parameters
$id : ContactRequestId
$boothId : BoothId
$boothItemId : BoothItemId|null
$fromName : string
$fromEmail : string
$message : string
$senderUserId : WebviepUserId|null
$createdAt : DateTimeImmutable
$status : ContactRequestStatus
$consentGiven : bool

        
On this page

Search results