module Marten::Handlers::RecordRetrieving::ClassMethods

Defined in:

marten/handlers/concerns/record_retrieving.cr

Instance Method Summary

Instance Method Detail

def lookup_field(lookup_field : String | Symbol) #

Allows to configure the name of the model field that will be used to retrieve the record.


[View source]
def lookup_param(lookup_param : String | Symbol) #

Allows to configure the name of the URL parameter containing the ID used to retrieve the record.


[View source]
def lookup_param : String #

Returns the the name of the URL parameter containing the ID used to retrieve the record.

By default, the lookup param name corresponds to the value returned by #lookup_field.


[View source]