mirror of
https://github.com/philomena-dev/philomena.git
synced 2025-01-19 22:27:59 +01:00
add 'search posts' button to topic header
This commit is contained in:
parent
ae189bafce
commit
5cdc647208
3 changed files with 5 additions and 6 deletions
|
@ -43,9 +43,9 @@ defmodule Philomena.Posts.Query do
|
|||
|
||||
int_fields = ~W(id)
|
||||
date_fields = ~W(created_at updated_at)
|
||||
literal_fields = ~W(image_id)
|
||||
literal_fields = ~W(forum_id topic_id)
|
||||
ngram_fields = ~W(body subject)
|
||||
custom_fields = ~W(author user_id forum_id topic_id)
|
||||
custom_fields = ~W(author user_id)
|
||||
default_field = "body"
|
||||
transforms = %{
|
||||
"user_id" => &Philomena.Posts.Query.user_id_transform/2,
|
||||
|
|
|
@ -22,7 +22,6 @@ defmodule PhilomenaWeb.PostController do
|
|||
%{term: %{access_level: "normal"}},
|
||||
],
|
||||
must_not: [
|
||||
%{terms: %{image_tag_ids: conn.assigns.current_filter.hidden_tag_ids}},
|
||||
%{term: %{hidden_from_users: true}}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -11,9 +11,9 @@ h1 = @topic.title
|
|||
=> link(@forum.name, to: Routes.forum_path(@conn, :show, @forum))
|
||||
' »
|
||||
=> link(@topic.title, to: Routes.forum_topic_path(@conn, :show, @forum, @topic))
|
||||
/a href=posts_path(forum_id: @forum.id, subject: @topic.title)
|
||||
/ i.fa.fa-fw.fa-search>
|
||||
/ | Search Posts
|
||||
a href=Routes.post_path(@conn, :index, pq: "topic_id:#{@topic.id}")
|
||||
i.fa.fa-fw.fa-search>
|
||||
' Search Posts
|
||||
.flex.flex--wrap.block__header.block__header--light
|
||||
.flex--fixed
|
||||
= pagination
|
||||
|
|
Loading…
Reference in a new issue