Fix Rails/ApplicationController

This commit is contained in:
Neal Chambers
2023-08-17 16:40:01 +09:00
parent 5762492511
commit b78bbd2629
5 changed files with 5 additions and 5 deletions

View File

@@ -2,7 +2,7 @@
# Controller used to provide the API products for the DFC application
module DfcProvider
class BaseController < ActionController::Base
class ApplicationController < ActionController::Base
protect_from_forgery with: :null_session
rescue_from ActiveRecord::RecordNotFound, with: :not_found

View File

@@ -3,7 +3,7 @@
# Controller used to provide the API products for the DFC application
# CatalogItems are items that are being sold by the entreprise.
module DfcProvider
class CatalogItemsController < DfcProvider::BaseController
class CatalogItemsController < DfcProvider::ApplicationController
before_action :check_enterprise
def index

View File

@@ -2,7 +2,7 @@
# Controller used to provide the CatalogItem API for the DFC application
module DfcProvider
class EnterprisesController < DfcProvider::BaseController
class EnterprisesController < DfcProvider::ApplicationController
before_action :check_enterprise
def show

View File

@@ -2,7 +2,7 @@
# Controller used to provide the Persons API for the DFC application
module DfcProvider
class PersonsController < DfcProvider::BaseController
class PersonsController < DfcProvider::ApplicationController
before_action :check_user_accessibility
def show

View File

@@ -3,7 +3,7 @@
# Controller used to provide the SuppliedProducts API for the DFC application
# SuppliedProducts are products that are managed by an enterprise.
module DfcProvider
class SuppliedProductsController < DfcProvider::BaseController
class SuppliedProductsController < DfcProvider::ApplicationController
before_action :check_enterprise
rescue_from JSON::LD::JsonLdError::LoadingDocumentFailed, with: -> do
head :bad_request