AttrEngine.Schema.Attribute.UIConfig (attr_engine v0.2.1)

Copy Markdown View Source

Embedded schema for the UI-side configuration of an Attribute.

Controls how an attribute is presented and interacted with in backend UIs: input type, editability, visibility, custom view/edit modules, and identifier locking.

Fields

  • type — HTML input type (e.g. "text", "select", "textarea")
  • editable? — whether the attribute is editable in forms
  • hidden? — whether the attribute is hidden from the UI
  • custom_view? — whether a custom view module is used
  • edit_params / view_params — parameter maps for edit/view modules
  • edit_module / view_module — function-call specification maps
  • lock_handle? / lock_code? — prevent modification of handle/code on persisted records

Summary

Functions

Standard changeset — validates required fields and input type inclusion.

Returns the list of supported input type options.

Functions

changeset(ui_config, attrs)

Standard changeset — validates required fields and input type inclusion.

input_type_options()

@spec input_type_options() :: [{String.t(), String.t()}]

Returns the list of supported input type options.