cartodb-4.42/app/models/carto/client_application.rb
2024-04-06 05:25:13 +00:00

12 lines
337 B
Ruby

require 'active_record'
module Carto
class ClientApplication < ActiveRecord::Base
belongs_to :user, class_name: Carto::User
has_many :oauth_tokens, class_name: Carto::OauthToken, dependent: :destroy
has_many :access_tokens, -> { where(type: 'AccessToken') }, class_name: Carto::OauthToken, dependent: :destroy
end
end