<?php

namespace App\Models\Partner;

use Illuminate\Database\Eloquent\Model;

class PartnerBeautyUser extends Model
{


    protected $table = "partner_beauty_users";


    protected $dateFormat = "U";


    protected $fillable = ['id', 'partner_id', 'uid', 'field', 'original_photo', 'new_photo', 'replaced_at'];


    protected $appends = [
        'is_replace',
    ];

    protected $casts = [
        'is_beauty' => 'boolean',
        'is_replace' => 'boolean'
    ];


    public function getIsReplaceAttribute()
    {
        return $this->replaced_at ? true : false;
    }
}
