Skip to content

Commit 5f25570

Browse files
committed
new version
1 parent e112416 commit 5f25570

File tree

1,009 files changed

+111442
-5528
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,009 files changed

+111442
-5528
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,5 @@ composer.phar
2525
phpunit.phar
2626
# local phpunit config
2727
/phpunit.xml
28+
29+
/runtime

LICENSE.md

-32
This file was deleted.

README.md

-89
This file was deleted.

web/index-test.php admin-test.php

File renamed without changes.

admin.php

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
3+
use source\core\back\BaseBackApplication;
4+
use source\LuLu;
5+
6+
7+
// comment out the following two lines when deployed to production
8+
defined('YII_DEBUG') or define('YII_DEBUG', true);
9+
defined('YII_ENV') or define('YII_ENV', 'dev');
10+
11+
require (__DIR__ . '/vendor/autoload.php');
12+
require (__DIR__ . '/vendor/yiisoft/yii2/Yii.php');
13+
14+
require (__DIR__ . '/source/config/bootstrap.php');
15+
require (__DIR__ . '/backend/config/bootstrap.php');
16+
17+
18+
$config = yii\helpers\ArrayHelper::merge(
19+
require(__DIR__ . '/source/config/main.php'),
20+
require(__DIR__ . '/source/config/main-local.php'),
21+
require(__DIR__ . '/backend/config/main.php'),
22+
require(__DIR__ . '/backend/config/main-local.php')
23+
);
24+
25+
$app = new BaseBackApplication($config);
26+
$app->run();
27+

assets/AppAsset.php

-29
This file was deleted.

backend/config/bootstrap.php

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<?php

backend/config/main-local.php

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<?php
2+
3+
$config = [
4+
'components' => [
5+
'request' => [
6+
// !!! insert a secret key in the following (if it is empty) - this is required by cookie validation
7+
'cookieValidationKey' => '41SCN-vryMrrUOuOzXXcGo0GP4zBgMhr',
8+
],
9+
],
10+
];
11+
12+
if (!YII_ENV_TEST) {
13+
// configuration adjustments for 'dev' environment
14+
$config['bootstrap'][] = 'debug';
15+
$config['modules']['debug'] = 'yii\debug\Module';
16+
17+
$config['bootstrap'][] = 'gii';
18+
$config['modules']['gii'] = 'yii\gii\Module';
19+
}
20+
21+
return $config;

backend/config/main.php

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
<?php
2+
$params = array_merge(
3+
require(__DIR__ . '/../../source/config/params.php'),
4+
require(__DIR__ . '/../../source/config/params-local.php'),
5+
require(__DIR__ . '/params.php'),
6+
require(__DIR__ . '/params-local.php')
7+
);
8+
9+
return [
10+
'id' => 'app-backend',
11+
'basePath' => dirname(__DIR__),
12+
'controllerNamespace' => 'backend\controllers',
13+
'bootstrap' => ['log'],
14+
'modules' => [],
15+
'components' => [
16+
'user' => [
17+
'identityClass' => 'source\models\User',
18+
'enableAutoLogin' => true,
19+
'loginUrl' => ['admin/login'],
20+
],
21+
'log' => [
22+
'traceLevel' => YII_DEBUG ? 3 : 0,
23+
'targets' => [
24+
[
25+
'class' => 'yii\log\FileTarget',
26+
'levels' => ['error', 'warning'],
27+
],
28+
],
29+
],
30+
'errorHandler' => [
31+
'errorAction' => 'admin/error',
32+
],
33+
'view' => [
34+
'class' => 'source\core\back\BaseBackView',
35+
],
36+
'moduleManager' => [
37+
'class' => 'source\modules\modularity\ModuleManager',
38+
],
39+
40+
],
41+
'modules' => [
42+
// 'comment' => [
43+
// 'class' => 'source\modules\comment\AdminModule',
44+
// ],
45+
// 'post' => [
46+
// 'class' => 'source\modules\post\AdminModule',
47+
// ],
48+
// 'page' => [
49+
// 'class' => 'source\modules\page\AdminModule',
50+
// ],
51+
// 'takonomy' => [
52+
// 'class' => 'source\modules\takonomy\AdminModule',
53+
// ],
54+
'menu' => [
55+
'class' => 'source\modules\menu\AdminModule',
56+
],
57+
'system' => [
58+
'class' => 'source\modules\system\AdminModule',
59+
],
60+
'modularity' => [
61+
'class' => 'source\modules\modularity\AdminModule',
62+
],
63+
],
64+
'params' => $params,
65+
];

backend/config/params-local.php

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<?php
2+
return [
3+
];

backend/config/params.php

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<?php
2+
return [
3+
'adminEmail' => '[email protected]',
4+
];

0 commit comments

Comments
 (0)