From a639228b8616f8d98ef5c1f69689837a0a087aac Mon Sep 17 00:00:00 2001 From: liyinglin Date: Wed, 12 Apr 2023 14:43:37 +0800 Subject: [PATCH] 1 --- app/Models/Visit.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Models/Visit.php b/app/Models/Visit.php index e1caf0e..ce992f0 100644 --- a/app/Models/Visit.php +++ b/app/Models/Visit.php @@ -80,7 +80,7 @@ class Visit extends SoftDeletesModel public function gateLogs() { - return $this->hasMany(GateLog::class, 'visit_id', 'id'); + return $this->hasMany(GateLog::class, 'code', 'code'); } // 小程序订阅消息