hasOne(Order::class, 'id', 'obj_id')->withTrashed()->select('id','order_sn','project_id', 'price', 'status', 'user_id','jiedan_js_id', 'create_time','pay_time','start_time','jiedan_time','finish_time','return_time','type','pay_type','pay_price','balance_price'); } public function user(){ return $this->hasOne(User::class,'id','user_id')->select('id', 'user_nickname', 'avatar', 'mobile','user_type'); } public function withdraw(){ return $this->hasOne(UserWithdraw::class,'id','obj_id'); } }