title: How to use After_save with condition?
body: <p>I'm unable to find that on google. 
  I have 3 models.</p>
  
  <p>model 1 -> has_many model 2 -> has many model 3</p>
  
  <p>model 1 has fields to determine how many model 2 are possible to create. and model 2 has fields to know how many model 3 must be created.</p>
  
  <p>I would like when i save model 1, create automatically model 2 and model 3.</p>
  
  <p>i thinked to use from model 1
      after_create create_model2_record</p>
  
  <pre><code>def create_model2_record
    for(x=0, x&lt;=model1.field; x++){  #c sample
      @model2 = Model2.new
    }
  end 
  </code></pre>
  
  <p>how can handle this with rails 3?
  thansk</p>