Sha256: c354bd6a4223d330be7cc33925629d1ffd6b9f3a70fd7164c5cc08759f354860

Contents?: true

Size: 347 Bytes

Versions: 14

Compression:

Stored size: 347 Bytes

Contents

# frozen_string_literal: true

class DemoGroupController < ApplicationController
  devise_jwt_auth_group :member, contains: [:user, :mang]
  before_action :authenticate_member!

  def members_only
    render json: {
      data: {
        message: "Welcome #{current_member.name}",
        user: current_member
      }
    }, status: 200
  end
end

Version data entries

14 entries across 14 versions & 3 rubygems

Version Path
devise_jwt_auth722-0.1.7 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth7-0.1.7 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.4.1 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.4.0 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.3.0 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.2.0 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.7 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.6 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.5 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.4 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.3 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.2 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.1 test/dummy/app/controllers/demo_group_controller.rb
devise_jwt_auth-0.1.0 test/dummy/app/controllers/demo_group_controller.rb