Documentation

Job
in package
implements ResourceInterface uses IdentifiableTrait, TimestampableTrait, ApprovableTrait, UpdateProposableTrait

Job model.

Tags
psalm-import-type

JobLabelArrayType from JobLabel as ImportedJobLabelArrayType

Attributes
#[Entity]
#[HasLifecycleCallbacks]

Table of Contents

Interfaces

ResourceInterface

Properties

$approvableText  : ApprovableText|null
When the entity has been approved/rejected a message can be attached. Since we do not always need this message it has been replaced with another entity which we can EXTRA_LAZY load to ensure it is not always included.
$approved  : ApprovableStatus
State of the approval.
$approvedAt  : DateTime|null
The date when the entity was approved.
$approver  : Member|null
Who (dis)approved the entity using this trait?
$attachment  : CompanyLocalisedText
The location(url) of an attachment describing the job.
$category  : JobCategory
The job's category.
$contactEmail  : string|null
The job's email.
$contactName  : string|null
The job's contact's name.
$contactPhone  : string|null
The job's phone.
$createdAt  : DateTime
The date at which the entity was created.
$description  : CompanyLocalisedText
The job's description.
$id  : int|null
The default value must be `null` to prevent issues with auto generating the value. The column is strictly not nullable.
$isUpdate  : bool
Whether this entity is a proposed update for another entity.
$labels  : Collection<string|int, JobLabel>
Job labels.
$location  : CompanyLocalisedText
The job's location.
$name  : CompanyLocalisedText
The job's display name.
$package  : CompanyJobPackage
The job's package.
$published  : bool
The job's status.
$slugName  : string
The job's slug name.
$updatedAt  : DateTime
The date at which the entity was updated.
$updateProposals  : Collection<string|int, JobUpdate>
Proposed updates to this job.
$website  : CompanyLocalisedText
The job's website.

Methods

__construct()  : mixed
addLabel()  : void
addLabels()  : void
getApprovableText()  : ApprovableText|null
getApproved()  : ApprovableStatus
getApprovedAt()  : DateTime|null
getApprover()  : Member|null
getAttachment()  : CompanyLocalisedText
Get the job's attachment.
getCategory()  : JobCategory
Get the job's category.
getCompany()  : Company
Get the job's company.
getContactEmail()  : string|null
Get the job's contact's email.
getContactName()  : string|null
Get the job's contact's name.
getContactPhone()  : string|null
Get the job's contact's phone.
getCreatedAt()  : DateTime
getDescription()  : CompanyLocalisedText
Get the job's description.
getId()  : int|null
Get the identifier of the object.
getIsUpdate()  : bool
Get whether this is a proposed update.
getLabels()  : Collection<string|int, JobLabel>
Get the labels. Returns an array of JobLabelAssignments.
getLocation()  : CompanyLocalisedText
Returns the job's location.
getName()  : CompanyLocalisedText
Get the job's name.
getPackage()  : CompanyJobPackage
Get the job's package.
getResourceId()  : string
getSlugName()  : string
Get the job's slug name.
getUpdatedAt()  : DateTime
getUpdateProposals()  : Collection<string|int, JobUpdate>
getWebsite()  : CompanyLocalisedText
Get the job's website.
isActive()  : bool
isApproved()  : bool
isPublished()  : bool
Get the job's status.
isUpdate()  : bool
Get whether this is a proposed update.
prePersist()  : void
Automatically fill in the `DateTime`s before the initial call to `persist()`.
preUpdate()  : void
Automatically update the `updatedAt` `DateTime` when doing an update to the entity.
removeLabel()  : void
removeLabels()  : void
setApprovableText()  : void
setApproved()  : void
setApprovedAt()  : void
setApprover()  : void
setAttachment()  : void
Set the job's attachment.
setCategory()  : void
Set the job's category.
setContactEmail()  : void
Set the job's contact's email.
setContactName()  : void
Set the job's contact's name.
setContactPhone()  : void
Set the job's contact's phone.
setDescription()  : void
Set the job's description.
setId()  : void
Setting the identifier manually will, in most instances, result in undefined behaviour. Use with caution!
setIsUpdate()  : void
Set whether this is a proposed update.
setLocation()  : void
Sets the job's location.
setName()  : void
Set the job's name.
setPackage()  : void
setPublished()  : void
Set the job's status.
setSlugName()  : void
Set the job's slug name.
setWebsite()  : void
Set the job's website.
toArray()  : ImportedJobLabelArrayType[]}
toGdprArray()  : ApprovableTraitGdprArrayType
setCreatedAt()  : void
setUpdatedAt()  : void

