new-support.webeffector.ru/common/config/main.php

59 lines
1.7 KiB
PHP
Raw Normal View History

2024-06-13 17:07:58 +03:00
<?php
2024-07-05 10:27:50 +03:00
use yii\i18n\Formatter;
use yii\rbac\DbManager;
use yii\caching\FileCache;
use yii\caching\DummyCache;
use yii\i18n\PhpMessageSource;
2024-06-13 17:07:58 +03:00
return [
'aliases' => [
'@bower' => '@vendor/bower-asset',
'@npm' => '@vendor/npm-asset',
],
'vendorPath' => dirname(dirname(__DIR__)) . '/vendor',
'components' => [
2024-07-05 10:27:50 +03:00
'formatter' => [
'class' => Formatter::class,
'defaultTimeZone' => 'Europe/Moscow',
'currencyCode' => 'rub',
],
2024-06-13 17:07:58 +03:00
'cache' => [
2024-07-05 10:27:50 +03:00
'class' => YII_ENV_DEV ? DummyCache::class : FileCache::class,
],
'authManager' => [
'class' => DbManager::class,
],
'assetManager' => [
// timeStamp css files
'appendTimestamp' => YII_ENV_DEV, //true|false
],
'i18n' => [
'translations' => [
'app*' => [
'class' => PhpMessageSource::class,
'basePath' => '@common/messages',
'fileMap' => [
'app' => 'app.php',
'error' => 'error.php',
],
],
'user*' => [
'class' => PhpMessageSource::class,
'basePath' => '@backend/modules/user/messages',
'fileMap' => [
'user' => 'user.php',
],
],
'schema*' => [
'class' => PhpMessageSource::class,
'basePath' => '@frontend/modules/schema/messages',
'fileMap' => [
'schema' => 'schema.php',
],
],
],
2024-06-13 17:07:58 +03:00
],
],
];