Sha256: a89abe0b35a1c78756c154e64f884982629e0d2e68c2d63a32e67404007a0e35

Contents?: true

Size: 515 Bytes

Versions: 7

Compression:

Stored size: 515 Bytes

Contents

module Cms
  module UsersService
    module CmsLoginUserControllerConcern
      extend ActiveSupport::Concern

      def cms_login_user_by_login(login, group_codes: nil)
        Cms::UsersService.use_user_by_login login, group_codes: group_codes

        sign_in :cms_user, Cms::UsersService.current
      end

      def cms_login_user_by_user(user, group_codes: nil)
        Cms::UsersService.use_user user, group_codes: group_codes

        sign_in :cms_user, Cms::UsersService.current
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
browsercms-artirix-4.0.4 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.3.3 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.3.2 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.3.1 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.3 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.2 lib/cms/users_service/cms_login_user_controller_concern.rb
browsercms-artirix-4.0.1.1 lib/cms/users_service/cms_login_user_controller_concern.rb