In micro not working relationships, Why they are ignored?
namespace App\Models;
use Phalcon\Mvc\Model;
use Workers;
class Accounts extends Model {
public $id;
public $login;
public $worker_id;
public function initialize() {
$this->hasOne('worker_id', Workers::class, 'id', ['alias' => 'worker']);
}
}
Loader:
$loader->registerNamespaces([
'App\\Models' => APP_PATH . $config->dirs->models,
]);
$loader->registerDirs([
APP_PATH . $config->dirs->controllers,
APP_PATH . $config->dirs->models
]);
$loader->register();
Returned ::find():
id:"14"
login:"login"
worker_id: "1"