Class: ApplicationController

Inherits:
ActionController::API
  • Object
show all
Includes:
ActionController::RequestForgeryProtection, AuthenticationAndSSOConcerns, ExceptionHandling, Headers, Instrumentation, Pundit::Authorization, SentryControllerLogging, SentryLogging, Traceable
Defined in:
app/controllers/application_controller.rb

Direct Known Subclasses

AppealsBaseController, AppealsBaseControllerV1, BBController, ClaimsBaseController, FacilitiesController, FlipperController, GIDSController, InheritedProofingController, PreneedsController, RxController, SMController, Swagger::Requests::ClaimLetters, V0::AddressesController, V0::AdminController, V0::ApidocsController, V0::AppointmentsController, V0::AppsController, V0::BackendStatusesController, V0::BenefitsClaimsController, V0::BenefitsDocumentsController, V0::BenefitsReferenceDataController, V0::CaregiversAssistanceClaimsController, V0::ClaimDocumentsController, V0::ClaimLettersController, V0::CoeController, V0::ContactUs::InquiriesController, V0::DebtLettersController, V0::DebtsController, V0::DecisionReviewEvidencesController, V0::DependentsApplicationsController, V0::DependentsVerificationsController, V0::DisabilityCompensationFormsController, V0::DocumentsController, V0::EVSSBenefitsClaimsController, V0::EVSSClaimsAsyncController, V0::EVSSClaimsController, V0::EducationBenefitsClaimsController, V0::EfolderController, V0::ExampleController, V0::FeatureTogglesController, V0::FinancialStatusReportsController, V0::Form1010EzrsController, V0::Form1010cg::AttachmentsController, V0::Form1095BsController, V0::FormsController, V0::GIBillFeedbacksController, V0::HCAAttachmentsController, V0::HealthCareApplicationsController, V0::IdCardAnnouncementSubscriptionController, V0::IdCardAttributesController, V0::InProgressFormsController, V0::IntentToFilesController, V0::LettersController, V0::LettersGeneratorController, V0::MDOT::SuppliesController, V0::MHVOptInFlagsController, V0::MPIUsersController, V0::MaintenanceWindowsController, V0::MedicalCopaysController, V0::OnsiteNotificationsController, V0::PPIUController, V0::Post911GIBillStatusesController, V0::Profile::AddressValidationController, V0::Profile::AddressesController, V0::Profile::AlternatePhonesController, V0::Profile::Ch33BankAccountsController, V0::Profile::CommunicationPreferencesController, V0::Profile::ConnectedApplicationsController, V0::Profile::ContactsController, V0::Profile::DirectDeposits::DisabilityCompensationsController, V0::Profile::EmailAddressesController, V0::Profile::EmailsController, V0::Profile::FullNamesController, V0::Profile::GenderIdentitiesController, V0::Profile::PaymentHistoryController, V0::Profile::PermissionsController, V0::Profile::PersonalInformationsController, V0::Profile::PersonsController, V0::Profile::PreferredNamesController, V0::Profile::PrimaryPhonesController, V0::Profile::ServiceHistoriesController, V0::Profile::TelephonesController, V0::Profile::TransactionsController, V0::Profile::ValidVAFileNumbersController, V0::RatedDisabilitiesController, V0::RatedDisabilitiesDiscrepanciesController, V0::SearchClickTrackingController, V0::SearchController, V0::SearchTypeaheadController, V0::TermsOfUseAgreementsController, V0::UploadSupportingEvidencesController, V0::UsersController, V0::VirtualAgent::VirtualAgentClaimController, V0::VirtualAgentJwtTokenController, V0::VirtualAgentSpeechTokenController, V0::VirtualAgentTokenController, V0::VirtualAgentTokenMsftController, V1::ApidocsController, V1::Profile::MilitaryInfosController, V1::SessionsController

Constant Summary collapse

VERSION_STATUS =
{
  draft: 'Draft Version',
  current: 'Current Version',
  previous: 'Previous Version',
  deprecated: 'Deprecated Version'
}.freeze

Constants included from SignIn::Authentication

SignIn::Authentication::BEARER_PATTERN

Constants included from ExceptionHandling

ExceptionHandling::SKIP_SENTRY_EXCEPTION_TYPES

Instance Method Summary collapse

Methods included from Traceable

#set_trace_tags

Methods included from SentryLogging

#log_exception_to_sentry, #log_message_to_sentry, #non_nil_hash?, #normalize_level, #rails_logger

Methods included from SignIn::Authentication

#authenticate, #authenticate_service_account, #load_user

Methods included from Headers

#block_unknown_hosts, #set_app_info_headers

Methods included from AuthenticationAndSSOConcerns

#authenticate, #clear_session, #extend_session!, #load_user, #log_sso_info, #render_unauthorized, #reset_session, #set_api_cookie!, #set_session_expiration_header, #sso_logging_info, #validate_inbound_login_params, #validate_session

Instance Method Details

#clear_saved_form(form_id) ⇒ Object



40
41
42
# File 'app/controllers/application_controller.rb', line 40

def clear_saved_form(form_id)
  InProgressForm.form_for_user(form_id, current_user)&.destroy if current_user
end

#cors_preflightObject



32
33
34
# File 'app/controllers/application_controller.rb', line 32

def cors_preflight
  head(:ok)
end

#routing_errorObject



36
37
38
# File 'app/controllers/application_controller.rb', line 36

def routing_error
  raise Common::Exceptions::RoutingError, params[:path]
end