관리-도구
편집 파일: PiercingPrice.php
<?php namespace App; use Illuminate\Database\Eloquent\Model; use Laraveldaily\Quickadmin\Observers\UserActionsObserver; use Illuminate\Database\Eloquent\SoftDeletes; class PiercingPrice extends Model { use SoftDeletes; /** * The attributes that should be mutated to dates. * * @var array */ protected $dates = ['deleted_at']; protected $table = 'piercing_price'; protected $fillable = [ 'name', 'price', 'intervals', 'picture', 'coef', 'piercingcatalog_id', 'body', 'showhide', 'type' ]; public static $showhide = ["show" => "show", "hide" => "hide",]; public static function boot() { parent::boot(); PiercingCatalog::observe(new UserActionsObserver); } public function catalog() { return $this->belongsTo('App\PiercingCatalog', 'piercingcatalog_id'); } }