Browse Source

add community

visuddhinanda 3 years ago
parent
commit
70d097e624
1 changed files with 8 additions and 0 deletions
  1. 8 0
      app/Http/Controllers/TermVocabularyController.php

+ 8 - 0
app/Http/Controllers/TermVocabularyController.php

@@ -34,6 +34,14 @@ class TermVocabularyController extends Controller
             case "user":
             case "user":
                 break;
                 break;
             case "community":
             case "community":
+                $localTerm = ChannelApi::getSysChannel(
+                    "_community_term_".strtolower($request->get('lang'))."_",
+                    "_community_term_en_"
+                );
+                if(!$localTerm){
+                    return $this->error('no term channel');
+                }
+                $table = $table->where('channal',$localTerm);
                 break;
                 break;
         }
         }
         $result = $table->get();
         $result = $table->get();