Skip to content

Instantly share code, notes, and snippets.

@zackperdue
Created January 28, 2013 21:12
Show Gist options
  • Save zackperdue/4659057 to your computer and use it in GitHub Desktop.
Save zackperdue/4659057 to your computer and use it in GitHub Desktop.
Does this actually work?
public function action_downloads()
{
$order_ids = ORM::factory('Order', array('id'))
->where('user_id', '=', $this->user->id)
->as_array();
$downloads = ORM::factory('Order_Item')
->where('order_id', 'IN', $order_ids)
->find_all();
$this->template->content = View::factory('account/downloads')
->bind('downloads', $downloads);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment