<?php

namespace Modules\Mall\Models;

use App\Models\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Modules\Mall\Models\Traits\BelongsToOrder;
use Modules\Mall\Models\Traits\BelongsToRefund;

class RefundItem extends Model
{

    use BelongsToOrder,
        BelongsToRefund;

    const UPDATED_AT = null;

    protected $table = 'mall_refund_items';

    public    $casts = [
        'source' => 'json',
    ];

    /**
     * Notes: 关联order_item
     * @Author: 玄尘
     * @Date  : 2021/5/19 9:50
     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
     */
    public function order_item(): BelongsTo
    {
        return $this->belongsTo(OrderItem::class);
    }

}
