Aura → AuraModel
The base plugin for a model.
All models use this plugin, and all methods it provides are available to all Aura/Sequel models.
- children Returns the children of the record.
- crumbs Returns an array of records of breadcrumb path of the record, starting from the root.
- menu_title Returns the name of the record as it should appear on the menu.
- parent Returns the parent.
- parent? Determines if the record has a parent.
- parentable? Determines if the record can have children.
- set_fields Sets the fields to the values in the hash.
- shown_in_menu? Determines if the record should be shown to visitors in the site menus.
- sort_index This is what they'll be sorted by.
- submenu Returns a list of items for the submenu.
- class_name Returns a string of the model's name for use in URLs.
- content? Returns if the model data is considered to be site content.
- parentable Determines if the model can have children.
- path Returns a URL path for an action for the model.
- roots Returns a set of results of all records that don't have parents.
- seed Ensures that the model has some bare essentials in it.
- seed! Like `seed`, but empties the table first.
- title Returns a string of the model's name to appear on pages.
- title_plural Returns a string of the model's name, pluralized, to appear on pages.