Sha256: 0690693bfaa4b295ef493c862744ab4ce8664ed2a23394b82c932d17b5662358

Contents?: true

Size: 548 Bytes

Versions: 54

Compression:

Stored size: 548 Bytes

Contents

class Ey::Core::Client::Feature < Ey::Core::Model
  extend Ey::Core::Associations

  identity :id

  attribute :name
  attribute :privacy
  attribute :description

  has_one :account

  def enable!(account)
    params = {
      "account" => account.id,
      "feature" => {
        "id" => self.id,
      }
    }

    self.connection.enable_feature(params)
  end

  def disable!(account)
    params = {
      "account" => account.id,
      "feature" => {
        "id" => self.id
      }
    }

    self.connection.disable_feature(params)
  end
end

Version data entries

54 entries across 54 versions & 3 rubygems

Version Path
ey-core-3.6.0.autoscaling1 lib/ey-core/models/feature.rb
ey-core-3.6.4 lib/ey-core/models/feature.rb
ey-core-3.6.3 lib/ey-core/models/feature.rb
ey-core-3.6.1 lib/ey-core/models/feature.rb
groove-ey-core-3.6.3 lib/ey-core/models/feature.rb
groove-ey-core-3.6.2 lib/ey-core/models/feature.rb
groove-ey-core-3.6.1 lib/ey-core/models/feature.rb
ey-core-3.5.0 lib/ey-core/models/feature.rb
ey-core-3.4.4 lib/ey-core/models/feature.rb
ey-core-3.4.2 lib/ey-core/models/feature.rb
ey-core-3.4.1 lib/ey-core/models/feature.rb
ey-core-3.4.0 lib/ey-core/models/feature.rb
ey-core-3.3.1 lib/ey-core/models/feature.rb
ey-core-3.3.0 lib/ey-core/models/feature.rb
ey-core-3.2.6 lib/ey-core/models/feature.rb
ey-core-3.2.5 lib/ey-core/models/feature.rb
ey-core-3.2.4 lib/ey-core/models/feature.rb
ey-core-3.2.3 lib/ey-core/models/feature.rb
ey-core-3.2.2 lib/ey-core/models/feature.rb
ey-core-3.2.1 lib/ey-core/models/feature.rb