summaryrefslogtreecommitdiff
path: root/app/Template/project_overview
diff options
context:
space:
mode:
Diffstat (limited to 'app/Template/project_overview')
-rw-r--r--app/Template/project_overview/attachments.php2
-rw-r--r--app/Template/project_overview/columns.php4
-rw-r--r--app/Template/project_overview/description.php4
-rw-r--r--app/Template/project_overview/files.php15
-rw-r--r--app/Template/project_overview/images.php18
-rw-r--r--app/Template/project_overview/information.php8
-rw-r--r--app/Template/project_overview/show.php1
7 files changed, 31 insertions, 21 deletions
diff --git a/app/Template/project_overview/attachments.php b/app/Template/project_overview/attachments.php
index ab8cf2ad..b8baadd0 100644
--- a/app/Template/project_overview/attachments.php
+++ b/app/Template/project_overview/attachments.php
@@ -5,7 +5,7 @@
<div class="accordion-content">
<?php if ($this->user->hasProjectAccess('ProjectFileController', 'create', $project['id'])): ?>
<div class="buttons-header">
- <?= $this->url->button('fa-plus', t('Upload a file'), 'ProjectFileController', 'create', array('project_id' => $project['id']), 'popover') ?>
+ <?= $this->modal->mediumButton('plus', t('Upload a file'), 'ProjectFileController', 'create', array('project_id' => $project['id'])) ?>
</div>
<?php endif ?>
diff --git a/app/Template/project_overview/columns.php b/app/Template/project_overview/columns.php
index cc5782bd..daae9ca7 100644
--- a/app/Template/project_overview/columns.php
+++ b/app/Template/project_overview/columns.php
@@ -1,8 +1,8 @@
<div class="project-overview-columns">
<?php foreach ($project['columns'] as $column): ?>
<div class="project-overview-column">
- <strong title="<?= t('Task count') ?>"><?= $column['nb_tasks'] ?></strong><br>
- <span><?= $this->text->e($column['title']) ?></span>
+ <strong title="<?= t('Task count') ?>"><?= $column['nb_tasks'] ?></strong>
+ <small><?= $this->text->e($column['title']) ?></small>
</div>
<?php endforeach ?>
</div>
diff --git a/app/Template/project_overview/description.php b/app/Template/project_overview/description.php
index 0c2027ed..80b93efe 100644
--- a/app/Template/project_overview/description.php
+++ b/app/Template/project_overview/description.php
@@ -3,9 +3,9 @@
<h3><a href="#" class="fa accordion-toggle"></a> <?= t('Description') ?></h3>
</div>
<div class="accordion-content">
- <?php if ($this->user->hasProjectAccess('ProjectEditController', 'description', $project['id'])): ?>
+ <?php if ($this->user->hasProjectAccess('ProjectEditController', 'show', $project['id'])): ?>
<div class="buttons-header">
- <?= $this->url->button('fa-edit', t('Edit description'), 'ProjectEditController', 'description', array('project_id' => $project['id']), 'popover') ?>
+ <?= $this->modal->mediumButton('edit', t('Edit description'), 'ProjectEditController', 'show', array('project_id' => $project['id'])) ?>
</div>
<?php endif ?>
<article class="markdown">
diff --git a/app/Template/project_overview/files.php b/app/Template/project_overview/files.php
index fa870938..85de52f7 100644
--- a/app/Template/project_overview/files.php
+++ b/app/Template/project_overview/files.php
@@ -1,5 +1,5 @@
<?php if (! empty($files)): ?>
- <table class="table-stripped">
+ <table class="table-striped table-scrolling">
<tr>
<th><?= t('Filename') ?></th>
<th><?= t('Creator') ?></th>
@@ -15,18 +15,19 @@
<ul>
<?php if ($this->file->getPreviewType($file['name']) !== null): ?>
<li>
- <i class="fa fa-eye fa-fw"></i>
- <?= $this->url->link(t('View file'), 'FileViewerController', 'show', array('project_id' => $project['id'], 'file_id' => $file['id']), false, 'popover') ?>
+ <?= $this->modal->large('eye', t('View file'), 'FileViewerController', 'show', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
+ </li>
+ <?php elseif ($this->file->getBrowserViewType($file['name']) !== null): ?>
+ <li>
+ <?= $this->url->icon('eye', t('View file'), 'FileViewerController', 'browser', array('project_id' => $project['id'], 'file_id' => $file['id']), false, '', '', true) ?>
</li>
<?php endif ?>
<li>
- <i class="fa fa-download fa-fw"></i>
- <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
+ <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
</li>
<?php if ($this->user->hasProjectAccess('ProjectFileController', 'remove', $project['id'])): ?>
<li>
- <i class="fa fa-trash fa-fw"></i>
- <?= $this->url->link(t('Remove'), 'ProjectFileController', 'confirm', array('project_id' => $project['id'], 'file_id' => $file['id']), false, 'popover') ?>
+ <?= $this->modal->confirm('trash-o', t('Remove'), 'ProjectFileController', 'confirm', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
</li>
<?php endif ?>
</ul>
diff --git a/app/Template/project_overview/images.php b/app/Template/project_overview/images.php
index 7f38e2b1..7e7962e8 100644
--- a/app/Template/project_overview/images.php
+++ b/app/Template/project_overview/images.php
@@ -2,20 +2,28 @@
<div class="file-thumbnails">
<?php foreach ($images as $file): ?>
<div class="file-thumbnail">
- <a href="<?= $this->url->href('FileViewerController', 'show', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>" class="popover"><img src="<?= $this->url->href('FileViewerController', 'thumbnail', array('file_id' => $file['id'], 'project_id' => $project['id'])) ?>" title="<?= $this->text->e($file['name']) ?>" alt="<?= $this->text->e($file['name']) ?>"></a>
+ <?= $this->app->component('image-slideshow', array(
+ 'images' => $images,
+ 'image' => $file,
+ 'regex' => 'FILE_ID',
+ 'url' => array(
+ 'image' => $this->url->to('FileViewerController', 'image', array('file_id' => 'FILE_ID', 'project_id' => $project['id'])),
+ 'thumbnail' => $this->url->to('FileViewerController', 'thumbnail', array('file_id' => 'FILE_ID', 'project_id' => $project['id'])),
+ 'download' => $this->url->to('FileViewerController', 'download', array('file_id' => 'FILE_ID', 'project_id' => $project['id'])),
+ )
+ )) ?>
+
<div class="file-thumbnail-content">
<div class="file-thumbnail-title">
<div class="dropdown">
<a href="#" class="dropdown-menu dropdown-menu-link-text"><?= $this->text->e($file['name']) ?> <i class="fa fa-caret-down"></i></a>
<ul>
<li>
- <i class="fa fa-download fa-fw"></i>
- <?= $this->url->link(t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
+ <?= $this->url->icon('download', t('Download'), 'FileViewerController', 'download', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
</li>
<?php if ($this->user->hasProjectAccess('ProjectFileController', 'remove', $project['id'])): ?>
<li>
- <i class="fa fa-trash fa-fw"></i>
- <?= $this->url->link(t('Remove'), 'ProjectFileController', 'confirm', array('project_id' => $project['id'], 'file_id' => $file['id']), false, 'popover') ?>
+ <?= $this->modal->confirm('trash-o', t('Remove'), 'ProjectFileController', 'confirm', array('project_id' => $project['id'], 'file_id' => $file['id'])) ?>
</li>
<?php endif ?>
</ul>
diff --git a/app/Template/project_overview/information.php b/app/Template/project_overview/information.php
index fdf0f753..0fe53e08 100644
--- a/app/Template/project_overview/information.php
+++ b/app/Template/project_overview/information.php
@@ -3,7 +3,7 @@
<h3><a href="#" class="fa accordion-toggle"></a> <?= t('Information') ?></h3>
</div>
<div class="accordion-content">
- <div class="listing">
+ <div class="panel">
<ul>
<?php if ($project['owner_id'] > 0): ?>
<li><?= t('Project owner: ') ?><strong><?= $this->text->e($project['owner_name'] ?: $project['owner_username']) ?></strong></li>
@@ -29,9 +29,9 @@
<?php endif ?>
<?php if ($project['is_public']): ?>
- <li><i class="fa fa-share-alt"></i> <?= $this->url->link(t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li>
- <li><i class="fa fa-rss-square"></i> <?= $this->url->link(t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li>
- <li><i class="fa fa-calendar"></i> <?= $this->url->link(t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li>
+ <li><?= $this->url->icon('share-alt', t('Public link'), 'BoardViewController', 'readonly', array('token' => $project['token']), false, '', '', true) ?></li>
+ <li><?= $this->url->icon('rss-square', t('RSS feed'), 'FeedController', 'project', array('token' => $project['token']), false, '', '', true) ?></li>
+ <li><?= $this->url->icon('calendar', t('iCal feed'), 'ICalendarController', 'project', array('token' => $project['token'])) ?></li>
<?php endif ?>
</ul>
</div>
diff --git a/app/Template/project_overview/show.php b/app/Template/project_overview/show.php
index 6b2bc2cf..d87b2775 100644
--- a/app/Template/project_overview/show.php
+++ b/app/Template/project_overview/show.php
@@ -1,6 +1,7 @@
<section id="main">
<?= $this->projectHeader->render($project, 'ProjectOverviewController', 'show') ?>
<?= $this->render('project_overview/columns', array('project' => $project)) ?>
+ <?= $this->hook->render('template:project-overview:before-description', array('project' => $project)) ?>
<?= $this->render('project_overview/description', array('project' => $project)) ?>
<?= $this->render('project_overview/attachments', array('project' => $project, 'images' => $images, 'files' => $files)) ?>
<?= $this->render('project_overview/information', array('project' => $project, 'users' => $users, 'roles' => $roles)) ?>