getting api working

This commit is contained in:
Chris Smith
2025-02-20 16:41:41 +01:00
parent 1ab66464f2
commit c9533688ba
6 changed files with 15 additions and 4 deletions

View File

@@ -0,0 +1 @@
<?php

View File

@@ -7,9 +7,9 @@ $params = array_merge(
);
return [
'id' => 'app-backend',
'id' => 'calorie-api',
'basePath' => dirname(__DIR__),
'controllerNamespace' => 'backend\controllers',
'controllerNamespace' => 'api\controllers',
'bootstrap' => ['log'],
'modules' => [],
'components' => [
@@ -23,7 +23,7 @@ return [
],
'session' => [
// this is the name of the session cookie used for login on the backend
'name' => 'advanced-backend',
'name' => 'calorie-api',
],
'log' => [
'traceLevel' => YII_DEBUG ? 3 : 0,

View File

@@ -0,0 +1,4 @@
<?php
return [
];

View File

@@ -0,0 +1,4 @@
<?php
return [
];

View File

@@ -1,6 +1,6 @@
<?php
namespace backend\controllers;
namespace api\controllers;
use common\models\LoginForm;
use Yii;