Properties

$approvableText

When the entity has been approved/rejected a message can be attached. Since we do not always need this message it has been replaced with another entity which we can EXTRA_LAZY load to ensure it is not always included.

protected ApprovableText|null $approvableText = null
Attributes
#[JoinColumn]
$name: 'approvableText_id'
$referencedColumnName: 'id'
$nullable: true
#[OneToOne]
$targetEntity: \Application\Model\ApprovableText::class
$cascade: ['persist', 'remove']
$fetch: 'EXTRA_LAZY'
$orphanRemoval: true

$approved

State of the approval.

protected ApprovableStatus $approved
Attributes
#[Column]
$type: 'integer'
$enumType: \Application\Model\Enums\ApprovableStatus::class

$approvedAt

The date when the entity was approved.

protected DateTime|null $approvedAt = null
Attributes
#[Column]
$type: 'datetime'
$nullable: true

$approver

Who (dis)approved the entity using this trait?

protected Member|null $approver = null
Attributes
#[JoinColumn]
$referencedColumnName: 'lidnr'
#[ManyToOne]
$targetEntity: \Decision\Model\Member::class

$attachment

The location(url) of an attachment describing the job.

protected CompanyLocalisedText $attachment
Attributes
#[JoinColumn]
$name: 'attachment_id'
$referencedColumnName: 'id'
$nullable: false
#[OneToOne]
$targetEntity: \Company\Model\CompanyLocalisedText::class
$cascade: ['persist', 'remove']
$orphanRemoval: true

$category

The job's category.

protected JobCategory $category
Attributes
#[JoinColumn]
$name: 'category_id'
$referencedColumnName: 'id'
$nullable: false
#[ManyToOne]
$targetEntity: \Company\Model\JobCategory::class

$contactEmail

The job's email.

protected string|null $contactEmail
Attributes
#[Column]
$type: 'string'
$nullable: true

$contactName

The job's contact's name.

protected string|null $contactName
Attributes
#[Column]
$type: 'string'
$nullable: true

$contactPhone

The job's phone.

protected string|null $contactPhone
Attributes
#[Column]
$type: 'string'
$nullable: true

$createdAt

The date at which the entity was created.

protected DateTime $createdAt
Attributes
#[Column]
$type: 'datetime'

$description

The job's description.

protected CompanyLocalisedText $description
Attributes
#[JoinColumn]
$name: 'description_id'
$referencedColumnName: 'id'
$nullable: false
#[OneToOne]
$targetEntity: \Company\Model\CompanyLocalisedText::class
$cascade: ['persist', 'remove']
$orphanRemoval: true

$id

The default value must be `null` to prevent issues with auto generating the value. The column is strictly not nullable.

protected int|null $id = null
Attributes
#[Column]
$type: 'integer'
#[GeneratedValue]
$strategy: 'IDENTITY'
#[Id]

$isUpdate

Whether this entity is a proposed update for another entity.

protected bool $isUpdate = false
Attributes
#[Column]
$type: 'boolean'

$labels

Job labels.

protected Collection<string|int, JobLabel> $labels
Attributes
#[JoinTable]
$name: 'JobLabelAssignment'
#[ManyToMany]
$targetEntity: \Company\Model\JobLabel::class
$inversedBy: 'jobs'
$cascade: ['persist']

$location

The job's location.

protected CompanyLocalisedText $location
Attributes
#[JoinColumn]
$name: 'location_id'
$referencedColumnName: 'id'
$nullable: false
#[OneToOne]
$targetEntity: \Company\Model\CompanyLocalisedText::class
$cascade: ['persist', 'remove']
$orphanRemoval: true

$name

The job's display name.

protected CompanyLocalisedText $name
Attributes
#[JoinColumn]
$name: 'name_id'
$referencedColumnName: 'id'
$nullable: false
#[OneToOne]
$targetEntity: \Company\Model\CompanyLocalisedText::class
$cascade: ['persist', 'remove']
$orphanRemoval: true

$package

The job's package.

protected CompanyJobPackage $package
Attributes
#[JoinColumn]
$name: 'package_id'
$referencedColumnName: 'id'
$nullable: false
#[ManyToOne]
$targetEntity: \Company\Model\CompanyJobPackage::class
$inversedBy: 'jobs'

$published

The job's status.

protected bool $published
Attributes
#[Column]
$type: 'boolean'

$slugName

The job's slug name.

protected string $slugName
Attributes
#[Column]
$type: 'string'

$updatedAt

