Module Yii2 Lajax翻译管理器

Module Yii2 Lajax翻译管理器,module,yii2,multilingual,translate,Module,Yii2,Multilingual,Translate,我使用的是yii2基本框架。我想使用“lajax/yii2翻译管理器”() 我进行了迁移。我在config文件夹web.php和console.php中进行配置 'language' => 'en-US','components' => [ 'i18n' => [ 'translations' => [ '*' => [ 'class' => 'yii\i18n\DbMessageSource',

我使用的是yii2基本框架。我想使用“lajax/yii2翻译管理器”()

我进行了迁移。我在config文件夹web.php和console.php中进行配置

'language' => 'en-US','components' => [
'i18n' => [
    'translations' => [
        '*' => [
            'class' => 'yii\i18n\DbMessageSource',
            'db' => 'db',
            'sourceLanguage' => 'xx-XX', // Developer language
            'sourceMessageTable' => '{{%language_source}}',
            'messageTable' => '{{%language_translate}}',
            'cachingDuration' => 86400,
            'enableCaching' => true,
        ],
    ],
],

'modules' => [
'translatemanager' => [
    'class' => 'lajax\translatemanager\Module',
    'root' => '@app',               // The root directory of the project scan.
    'scanRootParentDirectory' => true, // Whether scan the defined `root` parent directory, or the folder itself.
                                       // IMPORTANT: for detailed instructions read the chapter about root configuration.
    'layout' => 'language',         // Name of the used layout. If using own layout use 'null'.
    'allowedIPs' => ['127.0.0.1'],  // IP addresses from which the translation interface is accessible.
    'roles' => ['@'],               // For setting access levels to the translating interface.
    'tmpDir' => '@runtime',         // Writable directory for the client-side temporary language files.
                                    // IMPORTANT: must be identical for all applications (the AssetsManager serves the JavaScript files containing language elements from this directory).
    'phpTranslators' => ['::t'],    // list of the php function for translating messages.
    'jsTranslators' => ['lajax.t'], // list of the js function for translating messages.
    'patterns' => ['*.js', '*.php'],// list of file extensions that contain language elements.
    'ignoredCategories' => ['yii'], // these categories won't be included in the language database.
    'ignoredItems' => ['config'],   // these files will not be processed.
    'scanTimeLimit' => null,        // increase to prevent "Maximum execution time" errors, if null the default max_execution_time will be used
    'searchEmptyCommand' => '!',    // the search string to enter in the 'Translation' search field to find not yet translated items, set to null to disable this feature
    'defaultExportStatus' => 1,     // the default selection of languages to export, set to 0 to select all languages by default
    'defaultExportFormat' => 'json',// the default format for export, can be 'json' or 'xml'
    'tables' => [                   // Properties of individual tables
        [
            'connection' => 'db',   // connection identifier
            'table' => '{{%language}}',         // table name
            'columns' => ['name', 'name_ascii'],// names of multilingual fields
            'category' => 'database-table-name',// the category is the database table name
        ]
    ]
],
],
当我想去的时候

yii2_project/translatemanager/language/list       
我得到一个找不到的错误URL


如何管理和使用lajax translate manager。

[已解决]

使用菜单项

$menuItems = [
['label' => Yii::t('language', 'Language'), 'items' => [
        ['label' => Yii::t('language', 'List of languages'), 'url' => ['/translatemanager/language/list']],
        ['label' => Yii::t('language', 'Create'), 'url' => ['/translatemanager/language/create']],
    ]
],
['label' => Yii::t('language', 'Scan'), 'url' => ['/translatemanager/language/scan']],
['label' => Yii::t('language', 'Optimize'), 'url' => ['/translatemanager/language/optimizer']],
['label' => Yii::t('language', 'Im-/Export'), 'items' => [
    ['label' => Yii::t('language', 'Import'), 'url' => ['/translatemanager/language/import']],
    ['label' => Yii::t('language', 'Export'), 'url' => ['/translatemanager/language/export']],
]

])

我怀疑这应该是实际的解决办法。