Backpex
▼
Project version
v0.12.0
v0.11.0
v0.10.0
v0.9.1
v0.9.0
v0.8.2
v0.8.1
v0.8.0
v0.7.1
v0.7.0
v0.6.0
v0.5.1
v0.5.0
v0.4.0
v0.3.2
v0.3.1
v0.3.0
v0.2.0
v0.1.1
GUIDES
Modules
API Reference
Modules
Translations
Setup
Modify texts (per LiveResource)
Introduction
Introduction
Key Features
Installation & Documentation
Learn More
License
About
What is Backpex?
Why we built Backpex?
Contribute to Backpex
What can I contribute?
Fork the repository
Clone the repository
Setting up your development environment
Making changes
Get Started
Installation
Prerequisites
Global configuration
Add to list of dependencies
Add files to Tailwind content
Setup formatter
Create an example resource
Create layout
Configure LiveResource
Configure Routing
Add Init Assigns and LiveSession
Remove default background color
Set daisyUI theme
Remove @tailwindcss/forms plugin
Provide Tailwind Plugin for heroicons
Live Resource
What is a LiveResource?
Templates
Configuration
Item Query
Configuration
Ordering
Configuration
Hooks
Configuration
Navigation
Configuration
Available Live Actions
Form Actions
Panels
Configuration
Usage
Fluid Layout
Configure LiveResource
Listen to PubSub Events
Additional classes for index table rows
Configuration
Fields
What is a Field?
Built-in Field Types
Configuration
Field Configuration
Custom Fields
Creating a Custom Field
Add field option validation
Alignment
Field Alignment (Index View)
Label Alignment (Edit View)
Visibility
Visibility with only and except
Visibility with visible
Visibility with can?
Advanced Example
Defaults
Configuration
Readonly
Supported fields
Configuration
Readonly for custom fields
Custom Alias
Configuration
Placeholder
Configuration
Debounce and Throttle
Configuration
Index Edit
Configuration
Supported fields
Custom index editable implementation
Error Customization
Configuration
Computed Fields
Configuration
Example
Computed Fields with Associations
Filter
What is a Filter?
Built-in Filters
How to add a Filter?
Defining a Filter module
Adding the Filter to your LiveResource
Overwriting the Filter Label
Filter Presets
Defining a Filter Preset
Custom Filter
Creating a Custom Filter
Visibility and Authorization
Configuration
Actions
Item Actions
Configuration
Implementing an Item Action
Placement of Item Actions
Advanced Item Action
Resource Actions
Configuration
Implementing a Resource Action
Authorization
LiveResource Authorization
Configuration
Parameters
Return value
Field Authorization
Configuration
Searching
Search
Configuration
Full-Text Search
Create a Generated Column
Create an Index
Upgrade Guides
Upgrading to v0.12
Bump Your Deps
Upgrade to Tailwind 4 and daisyUI 5
PubSub config is now optional
return_to/4 becomes return_to/5
"Save & Continue editing" button is disabled by default
Translations have been updated
Backpex.translate/2 has been split up
Upgrading to v0.11
Bump Your Deps
Removed Alpine.js in favor of Backpex JS hooks
Parameter changes in core modules
Make sure to cover all cases with the item_query/3 function
We removed Ecto.Query import from LiveResource
Component changes
Upgrading to v0.10
Bump Your Deps
LiveView 1.0
Upgrading to v0.9
Bump your deps
Refactor calls to Backpex.HTML.Form.field_input/1
Backpex.LiveResource function usage
Refactor custom fields
Removed string support on throttle field options
Resource Action and Item Action init_change/1 is renamed
Resource Action and Item Action handle functions behave differently
Translate new texts
Upgrading to v0.8
Bump your deps
Introduction of the adapter pattern
Upgrading to v0.7
Bump Your Deps
Update calls to Backpex.Field.handle_index_editable/2
Update calls to Backpex.Resource
Update your Item Actions
Upgrading to v0.6
Bump Your Deps
Change Backpex.Fields.ManyToMany to Backpex.Fields.HasMany
Upgrading to v0.5
Bump Your Deps
Uploads: Item in consume_upload/4 now contains changes
Resource Actions now receive the data instead of the params
Item Actions now receive the data instead of the params
Refactor the use of icons
Upgrading to v0.3
Bump Your Deps
Update calls to Backpex.Resource
Update Upload callback functions
Upgrading to v0.2
Bump Your Deps
Pass assigns to init_change functions
Change arity of changeset functions
Update prompt option
Backpex
Summary
Functions
translate/2
translate_error/1
Backpex.CookieController
Summary
Functions
update/2
Backpex.Ecto.Amount.Type
Sections
Migration
Schema
Summary
Functions
cast/2
dump/3
init/1
load/3
type/1
Backpex.FormComponent
Summary
Functions
handle_event/3
noreply/1
ok/1
render/1
update/2
Backpex.InitAssigns
Summary
Functions
noreply/1
ok/1
on_mount/4
Backpex.LiveResource
Summary
Callbacks
can?/3
fields/0
filters/0
filters/1
index_row_class/4
item_actions/1
metrics/0
on_item_created/2
on_item_deleted/2
on_item_updated/2
panels/0
plural_name/0
render_resource_slot/3
resource_actions/0
return_to/5
singular_name/0
translate/1
Functions
__using__/1
active_filters/1
assign_items/1
calculate_total_pages/2
empty_filter_key/0
filter_field_by_action/2
filter_options/2
filtered_fields_by_action/3
get_filter_options/1
order_options_by_params/4
orderable?/1
orderable_fields/1
parse_integer/3
primary_value/2
pubsub/1
resolve_init_order/2
search_options/3
searchable_fields/1
subscribe_to_topic/2
validate_page/2
validated_fields/1
value_in_permitted_or_default/3
Backpex.Resource
Summary
Functions
broadcast/3
build_changeset_metadata/2
change/6
count/3
delete_all/2
get/3
get!/3
insert/5
list/3
update/6
update_all/4
Backpex.Router
Summary
Functions
active?/2
backpex_routes/0
cookie_path/1
filter_actions/3
get_path/5
get_path/6
has_resource_actions?/2
live_resources/3
member?/3
put_route_params/2
Backpex.ThemeSelectorPlug
Summary
Functions
call/2
init/1
BackpexWeb
Summary
Functions
__using__/1
field/0
filter/0
html/0
item_action/0
metric/0
Adapters
Backpex.Adapter
Summary
Callbacks
change/6
count/3
delete_all/2
get/3
insert/2
list/3
update/2
update_all/3
Backpex.Adapters.Ash
Sections
adapter_config
Summary
Functions
change/6
count/3
delete_all/2
get/3
insert/2
list/3
update/2
update_all/3
validate_config!/1
Backpex.Adapters.Ecto
Sections
adapter_config
Summary
Functions
apply_criteria/3
apply_filters/3
apply_search/4
change/6
count/3
delete_all/2
get/3
get_primary_key_field/1
insert/2
list/3
list_query/3
name_by_schema/1
update/2
update_all/3
validate_config!/1
Components
Backpex.HTML
Summary
Functions
pretty_value/1
Backpex.HTML.CoreComponents
Summary
Components
filter_badge/1
icon/1
Functions
noreply/1
ok/1
Backpex.HTML.Form
Summary
Components
error/1
input/1
multi_select/1
Functions
form_errors?/2
noreply/1
ok/1
translate_form_errors/2
Backpex.HTML.Layout
Summary
Components
app_shell/1
backpex_logo/1
field_container/1
flash_messages/1
footer/1
input_label/1
main_container/1
main_title/1
modal/1
sidebar_item/1
sidebar_section/1
theme_selector/1
topbar/1
topbar_branding/1
topbar_dropdown/1
Functions
hide_modal/2
noreply/1
ok/1
visible_fields_by_panel/3
Backpex.HTML.Resource
Summary
Components
edit_card/1
empty_state/1
index_filter/1
index_search_form/1
order_link/1
pagination/1
pagination_info/1
resource_buttons/1
resource_field/1
resource_filters/1
resource_form_field/1
resource_index_main/1
resource_index_table/1
resource_metrics/1
resource_show_main/1
select_per_page/1
show_panel/1
toggle_columns/1
toggle_columns_inputs/1
Functions
form_component/1
noreply/1
ok/1
pagination_items/2
resource_form/1
resource_form_main/1
resource_index/1
resource_show/1
Fields
Backpex.Field
Summary
Callbacks
assign_uploads/2
association?/1
before_changeset/6
display_field/1
render_form/1
render_form_readonly/1
render_index_form/1
render_value/1
schema/2
search_condition/3
Functions
__using__/1
align_label/3
changeset_types/1
debounce/2
default_config_schema/0
handle_index_editable/3
index_editable_enabled?/3
placeholder/2
readonly?/2
throttle/2
translate_error_fun/2
Backpex.Fields.BelongsTo
Sections
Field-specific options
Example
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Boolean
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Currency
Sections
Field-specific options
Schema
Example
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Date
Sections
Field-specific options
Examples
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.DateTime
Sections
Field-specific options
Examples
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.HasMany
Sections
Field-specific options
Example
Summary
Functions
assign_selected/1
noreply/1
ok/1
validate_config!/2
Backpex.Fields.HasManyThrough
Sections
Field-specific options
Example
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.InlineCRUD
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.MultiSelect
Sections
Field-specific options
Example
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Number
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Select
Sections
Field-specific options
Example
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Text
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Textarea
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Time
Sections
Field-specific options
Examples
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.URL
Sections
Field-specific options
Summary
Functions
noreply/1
ok/1
validate_config!/2
Backpex.Fields.Upload
Sections
Field-specific options
Full Single File Example
Full Multi File Example
Full External File Example
Summary
Functions
existing_file_paths/3
label_from_file/2
list_existing_files/3
map_file_paths/2
noreply/1
ok/1
validate_config!/2
Actions
Backpex.ItemAction
Summary
Callbacks
base_schema/1
cancel_label/1
changeset/3
confirm/1
confirm_label/1
fields/0
handle/3
icon/2
label/2
Functions
__using__/1
default_actions/0
has_confirm_modal?/1
has_form?/1
Backpex.ItemActions.Delete
Summary
Functions
noreply/1
ok/1
Backpex.ItemActions.Edit
Summary
Functions
noreply/1
ok/1
Backpex.ItemActions.Show
Summary
Functions
noreply/1
ok/1
Backpex.ResourceAction
Summary
Callbacks
base_schema/1
changeset/3
fields/0
handle/2
label/0
title/0
Functions
__using__/1
name/2
Filters
Backpex.Filter
Summary
Callbacks
can?/1
label/0
query/3
render/1
render_form/1
Backpex.Filters.Boolean
Summary
Callbacks
options/0
Functions
find_option_label/2
maybe_query/2
noreply/1
ok/1
option_value_to_label/2
predicates/1
query/4
render/1
render_form/1
Backpex.Filters.MultiSelect
Summary
Callbacks
options/0
Functions
find_option_label/2
maybe_query/2
noreply/1
ok/1
option_value_to_label/2
query/3
render/1
render_form/1
Backpex.Filters.Range
Summary
Callbacks
type/0
Functions
date?/1
do_query/3
maybe_parse/3
maybe_parse_range/3
noreply/1
ok/1
parse_float_or_int/1
query/4
range_input_set/1
render/1
render_form/1
render_type/1
Backpex.Filters.Select
Summary
Callbacks
options/0
prompt/0
Functions
noreply/1
ok/1
option_value_to_label/2
query/3
render/1
render_form/1
selected/1
Metrics
Backpex.Metric
Summary
Callbacks
format/2
query/3
render/1
Functions
metrics_visible?/2
Backpex.Metrics.Value
Sections
Options
Example
Summary
Functions
format/2
query/3
render/1
Exceptions
Backpex.ForbiddenError
Backpex.NoResultsError
Search documentation of Backpex
Settings
Backpex.NoResultsError
exception
(Backpex v0.12.0)
View Source
Raised when no results can be found.