hi i am using scope
i have two collection contact and company
company has_many contact
contact belong to company
condition
scopedData = Contact.scoped
scopedData = scopedData.where(:email => "vinay@gmail.com")
then from this scoped data
want to find where company name is "test"
hi i am using scope
i have two collection contact and company
company has_many contact
contact belong to company
condition
scopedData = Contact.scoped
scopedData = scopedData.where(:email => "vinay@gmail.com")
then from this scoped data
want to find where company name is "test"
how to use scoped on this
please help me friends