mirror of
https://github.com/philomena-dev/philomena.git
synced 2024-11-23 20:18:00 +01:00
Filter images and home pages to images with thumbnails
This commit is contained in:
parent
e668881c18
commit
715506352c
2 changed files with 2 additions and 2 deletions
|
@ -23,7 +23,7 @@ defmodule PhilomenaWeb.ActivityController do
|
||||||
{:ok, {images, _tags}} =
|
{:ok, {images, _tags}} =
|
||||||
ImageLoader.search_string(
|
ImageLoader.search_string(
|
||||||
conn,
|
conn,
|
||||||
"created_at.lte:3 minutes ago",
|
"created_at.lte:3 minutes ago, thumbnails_generated:true",
|
||||||
pagination: %{conn.assigns.image_pagination | page_number: 1}
|
pagination: %{conn.assigns.image_pagination | page_number: 1}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,7 @@ defmodule PhilomenaWeb.ImageController do
|
||||||
plug PhilomenaWeb.AdvertPlug when action in [:show]
|
plug PhilomenaWeb.AdvertPlug when action in [:show]
|
||||||
|
|
||||||
def index(conn, _params) do
|
def index(conn, _params) do
|
||||||
{:ok, {images, _tags}} = ImageLoader.search_string(conn, "created_at.lte:3 minutes ago")
|
{:ok, {images, _tags}} = ImageLoader.search_string(conn, "created_at.lte:3 minutes ago, thumbnails_generated:true")
|
||||||
|
|
||||||
images = Elasticsearch.search_records(images, preload(Image, tags: :aliases))
|
images = Elasticsearch.search_records(images, preload(Image, tags: :aliases))
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue