-
Notifications
You must be signed in to change notification settings - Fork 0
/
Bootstrap.php
48 lines (40 loc) · 1.21 KB
/
Bootstrap.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?php
/**
* ActiveForm is a widget that builds an interactive HTML form for one or multiple data models.
*
* @author Ben Bi <[email protected]>
* @link http://www.cciza.com/
* @copyright 2014-2016 CCIZA Software LLC
* @license
*/
namespace cza\base;
use Yii;
use yii\base\BootstrapInterface;
/**
* This constant defines the framework installation directory.
*/
defined('CZA_PATH') or define('CZA_PATH', __DIR__);
class Bootstrap extends \yii\base\Component implements BootstrapInterface {
/**
* - route translations
* @param \yii\base\Application $app
*/
public function bootstrap($app) {
// \Yii::info(__CLASS__);
// $app->attachBehavior('AppConfigBehavior', 'cza\base\behaviors\AppConfigBehavior');
//
$app->i18n->translations['cza*'] = [
'class' => 'yii\i18n\PhpMessageSource',
'sourceLanguage' => 'en-US',
'basePath' => '@cza/base/messages',
'fileMap' => [
'cza' => 'default.php',
'cza/languages' => 'languages.php',
],
];
// declare CZA Helper
$app->set('czaHelper', [
'class' => '\cza\base\helpers\Helper',
]);
}
}