ersaf/news

There is no license information available for the latest version (1.0.0) of this package.

Ersaf News

1.0.0 2020-04-14 07:44 UTC

README

News management.

Installation

You need to require this package and enable the module in your configuration.

add to composer requirements in composer.json

"ersaf/news": "dev-master as 1.0.0",

or run command bash:

composer require "ersaf/news": "dev-master as 1.0.0",

Configure the theme property of the view application component.

    'view' => [
        'class' => 'elitedivision\amos\core\components\AmosView',
        'theme' => [
            'pathMap' => [
               '@vendor/elitedivision/amos-news/src/views/news' => '@vendor/ersaf/news/src/views/news',
            ],
        ],
    ],

Add configurations to News module in modules-amos.php in backend as follows

 'news' => [

	'modelMap' => [
            'News' => 'ersaf\news\models\News',
            'NewsSearch' => 'ersaf\news\models\search\NewsSearch'
        ],
        'controllerMap' => [
            'news' => [
                'class' => 'ersaf\news\controllers\NewsController',
            ]
        ],
 ],

Add configurations to i18n component in components-others.php in common as follows

 'i18n' => [
    'translations' => [
        '*' => [
            'extraCategoryPaths' => [
                'amosnews' => '@vendor/ersaf/news/src/i18n',
            ],
        ],
    ],
  ],

add news migrations to console modules (console/config/migrations-amos.php):

'@vendor/ersaf/news/src/migrations'