소스 검색

fixed:用户端->附近技师

刘学玺 4 달 전
부모
커밋
56fb1e4809
2개의 변경된 파일3개의 추가작업 그리고 11개의 파일을 삭제
  1. 0 8
      app/Models/CoachUser.php
  2. 3 3
      app/Services/Client/CoachService.php

+ 0 - 8
app/Models/CoachUser.php

@@ -38,12 +38,4 @@ class CoachUser extends Model
     {
         return $this->belongsTo(MemberUser::class, 'user_id');
     }
-
-    /**
-     * 获取技师资格认证信息
-     */
-    public function qual()
-    {
-        return $this->hasOne(CoachQualRecord::class, 'id', 'qual_record_id');
-    }
 }

+ 3 - 3
app/Services/Client/CoachService.php

@@ -68,9 +68,9 @@ class CoachService
             ->whereHas('real', function ($query) {
                 $query->where('state', TechnicianAuthStatus::PASSED->value);
             })
-            // ->whereHas('qual', function ($query) {
-            //     $query->where('state', TechnicianAuthStatus::PASSED->value);
-            // })
+            ->whereHas('qual', function ($query) {
+                $query->where('state', TechnicianAuthStatus::PASSED->value);
+            })
             ->with(['info:id,nickname,avatar,gender'])
             ->paginate($perPage);