View Source ExTeal.Resource.Repo behaviour (ExTeal v0.27.0)

Summary

Callbacks

Defines the module use-ing Ecto.Repo to be used by the resource.

Callbacks

@callback repo() :: module()

Defines the module use-ing Ecto.Repo to be used by the resource.

Defaults to the value set in config if present:

config :ex_teal,
   repo: MyApp.Repo

Default can be overridden per resource:

def repo, do: MyApp.SecondaryRepo