title: Ruby on Rails 4 render :json with conditions
body: <p>I have this render expression in a Ruby on Rails 4 controller:</p>
  
  <pre><code>render :json =&gt; @account_preferences, :include =&gt; {:payment_methods =&gt; {:include =&gt; {:payment_type =&gt; {:only =&gt; [:id, :name]}}}}
  </code></pre>
  
  <p>Can I filter the payment_methods somehow in this expression to get only the payment_methods with state = 'Confirmed'?</p>