rsanchez / Deep

A set of Eloquent models for ExpressionEngine Channel Entries.
http://rsanchez.github.io/Deep/
MIT License
51 stars 14 forks source link

Assets Collection returning 0 results #16

Closed bryantAXS closed 10 years ago

bryantAXS commented 10 years ago

Not entirely sure where to start debugging this one, but I have a simple Assets field with one entry added to it. When I try and access the raw field itself $entry->image_field_name, I get:

object(rsanchez\Deep\Collection\AssetCollection)[294]
  protected 'items' => 
    array (size=0)
      empty
rsanchez commented 10 years ago

Are you using local files with Assets? Or S3/Google? I have only tested Deep with local files, aka the Assets EE driver. That's probably the issue, if so.

Custom field hydration has been heavily refactored in the 1.1 branch. I'm hesitant to devote any time debugging 1.0 at this point. If you don't mind installing 1.1, I can help you debug at that point. Probably the best thing to do is send me a SQL dump if updating doesn't fix anything.

Install it in your composer.json like so: "rsanchez/deep": "1.1.*@dev". The big caveat is that Deep 1.1 requires PHP 5.4 / Eloquent 4.2 (up from 4.1).

bryantAXS commented 10 years ago

Awesome I just updated and that's working great now. For reference I was using local files.

Thanks for the quick response Rob!

On Wed, Aug 6, 2014 at 7:16 PM, Rob Sanchez notifications@github.com wrote:

Are you using local files with Assets? Or S3/Google? I have only tested Deep with local files, aka the Assets EE driver. That's probably the issue, if so.

Custom field hydration has been heavily refactored in the 1.1 branch https://github.com/rsanchez/Deep/tree/1.1. I'm hesitant to devote any time debugging 1.0 at this point. If you don't mind installing 1.1, I can help you debug at that point. Probably the best thing to do is send me a SQL dump if updating doesn't fix anything.

Install it in your composer.json like so: "rsanchez/deep": "1.1.*@dev https://github.com/dev". The big caveat is that Deep 1.1 requires PHP 5.4 / Eloquent 4.2 (up from 4.1).

— Reply to this email directly or view it on GitHub https://github.com/rsanchez/Deep/issues/16#issuecomment-51415279.

Bryant Hughes bryant@thegoodlab.com www.thegoodlab.com @thegoodlab http://www.twitter.com/thegoodlab