Hi.
I have a model class which inherits from a base model class. Inside my base model class I have an initialize()
method with the following instruction:
public function initialize()
{
$this->setConnectionService('myAdapterWrite');
}
The thing is, in all my other classes that inherit from the base model class I am overwriting this initialize()
method with another adapter and the connection seems to keep the first adapter at all. I mean, it does not change the adapter. It just set up the adapter at the first time.
When debuging, I realized that the initialize()
is called just once. Hence, when I try changing the adapter it does not connect to the other database I need.
I am sorry if I did not make myself clear.
Does it have any solution?
Thanks in any advance.