1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-12 23:09:03 +01:00
fab-manager/app/controllers/api/subscriptions_controller.rb
2021-10-18 10:15:48 +02:00

23 lines
512 B
Ruby

# frozen_string_literal: true
# API Controller for resources of type Subscription
class API::SubscriptionsController < API::ApiController
before_action :set_subscription, only: %i[show payment_details]
before_action :authenticate_user!
def show
authorize @subscription
end
def payment_details
authorize @subscription
end
private
# Use callbacks to share common setup or constraints between actions.
def set_subscription
@subscription = Subscription.find(params[:id])
end
end