⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.19
Server IP:
178.33.27.10
Server:
Linux cpanel.dev-unit.com 3.10.0-1160.108.1.el7.x86_64 #1 SMP Thu Jan 25 16:17:31 UTC 2024 x86_64
Server Software:
Apache/2.4.57 (Unix) OpenSSL/1.0.2k-fips
PHP Version:
8.2.11
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
id
/
crm.dev-unit.com
/
app
/
Models
/
View File Name :
Setting.php
<?php namespace App\Models; use Barryvdh\LaravelIdeHelper\Eloquent; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Carbon; use Spatie\MediaLibrary\HasMedia; use Spatie\MediaLibrary\InteractsWithMedia; /** * App\Models\Setting * * @property int $id * @property string $key * @property string|null $value * @property int $group * @property Carbon|null $created_at * @property Carbon|null $updated_at * @property-read int|null $media_count * * @method static Builder|Setting newModelQuery() * @method static Builder|Setting newQuery() * @method static Builder|Setting query() * @method static Builder|Setting whereCreatedAt($value) * @method static Builder|Setting whereGroup($value) * @method static Builder|Setting whereId($value) * @method static Builder|Setting whereKey($value) * @method static Builder|Setting whereUpdatedAt($value) * @method static Builder|Setting whereValue($value) * @mixin Eloquent */ class Setting extends Model implements HasMedia { use InteractsWithMedia; public const PATH = 'settings'; public const FAVICON = 'settings/favicon'; const GROUP_GENERAL = 1; const COMPANY_INFORMATION = 2; const NOTE = 3; const GROUP_ARRAY = [ 'general' => self::GROUP_GENERAL, 'company_information' => self::COMPANY_INFORMATION, 'note' => self::NOTE, ]; const CURRENCIES = [ 'eur' => 'Euro (EUR)', 'aud' => 'Australia Dollar (AUD)', 'inr' => 'India Rupee (INR)', 'usd' => 'USA Dollar (USD)', 'jpy' => 'Japanese Yen (JPY)', 'gbp' => 'British Pound (GBP)', 'cad' => 'Canadian Dollar (CAD)', ]; /** * Validation rules * * @var array */ public static $rules = [ 'group' => 'required|integer', ]; /** * @var string */ protected $table = 'settings'; /** * @var string[] */ protected $fillable = [ 'key', 'value', ]; /** * The attributes that should be casted to native types. * * @var array */ protected $casts = [ 'id' => 'integer', 'key' => 'string', 'value' => 'string', ]; }