Packages
kanta_sync_plugin
0.1.0
Kanta plugin for syncing translations on staging/dev with production
Current section
Files
Jump to
Current section
Files
lib/finders/list_updated_locales.ex
defmodule Kanta.Sync.Translations.Locale.Finders.ListUpdatedLocales do
@moduledoc """
Query module aka Finder responsible for listing locales
"""
use Kanta.Query,
module: Kanta.Translations.Locale,
binding: :locale
import Kanta.Sync.Utils.QueryUtils
def find(params \\ []) do
base()
|> order_by(:id)
|> updated_since_last_fetch(:locale)
|> paginate(params[:page], params[:per])
end
end