Class: Belt::WelcomeController
- Inherits:
-
BeltController::Base
- Object
- BeltController::Base
- Belt::WelcomeController
- Defined in:
- lib/belt/controllers/welcome_controller.rb
Overview
Gem-embedded welcome controller that serves the default "it works!" page.
- Resolved via the ActionRouter's Belt
namespace fallback when no app-defined
WelcomeController exists. Gets replaced once the user defines their own root route.
Constant Summary collapse
- ASSETS_DIR =
File.('../assets', __dir__)
Instance Attribute Summary
Attributes inherited from BeltController::Base
Instance Method Summary collapse
Methods inherited from BeltController::Base
#action_name, #admin?, after_action, after_actions, all_after_actions, all_before_actions, all_rescue_handlers, all_skipped_before_actions, #authenticate!, before_action, before_actions, #current_user_id, #dispatch, #employee?, #initialize, #params, rescue_from, rescue_handlers, skip_before_action, skipped_before_actions, #user_groups
Methods included from Rendering
Methods included from Helpers::Response
#cors_headers, #error_response, #handle_error_and_respond, #html_response, #success_response
Constructor Details
This class inherits a constructor from BeltController::Base
Instance Method Details
#show ⇒ Object
14 15 16 17 18 19 20 21 22 |
# File 'lib/belt/controllers/welcome_controller.rb', line 14 def show @title = ENV.fetch('WELCOME_TITLE', 'Welcome to Belt') @subtitle = ENV.fetch('WELCOME_SUBTITLE', 'API Gateway → Lambda → DynamoDB — all connected.') @css = welcome_css @background_image = background_image_base64 @dynamodb_connected = dynamodb_connected? render end |