Browse Source

话题数

wzq 5 years ago
parent
commit
75a79c742b
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/Repositories/PostRepositories.php

+ 2 - 2
app/Repositories/PostRepositories.php

@@ -100,8 +100,8 @@ class PostRepositories
 
         $topicIds = json_decode($request['topic_ids'], true);
         $topicCount = count($topicIds);
-        if ($topicCount == 0 || $topicCount > 5) {
-            return jsonError('所选话题必须1-5个');
+        if ($topicCount == 0 || $topicCount > 2) {
+            return jsonError('所选话题必须1-2个');
         }
         //验证话题
         $hasTopicCount = $this->topic->whereIn('id', $topicIds)->count();