The date at which the entity was updated.

protected DateTime $updatedAt
Attributes
#[Column]
$type: 'datetime'

$updateProposals

Proposed updates to this job.

protected Collection<string|int, JobUpdate> $updateProposals
Attributes
#[OneToMany]
$targetEntity: \Company\Model\Proposals\JobUpdate::class
$mappedBy: 'original'
$cascade: ['persist', 'remove']
$orphanRemoval: true
$fetch: 'EXTRA_LAZY'

$website

The job's website.

protected CompanyLocalisedText $website
Attributes
#[JoinColumn]
$name: 'website_id'
$referencedColumnName: 'id'
$nullable: false
#[OneToOne]
$targetEntity: \Company\Model\CompanyLocalisedText::class
$cascade: ['persist', 'remove']
$orphanRemoval: true

Methods

__construct()

public __construct() : mixed

addLabels()

public addLabels(array<string|int, JobLabel$labels) : void
Parameters
$labels : array<string|int, JobLabel>

getApprovedAt()

public getApprovedAt() : DateTime|null
Return values
DateTime|null

getContactEmail()

Get the job's contact's email.

public getContactEmail() : string|null
Return values
string|null

getContactName()

Get the job's contact's name.

public getContactName() : string|null
Return values
string|null

getContactPhone()

Get the job's contact's phone.

public getContactPhone() : string|null
Return values
string|null

getId()

Get the identifier of the object.

public getId() : int|null
Tags
psalm-ignore-nullable-return
Return values
int|null

getIsUpdate()

Get whether this is a proposed update.

public getIsUpdate() : bool
Return values
bool

getLabels()

Get the labels. Returns an array of JobLabelAssignments.

public getLabels() : Collection<string|int, JobLabel>
Return values
Collection<string|int, JobLabel>

getLocation()

Returns the job's location.

public getLocation() : CompanyLocalisedText

The location property specifies for which location (i.e. city or country) this job is intended. This location may not be equal to the company's address.

Return values
CompanyLocalisedText

getResourceId()

public getResourceId() : string
Return values
string

getSlugName()

Get the job's slug name.

public getSlugName() : string
Return values
string

the Jobs slug name

getUpdateProposals()

public getUpdateProposals() : Collection<string|int, JobUpdate>
Return values
Collection<string|int, JobUpdate>

isActive()

public isActive() : bool
Return values
bool

isPublished()

Get the job's status.

public isPublished() : bool
Return values
bool

isUpdate()

Get whether this is a proposed update.

public isUpdate() : bool
Return values
bool

prePersist()

Automatically fill in the `DateTime`s before the initial call to `persist()`.

public prePersist() : void
Attributes
#[PrePersist]

preUpdate()

Automatically update the `updatedAt` `DateTime` when doing an update to the entity.

public preUpdate() : void
Attributes
#[PreUpdate]

removeLabels()

public removeLabels(array<string|int, JobLabel$labels) : void
Parameters
$labels : array<string|int, JobLabel>

setApprovedAt()

public setApprovedAt(DateTime|null $approvedAt) : void
Parameters
$approvedAt : DateTime|null

setContactEmail()

Set the job's contact's email.

public setContactEmail(string|null $contactEmail) : void
Parameters
$contactEmail : string|null

setContactName()

Set the job's contact's name.

public setContactName(string|null $name) : void
Parameters
$name : string|null

setContactPhone()

Set the job's contact's phone.

public setContactPhone(string|null $contactPhone) : void
Parameters
$contactPhone : string|null

setId()

Setting the identifier manually will, in most instances, result in undefined behaviour. Use with caution!

public setId(int|null $id) : void
Parameters
$id : int|null

setIsUpdate()

Set whether this is a proposed update.

public setIsUpdate(bool $isUpdate) : void
Parameters
$isUpdate : bool

setPublished()

Set the job's status.

public setPublished(bool $published) : void
Parameters
$published : bool

setSlugName()

Set the job's slug name.

public setSlugName(string $name) : void
Parameters
$name : string

toArray()

public toArray() : ImportedJobLabelArrayType[]}
Return values
ImportedJobLabelArrayType[]}

toGdprArray()

public toGdprArray() : ApprovableTraitGdprArrayType
Return values
ApprovableTraitGdprArrayType

setCreatedAt()

private setCreatedAt(DateTime $createdAt) : void
Parameters
$createdAt : DateTime

setUpdatedAt()

private setUpdatedAt(DateTime $updatedAt) : void
Parameters
$updatedAt : DateTime

        
On this page

Search results