CompanyText
extends CompanyText
in package
Translation of a company: public title, slogan, annotation and description.
Attributes
- #[Entity]
- #[Table]
- $name: 'cms_mod_company_company_texts'
- #[TableAlias]
- 'companyText'
Table of Contents
Properties
- $activeTranslation : bool
- $annotation : string|null
- $description : string|null
- $languageId : int|null
- $parent : mixed
- $slogan : string|null
- $title : string|null
Methods
- __construct() : mixed
- callInitMethods() : void
- Calls `init{TraitName}()` for every used trait that defines such a method.
- getActiveTranslation() : bool
- getAllTraits() : array<string, string>
- Returns all traits the class uses, including those used by parent classes and nested traits.
- getAnnotation() : string|null
- getDescription() : string|null
- getLanguageId() : int|null
- Translation language; null only for a new entity before `setLanguageId()`.
- getParent() : object|null
- getSlogan() : string|null
- getTitle() : string|null
- isActiveTranslation() : bool
- setActiveTranslation() : $this
- setAnnotation() : $this
- setDescription() : $this
- setLanguageId() : $this
- setParent() : static
- setSlogan() : $this
- setTitle() : $this
- getTraitsRecursive() : array<string, string>
- Walks the trait list recursively and collects nested traits too.
Properties
$activeTranslation
protected
bool
$activeTranslation
= true
Attributes
- #[Column]
- $name: 'active_translation'
- $type: 'boolean'
$annotation
protected
string|null
$annotation
= null
Attributes
- #[Column]
- $name: 'annotation'
- $type: 'text'
- $nullable: true
$description
protected
string|null
$description
= null
Attributes
- #[Column]
- $name: 'description'
- $type: 'text'
- $nullable: true
$languageId
protected
int|null
$languageId
= null
Attributes
- #[Column]
- $name: 'cms_system_languages_language_id'
- $type: 'integer'
- $options: ['unsigned' => true]
- #[Id]
- #[Identity]
$parent
protected
mixed
$parent
= null
Attributes
- #[Id]
- #[JoinColumn]
- $name: 'cms_mod_company_companies_company_id'
- $referencedColumnName: 'company_id'
- $onDelete: 'CASCADE'
- #[ManyToOne]
- $targetEntity: \App\UI\Api\Company\Models\Entities\Company::class
- $inversedBy: 'translations'
$slogan
protected
string|null
$slogan
= null
Attributes
- #[Column]
- $name: 'slogan'
- $type: 'string'
- $length: 255
- $nullable: true
$title
protected
string|null
$title
= null
Attributes
- #[Column]
- $name: 'title'
- $type: 'string'
- $length: 255
- $nullable: true
Methods
__construct()
public
__construct([int|null $languageId = null ][, string|null $title = null ][, string|null $slogan = null ][, string|null $annotation = null ][, string|null $description = null ][, bool $activeTranslation = true ]) : mixed
Parameters
- $languageId : int|null = null
- $title : string|null = null
- $slogan : string|null = null
- $annotation : string|null = null
- $description : string|null = null
- $activeTranslation : bool = true
callInitMethods()
Calls `init{TraitName}()` for every used trait that defines such a method.
public
callInitMethods() : void
getActiveTranslation()
public
getActiveTranslation() : bool
Return values
boolgetAllTraits()
Returns all traits the class uses, including those used by parent classes and nested traits.
public
getAllTraits() : array<string, string>
Return values
array<string, string>getAnnotation()
public
getAnnotation() : string|null
Return values
string|nullgetDescription()
public
getDescription() : string|null
Return values
string|nullgetLanguageId()
Translation language; null only for a new entity before `setLanguageId()`.
public
getLanguageId() : int|null
Return values
int|nullgetParent()
public
getParent() : object|null
Return values
object|nullgetSlogan()
public
getSlogan() : string|null
Return values
string|nullgetTitle()
public
getTitle() : string|null
Return values
string|nullisActiveTranslation()
public
isActiveTranslation() : bool
Return values
boolsetActiveTranslation()
public
setActiveTranslation(bool $activeTranslation) : $this
Parameters
- $activeTranslation : bool
Return values
$thissetAnnotation()
public
setAnnotation(string|null $annotation) : $this
Parameters
- $annotation : string|null
Return values
$thissetDescription()
public
setDescription(string|null $description) : $this
Parameters
- $description : string|null
Return values
$thissetLanguageId()
public
setLanguageId(int $languageId) : $this
Parameters
- $languageId : int
Return values
$thissetParent()
public
setParent(object|null $parent) : static
Parameters
- $parent : object|null
Return values
staticsetSlogan()
public
setSlogan(string|null $slogan) : $this
Parameters
- $slogan : string|null
Return values
$thissetTitle()
public
setTitle(string|null $title) : $this
Parameters
- $title : string|null
Return values
$thisgetTraitsRecursive()
Walks the trait list recursively and collects nested traits too.
private
static getTraitsRecursive(array<string, string> $traits) : array<string, string>
Parameters
- $traits : array<string, string>