HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers10/lmbm.komma.pro/app/KommaApp/Shop/Properties/Models/PropertyKey.php
<?php


namespace App\KommaApp\Shop\Properties\Models;


use App\KommaApp\Kms\Core\AbstractTranslatableModel;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Database\Eloquent\Relations\HasOne;

/**
 * Class PropertyKey
 *
 * @property-read integer $id
 * 
 * Represents a property key that could be for example represent "color".
 * It does not represent the value that could for example be "green".
 * The translations associated to it would be in the case of "color",
 * the translations for the word "color" in multiple languages.
 * @package App\KommaApp\Shop\Properties\Models
 * @property \Carbon\Carbon|null $created_at
 * @property \Carbon\Carbon|null $updated_at
 * @property-read \App\KommaApp\Shop\Properties\Models\Property $property
 * @property-read \App\KommaApp\Shop\Properties\Models\PropertyKeyTranslation $translation
 * @property-read \Illuminate\Database\Eloquent\Collection|\App\KommaApp\Shop\Properties\Models\PropertyKeyTranslation[] $translations
 * @method static \Illuminate\Database\Eloquent\Builder|\App\KommaApp\Shop\Properties\Models\PropertyKey whereCreatedAt($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\KommaApp\Shop\Properties\Models\PropertyKey whereId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\KommaApp\Shop\Properties\Models\PropertyKey whereUpdatedAt($value)
 * @mixin \Eloquent
 */
class PropertyKey extends AbstractTranslatableModel
{
    /*
    * Transient properties on Eloquent models
    * These are not saved to database.
    */
    public $thumbnail = false;

    /**
     * Gets the translation models for this model
     *
     * @return HasMany that resolves to AbstractTranslationModel instances
     */
    public function translations(): HasMany
    {
        return $this->hasMany(PropertyKeyTranslation::class);
    }


    public function property(): HasOne
    {
        return $this->HasOne(Property::class);
    }
}