weizong song 1 year ago
parent b5083cb336
commit 70017af4f8

@ -200,6 +200,11 @@ class Orders extends SoftDeletesModel
return $this->hasOneThrough(ParamedicLevel::class, ProductParamedicLevel::class, "id", "id", "product_paramedic_level_id", "paramedic_level_id");
}
public function wechatpayAccount()
{
return $this->hasOneThrough(WechatpayAccount::class, Orders::class, "id", "id", "order_id", "wechatpay_account_id");
}
public function bed()
{
return $this->belongsTo(Bed::class);

@ -44,11 +44,6 @@ class Recharge extends SoftDeletesModel
return $this->belongsTo(Orders::class);
}
public function wechatpayAccount()
{
return $this->hasOneThrough(WechatpayAccount::class, Orders::class, "id", "id", "order_id", "wechatpay_account_id");
}
public function patient()
{
return $this->hasOneThrough(Patient::class, Orders::class, "id", "id", "order_id", "patient_id");

Loading…
Cancel
Save