Sha256: 511e89cc01c1ee9cadfd974f6581a7990d04a4c278bbf20ba11884bb2eeb97ac

Contents?: true

Size: 751 Bytes

Versions: 7

Compression:

Stored size: 751 Bytes

Contents

# Holds attribute lists for application models.
# Is used to configure attributes in the layer between a model and its representation in the Netzke application, thus providing default attributes
# for grids and panels.
class NetzkeModelAttrList < NetzkeFieldList
  
  # Updates attributes for all lists owned by owner_id and below the current authority level
  def self.update_fields(owner_id, attrs_hash)
    super
    
    NetzkeFieldList.find_all_lists_under_current_authority(owner_id).each do |list|
      list.update_attrs(attrs_hash)
    end
  end
  
  def self.add_attrs(attrs)
    NetzkeFieldList.find_all_lists_under_current_authority(owner_id).each do |list|
      attrs.each{ |attr_hash| list.append_attr(attr_hash) }
    end
  end
  
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
netzke-basepack-0.6.0 app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.14 lib/app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.13 lib/app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.12 lib/app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.11 lib/app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.10 lib/app/models/netzke_model_attr_list.rb
netzke-basepack-0.5.9 lib/app/models/netzke_model_attr_list.rb