lizhen_gitee 10 ماه پیش
والد
کامیت
03b4d12c5d
2فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 1 1
      application/api/controller/Index.php
  2. 1 1
      application/api/controller/Topicdongtai.php

+ 1 - 1
application/api/controller/Index.php

@@ -118,7 +118,7 @@ class Index extends Api
         }
 
         $where = [
-            'gender' => ['neq',$this->auth->gender],
+            'gender' => $this->auth->gender == 1 ? 0 : 1,
             'status' => 1,
         ];
         if(is_numeric($keyword)){

+ 1 - 1
application/api/controller/Topicdongtai.php

@@ -184,7 +184,7 @@ class Topicdongtai extends Api
 
 
         //性别
-        $where['user.gender'] = ['neq',$this->auth->gender];
+        $where['user.gender'] = $this->auth->gender == 1 ? 0 : 1;
 
         //排除黑名单的
         $where_black = [];