It looks like you're new here. If you want to get involved, click one of these buttons!
I declare property_type in the foreign key:
https://pasteboard.co/IzXgJjW.png
then access it from here:
https://pasteboard.co/IzXhVse.png
or if I use:
return $this->get_type();
and the function:
https://pasteboard.co/IzXicEn.png
OR
https://pasteboard.co/IzXihzM.png
I always got:
https://pasteboard.co/IzXjrzy.png
Could you please explain why the queries showed twice or thrice?
Thank you.
Comments
Unfortunately it's tough to tell from the screenshots and code to properly debug. I would start from where it's originally called and debug from there. It may take you into the internals of the MY_Model class.