app/models/run.rb
# generate new association with collection of targets
# targets are either entity or entity_ref
generate new association with collection of targets
targets are either entity or entity_ref
generate new association with collection of targets targets are either entity or entity_ref
def new_assoc(targets, target_model_name, assoc_net, assoc_target_type, assoc_name = nil)
    assoc_name ||= target_model_name.to_assoc_name(assoc_target_type)
    assoc = Association.new(targets)
    assoc.assoc_name = assoc_name
    assoc.connection_factors = get_assoc_connection_factors(target_model_name, assoc_net)
    assoc.assoc_entity = self
    assoc.target_model = target_model_name.to_model
    assoc.assoc_target_type   = assoc_target_type
    assoc
  end
def new_assoc ( targets , target_model_name , assoc_net , assoc_target_type , assoc_name = nil ) assoc_name ||= target_model_name . to_assoc_name ( assoc_target_type ) assoc = Association . new ( targets ) assoc . assoc_name = assoc_name assoc . connection_factors = get_assoc_connection_factors ( target_model_name , assoc_net ) assoc . assoc_entity = self assoc . target_model = target_model_name . to_model assoc . assoc_target_type = assoc_target_type assoc end
generate new association with collection of targets
targets are either entity or entity_ref
generate new association with collection of targets targets are either entity or entity_ref
targets
<not_specific>
target_model_name
<not_specific>
assoc_net
<not_specific>
assoc_target_type
<not_specific>
assoc_name
<not_specific>