33 lines
649 B
PHP
33 lines
649 B
PHP
|
|
<?php
|
|||
|
|
|
|||
|
|
namespace App\Models\business;
|
|||
|
|
|
|||
|
|
use App\BaseApp\BaseBusinessModel;
|
|||
|
|
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
|||
|
|
|
|||
|
|
/**
|
|||
|
|
* 售后申请(cc_after_sale)
|
|||
|
|
*/
|
|||
|
|
class AfterSaleModel extends BaseBusinessModel
|
|||
|
|
{
|
|||
|
|
protected $table = 'after_sale';
|
|||
|
|
|
|||
|
|
protected $guarded = [];
|
|||
|
|
|
|||
|
|
public const STATUS_PENDING = 0;
|
|||
|
|
|
|||
|
|
public const STATUS_APPROVED = 1;
|
|||
|
|
|
|||
|
|
public const STATUS_REJECTED = 2;
|
|||
|
|
|
|||
|
|
public function order(): BelongsTo
|
|||
|
|
{
|
|||
|
|
return $this->belongsTo(OrderModel::class, 'order_id', 'id');
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
public function user(): BelongsTo
|
|||
|
|
{
|
|||
|
|
return $this->belongsTo(WxUserModel::class, 'user_id', 'id');
|
|||
|
|
}
|
|||
|
|
}
|