View Source Indexed.Helpers (Indexed v0.3.4)
Helper functions for internal use.
Link to this section Summary
Functions
Given a lookup map, add field
according to record
.
Get the id of the record being operated on from an action state.
Get the id of the record being operated on.
Convert a field-only order hint into a tuple one.
Given a lookup map, remove field
according to record
.
Link to this section Functions
@spec add_to_lookup(Indexed.lookup(), Indexed.record(), atom(), Indexed.id()) :: Indexed.lookup()
Given a lookup map, add field
according to record
.
Get the id of the record being operated on from an action state.
See id_value/2
.
Get the id of the record being operated on.
See Indexed.Entity.t/0
.
@spec normalize_order_hint(Indexed.order_hint()) :: [{:asc | :desc, atom()}]
Convert a field-only order hint into a tuple one.
Given a lookup map, remove field
according to record
.