diff --git a/app/Controller/Board.php b/app/Controller/Board.php
index 90b7f3575..a6e002f2f 100644
--- a/app/Controller/Board.php
+++ b/app/Controller/Board.php
@@ -127,6 +127,7 @@ class Board extends Base
'swimlanes' => $this->board->getBoard($project['id']),
'categories' => $this->category->getList($project['id'], false),
'title' => $project['name'],
+ 'description' => $project['description'],
'no_layout' => true,
'not_editable' => true,
'board_public_refresh_interval' => $this->config->get('board_public_refresh_interval'),
@@ -187,6 +188,7 @@ class Board extends Base
'swimlanes' => $this->board->getBoard($project['id']),
'categories' => $this->category->getList($project['id'], true, true),
'title' => $project['name'],
+ 'description' => $project['description'],
'board_selector' => $board_selector,
'board_private_refresh_interval' => $this->config->get('board_private_refresh_interval'),
'board_highlight_period' => $this->config->get('board_highlight_period'),
diff --git a/app/Schema/Mysql.php b/app/Schema/Mysql.php
index 947a62b35..eeab24d69 100644
--- a/app/Schema/Mysql.php
+++ b/app/Schema/Mysql.php
@@ -6,7 +6,12 @@ use PDO;
use Core\Security;
use Model\Link;
-const VERSION = 46;
+const VERSION = 47;
+
+function version_47($pdo)
+{
+ $pdo->exec('ALTER TABLE projects ADD COLUMN description TEXT');
+}
function version_46($pdo)
{
diff --git a/app/Schema/Postgres.php b/app/Schema/Postgres.php
index 027401ff4..c3e8fbda6 100644
--- a/app/Schema/Postgres.php
+++ b/app/Schema/Postgres.php
@@ -6,7 +6,12 @@ use PDO;
use Core\Security;
use Model\Link;
-const VERSION = 27;
+const VERSION = 28;
+
+function version_28($pdo)
+{
+ $pdo->exec('ALTER TABLE projects ADD COLUMN description TEXT');
+}
function version_27($pdo)
{
diff --git a/app/Schema/Sqlite.php b/app/Schema/Sqlite.php
index c6dec33f0..eefa0ae11 100644
--- a/app/Schema/Sqlite.php
+++ b/app/Schema/Sqlite.php
@@ -6,7 +6,12 @@ use Core\Security;
use PDO;
use Model\Link;
-const VERSION = 45;
+const VERSION = 46;
+
+function version_46($pdo)
+{
+ $pdo->exec('ALTER TABLE projects ADD COLUMN description TEXT');
+}
function version_45($pdo)
{
diff --git a/app/Template/app/projects.php b/app/Template/app/projects.php
index 4740c4b87..c3a39a839 100644
--- a/app/Template/app/projects.php
+++ b/app/Template/app/projects.php
@@ -17,9 +17,15 @@
isManager($project['id'])): ?>
= $this->a('', 'project', 'show', array('project_id' => $project['id']), false, 'dashboard-table-link', t('Settings')) ?>
-
+
= $this->a('', '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'])) ?>
+
+
+
+
+
@@ -32,4 +38,4 @@
= $paginator ?>
-
\ No newline at end of file
+
diff --git a/app/Template/layout.php b/app/Template/layout.php
index ad4c4084f..7adb05598 100644
--- a/app/Template/layout.php
+++ b/app/Template/layout.php
@@ -35,7 +35,13 @@
|
@@ -54,4 +60,4 @@
= $paginator ?>
-
\ No newline at end of file
+
diff --git a/app/Template/project/show.php b/app/Template/project/show.php
index b8bfd5101..b00033707 100644
--- a/app/Template/project/show.php
+++ b/app/Template/project/show.php
@@ -60,3 +60,13 @@
+
+
+
+
+
+ = $this->markdown($project['description']) ?>
+
+
diff --git a/docs/api-json-rpc.markdown b/docs/api-json-rpc.markdown
index 346b1decb..0e6464378 100644
--- a/docs/api-json-rpc.markdown
+++ b/docs/api-json-rpc.markdown
@@ -176,6 +176,7 @@ Response example:
- Purpose: **Create a new project**
- Parameters:
- **name** (string, required)
+ - **description** (string, optional)
- Result on success: **project_id**
- Result on failure: **false**
@@ -235,7 +236,8 @@ Response example:
"is_active": "1",
"token": "",
"last_modified": "1410263246",
- "is_public": "0"
+ "is_public": "0",
+ "description": "A sample project"
}
}
```
@@ -273,7 +275,8 @@ Response example:
"is_active": "1",
"token": "",
"last_modified": "0",
- "is_public": "0"
+ "is_public": "0",
+ "description": "A sample project"
}
}
```
@@ -309,7 +312,8 @@ Response example:
"is_active": "1",
"token": "",
"last_modified": "0",
- "is_public": "0"
+ "is_public": "0",
+ "description": "PHP client project"
},
{
"id": "1",
@@ -317,7 +321,8 @@ Response example:
"is_active": "1",
"token": "",
"last_modified": "0",
- "is_public": "0"
+ "is_public": "0",
+ "description": "Test project"
}
]
}
@@ -332,6 +337,7 @@ Response example:
- **is_active** (integer, optional)
- **token** (string, optional)
- **is_public** (integer, optional)
+ - **description** (string, optional)
- Result on success: **true**
- Result on failure: **false**
diff --git a/jsonrpc.php b/jsonrpc.php
index 566976cdd..3c903e8f4 100644
--- a/jsonrpc.php
+++ b/jsonrpc.php
@@ -22,13 +22,16 @@ $server->bind('enableProjectPublicAccess', $container['project'], 'enablePublicA
$server->bind('disableProjectPublicAccess', $container['project'], 'disablePublicAccess');
$server->bind('getProjectActivity', $container['projectActivity'], 'getProjects');
-$server->register('createProject', function($name) use ($container) {
- $values = array('name' => $name);
+$server->register('createProject', function($name, $description = null) use ($container) {
+ $values = array(
+ 'name' => $name,
+ 'description' => $description
+ );
list($valid,) = $container['project']->validateCreation($values);
return $valid ? $container['project']->create($values) : false;
});
-$server->register('updateProject', function($id, $name, $is_active = null, $is_public = null, $token = null) use ($container) {
+$server->register('updateProject', function($id, $name, $is_active = null, $is_public = null, $token = null, $description = null) use ($container) {
$values = array(
'id' => $id,
@@ -36,6 +39,7 @@ $server->register('updateProject', function($id, $name, $is_active = null, $is_p
'is_active' => $is_active,
'is_public' => $is_public,
'token' => $token,
+ 'description' => $description
);
foreach ($values as $key => $value) {
|