SELECT [model].*, [model].[divisionId], [model].[objectId] FROM [PRECEPT] [model] LEFT JOIN [Division] [dev] ON model.divisionId = dev.id LEFT JOIN [Objects] [ob] ON model.objectId = ob.id WHERE [dateComplete] IS NULL ORDER BY [dev].[name] DESC
<?php
namespace api\modules\v1\controllers;
use http\Exception;
use yii\data\ActiveDataProvider;
use yii\rest\ActiveController;
class PreceptController extends ActiveController
{
public $modelClass = 'api\modules\v1\models\Precept';
public function actions()
{
$actions = parent::actions();
return $actions;
}
}