Lorrain Fontaine

yeah that $owns thing is not really well done nor referenced in the documentation ^^

Conan

oh yea always forget the $owns 🙈 yep that's the issue... thanks @dorsetdigital 👏

👍 (1)
Conan

yes

  1. Document.php
  2. private static $has_one = [
  3. 'File' => File::class,
  4. ];
Conan

My brain aint working right now

  1. <% loop $Documents %>
  2. <!-- Document has_one File -->
  3. $FileID <!-- works -->
  4. $File.ID <!-- nope -->
  5. <a href="$File.Link"><p>$Title</p></a>
  6. <% end_loop %>

Why can't I access the File object? I've fallen into this trap so many times before.. 🙈

nate-sd

Oh no. Confusing people at cons. Great blog post though.