You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1.6 KiB

<?php
/**
* Created by Error202
* Date: 17.08.2018
*/
use yii\helpers\Html;
/**
* @var $this \yii\web\View
* @var $modules array
* @var $message string
*/
$this->title = Yii::t('main', 'Available Modules');
$this->params['breadcrumbs'][] = $this->title;
?>
<?php if ($message) : ?>
<?php endif; ?>
<div class="row">
<?php foreach ($modules as $module) : ?>
<?php
$color = '#00aced';
$module_name = $module['locale_name'];
$module_description = $module['locale_description'];
?>
<div class="col-md-4">
<div class="box">
<div class="box-header with-border">
<h3 class="box-title"><?= $module_name ?></h3>
</div>
<div class="box-body">
<?= $module_description ?>
</div>
<div class="box-footer" style="text-align: right">
<?php if (Yii::$app->moduleManager->isExists($module['name'])) : ?>
<span class="text-bold text-green"><?= Yii::t('main', 'Installed') ?></span>
<?php else : ?>
6 years ago
<?= Html::a(Yii::t('main', 'Enable'), ['module/install', 'name' => $module['name']], [
'class' => 'btn btn-default btn-sm',
'data' => [
'method' => 'post',
],
]) ?>
<?php endif; ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>