class
Amber::Controller::Error
- Amber::Controller::Error
- Amber::Controller::Base
- Reference
- Object
Included Modules
Defined in:
amber/controller/error.crConstructors
Instance methods inherited from module Amber::Controller::Error::Helpers
bad_request
bad_request,
forbidden
forbidden,
internal_server_error
internal_server_error,
not_found
not_found
Instance methods inherited from class Amber::Controller::Base
client_ip(*args, **options)client_ip(*args, **options, &) client_ip, cookies(*args, **options)
cookies(*args, **options, &) cookies, delete?(*args, **options)
delete?(*args, **options, &) delete?, filters : Filters filters, filters=(filters : Filters) filters=, flash(*args, **options)
flash(*args, **options, &) flash, format(*args, **options)
format(*args, **options, &) format, get?(*args, **options)
get?(*args, **options, &) get?, halt!(*args, **options)
halt!(*args, **options, &) halt!, head?(*args, **options)
head?(*args, **options, &) head?, patch?(*args, **options)
patch?(*args, **options, &) patch?, port(*args, **options)
port(*args, **options, &) port, post?(*args, **options)
post?(*args, **options, &) post?, put?(*args, **options)
put?(*args, **options, &) put?, request(*args, **options)
request(*args, **options, &) request, request_data : Hash(String, JSON::Any) | Nil request_data, request_data=(request_data : Hash(String, JSON::Any) | Nil) request_data=, requested_url(*args, **options)
requested_url(*args, **options, &) requested_url, response(*args, **options)
response(*args, **options, &) response, route(*args, **options)
route(*args, **options, &) route, route_path(name : Symbol, **params) : String route_path, route_url(name : Symbol, **params) : String route_url, run_after_filter(action) run_after_filter, run_before_filter(action) run_before_filter, session(*args, **options)
session(*args, **options, &) session, validation_result : Amber::Schema::LegacyResult | Nil validation_result, validation_result=(validation_result : Amber::Schema::LegacyResult | Nil) validation_result=, valve(*args, **options)
valve(*args, **options, &) valve, websocket?(*args, **options)
websocket?(*args, **options, &) websocket?
Constructor methods inherited from class Amber::Controller::Base
new(context : HTTP::Server::Context)
new
Macros inherited from module Amber::DSL::Callbacks
after_action
after_action,
before_action
before_action
Instance methods inherited from module Amber::Controller::Helpers::MarkdownHelper
render_markdown(source : String, options : Amber::Markdown::Options = Amber::Markdown::Options.new) : Stringrender_markdown(*, file : String, options : Amber::Markdown::Options = Amber::Markdown::Options.new) : String render_markdown
Instance methods inherited from module Amber::Controller::Helpers::AssetHelpers
favicon_tag(path : String = "/favicon.ico") : String
favicon_tag,
image_tag(src : String, **attrs) : String
image_tag,
javascript_include_tag(path : String, **attrs) : String
javascript_include_tag,
stylesheet_link_tag(path : String, **attrs) : String
stylesheet_link_tag
Instance methods inherited from module Amber::Controller::Helpers::URLHelpers
button_to(text : String, url : String, method : String = "POST", **attrs) : String
button_to,
link_back(text : String = "Back", **attrs) : String
link_back,
link_to(text : String, url : String, **attrs) : String
link_to,
mail_to(email : String, text : String | Nil = nil, **attrs) : String
mail_to
Instance methods inherited from module Amber::Controller::Helpers::FormHelpers
checkbox(name : String, checked : Bool = false, **attrs) : String
checkbox,
email_field(name : String, value : String | Nil = nil, **attrs) : String
email_field,
form_for(action : String, method : String = "POST", **attrs, &block : -> String) : String
form_for,
hidden_field(name : String, value : String) : String
hidden_field,
label(for_field : String, text : String | Nil = nil, **attrs) : String
label,
number_field(name : String, value : Number | Nil = nil, **attrs) : String
number_field,
password_field(name : String, **attrs) : String
password_field,
radio_button(name : String, value : String, checked : Bool = false, **attrs) : String
radio_button,
select_field(name : String, options : Array, selected : String | Nil = nil, **attrs) : String
select_field,
submit_button(text : String = "Submit", **attrs) : String
submit_button,
text_area(name : String, value : String | Nil = nil, **attrs) : String
text_area,
text_field(name : String, value : String | Nil = nil, **attrs) : String
text_field
Instance methods inherited from module Amber::Controller::Helpers::NumberHelpers
number_to_currency(number : Number, unit : String = "$", precision : Int32 = 2) : String
number_to_currency,
number_to_human_size(bytes : Number) : String
number_to_human_size,
number_to_percentage(number : Number, precision : Int32 = 1) : String
number_to_percentage,
number_with_delimiter(number : Number, delimiter : String = ",") : String
number_with_delimiter
Instance methods inherited from module Amber::Controller::Helpers::TextHelpers
escape_html(text : String) : String
escape_html,
highlight(text : String, phrase : String, tag : String = "mark") : String
highlight,
pluralize(count : Int32, singular : String, plural : String | Nil = nil) : String
pluralize,
simple_format(text : String) : String
simple_format,
strip_tags(html : String) : String
strip_tags,
truncate(text : String, length : Int32 = 30, omission : String = "...") : String
truncate,
word_wrap(text : String, line_width : Int32 = 80) : String
word_wrap
Instance methods inherited from module Amber::Controller::Helpers::TagHelpers
content_tag(tag_name : String, content : String | Nil = nil, **attrs, &block : -> String) : Stringcontent_tag(tag_name : String, content : String | Nil = nil, **attrs) : String content_tag, tag(tag_name : String, **attrs) : String tag
Instance methods inherited from module Amber::Controller::Helpers::I18n
l(*arg)
l,
t(*arg)
t
Instance methods inherited from module Amber::Controller::Helpers::Route
action_name
action_name,
controller_name
controller_name,
controller_name_no_underscore
controller_name_no_underscore,
route_resource
route_resource,
route_scope
route_scope
Instance methods inherited from module Amber::Controller::Helpers::Responders
set_response(body, status_code = 200, content_type = Content::TYPE[:html])
set_response
Macros inherited from module Amber::Controller::Helpers::Render
render(template = nil, layout = true, partial = nil, path = "src/views", folder = __FILE__)
render
Instance methods inherited from module Amber::Controller::Helpers::Redirect
redirect_back(**args)
redirect_back,
redirect_to(controller : Symbol | Class, action : Symbol, **args)redirect_to(location : String, **args)
redirect_to(action : Symbol, **args) redirect_to