Hello! We are finally ready to use CodeIgniter 4. I only have some problems with using a model inside a model. I was expecting that I could use something like this:
PHP Code:
namespace App\Models;
use CodeIgniter\Model;
class Filters_model extends Model {
function __construct(){
// Call the Model constructor
parent::__construct();
$this->session = session();
$this->customers = model('Customers_model');
}
}
But that doesn't seems to work. I'm getting a "Service Temporarily Unavailable" error. In CI3 you could just put it in autoload and use it wherever you like.
How can I include a model inside a current model to use those functions of that model?