hasOne(StoreGoods::class,'id','goods_id'); } public function order(){ return $this->belongsTo(OrderW::class,'order_id','id'); } public function getPriceAttribute($value){ return round($value); } public function getCostPriceAttribute($value){ return round($value); } public function getCostAccountAttribute($value){ return round($value); } public function getAccountAttribute($value){ return round($value); } }