wzq 5 anni fa
parent
commit
2a2f155c68
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      app/Repositories/PostRepositories.php

+ 2 - 2
app/Repositories/PostRepositories.php

@@ -375,11 +375,11 @@ class PostRepositories
             $post = $this->post;
             $order = 'post.id';
         }elseif($type == 'collect'){
-            $post = $this->post->join('post_collect', 'post_collect.post_id', '=', 'post.id');
+            $post = $this->post->withTrashed()->join('post_collect', 'post_collect.post_id', '=', 'post.id');
             $where[] = ['post_collect.uid', $uid];
             $order = 'post_collect.id';
         }else{
-            $post = $this->post->join('post_share', 'post_share.post_id', '=', 'post.id');
+            $post = $this->post->withTrashed()->join('post_share', 'post_share.post_id', '=', 'post.id');
             $where[] = ['post_share.uid', $uid];
             $order = 'post_share.updated_at';
         }