1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-11-29 10:24:20 +01:00
fab-manager/app/models/open_api/client.rb

10 lines
270 B
Ruby

class OpenAPI::Client < ActiveRecord::Base
has_many :calls_count_tracings, foreign_key: :open_api_client_id, dependent: :destroy
has_secure_token
validates :name, presence: true
def increment_calls_count
update_column(:calls_count, calls_count+1)
end
end