incubator
incubator copied to clipboard
Use the model->columns() method to return className as Phalcon\Mvc\ model \Row
Phalcon\Mvc\Model\EagerLoading\Loader::__construct() $className: Method will not get the real model class
When I use the model cloumns method to restrict query columns, instead of returning the original model class, I return a Phalcon\Mvc\model\Row
, which prevents me from preloading with the with method.
I think the second argument from the Loader::fromResultset()
can pass the model name,I solved it this way