Sha256: 147a035bf2be0bb9fe29251272b3a4c28ede11ccd31b23f279394904f7e18ad1

Contents?: true

Size: 346 Bytes

Versions: 80

Compression:

Stored size: 346 Bytes

Contents

class RailsOps::VirtualModel < ActiveType::Object
  include RailsOps::ModelMixins

  # Override write_attribute. This enables using write_attribute even for
  # virtual attributes.
  def write_attribute(name, value)
    if virtual_columns_hash.include?(name.to_s)
      write_virtual_attribute(name, value)
    else
      super
    end
  end
end

Version data entries

80 entries across 80 versions & 1 rubygems

Version Path
rails_ops-1.5.8 lib/rails_ops/virtual_model.rb
rails_ops-1.5.7 lib/rails_ops/virtual_model.rb
rails_ops-1.5.6 lib/rails_ops/virtual_model.rb
rails_ops-1.5.5 lib/rails_ops/virtual_model.rb
rails_ops-1.5.4 lib/rails_ops/virtual_model.rb
rails_ops-1.5.0 lib/rails_ops/virtual_model.rb
rails_ops-1.4.8 lib/rails_ops/virtual_model.rb
rails_ops-1.4.7 lib/rails_ops/virtual_model.rb
rails_ops-1.4.6 lib/rails_ops/virtual_model.rb
rails_ops-1.4.5 lib/rails_ops/virtual_model.rb
rails_ops-1.4.4 lib/rails_ops/virtual_model.rb
rails_ops-1.4.3 lib/rails_ops/virtual_model.rb
rails_ops-1.4.2 lib/rails_ops/virtual_model.rb
rails_ops-1.0.17.1 lib/rails_ops/virtual_model.rb
rails_ops-1.4.1 lib/rails_ops/virtual_model.rb
rails_ops-1.4.0 lib/rails_ops/virtual_model.rb
rails_ops-1.3.0 lib/rails_ops/virtual_model.rb
rails_ops-1.2.3 lib/rails_ops/virtual_model.rb
rails_ops-1.2.2 lib/rails_ops/virtual_model.rb
rails_ops-1.2.1 lib/rails_ops/virtual_model.rb