Add project calendars (merge/refactoring of #490)
This commit is contained in:
@@ -196,4 +196,14 @@ class App extends Base
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Colors stylesheet
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
*/
|
||||||
|
public function colors()
|
||||||
|
{
|
||||||
|
$this->response->css($this->color->getCss());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
79
app/Controller/Calendar.php
Normal file
79
app/Controller/Calendar.php
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Controller;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Project Calendar controller
|
||||||
|
*
|
||||||
|
* @package controller
|
||||||
|
* @author Frederic Guillot
|
||||||
|
* @author Timo Litzbarski
|
||||||
|
*/
|
||||||
|
class Calendar extends Base
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Show calendar view
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
*/
|
||||||
|
public function show()
|
||||||
|
{
|
||||||
|
$project = $this->getProject();
|
||||||
|
|
||||||
|
$this->response->html($this->template->layout('calendar/show', array(
|
||||||
|
'check_interval' => $this->config->get('board_private_refresh_interval'),
|
||||||
|
'users_list' => $this->projectPermission->getMemberList($project['id'], true, true),
|
||||||
|
'categories_list' => $this->category->getList($project['id'], true, true),
|
||||||
|
'columns_list' => $this->board->getColumnsList($project['id'], true),
|
||||||
|
'swimlanes_list' => $this->swimlane->getList($project['id'], true),
|
||||||
|
'colors_list' => $this->color->getList(true),
|
||||||
|
'status_list' => $this->taskStatus->getList(true),
|
||||||
|
'project' => $project,
|
||||||
|
'title' => t('Calendar for "%s"', $project['name']),
|
||||||
|
'board_selector' => $this->projectPermission->getAllowedProjects($this->userSession->getId()),
|
||||||
|
)));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get tasks to display on the calendar
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
*/
|
||||||
|
public function events()
|
||||||
|
{
|
||||||
|
$this->response->json(
|
||||||
|
$this->taskFilter
|
||||||
|
->create()
|
||||||
|
->filterByProject($this->request->getIntegerParam('project_id'))
|
||||||
|
->filterByCategory($this->request->getIntegerParam('category_id', -1))
|
||||||
|
->filterByOwner($this->request->getIntegerParam('owner_id', -1))
|
||||||
|
->filterByColumn($this->request->getIntegerParam('column_id', -1))
|
||||||
|
->filterBySwimlane($this->request->getIntegerParam('swimlane_id', -1))
|
||||||
|
->filterByColor($this->request->getStringParam('color_id'))
|
||||||
|
->filterByStatus($this->request->getIntegerParam('is_active', -1))
|
||||||
|
->filterByDueDateRange(
|
||||||
|
$this->request->getStringParam('start'),
|
||||||
|
$this->request->getStringParam('end')
|
||||||
|
)
|
||||||
|
->toCalendarEvents()
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update task due date
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
*/
|
||||||
|
public function save()
|
||||||
|
{
|
||||||
|
if ($this->request->isAjax() && $this->request->isPost()) {
|
||||||
|
|
||||||
|
$values = $this->request->getJson();
|
||||||
|
|
||||||
|
$this->taskModification->update(array(
|
||||||
|
'id' => $values['task_id'],
|
||||||
|
'date_due' => $values['date_due'],
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -104,9 +104,9 @@ class Helper
|
|||||||
* @param string $filename Filename
|
* @param string $filename Filename
|
||||||
* @return string
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function css($filename)
|
public function css($filename, $is_file = true)
|
||||||
{
|
{
|
||||||
return '<link rel="stylesheet" href="'.$filename.'?'.filemtime($filename).'" media="screen">';
|
return '<link rel="stylesheet" href="'.$filename.($is_file ? '?'.filemtime($filename) : '').'" media="screen">';
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -417,7 +417,7 @@ class Helper
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* URL query string
|
* Generate controller/action url for templates
|
||||||
*
|
*
|
||||||
* u('task', 'show', array('task_id' => $task_id))
|
* u('task', 'show', array('task_id' => $task_id))
|
||||||
*
|
*
|
||||||
@@ -429,17 +429,40 @@ class Helper
|
|||||||
*/
|
*/
|
||||||
public function u($controller, $action, array $params = array(), $csrf = false)
|
public function u($controller, $action, array $params = array(), $csrf = false)
|
||||||
{
|
{
|
||||||
$html = '?controller='.$controller.'&action='.$action;
|
$values = array(
|
||||||
|
'controller' => $controller,
|
||||||
|
'action' => $action,
|
||||||
|
);
|
||||||
|
|
||||||
if ($csrf) {
|
if ($csrf) {
|
||||||
$params['csrf_token'] = Security::getCSRFToken();
|
$params['csrf_token'] = Security::getCSRFToken();
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach ($params as $key => $value) {
|
$values += $params;
|
||||||
$html .= '&'.$key.'='.$value;
|
|
||||||
}
|
|
||||||
|
|
||||||
return $html;
|
return '?'.http_build_query($values, '', '&');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Generate controller/action url
|
||||||
|
*
|
||||||
|
* l('task', 'show', array('task_id' => $task_id))
|
||||||
|
*
|
||||||
|
* @param string $controller Controller name
|
||||||
|
* @param string $action Action name
|
||||||
|
* @param array $params Url parameters
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function url($controller, $action, array $params = array())
|
||||||
|
{
|
||||||
|
$values = array(
|
||||||
|
'controller' => $controller,
|
||||||
|
'action' => $action,
|
||||||
|
);
|
||||||
|
|
||||||
|
$values += $params;
|
||||||
|
|
||||||
|
return '?'.http_build_query($values, '');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -656,4 +679,55 @@ class Helper
|
|||||||
|
|
||||||
return $default_value;
|
return $default_value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get calendar translations
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getCalendarTranslations()
|
||||||
|
{
|
||||||
|
return json_encode(array(
|
||||||
|
'Today' => t('Today'),
|
||||||
|
'Jan' => t('Jan'),
|
||||||
|
'Feb' => t('Feb'),
|
||||||
|
'Mar' => t('Mar'),
|
||||||
|
'Apr' => t('Apr'),
|
||||||
|
'May' => t('May'),
|
||||||
|
'Jun' => t('Jun'),
|
||||||
|
'Jul' => t('Jul'),
|
||||||
|
'Aug' => t('Aug'),
|
||||||
|
'Sep' => t('Sep'),
|
||||||
|
'Oct' => t('Oct'),
|
||||||
|
'Nov' => t('Nov'),
|
||||||
|
'Dec' => t('Dec'),
|
||||||
|
'January' => t('January'),
|
||||||
|
'February' => t('February'),
|
||||||
|
'March' => t('March'),
|
||||||
|
'April' => t('April'),
|
||||||
|
'May' => t('May'),
|
||||||
|
'June' => t('June'),
|
||||||
|
'July' => t('July'),
|
||||||
|
'August' => t('August'),
|
||||||
|
'September' => t('September'),
|
||||||
|
'October' => t('October'),
|
||||||
|
'November' => t('November'),
|
||||||
|
'December' => t('December'),
|
||||||
|
'Sunday' => t('Sunday'),
|
||||||
|
'Monday' => t('Monday'),
|
||||||
|
'Tuesday' => t('Tuesday'),
|
||||||
|
'Wednesday' => t('Wednesday'),
|
||||||
|
'Thursday' => t('Thursday'),
|
||||||
|
'Friday' => t('Friday'),
|
||||||
|
'Saturday' => t('Saturday'),
|
||||||
|
'Sun' => t('Sun'),
|
||||||
|
'Mon' => t('Mon'),
|
||||||
|
'Tue' => t('Tue'),
|
||||||
|
'Wed' => t('Wed'),
|
||||||
|
'Thu' => t('Thu'),
|
||||||
|
'Fri' => t('Fri'),
|
||||||
|
'Sat' => t('Sat'),
|
||||||
|
));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -167,6 +167,23 @@ class Response
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Send a css response
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @param string $data Raw data
|
||||||
|
* @param integer $status_code HTTP status code
|
||||||
|
*/
|
||||||
|
public function css($data, $status_code = 200)
|
||||||
|
{
|
||||||
|
$this->status($status_code);
|
||||||
|
|
||||||
|
header('Content-Type: text/css; charset=utf-8');
|
||||||
|
echo $data;
|
||||||
|
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Send a binary response
|
* Send a binary response
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
'Application default' => 'Anwendungsstandard',
|
'Application default' => 'Anwendungsstandard',
|
||||||
'Language:' => 'Sprache:',
|
'Language:' => 'Sprache:',
|
||||||
'Timezone:' => 'Zeitzone:',
|
'Timezone:' => 'Zeitzone:',
|
||||||
// 'Next' => '',
|
'All columns' => 'Alle Spalten',
|
||||||
|
'Calendar for "%s"' => 'Kalender für "%s"',
|
||||||
|
'Filter by column' => 'Spalte filtern',
|
||||||
|
'Filter by status' => 'Status filtern',
|
||||||
|
'Calendar' => 'Kalender',
|
||||||
|
'Today' => 'Heute',
|
||||||
|
'Jan ' => 'Jan',
|
||||||
|
'Feb' => 'Feb',
|
||||||
|
'Mar' => 'Mar',
|
||||||
|
'Apr' => 'Apr',
|
||||||
|
'May' => 'Mai',
|
||||||
|
'Jun' => 'Jun',
|
||||||
|
'Jul' => 'Jul',
|
||||||
|
'Aug' => 'Aug',
|
||||||
|
'Sep' => 'Sep',
|
||||||
|
'Oct' => 'Okt',
|
||||||
|
'Nov' => 'Nov',
|
||||||
|
'Dec' => 'Dez',
|
||||||
|
'January' => 'Januar',
|
||||||
|
'February' => 'Februar',
|
||||||
|
'March' => 'März',
|
||||||
|
'April' => 'April',
|
||||||
|
'June' => 'Juni',
|
||||||
|
'July' => 'Juli',
|
||||||
|
'August' => 'August',
|
||||||
|
'September' => 'September',
|
||||||
|
'October' => 'Oktober',
|
||||||
|
'November' => 'November',
|
||||||
|
'December' => 'Dezember',
|
||||||
|
'Sunday' => 'Sonntag',
|
||||||
|
'Monday' => 'Montag',
|
||||||
|
'Tuesday' => 'Dienstag',
|
||||||
|
'Wednesday' => 'Mittwoch',
|
||||||
|
'Thursday' => 'Donnerstag',
|
||||||
|
'Friday' => 'Freitag',
|
||||||
|
'Saturday' => 'Samstag',
|
||||||
|
'Sun' => 'So',
|
||||||
|
'Mon' => 'Mo',
|
||||||
|
'Tue' => 'Di',
|
||||||
|
'Wed' => 'Mi',
|
||||||
|
'Thu' => 'Do',
|
||||||
|
'Fri' => 'Fr',
|
||||||
|
'Sat' => 'Sa',
|
||||||
|
'Next' => 'Nächste',
|
||||||
|
// '#%d' => '',
|
||||||
|
'Filter by color' => 'Farbe filtern',
|
||||||
|
'Filter by swimlane' => 'Swimlane filtern',
|
||||||
|
'All swimlanes' => 'Alle Swimlanes',
|
||||||
|
'All colors' => 'Alle Farben',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,6 +647,55 @@ return array(
|
|||||||
'Application default' => 'Valeur par défaut de l\'application',
|
'Application default' => 'Valeur par défaut de l\'application',
|
||||||
'Language:' => 'Langue :',
|
'Language:' => 'Langue :',
|
||||||
'Timezone:' => 'Fuseau horaire :',
|
'Timezone:' => 'Fuseau horaire :',
|
||||||
|
'All columns' => 'Toutes les colonnes',
|
||||||
|
'Calendar for "%s"' => 'Agenda pour le projet « %s »',
|
||||||
|
'Filter by column' => 'Filtrer par colonne',
|
||||||
|
'Filter by status' => 'Filtrer par status',
|
||||||
|
'Calendar' => 'Agenda',
|
||||||
|
'Today' => 'Aujourd\'hui',
|
||||||
|
'Jan ' => 'Janv',
|
||||||
|
'Feb' => 'Fév',
|
||||||
|
'Mar' => 'Mars',
|
||||||
|
'Apr' => 'Avr',
|
||||||
|
'May' => 'Mai',
|
||||||
|
'Jun' => 'Juin',
|
||||||
|
'Jul' => 'Juil',
|
||||||
|
'Aug' => 'Août',
|
||||||
|
'Sep' => 'Sept',
|
||||||
|
'Oct' => 'Oct',
|
||||||
|
'Nov' => 'Nov',
|
||||||
|
'Dec' => 'Déc',
|
||||||
|
'January' => 'Janvier',
|
||||||
|
'February' => 'Février',
|
||||||
|
'March' => 'Mars',
|
||||||
|
'April' => 'Avril',
|
||||||
|
'May' => 'Mai',
|
||||||
|
'June' => 'Juin',
|
||||||
|
'July' => 'Juillet',
|
||||||
|
'August' => 'Août',
|
||||||
|
'September' => 'Septembre',
|
||||||
|
'October' => 'Octobre',
|
||||||
|
'November' => 'Novembre',
|
||||||
|
'December' => 'Décembre',
|
||||||
|
'Sunday' => 'Dimanche',
|
||||||
|
'Monday' => 'Lundi',
|
||||||
|
'Tuesday' => 'Mardi',
|
||||||
|
'Wednesday' => 'Mercredi',
|
||||||
|
'Thursday' => 'Jeudi',
|
||||||
|
'Friday' => 'Vendredi',
|
||||||
|
'Saturday' => 'Samedi',
|
||||||
|
'Sun' => 'Dim',
|
||||||
|
'Mon' => 'Lun',
|
||||||
|
'Tue' => 'Mar',
|
||||||
|
'Wed' => 'Mer',
|
||||||
|
'Thu' => 'Jeu',
|
||||||
|
'Fri' => 'Ven',
|
||||||
|
'Sat' => 'Sam',
|
||||||
'Next' => 'Suivant',
|
'Next' => 'Suivant',
|
||||||
'#%d' => 'n˚%d',
|
'#%d' => 'n˚%d',
|
||||||
|
'Filter by color' => 'Filtrer par couleur',
|
||||||
|
'Filter by swimlane' => 'Filtrer par swimlanes',
|
||||||
|
'All swimlanes' => 'Toutes les swimlanes',
|
||||||
|
'All colors' => 'Toutes les couleurs',
|
||||||
|
'All status' => 'Tous les états',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
'Application default' => 'Aplicação padrão',
|
'Application default' => 'Aplicação padrão',
|
||||||
'Language:' => 'Idioma',
|
'Language:' => 'Idioma',
|
||||||
'Timezone:' => 'Fuso horário',
|
'Timezone:' => 'Fuso horário',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
'Next' => 'Próximo',
|
'Next' => 'Próximo',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
'Application default' => 'Applikationsstandard',
|
'Application default' => 'Applikationsstandard',
|
||||||
'Language:' => 'Språk',
|
'Language:' => 'Språk',
|
||||||
'Timezone:' => 'Tidszon',
|
'Timezone:' => 'Tidszon',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
'Next' => 'Nästa',
|
'Next' => 'Nästa',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -647,5 +647,54 @@ return array(
|
|||||||
// 'Application default' => '',
|
// 'Application default' => '',
|
||||||
// 'Language:' => '',
|
// 'Language:' => '',
|
||||||
// 'Timezone:' => '',
|
// 'Timezone:' => '',
|
||||||
|
// 'All columns' => '',
|
||||||
|
// 'Calendar for "%s"' => '',
|
||||||
|
// 'Filter by column' => '',
|
||||||
|
// 'Filter by status' => '',
|
||||||
|
// 'Calendar' => '',
|
||||||
|
// 'Today' => '',
|
||||||
|
// 'Jan ' => '',
|
||||||
|
// 'Feb' => '',
|
||||||
|
// 'Mar' => '',
|
||||||
|
// 'Apr' => '',
|
||||||
|
// 'May' => '',
|
||||||
|
// 'Jun' => '',
|
||||||
|
// 'Jul' => '',
|
||||||
|
// 'Aug' => '',
|
||||||
|
// 'Sep' => '',
|
||||||
|
// 'Oct' => '',
|
||||||
|
// 'Nov' => '',
|
||||||
|
// 'Dec' => '',
|
||||||
|
// 'January' => '',
|
||||||
|
// 'February' => '',
|
||||||
|
// 'March' => '',
|
||||||
|
// 'April' => '',
|
||||||
|
// 'June' => '',
|
||||||
|
// 'July' => '',
|
||||||
|
// 'August' => '',
|
||||||
|
// 'September' => '',
|
||||||
|
// 'October' => '',
|
||||||
|
// 'November' => '',
|
||||||
|
// 'December' => '',
|
||||||
|
// 'Sunday' => '',
|
||||||
|
// 'Monday' => '',
|
||||||
|
// 'Tuesday' => '',
|
||||||
|
// 'Wednesday' => '',
|
||||||
|
// 'Thursday' => '',
|
||||||
|
// 'Friday' => '',
|
||||||
|
// 'Saturday' => '',
|
||||||
|
// 'Sun' => '',
|
||||||
|
// 'Mon' => '',
|
||||||
|
// 'Tue' => '',
|
||||||
|
// 'Wed' => '',
|
||||||
|
// 'Thu' => '',
|
||||||
|
// 'Fri' => '',
|
||||||
|
// 'Sat' => '',
|
||||||
// 'Next' => '',
|
// 'Next' => '',
|
||||||
|
// '#%d' => '',
|
||||||
|
// 'Filter by color' => '',
|
||||||
|
// 'Filter by swimlane' => '',
|
||||||
|
// 'All swimlanes' => '',
|
||||||
|
// 'All colors' => '',
|
||||||
|
// 'All status' => '',
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ class Acl extends Base
|
|||||||
'project' => array('show', 'tasks', 'search', 'activity'),
|
'project' => array('show', 'tasks', 'search', 'activity'),
|
||||||
'subtask' => '*',
|
'subtask' => '*',
|
||||||
'task' => '*',
|
'task' => '*',
|
||||||
|
'calendar' => '*',
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -258,16 +258,19 @@ class Board extends Base
|
|||||||
*
|
*
|
||||||
* @access public
|
* @access public
|
||||||
* @param integer $project_id
|
* @param integer $project_id
|
||||||
|
* @param boolean $prepend Prepend default value
|
||||||
* @return array
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function getColumnStats($project_id)
|
public function getColumnStats($project_id, $prepend = false)
|
||||||
{
|
{
|
||||||
return $this->db
|
$listing = $this->db
|
||||||
->table(Task::TABLE)
|
->table(Task::TABLE)
|
||||||
->eq('project_id', $project_id)
|
->eq('project_id', $project_id)
|
||||||
->eq('is_active', 1)
|
->eq('is_active', 1)
|
||||||
->groupBy('column_id')
|
->groupBy('column_id')
|
||||||
->listing('column_id', 'COUNT(*) AS total');
|
->listing('column_id', 'COUNT(*) AS total');
|
||||||
|
|
||||||
|
return $prepend ? array(-1 => t('All columns')) + $listing : $listing;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -287,11 +290,13 @@ class Board extends Base
|
|||||||
*
|
*
|
||||||
* @access public
|
* @access public
|
||||||
* @param integer $project_id Project id
|
* @param integer $project_id Project id
|
||||||
|
* @param boolean $prepend Prepend a default value
|
||||||
* @return array
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function getColumnsList($project_id)
|
public function getColumnsList($project_id, $prepend = false)
|
||||||
{
|
{
|
||||||
return $this->db->table(self::TABLE)->eq('project_id', $project_id)->asc('position')->listing('id', 'title');
|
$listing = $this->db->table(self::TABLE)->eq('project_id', $project_id)->asc('position')->listing('id', 'title');
|
||||||
|
return $prepend ? array(-1 => t('All columns')) + $listing : $listing;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -3,22 +3,68 @@
|
|||||||
namespace Model;
|
namespace Model;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Color model (TODO: model for the future color picker)
|
* Color model
|
||||||
*
|
*
|
||||||
* @package model
|
* @package model
|
||||||
* @author Frederic Guillot
|
* @author Frederic Guillot
|
||||||
*/
|
*/
|
||||||
class Color extends Base
|
class Color extends Base
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* Default colors
|
||||||
|
*
|
||||||
|
* @access private
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
private $default_colors = array(
|
||||||
|
'yellow' => array(
|
||||||
|
'name' => 'Yellow',
|
||||||
|
'background' => 'rgb(245, 247, 196)',
|
||||||
|
'border' => 'rgb(223, 227, 45)',
|
||||||
|
),
|
||||||
|
'blue' => array(
|
||||||
|
'name' => 'Blue',
|
||||||
|
'background' => 'rgb(219, 235, 255)',
|
||||||
|
'border' => 'rgb(168, 207, 255)',
|
||||||
|
),
|
||||||
|
'green' => array(
|
||||||
|
'name' => 'Green',
|
||||||
|
'background' => 'rgb(189, 244, 203)',
|
||||||
|
'border' => 'rgb(74, 227, 113)',
|
||||||
|
),
|
||||||
|
'purple' => array(
|
||||||
|
'name' => 'Purple',
|
||||||
|
'background' => 'rgb(223, 176, 255)',
|
||||||
|
'border' => 'rgb(205, 133, 254)',
|
||||||
|
),
|
||||||
|
'red' => array(
|
||||||
|
'name' => 'Red',
|
||||||
|
'background' => 'rgb(255, 187, 187)',
|
||||||
|
'border' => 'rgb(255, 151, 151)',
|
||||||
|
),
|
||||||
|
'orange' => array(
|
||||||
|
'name' => 'Orange',
|
||||||
|
'background' => 'rgb(255, 215, 179)',
|
||||||
|
'border' => 'rgb(255, 172, 98)',
|
||||||
|
),
|
||||||
|
'grey' => array(
|
||||||
|
'name' => 'Grey',
|
||||||
|
'background' => 'rgb(238, 238, 238)',
|
||||||
|
'border' => 'rgb(204, 204, 204)',
|
||||||
|
),
|
||||||
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get available colors
|
* Get available colors
|
||||||
*
|
*
|
||||||
* @access public
|
* @access public
|
||||||
* @return array
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function getList()
|
public function getList($prepend = false)
|
||||||
{
|
{
|
||||||
return array(
|
$listing = $prepend ? array('' => t('All colors')) : array();
|
||||||
|
|
||||||
|
return $listing + array(
|
||||||
'yellow' => t('Yellow'),
|
'yellow' => t('Yellow'),
|
||||||
'blue' => t('Blue'),
|
'blue' => t('Blue'),
|
||||||
'green' => t('Green'),
|
'green' => t('Green'),
|
||||||
@@ -39,4 +85,57 @@ class Color extends Base
|
|||||||
{
|
{
|
||||||
return 'yellow'; // TODO: make this parameter configurable
|
return 'yellow'; // TODO: make this parameter configurable
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get Bordercolor from string
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @param string $color_id Color id
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getBorderColor($color_id)
|
||||||
|
{
|
||||||
|
if (isset($this->default_colors[$color_id])) {
|
||||||
|
return $this->default_colors[$color_id]['border'];
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this->default_colors[$this->getDefaultColor()]['border'];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get background color from the color_id
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @param string $color_id Color id
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getBackgroundColor($color_id)
|
||||||
|
{
|
||||||
|
if (isset($this->default_colors[$color_id])) {
|
||||||
|
return $this->default_colors[$color_id]['background'];
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this->default_colors[$this->getDefaultColor()]['background'];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get CSS stylesheet of all colors
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @return string
|
||||||
|
*/
|
||||||
|
public function getCss()
|
||||||
|
{
|
||||||
|
$buffer = '';
|
||||||
|
|
||||||
|
foreach ($this->default_colors as $color => $values) {
|
||||||
|
$buffer .= 'td.color-'.$color.',';
|
||||||
|
$buffer .= 'div.color-'.$color.' {';
|
||||||
|
$buffer .= 'background-color: '.$values['background'].';';
|
||||||
|
$buffer .= 'border-color: '.$values['border'];
|
||||||
|
$buffer .= '}';
|
||||||
|
}
|
||||||
|
|
||||||
|
return $buffer;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -98,6 +98,18 @@ class DateParser extends Base
|
|||||||
return mktime(0, 0, 0, date('m', $timestamp), date('d', $timestamp), date('Y', $timestamp));
|
return mktime(0, 0, 0, date('m', $timestamp), date('d', $timestamp), date('Y', $timestamp));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get a timetstamp from an ISO date format
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @param string $date Date format
|
||||||
|
* @return integer
|
||||||
|
*/
|
||||||
|
public function getTimestampFromIsoFormat($date)
|
||||||
|
{
|
||||||
|
return $this->resetDateToMidnight(strtotime($date));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Format date (form display)
|
* Format date (form display)
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -161,20 +161,20 @@ class Swimlane extends Base
|
|||||||
*
|
*
|
||||||
* @access public
|
* @access public
|
||||||
* @param integer $project_id Project id
|
* @param integer $project_id Project id
|
||||||
|
* @param boolean $prepend Prepend default value
|
||||||
* @return array
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function getSwimlanesList($project_id)
|
public function getList($project_id, $prepend = false)
|
||||||
{
|
{
|
||||||
$swimlanes = $this->db->table(self::TABLE)
|
$swimlanes = array();
|
||||||
->eq('project_id', $project_id)
|
$swimlanes[] = $this->db->table(Project::TABLE)->eq('id', $project_id)->findOneColumn('default_swimlane');
|
||||||
->orderBy('position', 'asc')
|
|
||||||
->listing('id', 'name');
|
|
||||||
|
|
||||||
$swimlanes[0] = $this->db->table(Project::TABLE)
|
$swimlanes = array_merge(
|
||||||
->eq('id', $project_id)
|
$swimlanes,
|
||||||
->findOneColumn('default_swimlane');
|
$this->db->table(self::TABLE)->eq('project_id', $project_id)->orderBy('name', 'asc')->listing('id', 'name')
|
||||||
|
);
|
||||||
|
|
||||||
return $swimlanes;
|
return $prepend ? array(-1 => t('All swimlanes')) + $swimlanes : $swimlanes;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ class TaskExport extends Base
|
|||||||
public function export($project_id, $from, $to)
|
public function export($project_id, $from, $to)
|
||||||
{
|
{
|
||||||
$tasks = $this->getTasks($project_id, $from, $to);
|
$tasks = $this->getTasks($project_id, $from, $to);
|
||||||
$swimlanes = $this->swimlane->getSwimlanesList($project_id);
|
$swimlanes = $this->swimlane->getList($project_id);
|
||||||
$results = array($this->getColumns());
|
$results = array($this->getColumns());
|
||||||
|
|
||||||
foreach ($tasks as &$task) {
|
foreach ($tasks as &$task) {
|
||||||
|
|||||||
117
app/Model/TaskFilter.php
Normal file
117
app/Model/TaskFilter.php
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Model;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Task Filter
|
||||||
|
*
|
||||||
|
* @package model
|
||||||
|
* @author Frederic Guillot
|
||||||
|
*/
|
||||||
|
class TaskFilter extends Base
|
||||||
|
{
|
||||||
|
private $query;
|
||||||
|
|
||||||
|
public function create()
|
||||||
|
{
|
||||||
|
$this->query = $this->db->table(Task::TABLE);
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByProject($project_id)
|
||||||
|
{
|
||||||
|
if ($project_id > 0) {
|
||||||
|
$this->query->eq('project_id', $project_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByCategory($category_id)
|
||||||
|
{
|
||||||
|
if ($category_id >= 0) {
|
||||||
|
$this->query->eq('category_id', $category_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByOwner($owner_id)
|
||||||
|
{
|
||||||
|
if ($owner_id >= 0) {
|
||||||
|
$this->query->eq('owner_id', $owner_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByColor($color_id)
|
||||||
|
{
|
||||||
|
if ($color_id !== '') {
|
||||||
|
$this->query->eq('color_id', $color_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByColumn($column_id)
|
||||||
|
{
|
||||||
|
if ($column_id >= 0) {
|
||||||
|
$this->query->eq('column_id', $column_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterBySwimlane($swimlane_id)
|
||||||
|
{
|
||||||
|
if ($swimlane_id >= 0) {
|
||||||
|
$this->query->eq('swimlane_id', $swimlane_id);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByStatus($is_active)
|
||||||
|
{
|
||||||
|
if ($is_active >= 0) {
|
||||||
|
$this->query->eq('is_active', $is_active);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function filterByDueDateRange($start, $end)
|
||||||
|
{
|
||||||
|
$this->query->gte('date_due', $this->dateParser->getTimestampFromIsoFormat($start));
|
||||||
|
$this->query->lte('date_due', $this->dateParser->getTimestampFromIsoFormat($end));
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function findAll()
|
||||||
|
{
|
||||||
|
return $this->query->findAll();
|
||||||
|
}
|
||||||
|
|
||||||
|
public function toCalendarEvents()
|
||||||
|
{
|
||||||
|
$events = array();
|
||||||
|
|
||||||
|
foreach ($this->query->findAll() as $task) {
|
||||||
|
$events[] = array(
|
||||||
|
'id' => $task['id'],
|
||||||
|
'title' => t('#%d', $task['id']).' '.$task['title'],
|
||||||
|
'start' => date('Y-m-d', $task['date_due']),
|
||||||
|
'end' => date('Y-m-d', $task['date_due']),
|
||||||
|
'allday' => true,
|
||||||
|
'backgroundColor' => $this->color->getBackgroundColor($task['color_id']),
|
||||||
|
'borderColor' => $this->color->getBorderColor($task['color_id']),
|
||||||
|
'textColor' => 'black',
|
||||||
|
'url' => $this->helper->url('task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
return $events;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -12,6 +12,23 @@ use Event\TaskEvent;
|
|||||||
*/
|
*/
|
||||||
class TaskStatus extends Base
|
class TaskStatus extends Base
|
||||||
{
|
{
|
||||||
|
/**
|
||||||
|
* Return the list of statuses
|
||||||
|
*
|
||||||
|
* @access public
|
||||||
|
* @param boolean $prepend Prepend default value
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
public function getList($prepend = false)
|
||||||
|
{
|
||||||
|
$listing = $prepend ? array(-1 => t('All status')) : array();
|
||||||
|
|
||||||
|
return $listing + array(
|
||||||
|
Task::STATUS_OPEN => t('Open'),
|
||||||
|
Task::STATUS_CLOSED => t('Closed'),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return true if the task is closed
|
* Return true if the task is closed
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -39,6 +39,7 @@ class ClassProvider implements ServiceProviderInterface
|
|||||||
'TaskDuplication',
|
'TaskDuplication',
|
||||||
'TaskExport',
|
'TaskExport',
|
||||||
'TaskFinder',
|
'TaskFinder',
|
||||||
|
'TaskFilter',
|
||||||
'TaskModification',
|
'TaskModification',
|
||||||
'TaskPaginator',
|
'TaskPaginator',
|
||||||
'TaskPermission',
|
'TaskPermission',
|
||||||
@@ -51,6 +52,7 @@ class ClassProvider implements ServiceProviderInterface
|
|||||||
'Webhook',
|
'Webhook',
|
||||||
),
|
),
|
||||||
'Core' => array(
|
'Core' => array(
|
||||||
|
'Helper',
|
||||||
'Template',
|
'Template',
|
||||||
'Session',
|
'Session',
|
||||||
'MemoryCache',
|
'MemoryCache',
|
||||||
|
|||||||
@@ -17,6 +17,7 @@
|
|||||||
<?php if ($this->isManager($project['id'])): ?>
|
<?php if ($this->isManager($project['id'])): ?>
|
||||||
<?= $this->a('<i class="fa fa-cog"></i>', 'project', 'show', array('project_id' => $project['id']), false, 'dashboard-table-link', t('Settings')) ?>
|
<?= $this->a('<i class="fa fa-cog"></i>', 'project', 'show', array('project_id' => $project['id']), false, 'dashboard-table-link', t('Settings')) ?>
|
||||||
<?php endif ?>
|
<?php endif ?>
|
||||||
|
<?= $this->a('<i class="fa fa-calendar"></i>', 'calendar', 'show', array('project_id' => $project['id']), false, 'dashboard-table-link', t('Calendar')) ?>
|
||||||
<?= $this->a($this->e($project['name']), 'board', 'show', array('project_id' => $project['id'])) ?>
|
<?= $this->a($this->e($project['name']), 'board', 'show', array('project_id' => $project['id'])) ?>
|
||||||
</td>
|
</td>
|
||||||
<td class="dashboard-project-stats">
|
<td class="dashboard-project-stats">
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<?php foreach ($subtasks as $subtask): ?>
|
<?php foreach ($subtasks as $subtask): ?>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="task-table task-<?= $subtask['color_id'] ?>">
|
<td class="task-table color-<?= $subtask['color_id'] ?>">
|
||||||
<?= $this->a('#'.$subtask['task_id'], 'task', 'show', array('task_id' => $subtask['task_id'], 'project_id' => $subtask['project_id'])) ?>
|
<?= $this->a('#'.$subtask['task_id'], 'task', 'show', array('task_id' => $subtask['task_id'], 'project_id' => $subtask['project_id'])) ?>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<?php foreach ($tasks as $task): ?>
|
<?php foreach ($tasks as $task): ?>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="task-table task-<?= $task['color_id'] ?>">
|
<td class="task-table color-<?= $task['color_id'] ?>">
|
||||||
<?= $this->a('#'.$task['id'], 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
|
<?= $this->a('#'.$task['id'], 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
|||||||
@@ -23,13 +23,19 @@
|
|||||||
<i class="fa fa-dashboard fa-fw"></i>
|
<i class="fa fa-dashboard fa-fw"></i>
|
||||||
<?= $this->a(t('Activity'), 'project', 'activity', array('project_id' => $project['id'])) ?>
|
<?= $this->a(t('Activity'), 'project', 'activity', array('project_id' => $project['id'])) ?>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<i class="fa fa-calendar fa-fw"></i>
|
||||||
|
<?= $this->a(t('Calendar'), 'calendar', 'show', array('project_id' => $project['id'])) ?>
|
||||||
|
</li>
|
||||||
<?php if ($this->acl->isManagerActionAllowed($project['id'])): ?>
|
<?php if ($this->acl->isManagerActionAllowed($project['id'])): ?>
|
||||||
<li>
|
<li>
|
||||||
<i class="fa fa-line-chart fa-fw"></i>
|
<i class="fa fa-line-chart fa-fw"></i>
|
||||||
<?= $this->a(t('Analytics'), 'analytic', 'tasks', array('project_id' => $project['id'])) ?>
|
<?= $this->a(t('Analytics'), 'analytic', 'tasks', array('project_id' => $project['id'])) ?>
|
||||||
</li>
|
</li>
|
||||||
<li><i class="fa fa-cog fa-fw"></i>
|
<li>
|
||||||
|
<i class="fa fa-cog fa-fw"></i>
|
||||||
<?= $this->a(t('Configure'), 'project', 'show', array('project_id' => $project['id'])) ?>
|
<?= $this->a(t('Configure'), 'project', 'show', array('project_id' => $project['id'])) ?>
|
||||||
|
</li>
|
||||||
<?php endif ?>
|
<?php endif ?>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
<?php if ($not_editable): ?>
|
<?php if ($not_editable): ?>
|
||||||
|
|
||||||
<div class="task-board task-<?= $task['color_id'] ?> <?= $task['date_modification'] > time() - $board_highlight_period ? 'task-board-recent' : '' ?>">
|
<div class="task-board color-<?= $task['color_id'] ?> <?= $task['date_modification'] > time() - $board_highlight_period ? 'task-board-recent' : '' ?>">
|
||||||
|
|
||||||
<?= $this->a('#'.$task['id'], 'task', 'readonly', array('task_id' => $task['id'], 'token' => $project['token'])) ?>
|
<?= $this->a('#'.$task['id'], 'task', 'readonly', array('task_id' => $task['id'], 'token' => $project['token'])) ?>
|
||||||
|
|
||||||
@@ -30,7 +30,7 @@
|
|||||||
|
|
||||||
<?php else: ?>
|
<?php else: ?>
|
||||||
|
|
||||||
<div class="task-board draggable-item task-<?= $task['color_id'] ?> <?= $task['date_modification'] > time() - $board_highlight_period ? 'task-board-recent' : '' ?>"
|
<div class="task-board draggable-item color-<?= $task['color_id'] ?> <?= $task['date_modification'] > time() - $board_highlight_period ? 'task-board-recent' : '' ?>"
|
||||||
data-task-id="<?= $task['id'] ?>"
|
data-task-id="<?= $task['id'] ?>"
|
||||||
data-owner-id="<?= $task['owner_id'] ?>"
|
data-owner-id="<?= $task['owner_id'] ?>"
|
||||||
data-category-id="<?= $task['category_id'] ?>"
|
data-category-id="<?= $task['category_id'] ?>"
|
||||||
|
|||||||
29
app/Template/calendar/show.php
Normal file
29
app/Template/calendar/show.php
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
<section id="main">
|
||||||
|
<div class="page-header">
|
||||||
|
<ul>
|
||||||
|
<li><i class="fa fa-table fa-fw"></i><?= $this->a(t('Back to the board'), 'board', 'show', array('project_id' => $project['id'])) ?></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<section class="sidebar-container">
|
||||||
|
|
||||||
|
<?= $this->render('calendar/sidebar', array(
|
||||||
|
'project' => $project,
|
||||||
|
'users_list' => $users_list,
|
||||||
|
'categories_list' => $categories_list,
|
||||||
|
'columns_list' => $columns_list,
|
||||||
|
'swimlanes_list' => $swimlanes_list,
|
||||||
|
'colors_list' => $colors_list,
|
||||||
|
'status_list' => $status_list
|
||||||
|
)) ?>
|
||||||
|
|
||||||
|
<div class="sidebar-content">
|
||||||
|
<div id="calendar"
|
||||||
|
data-save-url="<?= $this->u('calendar', 'save', array('project_id' => $project['id'])) ?>"
|
||||||
|
data-check-url="<?= $this->u('calendar', 'events', array('project_id' => $project['id'])) ?>"
|
||||||
|
data-check-interval="<?= $check_interval ?>"
|
||||||
|
data-translations='<?= $this->getCalendarTranslations() ?>'
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</section>
|
||||||
40
app/Template/calendar/sidebar.php
Normal file
40
app/Template/calendar/sidebar.php
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
<div class="sidebar">
|
||||||
|
<ul class="no-bullet">
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by user') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('owner_id', $users_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by category') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('category_id', $categories_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by column') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('column_id', $columns_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by swimlane') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('swimlane_id', $swimlanes_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by color') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('color_id', $colors_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= t('Filter by status') ?>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<?= $this->formSelect('is_active', $status_list, array(), array(), 'calendar-filter') ?>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
@@ -14,6 +14,7 @@
|
|||||||
<?= $this->js('assets/js/app.js') ?>
|
<?= $this->js('assets/js/app.js') ?>
|
||||||
<?php endif ?>
|
<?php endif ?>
|
||||||
|
|
||||||
|
<?= $this->css($this->u('app', 'colors'), false) ?>
|
||||||
<?= $this->css('assets/css/app.css') ?>
|
<?= $this->css('assets/css/app.css') ?>
|
||||||
|
|
||||||
<link rel="icon" type="image/png" href="assets/img/favicon.png">
|
<link rel="icon" type="image/png" href="assets/img/favicon.png">
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<div class="task-<?= $task['color_id'] ?> task-show-details">
|
<div class="color-<?= $task['color_id'] ?> task-show-details">
|
||||||
<h2><?= $this->e('#'.$task['id'].' '.$task['title']) ?></h2>
|
<h2><?= $this->e('#'.$task['id'].' '.$task['title']) ?></h2>
|
||||||
<?php if ($task['score']): ?>
|
<?php if ($task['score']): ?>
|
||||||
<span class="task-score"><?= $this->e($task['score']) ?></span>
|
<span class="task-score"><?= $this->e($task['score']) ?></span>
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<?php foreach ($tasks as $task): ?>
|
<?php foreach ($tasks as $task): ?>
|
||||||
<tr>
|
<tr>
|
||||||
<td class="task-table task-<?= $task['color_id'] ?>">
|
<td class="task-table color-<?= $task['color_id'] ?>">
|
||||||
<?= $this->a('#'.$this->e($task['id']), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, '', t('View this task')) ?>
|
<?= $this->a('#'.$this->e($task['id']), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, '', t('View this task')) ?>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
5
assets/css/fullcalendar.min.css
vendored
Normal file
5
assets/css/fullcalendar.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -13,6 +13,7 @@
|
|||||||
left: 0px;
|
left: 0px;
|
||||||
top: 0;
|
top: 0;
|
||||||
max-width: 250px;
|
max-width: 250px;
|
||||||
|
min-width: 200px;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
padding-top: 0;
|
padding-top: 0;
|
||||||
border: 1px solid #ddd;
|
border: 1px solid #ddd;
|
||||||
|
|||||||
@@ -205,46 +205,3 @@ a.task-board-nobody {
|
|||||||
margin-bottom: 25px;
|
margin-bottom: 25px;
|
||||||
padding: 3px;
|
padding: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* task colors */
|
|
||||||
tr td.task-blue,
|
|
||||||
.task-blue {
|
|
||||||
background-color: rgb(219, 235, 255);
|
|
||||||
border-color: rgb(168, 207, 255);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-purple,
|
|
||||||
.task-purple {
|
|
||||||
background-color: rgb(223, 176, 255);
|
|
||||||
border-color: rgb(205, 133, 254);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-grey,
|
|
||||||
.task-grey {
|
|
||||||
background-color: rgb(238, 238, 238);
|
|
||||||
border-color: rgb(204, 204, 204);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-red,
|
|
||||||
.task-red {
|
|
||||||
background-color: rgb(255, 187, 187);
|
|
||||||
border-color: rgb(255, 151, 151);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-green,
|
|
||||||
.task-green {
|
|
||||||
background-color: rgb(189, 244, 203);
|
|
||||||
border-color: rgb(74, 227, 113);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-yellow,
|
|
||||||
.task-yellow {
|
|
||||||
background-color: rgb(245, 247, 196);
|
|
||||||
border-color: rgb(223, 227, 45);
|
|
||||||
}
|
|
||||||
|
|
||||||
tr td.task-orange,
|
|
||||||
.task-orange {
|
|
||||||
background-color: rgb(255, 215, 179);
|
|
||||||
border-color: rgb(255, 172, 98);
|
|
||||||
}
|
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -65,6 +65,22 @@ var Kanboard = (function() {
|
|||||||
return true;
|
return true;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// Save preferences in local storage
|
||||||
|
SetStorageItem: function(key, value) {
|
||||||
|
if (typeof(Storage) !== "undefined") {
|
||||||
|
localStorage.setItem(key, value);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
GetStorageItem: function(key) {
|
||||||
|
|
||||||
|
if (typeof(Storage) !== "undefined") {
|
||||||
|
return localStorage.getItem(key);
|
||||||
|
}
|
||||||
|
|
||||||
|
return '';
|
||||||
|
},
|
||||||
|
|
||||||
// Generate Markdown preview
|
// Generate Markdown preview
|
||||||
MarkdownPreview: function(e) {
|
MarkdownPreview: function(e) {
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
// Board related functions
|
|
||||||
Kanboard.Board = (function() {
|
Kanboard.Board = (function() {
|
||||||
|
|
||||||
var checkInterval = null;
|
var checkInterval = null;
|
||||||
@@ -191,6 +190,7 @@ Kanboard.Board = (function() {
|
|||||||
var selectedUserId = $("#form-user_id").val();
|
var selectedUserId = $("#form-user_id").val();
|
||||||
var selectedCategoryId = $("#form-category_id").val();
|
var selectedCategoryId = $("#form-category_id").val();
|
||||||
var filterDueDate = $("#filter-due-date").hasClass("filter-on");
|
var filterDueDate = $("#filter-due-date").hasClass("filter-on");
|
||||||
|
var projectId = $('#board').data('project-id');
|
||||||
|
|
||||||
$("[data-task-id]").each(function(index, item) {
|
$("[data-task-id]").each(function(index, item) {
|
||||||
|
|
||||||
@@ -214,43 +214,36 @@ Kanboard.Board = (function() {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Save filter settings for active project to localStorage
|
// Save filter settings
|
||||||
if (typeof(Storage) !== "undefined") {
|
Kanboard.SetStorageItem("board_filter_" + projectId + "_form-user_id", selectedUserId);
|
||||||
var projectId = $('#board').data('project-id');
|
Kanboard.SetStorageItem("board_filter_" + projectId + "_form-category_id", selectedCategoryId);
|
||||||
localStorage.setItem("filters_" + projectId + "_form-user_id", selectedUserId);
|
Kanboard.SetStorageItem("board_filter_" + projectId + "_filter-due-date", ~~(filterDueDate));
|
||||||
localStorage.setItem("filters_" + projectId + "_form-category_id", selectedCategoryId);
|
|
||||||
localStorage.setItem("filters_" + projectId + "_filter-due-date", ~~(filterDueDate));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Load filter events
|
// Load filter events
|
||||||
function filter_load_events()
|
function filter_load_events()
|
||||||
{
|
{
|
||||||
|
var projectId = $('#board').data('project-id');
|
||||||
|
|
||||||
$("#form-user_id").change(filter_apply);
|
$("#form-user_id").change(filter_apply);
|
||||||
|
|
||||||
$("#form-category_id").change(filter_apply);
|
$("#form-category_id").change(filter_apply);
|
||||||
|
|
||||||
$("#filter-due-date").click(function(e) {
|
$("#filter-due-date").click(function(e) {
|
||||||
$(this).toggleClass("filter-on");
|
$(this).toggleClass("filter-on");
|
||||||
filter_apply();
|
filter_apply();
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
});
|
});
|
||||||
|
|
||||||
// Get and set filters from localStorage for active project
|
// Get and set filters from localStorage
|
||||||
if (typeof(Storage) !== "undefined") {
|
$("#form-user_id").val(Kanboard.GetStorageItem("board_filter_" + projectId + "_form-user_id") || -1);
|
||||||
var projectId = $('#board').data('project-id');
|
$("#form-category_id").val(Kanboard.GetStorageItem("board_filter_" + projectId + "_form-category_id") || -1);
|
||||||
|
|
||||||
$("#form-user_id").val(localStorage.getItem("filters_" + projectId + "_form-user_id") || -1);
|
if (+Kanboard.GetStorageItem("board_filter_" + projectId + "_filter-due-date")) {
|
||||||
$("#form-category_id").val(localStorage.getItem("filters_" + projectId + "_form-category_id") || -1);
|
$("#filter-due-date").addClass("filter-on");
|
||||||
|
} else {
|
||||||
if (+localStorage.getItem("filters_" + projectId + "_filter-due-date")) {
|
$("#filter-due-date").removeClass("filter-on");
|
||||||
$("#filter-due-date").addClass("filter-on");
|
|
||||||
} else {
|
|
||||||
$("#filter-due-date").removeClass("filter-on");
|
|
||||||
}
|
|
||||||
|
|
||||||
filter_apply();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
filter_apply();
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
|||||||
103
assets/js/calendar.js
Normal file
103
assets/js/calendar.js
Normal file
@@ -0,0 +1,103 @@
|
|||||||
|
Kanboard.Calendar = (function() {
|
||||||
|
|
||||||
|
// Show the empty calendar
|
||||||
|
function show_calendar()
|
||||||
|
{
|
||||||
|
var calendar = $("#calendar");
|
||||||
|
var translations = calendar.data("translations");
|
||||||
|
|
||||||
|
calendar.fullCalendar({
|
||||||
|
editable: true,
|
||||||
|
eventLimit: true,
|
||||||
|
header: {
|
||||||
|
left: 'prev,next today',
|
||||||
|
center: 'title',
|
||||||
|
right: ''
|
||||||
|
},
|
||||||
|
eventDrop: move_calendar_event,
|
||||||
|
monthNames: [translations.January, translations.February, translations.March, translations.April, translations.May, translations.June, translations.July, translations.August, translations.September, translations.October, translations.November, translations.December],
|
||||||
|
monthNamesShort: [translations.Jan, translations.Feb, translations.Mar, translations.Apr, translations.May, translations.Jun, translations.Jul, translations.Aug, translations.Sep, translations.Oct, translations.Nov, translations.Dec],
|
||||||
|
buttonText: {today: translations.Today},
|
||||||
|
dayNames: [translations.Sunday, translations.Monday, translations.Tuesday, translations.Wednesday, translations.Thursday, translations.Friday, translations.Saturday],
|
||||||
|
dayNamesShort: [translations.Sun, translations.Mon, translations.Tue, translations.Wed, translations.Thu, translations.Fri, translations.Sat]
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// Save the new due date for a moved task
|
||||||
|
function move_calendar_event(calendar_event)
|
||||||
|
{
|
||||||
|
$.ajax({
|
||||||
|
cache: false,
|
||||||
|
url: $("#calendar").data("save-url"),
|
||||||
|
contentType: "application/json",
|
||||||
|
type: "POST",
|
||||||
|
processData: false,
|
||||||
|
data: JSON.stringify({
|
||||||
|
"task_id": calendar_event.id,
|
||||||
|
"date_due": calendar_event.start.format()
|
||||||
|
})
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// Refresh the calendar events
|
||||||
|
function refresh_calendar(filters)
|
||||||
|
{
|
||||||
|
var calendar = $("#calendar");
|
||||||
|
var url = calendar.data("check-url");
|
||||||
|
var params = {
|
||||||
|
"start": calendar.fullCalendar('getView').start.format(),
|
||||||
|
"end": calendar.fullCalendar('getView').end.format()
|
||||||
|
}
|
||||||
|
|
||||||
|
jQuery.extend(params, filters);
|
||||||
|
|
||||||
|
for (var key in params) {
|
||||||
|
url += "&" + key + "=" + params[key];
|
||||||
|
}
|
||||||
|
|
||||||
|
$.getJSON(url, function(events) {
|
||||||
|
calendar.fullCalendar('removeEvents');
|
||||||
|
calendar.fullCalendar('addEventSource', events);
|
||||||
|
calendar.fullCalendar('rerenderEvents');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
// Restore saved filters
|
||||||
|
function load_filters()
|
||||||
|
{
|
||||||
|
var filters = Kanboard.GetStorageItem('calendar_filters');
|
||||||
|
|
||||||
|
if (filters !== "undefined" && filters !== "") {
|
||||||
|
filters = JSON.parse(filters);
|
||||||
|
|
||||||
|
for (var filter in filters) {
|
||||||
|
$("select[name=" + filter + "]").val(filters[filter]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
refresh_calendar(filters || {});
|
||||||
|
|
||||||
|
$('.calendar-filter').change(apply_filters);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Apply filters on change
|
||||||
|
function apply_filters()
|
||||||
|
{
|
||||||
|
var filters = {};
|
||||||
|
|
||||||
|
$('.calendar-filter').each(function(index, element) {
|
||||||
|
filters[$(this).attr("name")] = $(this).val();
|
||||||
|
});
|
||||||
|
|
||||||
|
Kanboard.SetStorageItem("calendar_filters", JSON.stringify(filters));
|
||||||
|
refresh_calendar(filters);
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
Init: function() {
|
||||||
|
show_calendar();
|
||||||
|
load_filters();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
})();
|
||||||
8
assets/js/fullcalendar.min.js
vendored
Normal file
8
assets/js/fullcalendar.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -6,6 +6,9 @@ $(function() {
|
|||||||
if (Kanboard.Exists("board")) {
|
if (Kanboard.Exists("board")) {
|
||||||
Kanboard.Board.Init();
|
Kanboard.Board.Init();
|
||||||
}
|
}
|
||||||
|
else if (Kanboard.Exists("calendar")) {
|
||||||
|
Kanboard.Calendar.Init();
|
||||||
|
}
|
||||||
else if (Kanboard.Exists("task-section")) {
|
else if (Kanboard.Exists("task-section")) {
|
||||||
Kanboard.Task.Init();
|
Kanboard.Task.Init();
|
||||||
}
|
}
|
||||||
|
|||||||
6
assets/js/moment.min.js
vendored
Normal file
6
assets/js/moment.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
@@ -1,8 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
css="base links title table form button alert tooltip header board project task comment subtask markdown listing activity dashboard pagination popover confirm sidebar responsive font-awesome.min jquery-ui-1.10.4.custom chosen.min"
|
css="base links title table form button alert tooltip header board project task comment subtask markdown listing activity dashboard pagination popover confirm sidebar responsive jquery-ui-1.10.4.custom chosen.min fullcalendar.min font-awesome.min"
|
||||||
js="jquery-1.11.1.min jquery-ui-1.10.4.custom.min jquery.ui.touch-punch.min chosen.jquery.min minify.min"
|
js="jquery-1.11.1.min jquery-ui-1.10.4.custom.min jquery.ui.touch-punch.min chosen.jquery.min moment.min fullcalendar.min minify.min"
|
||||||
minify="base board task analytic init"
|
minify="base board calendar task analytic init"
|
||||||
|
|
||||||
rm -f assets/js/minify* 2>/dev/null
|
rm -f assets/js/minify* 2>/dev/null
|
||||||
rm -f assets/js/app.js 2>/dev/null
|
rm -f assets/js/app.js 2>/dev/null
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ class SwimlaneTest extends Base
|
|||||||
$this->assertEquals(1, $s->create(1, 'Swimlane #1'));
|
$this->assertEquals(1, $s->create(1, 'Swimlane #1'));
|
||||||
$this->assertEquals(2, $s->create(1, 'Swimlane #2'));
|
$this->assertEquals(2, $s->create(1, 'Swimlane #2'));
|
||||||
|
|
||||||
$swimlanes = $s->getSwimlanesList(1);
|
$swimlanes = $s->getList(1);
|
||||||
$expected = array('Default swimlane', 'Swimlane #1', 'Swimlane #2');
|
$expected = array('Default swimlane', 'Swimlane #1', 'Swimlane #2');
|
||||||
|
|
||||||
$this->assertEquals($expected, $swimlanes);
|
$this->assertEquals($expected, $swimlanes);
|
||||||
|
|||||||
Reference in New Issue
Block a user