Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Bug with getRelated with columns provided when they are initialised in relation params #12972
Expected and Actual Behavior
Actualy when I have defined some relation like:
$this->belongsTo( 'robots_id', 'Store\Toys\Robots', 'id', [ 'alias' => 'Robots', 'params' => [ 'columns' => 'id,name' ] ] );
And ask for
in result I have two columns id and name, and its expected result.
But if i as for:
in result I have again two columns without price.
I think that is a bug in https://github.com/phalcon/cphalcon/blob/master/phalcon/mvc/model/manager.zep#L1307
let builder = this->createBuilder(this->_mergeFindParameters(extraParameters, parameters));
we are overwriting relation parameters on provided parameters...