View Source Mobilizon.Service.Export.Participants.Common (Mobilizon v5.0.0-beta.1)

Common functions for managing participants export

Summary

Functions

Link to this function

clean_exports(format, upload_path, expiration \\ 3600)

View Source
@spec clean_exports(String.t(), String.t(), integer()) :: :ok

Clean outdated files in export folder

@spec columns() :: [String.t()]
@spec enabled_formats() :: [String.t()]
@spec export_enabled?(module()) :: boolean()
@spec export_modules() :: [module()]
@spec export_path(String.t()) :: String.t()
Link to this function

save_upload(full_path, file_path, reference, file_name, format)

View Source
@spec save_upload(String.t(), String.t(), String.t(), String.t(), String.t()) ::
  {:ok, Mobilizon.Export.t()} | {:error, atom() | Ecto.Changeset.t()}
@spec translate_role(atom()) :: String.t()

Match a participant role to it's translated version