Sha256: 58286cd6eef1b2d86398ea709b01378bf625eb82f548bb2edc72deaff46c32ec

Contents?: true

Size: 631 Bytes

Versions: 1

Compression:

Stored size: 631 Bytes

Contents

require 'active_record/connection_adapters/abstract/schema_definitions'

module OAuth2
  module Auth
    module Server
      module Schema

        def oauth2_client
          string :identifier, :secret, :name, :redirect_uri, :null => false
        end

        def oauth2_access_token
          belongs_to :client

          string :token, :null => false
          string :scope
          datetime :expires_at
        end

      end
    end
  end
end

ActiveRecord::ConnectionAdapters::Table.send :include, OAuth2::Auth::Server::Schema
ActiveRecord::ConnectionAdapters::TableDefinition.send :include, OAuth2::Auth::Server::Schema

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
oauth2-auth-server-0.0.2 lib/oauth2-auth-server/schema.rb