Merge branch 'sgm_displaycard' into kanban
This commit is contained in:
@@ -66,8 +66,8 @@ CREATE TABLE `zt_kanbancard` (
|
||||
`pri` mediumint(8) unsigned NOT NULL,
|
||||
`assignedTo` text NOT NULL,
|
||||
`desc` text NOT NULL,
|
||||
`begin` datetime NOT NULL,
|
||||
`end` datetime NOT NULL,
|
||||
`begin` date NOT NULL,
|
||||
`end` date NOT NULL,
|
||||
`estimate` float unsigned NOT NULL,
|
||||
`color` char(7) NOT NULL,
|
||||
`acl` char(30) NOT NULL DEFAULT 'open',
|
||||
@@ -109,3 +109,4 @@ ALTER TABLE `zt_kanbanlane` ADD COLUMN `region` mediumint(8) unsigned NOT NULL A
|
||||
ALTER TABLE `zt_kanbanlane` ADD COLUMN `group` mediumint(8) unsigned NOT NULL AFTER `region`;
|
||||
ALTER TABLE `zt_kanbancolumn` ADD COLUMN `region` mediumint(8) unsigned NOT NULL AFTER `type`;
|
||||
ALTER TABLE `zt_kanbancolumn` ADD COLUMN `group` mediumint(8) unsigned NOT NULL AFTER `region`;
|
||||
ALTER TABLE `zt_project` ADD COLUMN `suspendedDate` date NOT NULL AFTER `canceledDate`;
|
||||
|
||||
+3
-2
@@ -708,8 +708,8 @@ CREATE TABLE `zt_kanbancard` (
|
||||
`pri` mediumint(8) unsigned NOT NULL,
|
||||
`assignedTo` text NOT NULL,
|
||||
`desc` text NOT NULL,
|
||||
`begin` datetime NOT NULL,
|
||||
`end` datetime NOT NULL,
|
||||
`begin` date NOT NULL,
|
||||
`end` date NOT NULL,
|
||||
`estimate` float unsigned NOT NULL,
|
||||
`color` char(7) NOT NULL,
|
||||
`acl` char(30) NOT NULL DEFAULT 'open',
|
||||
@@ -999,6 +999,7 @@ CREATE TABLE IF NOT EXISTS `zt_project` (
|
||||
`closedDate` datetime NOT NULL,
|
||||
`canceledBy` varchar(30) NOT NULL DEFAULT '',
|
||||
`canceledDate` datetime NOT NULL,
|
||||
`suspendedDate` date NOT NULL,
|
||||
`PO` varchar(30) NOT NULL DEFAULT '',
|
||||
`PM` varchar(30) NOT NULL DEFAULT '',
|
||||
`QD` varchar(30) NOT NULL DEFAULT '',
|
||||
|
||||
@@ -38,6 +38,7 @@ $config->action->objectNameFields['kanbanlane'] = 'name';
|
||||
$config->action->objectNameFields['kanbanspace'] = 'name';
|
||||
$config->action->objectNameFields['kanbanregion'] = 'name';
|
||||
$config->action->objectNameFields['kanban'] = 'name';
|
||||
$config->action->objectNameFields['kanbancard'] = 'name';
|
||||
|
||||
$config->action->commonImgSize = 870;
|
||||
|
||||
|
||||
@@ -386,10 +386,23 @@ $lang->action->dynamicAction->execution['undeleted'] = 'Restore ' . $lang->execu
|
||||
$lang->action->dynamicAction->execution['hidden'] = 'Hide ' . $lang->executionCommon;
|
||||
$lang->action->dynamicAction->execution['moved'] = 'Improt Task';
|
||||
|
||||
$lang->action->dynamicAction->kanban['create'] = 'Create Kanban';
|
||||
$lang->action->dynamicAction->kanban['edited'] = 'Kanban Settings';
|
||||
|
||||
$lang->action->dynamicAction->kanbanspace['create'] = 'Create Space';
|
||||
$lang->action->dynamicAction->kanbanspace['edited'] = 'Space Settings';
|
||||
$lang->action->dynamicAction->kanbanspace['closed'] = 'Close Kanban';
|
||||
|
||||
$lang->action->dynamicAction->kanbancolumn['create'] = 'Create Column';
|
||||
$lang->action->dynamicAction->kanbancolumn['edited'] = 'Column Settings';
|
||||
|
||||
$lang->action->dynamicAction->kanbanlane['created'] = 'Create Swimlane';
|
||||
$lang->action->dynamicAction->kanbanlane['edited'] = 'Swimlane Settings';
|
||||
$lang->action->dynamicAction->kanbanlane['moved'] = 'Move Swimlane';
|
||||
|
||||
$lang->action->dynamicAction->kanbancard['create'] = 'Create Card';
|
||||
$lang->action->dynamicAction->kanbancard['edited'] = 'Edit card';
|
||||
|
||||
$lang->action->dynamicAction->team['managedTeam'] = 'Manage Team';
|
||||
|
||||
$lang->action->dynamicAction->task['opened'] = 'Create Task';
|
||||
@@ -546,6 +559,7 @@ $lang->action->label->kanbanregion = 'Kanban Region|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->kanban = 'Kanban|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->kanbancolumn = 'Kanban Column|execution|kanban|execution=%s';
|
||||
$lang->action->label->kanbanlane = 'Kanban Lane|execution|kanban|execution=%s&type=all';
|
||||
$lang->action->label->kanbancard = 'Kanban Card|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->mr = 'Merge Request|mr|view|id=%s';
|
||||
|
||||
/* Object type. */
|
||||
|
||||
@@ -386,10 +386,23 @@ $lang->action->dynamicAction->execution['undeleted'] = '还原' . $lang->executi
|
||||
$lang->action->dynamicAction->execution['hidden'] = '隐藏' . $lang->executionCommon;
|
||||
$lang->action->dynamicAction->execution['moved'] = '导入任务';
|
||||
|
||||
$lang->action->dynamicAction->kanban['create'] = '创建看板';
|
||||
$lang->action->dynamicAction->kanban['edited'] = '设置看板';
|
||||
|
||||
$lang->action->dynamicAction->kanbanspace['create'] = '创建看板空间';
|
||||
$lang->action->dynamicAction->kanbanspace['edited'] = '设置看板空间';
|
||||
$lang->action->dynamicAction->kanbanspace['closed'] = '关闭看板空间';
|
||||
|
||||
$lang->action->dynamicAction->kanbancolumn['create'] = '创建看板列';
|
||||
$lang->action->dynamicAction->kanbancolumn['edited'] = '设置看板列';
|
||||
|
||||
$lang->action->dynamicAction->kanbanlane['created'] = '创建泳道';
|
||||
$lang->action->dynamicAction->kanbanlane['edited'] = '设置泳道';
|
||||
$lang->action->dynamicAction->kanbanlane['moved'] = '移动泳道';
|
||||
|
||||
$lang->action->dynamicAction->kanbancard['create'] = '创建看板卡片';
|
||||
$lang->action->dynamicAction->kanbancard['edited'] = '编辑看板卡片';
|
||||
|
||||
$lang->action->dynamicAction->team['managedTeam'] = '维护团队';
|
||||
|
||||
$lang->action->dynamicAction->task['opened'] = '创建任务';
|
||||
@@ -546,6 +559,7 @@ $lang->action->label->kanbanregion = '看板区域|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->kanban = '看板|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->kanbancolumn = '看板列|execution|kanban|execution=%s';
|
||||
$lang->action->label->kanbanlane = '看板泳道|execution|kanban|execution=%s&type=all';
|
||||
$lang->action->label->kanbancard = '看板卡片|kanban|view|kanbanID=%s';
|
||||
$lang->action->label->mr = '合并请求|mr|view|id=%s';
|
||||
|
||||
/* Object type. */
|
||||
|
||||
+15
-2
@@ -1233,9 +1233,22 @@ class actionModel extends model
|
||||
$action->objectLink = helper::createLink('assetlib', 'storyView', "storyID=$action->objectID");
|
||||
}
|
||||
|
||||
if($action->objectType == 'kanbanregion')
|
||||
if(strpos(',kanbanregion,kanbancard,', ",{$action->objectType},") !== false)
|
||||
{
|
||||
$kanbanID = $this->dao->select('kanban')->from(TABLE_KANBANREGION)->where('id')->eq($action->objectID)->fetch('kanban');
|
||||
$table = $this->config->objectTables[$action->objectType];
|
||||
$kanbanID = $this->dao->select('kanban')->from($table)->where('id')->eq($action->objectID)->fetch('kanban');
|
||||
|
||||
$action->objectLink = helper::createLink('kanban', 'view', "kanbanID=$kanbanID");
|
||||
}
|
||||
|
||||
if(strpos(',kanbanlane,kanbancolumn,', ",{$action->objectType},") !== false and empty($action->extra))
|
||||
{
|
||||
$table = $this->config->objectTables[$action->objectType];
|
||||
$kanbanID = $this->dao->select('t2.kanban')->from($table)->alias('t1')
|
||||
->leftJoin(TABLE_KANBANREGION)->alias('t2')->on('t1.region=t2.id')
|
||||
->where('t1.id')->eq($action->objectID)
|
||||
->fetch('kanban');
|
||||
|
||||
$action->objectLink = helper::createLink('kanban', 'view', "kanbanID=$kanbanID");
|
||||
}
|
||||
|
||||
|
||||
@@ -588,7 +588,12 @@ $lang->navGroup->task = 'execution';
|
||||
$lang->navGroup->build = 'execution';
|
||||
$lang->navGroup->team = 'execution';
|
||||
|
||||
$lang->navGroup->kanban = 'kanban';
|
||||
$lang->navGroup->kanbanspace = 'kanban';
|
||||
$lang->navGroup->kanban = 'kanban';
|
||||
$lang->navGroup->kanbanregion = 'kanban';
|
||||
$lang->navGroup->kanbanlane = 'kanban';
|
||||
$lang->navGroup->kanbancolumn = 'kanban';
|
||||
$lang->navGroup->kanbancard = 'kanban';
|
||||
|
||||
$lang->navGroup->doc = 'doc';
|
||||
$lang->navGroup->doclib = 'doc';
|
||||
|
||||
@@ -76,7 +76,14 @@ class design extends control
|
||||
$this->design->buildSearchForm($queryID, $actionURL);
|
||||
|
||||
/* Print top and right actions. */
|
||||
$this->lang->TRActions = '<div class="btn-group dropdown">';
|
||||
$this->lang->TRActions = '<div class="btn-toolbar pull-right">';
|
||||
if($this->config->maxVersion)
|
||||
{
|
||||
$this->lang->TRActions .= '<div class="btn-group">';
|
||||
$this->lang->TRActions .= html::a($this->createLink('design', 'submit', "productID=$productID", '', true), "<i class='icon-plus'></i> {$this->lang->design->createReview}", '', "class='btn btn-secondary iframe'");
|
||||
$this->lang->TRActions .= '</div>';
|
||||
}
|
||||
$this->lang->TRActions .= '<div class="btn-group dropdown">';
|
||||
$this->lang->TRActions .= html::a(inlink('create', "projectID=$projectID&productID=$productID&type=$type"), "<i class='icon-plus'></i> {$this->lang->design->create}", '', "class='btn btn-primary'");
|
||||
$this->lang->TRActions .= "<button type='button' class='btn btn-primary dropdown-toggle' data-toggle='dropdown'><span class='caret'></span>";
|
||||
$this->lang->TRActions .= '</button>';
|
||||
@@ -87,6 +94,7 @@ class design extends control
|
||||
|
||||
$this->lang->TRActions .= '</ul>';
|
||||
$this->lang->TRActions .= '</div>';
|
||||
$this->lang->TRActions .= '</div>';
|
||||
|
||||
/* Init pager and get designs. */
|
||||
$this->app->loadClass('pager', $static = true);
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = 'CreatedDate';
|
||||
$lang->design->basicInfo = 'Basic Information';
|
||||
$lang->design->noAssigned = 'Unassigned';
|
||||
$lang->design->comment = 'Comment';
|
||||
$lang->design->createReview = 'Create Review';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = 'Design';
|
||||
|
||||
@@ -37,6 +37,7 @@ $lang->design->createdDate = '创建时间';
|
||||
$lang->design->basicInfo = '基本信息';
|
||||
$lang->design->noAssigned = '未指派';
|
||||
$lang->design->comment = '注释';
|
||||
$lang->design->createReview = '发起评审';
|
||||
|
||||
/* 动作列表. */
|
||||
$lang->design->common = '设计';
|
||||
|
||||
@@ -17,8 +17,8 @@ td.flex span.label-badge {margin-left: 5px; min-width: 50px;}
|
||||
td.flex span.project-type-label {margin-left: 5px; min-width: 36px;}
|
||||
@-moz-document url-prefix() {.main-table tbody > tr.table-children > td:first-child::before {width: 4px;}}
|
||||
|
||||
.c-status, .c-date, .c-percent, .c-attribute {width: 80px;}
|
||||
.c-status, .c-date, .c-attribute {width: 80px;}
|
||||
.c-estimate, .c-consumed, .c-left, .c-pm {width: 70px;}
|
||||
.c-progress, .c-burn {width: 60px;}
|
||||
.c-realBegan, .c-end, .c-begin, .c-realEnd{width: 100px;}
|
||||
.c-percent, .c-realBegan, .c-end, .c-begin, .c-realEnd{width: 100px;}
|
||||
.c-action {text-align: center;}
|
||||
|
||||
@@ -646,6 +646,7 @@ $lang->resource->kanban->createCard = 'createCard';
|
||||
$lang->resource->kanban->editCard = 'editCard';
|
||||
$lang->resource->kanban->viewCard = 'viewCard';
|
||||
$lang->resource->kanban->sortCard = 'sortCard';
|
||||
$lang->resource->kanban->archiveCard = 'archiveCard';
|
||||
$lang->resource->kanban->laneMove = 'laneMove';
|
||||
$lang->resource->kanban->cardsSort = 'cardsSort';
|
||||
|
||||
@@ -677,8 +678,9 @@ $lang->kanban->methodOrder[125] = 'createCard';
|
||||
$lang->kanban->methodOrder[130] = 'editCard';
|
||||
$lang->kanban->methodOrder[135] = 'viewCard';
|
||||
$lang->kanban->methodOrder[140] = 'sortCard';
|
||||
$lang->kanban->methodOrder[145] = 'laneMove';
|
||||
$lang->kanban->methodOrder[150] = 'cardsSort';
|
||||
$lang->kanban->methodOrder[145] = 'archivedCard';
|
||||
$lang->kanban->methodOrder[150] = 'laneMove';
|
||||
$lang->kanban->methodOrder[155] = 'cardsSort';
|
||||
|
||||
/* Execution. */
|
||||
$lang->resource->execution = new stdclass();
|
||||
|
||||
@@ -36,8 +36,8 @@ $config->kanban->editor->createspace = array('id' => 'desc', 'tools' => 'simpleT
|
||||
$config->kanban->editor->editspace = array('id' => 'desc', 'tools' => 'simpleTools');
|
||||
$config->kanban->editor->createcard = array('id' => 'desc', 'tools' => 'simpleTools');
|
||||
$config->kanban->editor->close = array('id' => 'comment', 'tools' => 'simpleTools');
|
||||
|
||||
$config->kanban->editor->editcard = array('id' => 'desc', 'tools' => 'simpleTools');
|
||||
$config->kanban->editor->viewcard = array('id' => 'comment', 'tools' => 'simpleTools');
|
||||
|
||||
$config->kanban->default = new stdclass();
|
||||
$config->kanban->default->story = new stdclass();
|
||||
|
||||
+54
-19
@@ -50,13 +50,13 @@ class kanban extends control
|
||||
{
|
||||
$spaceID = $this->kanban->createSpace();
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
$this->loadModel('action')->create('kanbanSpace', $spaceID, 'created');
|
||||
die(js::reload('parent.parent'));
|
||||
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
|
||||
}
|
||||
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|noclosed');
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed|nodeleted');
|
||||
|
||||
$this->display();
|
||||
}
|
||||
@@ -75,16 +75,16 @@ class kanban extends control
|
||||
{
|
||||
$changes = $this->kanban->updateSpace($spaceID);
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
$actionID = $this->action->create('kanbanSpace', $spaceID, 'edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
|
||||
die(js::reload('parent.parent'));
|
||||
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
|
||||
}
|
||||
|
||||
$this->view->space = $this->kanban->getSpaceById($spaceID);
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|noclosed');
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed');
|
||||
|
||||
$this->display();
|
||||
}
|
||||
@@ -102,13 +102,13 @@ class kanban extends control
|
||||
{
|
||||
$kanbanID = $this->kanban->create();
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
$this->loadModel('action')->create('kanban', $kanbanID, 'created');
|
||||
die(js::reload('parent.parent'));
|
||||
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
|
||||
}
|
||||
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|noclosed');
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed|nodeleted');
|
||||
$this->view->spaceID = $spaceID;
|
||||
$this->view->spacePairs = array(0 => '') + $this->kanban->getSpacePairs();
|
||||
|
||||
@@ -129,15 +129,15 @@ class kanban extends control
|
||||
{
|
||||
$changes = $this->kanban->update($kanbanID);
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
$actionID = $this->action->create('kanban', $kanbanID, 'edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
|
||||
die(js::reload('parent.parent'));
|
||||
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
|
||||
}
|
||||
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter|noclosed');
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed');
|
||||
$this->view->spacePairs = array(0 => '') + $this->kanban->getSpacePairs();
|
||||
$this->view->kanban = $this->kanban->getByID($kanbanID);
|
||||
|
||||
@@ -184,7 +184,17 @@ class kanban extends control
|
||||
public function view($kanbanID)
|
||||
{
|
||||
$kanban = $this->kanban->getByID($kanbanID);
|
||||
$space = $this->kanban->getSpaceByID($kanban->space);
|
||||
|
||||
if(!$kanban)
|
||||
{
|
||||
if(defined('RUN_MODE') && RUN_MODE == 'api') return $this->send(array('status' => 'fail', 'code' => 404, 'message' => '404 Not found'));
|
||||
die(js::error($this->lang->notFound) . js::locate($this->createLink('kanban', 'space')));
|
||||
}
|
||||
|
||||
$kanbanIdList = $this->kanban->getCanViewObjects();
|
||||
if(!$this->app->user->admin and !in_array($kanbanID, $kanbanIdList)) die(js::error($this->lang->kanban->accessDenied) . js::locate('back'));
|
||||
|
||||
$space = $this->kanban->getSpaceByID($kanban->space);
|
||||
|
||||
$this->kanban->setSwitcher($kanban);
|
||||
$this->kanban->setHeaderActions($kanban);
|
||||
@@ -210,7 +220,7 @@ class kanban extends control
|
||||
{
|
||||
$laneID = $this->kanban->createLane($kanbanID, $regionID, $lane = null);
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
|
||||
|
||||
$this->loadModel('action')->create('kanbanLane', $laneID, 'created');
|
||||
die(js::reload('parent.parent'));
|
||||
}
|
||||
@@ -232,14 +242,14 @@ class kanban extends control
|
||||
$column = $this->kanban->getColumnByID($columnID);
|
||||
|
||||
if($_POST)
|
||||
{
|
||||
{
|
||||
$order = $position == 'left' ? $column->order : $column->order + 1;
|
||||
$columnID = $this->kanban->createColumn($column->region, null, $order);
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
|
||||
$this->loadModel('action')->create('kanbanColumn', $columnID, 'Created');
|
||||
die(js::reload('parent.parent'));
|
||||
}
|
||||
}
|
||||
|
||||
$this->view->title = $this->lang->kanban->createColumn;
|
||||
$this->view->column = $column;
|
||||
@@ -287,22 +297,47 @@ class kanban extends control
|
||||
{
|
||||
$changes = $this->kanban->updateCard($cardID);
|
||||
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
|
||||
$actionID = $this->action->create('kanbanCard', $cardID, 'edited');
|
||||
$this->action->logHistory($actionID, $changes);
|
||||
|
||||
die(js::reload('parent.parent'));
|
||||
return $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => 'parent'));
|
||||
}
|
||||
|
||||
$this->view->card = $this->kanban->getCardByID($cardID);
|
||||
$this->view->actions = $this->action->getList('kanbancard', $cardID);
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter');
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noclosed');
|
||||
$this->view->allUsers = $this->loadModel('user')->getPairs();
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* View a card.
|
||||
*
|
||||
* @param int $cardID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function viewCard($cardID)
|
||||
{
|
||||
$this->loadModel('action');
|
||||
|
||||
$card = $this->kanban->getCardByID($cardID);
|
||||
$kanban = $this->kanban->getByID($card->kanban);
|
||||
$space = $this->kanban->getSpaceById($kanban->space);
|
||||
|
||||
$this->view->card = $card;
|
||||
$this->view->actions = $this->action->getList('kanbancard', $cardID);
|
||||
$this->view->users = $this->loadModel('user')->getPairs('noletter');
|
||||
$this->view->space = $space;
|
||||
$this->view->kanban = $kanban;
|
||||
$this->view->usersAvatar = $this->user->getAvatarPairs();
|
||||
|
||||
$this->display();
|
||||
}
|
||||
|
||||
/**
|
||||
* Set WIP.
|
||||
*
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
#mainContent {padding-left: 0px;}
|
||||
@@ -0,0 +1 @@
|
||||
.table-form>tbody>tr>th {width: 150px;}
|
||||
@@ -0,0 +1 @@
|
||||
#mainContent {padding-left: 0px;}
|
||||
@@ -0,0 +1 @@
|
||||
#mainContent {padding-left: 0px;}
|
||||
@@ -0,0 +1 @@
|
||||
.table-form>tbody>tr>th {width: 70px;}
|
||||
@@ -0,0 +1 @@
|
||||
#mainContent {padding-left: 0px;}
|
||||
@@ -0,0 +1,2 @@
|
||||
[lang^='en'] .table-data tbody>tr>th {width: 100px;}
|
||||
.pull-left div {float: left !important;}
|
||||
@@ -42,9 +42,7 @@ function setMailto(field, value)
|
||||
*/
|
||||
function initColorPicker()
|
||||
{
|
||||
var colorList = ['#272E33', '#3DC6FD', '#2B529C', '#E48600', '#D2323D', '#229F24', '#777777', '#D2691E', '#008B8B', '#2E8B57', '#4169E1', '#4B0082', '#FA8072', '#BA55D3', '#6B8E23'];
|
||||
|
||||
var selectedColor = $('input[name=color]').val();
|
||||
var selectedColor = $().val();
|
||||
if(selectedColor && $.inArray(selectedColor.toUpperCase(), colorList) == -1) colorList.unshift(selectedColor);
|
||||
colorList.forEach(function(color, index)
|
||||
{
|
||||
|
||||
+26
-12
@@ -92,7 +92,9 @@ document.addEventListener('msfullscreenChange', function (e)
|
||||
function renderHeaderCol($column, column, $header, kanbanData)
|
||||
{
|
||||
/* Render group header. */
|
||||
var privs = kanbanData.actions;
|
||||
var privs = kanbanData.actions;
|
||||
var columnPrivs = kanbanData.columns[0].actions;
|
||||
|
||||
if(privs.includes('sortGroup'))
|
||||
{
|
||||
var groups = regions[column.region].groups;
|
||||
@@ -108,18 +110,30 @@ function renderHeaderCol($column, column, $header, kanbanData)
|
||||
}
|
||||
}
|
||||
|
||||
var regionID = $column.closest('.kanban').data('id');
|
||||
var groupID = $column.closest('.kanban-board').data('id');
|
||||
var laneID = column.$kanbanData.lanes[0].id ? column.$kanbanData.lanes[0].id : 0;
|
||||
var columnID = $column.closest('.kanban-col').data('id');
|
||||
var cardUrl = createLink('kanban', 'createCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&laneID=' + laneID + '&columnID=' + columnID);
|
||||
var regionID = $column.closest('.kanban').data('id');
|
||||
var groupID = $column.closest('.kanban-board').data('id');
|
||||
var laneID = column.$kanbanData.lanes[0].id ? column.$kanbanData.lanes[0].id : 0;
|
||||
var columnID = $column.closest('.kanban-col').data('id');
|
||||
var printMoreBtn = (columnPrivs.includes('editColumn') || columnPrivs.includes('setWIP') || columnPrivs.includes('createColumn') || columnPrivs.includes('copyColumn') || columnPrivs.includes('archiveColumn') || columnPrivs.includes('deleteColumn') || columnPrivs.includes('splitColumn'));
|
||||
|
||||
/* Render more menu. */
|
||||
if(!$column.children('.actions').length) $column.append('<div class="actions"></div>');
|
||||
var $actions = $column.children('.actions');
|
||||
var addItemBtn = ['<a data-contextmenu="columnCreate" data-toggle="modal" data-action="addItem" data-column="' + column.id + '" data-lane="' + laneID + '" href="' + cardUrl + '" class="text-primary iframe">', '<i class="icon icon-expand-alt"></i>', '</a>'].join('');
|
||||
var moreAction = ' <button class="btn btn-link action" title="' + kanbanLang.moreAction + '" data-contextmenu="column" data-column="' + column.id + '"><i class="icon icon-ellipsis-v"></i></button>';
|
||||
$actions.html(addItemBtn + moreAction);
|
||||
if(columnPrivs.includes('createCard') || printMoreBtn)
|
||||
{
|
||||
var addItemBtn = '';
|
||||
var moreAction = '';
|
||||
|
||||
if(!$column.children('.actions').length) $column.append('<div class="actions"></div>');
|
||||
var $actions = $column.children('.actions');
|
||||
|
||||
if(columnPrivs.includes('createCard'))
|
||||
{
|
||||
var cardUrl = createLink('kanban', 'createCard', 'kanbanID=' + kanbanID + '®ionID=' + regionID + '&groupID=' + groupID + '&laneID=' + laneID + '&columnID=' + columnID);
|
||||
addItemBtn = ['<a data-contextmenu="columnCreate" data-toggle="modal" data-action="addItem" data-column="' + column.id + '" data-lane="' + laneID + '" href="' + cardUrl + '" class="text-primary iframe">', '<i class="icon icon-expand-alt"></i>', '</a>'].join('');
|
||||
}
|
||||
|
||||
var moreAction = ' <button class="btn btn-link action" title="' + kanbanLang.moreAction + '" data-contextmenu="column" data-column="' + column.id + '"><i class="icon icon-ellipsis-v"></i></button>';
|
||||
$actions.html(addItemBtn + moreAction);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -166,7 +180,7 @@ function renderLaneName($lane, lane, $kanban, columns, kanban)
|
||||
if(!$lane.children('.actions').length && (canSet || canDelete))
|
||||
{
|
||||
$([
|
||||
'<div class="actions" title="' + lang.more + '">',
|
||||
'<div class="actions" title="' + kanbanLang.more + '">',
|
||||
'<a data-contextmenu="lane" data-lane="' + lane.id + '" data-kanban="' + kanban.id + '">',
|
||||
'<i class="icon icon-ellipsis-v"></i>',
|
||||
'</a>',
|
||||
|
||||
+52
-41
@@ -25,6 +25,7 @@ $lang->kanban->deleteColumn = 'Delete Column';
|
||||
$lang->kanban->createCard = 'Create Card';
|
||||
$lang->kanban->editCard = 'Edit Card';
|
||||
$lang->kanban->viewCard = 'View Card';
|
||||
$lang->kanban->archiveCard = 'Archive Card';
|
||||
$lang->kanban->sortCard = 'Sort Card';
|
||||
$lang->kanban->setting = 'Setting';
|
||||
$lang->kanban->splitColumn = 'Split Column';
|
||||
@@ -35,23 +36,27 @@ $lang->kanban->archiveColumn = 'Archive Column';
|
||||
$lang->kanban->spaceCommon = 'Kanban Space';
|
||||
|
||||
/* Fields. */
|
||||
$lang->kanban->space = 'Space';
|
||||
$lang->kanban->name = 'Name';
|
||||
$lang->kanban->owner = 'Owner';
|
||||
$lang->kanban->team = 'Team';
|
||||
$lang->kanban->desc = 'Description';
|
||||
$lang->kanban->acl = 'ACL';
|
||||
$lang->kanban->whitelist = 'White List';
|
||||
$lang->kanban->status = 'Status';
|
||||
$lang->kanban->createdBy = 'Created By';
|
||||
$lang->kanban->createdDate = 'Created Date';
|
||||
$lang->kanban->lastEditedBy = 'Edited By';
|
||||
$lang->kanban->lastEditedDate = 'Edited Date';
|
||||
$lang->kanban->closed = 'Closed';
|
||||
$lang->kanban->closedBy = 'Closed By';
|
||||
$lang->kanban->closedDate = 'Closed Date';
|
||||
$lang->kanban->empty = 'No Kanban';
|
||||
$lang->kanban->teamSumCount = '%s people in total';
|
||||
$lang->kanban->space = 'Space';
|
||||
$lang->kanban->name = 'Name';
|
||||
$lang->kanban->owner = 'Owner';
|
||||
$lang->kanban->team = 'Team';
|
||||
$lang->kanban->desc = 'Description';
|
||||
$lang->kanban->acl = 'ACL';
|
||||
$lang->kanban->whitelist = 'White List';
|
||||
$lang->kanban->status = 'Status';
|
||||
$lang->kanban->createdBy = 'Created By';
|
||||
$lang->kanban->createdDate = 'Created Date';
|
||||
$lang->kanban->lastEditedBy = 'Edited By';
|
||||
$lang->kanban->lastEditedDate = 'Edited Date';
|
||||
$lang->kanban->closed = 'Closed';
|
||||
$lang->kanban->closedBy = 'Closed By';
|
||||
$lang->kanban->closedDate = 'Closed Date';
|
||||
$lang->kanban->empty = 'No Kanban';
|
||||
$lang->kanban->teamSumCount = '%s people in total';
|
||||
$lang->kanban->createColumnOnLeft = 'Create Column On Left';
|
||||
$lang->kanban->createColumnOnRight = 'Create Column On Right';
|
||||
|
||||
$lang->kanban->accessDenied = "You have no access to the kanban.";
|
||||
|
||||
$lang->kanban->aclGroup['open'] = 'Open';
|
||||
$lang->kanban->aclGroup['private'] = 'Private';
|
||||
@@ -111,6 +116,7 @@ $lang->kanban->moveDown = 'Swimlane Down';
|
||||
$lang->kanban->laneMove = 'Swimlane Sorting';
|
||||
$lang->kanban->laneGroup = 'Lane Group';
|
||||
$lang->kanban->cardsSort = 'Cards Sortting';
|
||||
$lang->kanban->more = 'More';
|
||||
$lang->kanban->moreAction = 'More Action';
|
||||
$lang->kanban->noGroup = 'None';
|
||||
$lang->kanban->limitExceeded = 'Limit Exceeded';
|
||||
@@ -193,47 +199,53 @@ $lang->kanbanspace->featureBar['closed'] = 'Closed';
|
||||
$lang->kanbancolumn = new stdclass();
|
||||
$lang->kanbancolumn->name = $lang->kanban->columnName;
|
||||
$lang->kanbancolumn->limit = $lang->kanban->WIPCount;
|
||||
$lang->kanbancolumn->color = 'Column Color';
|
||||
|
||||
$lang->kanbanlane = new stdclass();
|
||||
$lang->kanbanlane->name = $lang->kanban->laneName;
|
||||
$lang->kanbanlane->common = 'Lane';
|
||||
$lang->kanbanlane->default = 'Default Lane';
|
||||
$lang->kanbanlane->column = 'Lane Kanban column';
|
||||
$lang->kanbanlane->otherlane = 'Select the lane that shares the Kanban column';
|
||||
$lang->kanbanlane->color = 'Lane color';
|
||||
$lang->kanbanlane->column = 'Lane Kanban Column';
|
||||
$lang->kanbanlane->otherlane = 'Select Existed Lane';
|
||||
$lang->kanbanlane->color = 'Lane Color';
|
||||
|
||||
$lang->kanbanlane->modeList['sameAsOther'] = 'Use the same Kanban column as other lanes';
|
||||
$lang->kanbanlane->modeList['independent'] = 'Independent Kanban column is adopted';
|
||||
|
||||
$lang->kanbanlane->name = $lang->kanban->laneName;
|
||||
$lang->kanbanlane->common = 'Lane';
|
||||
$lang->kanbanlane->default = 'Default Lane';
|
||||
|
||||
$lang->kanbanregion = new stdclass();
|
||||
$lang->kanbanregion->name = 'Kanban Region';
|
||||
$lang->kanbanregion->default = 'Default Region';
|
||||
|
||||
$lang->kanbancard = new stdclass();
|
||||
$lang->kanbancard->create = 'Create Card';
|
||||
$lang->kanbancard->create = 'Create Card';
|
||||
$lang->kanbancard->edit = 'Edit Card';
|
||||
$lang->kanbancard->view = 'View Card';
|
||||
$lang->kanbancard->archive = 'Archive';
|
||||
$lang->kanbancard->assign = 'Assign';
|
||||
$lang->kanbancard->copy = 'Copy';
|
||||
$lang->kanbancard->delete = 'Delete';
|
||||
|
||||
$lang->kanbancard->name = 'Card Name';
|
||||
$lang->kanbancard->legendBasicInfo = 'Basic Info';
|
||||
$lang->kanbancard->legendLifeTime = 'Card Life';
|
||||
$lang->kanbancard->space = 'Space';
|
||||
$lang->kanbancard->lane = 'Lane';
|
||||
$lang->kanbancard->column = 'Column';
|
||||
$lang->kanbancard->assignedTo = 'Assignee';
|
||||
$lang->kanbancard->beginAndEnd = 'Begin And End';
|
||||
$lang->kanbancard->begin = 'Begin';
|
||||
$lang->kanbancard->end = 'End';
|
||||
$lang->kanbancard->pri = 'Priority';
|
||||
$lang->kanbancard->desc = 'Description';
|
||||
$lang->kanbancard->estimate = 'Estimate';
|
||||
$lang->kanbancard->createdBy = 'Created By';
|
||||
$lang->kanbancard->createdDate = 'Created Date';
|
||||
$lang->kanbancard->lastEditedBy = 'Last Edited By';
|
||||
$lang->kanbancard->lastEditedDate = 'Last Edited Date';
|
||||
$lang->kanbancard->lblHour = 'h';
|
||||
$lang->kanbancard->space = 'Space';
|
||||
$lang->kanbancard->kanban = 'Kanban';
|
||||
$lang->kanbancard->lane = 'Lane';
|
||||
$lang->kanbancard->column = 'Column';
|
||||
$lang->kanbancard->assignedTo = 'Assignee';
|
||||
$lang->kanbancard->beginAndEnd = 'Begin And End';
|
||||
$lang->kanbancard->begin = 'Begin';
|
||||
$lang->kanbancard->end = 'End';
|
||||
$lang->kanbancard->pri = 'Priority';
|
||||
$lang->kanbancard->desc = 'Description';
|
||||
$lang->kanbancard->estimate = 'Estimate';
|
||||
$lang->kanbancard->createdBy = 'Created By';
|
||||
$lang->kanbancard->createdDate = 'Created Date';
|
||||
$lang->kanbancard->lastEditedBy = 'Last Edited By';
|
||||
$lang->kanbancard->lastEditedDate = 'Last Edited Date';
|
||||
$lang->kanbancard->archivedBy = 'Archived By';
|
||||
$lang->kanbancard->archivedDate = 'Archived Date';
|
||||
$lang->kanbancard->lblHour = 'h';
|
||||
|
||||
$lang->kanbancard->priList[1] = 1;
|
||||
$lang->kanbancard->priList[2] = 2;
|
||||
@@ -243,4 +255,3 @@ $lang->kanbancard->priList[4] = 4;
|
||||
$lang->kanbancard->error = new stdClass();
|
||||
$lang->kanbancard->error->recordMinus = 'Estimate cannot be negative!';
|
||||
$lang->kanbancard->error->endSmall = '"End Date" cannot be less than "Begin Date"';
|
||||
>>>>>>> module/kanban/lang/en.php
|
||||
|
||||
@@ -25,6 +25,7 @@ $lang->kanban->deleteColumn = '删除看板列';
|
||||
$lang->kanban->createCard = '创建卡片';
|
||||
$lang->kanban->editCard = '编辑卡片';
|
||||
$lang->kanban->viewCard = '查看卡片';
|
||||
$lang->kanban->archiveCard = '归档卡片';
|
||||
$lang->kanban->sortCard = '卡片排序';
|
||||
$lang->kanban->setting = '设置';
|
||||
$lang->kanban->splitColumn = '新增子看板列';
|
||||
@@ -56,6 +57,8 @@ $lang->kanban->teamSumCount = '共%s人';
|
||||
$lang->kanban->createColumnOnLeft = '在左侧添加看板列';
|
||||
$lang->kanban->createColumnOnRight = '在右侧添加看板列';
|
||||
|
||||
$lang->kanban->accessDenied = '您无权访问该看板';
|
||||
|
||||
$lang->kanban->aclList['open'] = '继承空间访问权限(能访问当前空间,即可访问)';
|
||||
$lang->kanban->aclList['private'] = '私有(看板团队成员、白名单、空间负责人可访问)';
|
||||
|
||||
@@ -114,6 +117,7 @@ $lang->kanban->moveDown = '泳道下移';
|
||||
$lang->kanban->laneMove = '泳道排序';
|
||||
$lang->kanban->laneGroup = '泳道分组';
|
||||
$lang->kanban->cardsSort = '卡片排序';
|
||||
$lang->kanban->more = '更多';
|
||||
$lang->kanban->moreAction = '更多操作';
|
||||
$lang->kanban->noGroup = '无';
|
||||
$lang->kanban->limitExceeded = '超出在制品限制';
|
||||
@@ -214,13 +218,19 @@ $lang->kanbanregion->name = '看板区域';
|
||||
$lang->kanbanregion->default = '默认区域';
|
||||
|
||||
$lang->kanbancard = new stdclass();
|
||||
$lang->kanbancard->create = '创建卡片';
|
||||
$lang->kanbancard->create = '创建卡片';
|
||||
$lang->kanbancard->edit = '编辑卡片';
|
||||
$lang->kanbancard->view = '查看卡片';
|
||||
$lang->kanbancard->archive = '归档';
|
||||
$lang->kanbancard->assign = '指派';
|
||||
$lang->kanbancard->copy = '复制';
|
||||
$lang->kanbancard->delete = '删除';
|
||||
|
||||
$lang->kanbancard->name = '卡片名称';
|
||||
$lang->kanbancard->legendBasicInfo = '基本信息';
|
||||
$lang->kanbancard->legendLifeTime = '卡片的一生';
|
||||
$lang->kanbancard->name = '卡片名称';
|
||||
$lang->kanbancard->space = '所属空间';
|
||||
$lang->kanbancard->kanban = '所属看板';
|
||||
$lang->kanbancard->lane = '所属泳道';
|
||||
$lang->kanbancard->column = '所属看板列';
|
||||
$lang->kanbancard->assignedTo = '指派给';
|
||||
@@ -234,6 +244,8 @@ $lang->kanbancard->createdBy = '由谁创建';
|
||||
$lang->kanbancard->createdDate = '由谁创建';
|
||||
$lang->kanbancard->lastEditedBy = '由谁编辑';
|
||||
$lang->kanbancard->lastEditedDate = '最后编辑时间';
|
||||
$lang->kanbancard->archivedBy = '由谁归档';
|
||||
$lang->kanbancard->archivedDate = '归档时间';
|
||||
$lang->kanbancard->lblHour = 'h';
|
||||
|
||||
$lang->kanbancard->priList[1] = 1;
|
||||
@@ -244,4 +256,3 @@ $lang->kanbancard->priList[4] = 4;
|
||||
$lang->kanbancard->error = new stdClass();
|
||||
$lang->kanbancard->error->recordMinus = '预计不能为负数!';
|
||||
$lang->kanbancard->error->endSmall = '"截止日期"不能小于"预计开始"!';
|
||||
>>>>>>> module/kanban/lang/zh-cn.php
|
||||
|
||||
+51
-12
@@ -397,7 +397,7 @@ class kanbanModel extends model
|
||||
$groupGroup = $this->getGroupGroupByRegions(array_keys($regions));
|
||||
$laneGroup = $this->getLaneGroupByRegions(array_keys($regions));
|
||||
$columnGroup = $this->getColumnGroupByRegions(array_keys($regions));
|
||||
//$taskGroup = $this->getTaskGroupByProject($kanbanID);
|
||||
$cardGroup = $this->getCardGroupByKanban($kanbanID);
|
||||
|
||||
foreach($regions as $regionID => $regionName)
|
||||
{
|
||||
@@ -412,7 +412,7 @@ class kanbanModel extends model
|
||||
$lanes = zget($laneGroup, $group->id, array());
|
||||
if(!$lanes) continue;
|
||||
|
||||
foreach($lanes as $lane) $lane->items = isset($taskGroup[$lane->id]) ? $taskGroup[$lane->id] : array();
|
||||
foreach($lanes as $lane) $lane->items = isset($cardGroup[$lane->id]) ? $cardGroup[$lane->id] : array();
|
||||
|
||||
$group->columns = zget($columnGroup, $group->id, array());
|
||||
$group->lanes = $lanes;
|
||||
@@ -511,7 +511,7 @@ class kanbanModel extends model
|
||||
->orderBy('order')
|
||||
->fetchGroup('group', 'id');
|
||||
|
||||
$actions = array('createColumn', 'copyColumn', 'editColumn', 'splitColumn', 'setWIP', 'archiveColumn', 'restoreColumn', 'deleteColumn');
|
||||
$actions = array('createColumn', 'copyColumn', 'editColumn', 'splitColumn', 'setWIP', 'archiveColumn', 'restoreColumn', 'deleteColumn', 'createCard', 'splitColumn');
|
||||
|
||||
/* Group by parent. */
|
||||
$parentColumnGroup = array();
|
||||
@@ -555,6 +555,37 @@ class kanbanModel extends model
|
||||
return $columnData;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get card group by kanban id.
|
||||
*
|
||||
* @param int $kanbanID
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getCardGroupByKanban($kanbanID)
|
||||
{
|
||||
$cards = $this->dao->select('*')->from(TABLE_KANBANCARD)
|
||||
->where('deleted')->eq(0)
|
||||
->andWhere('kanban')->eq($kanbanID)
|
||||
//->orderBy('`order` asc')
|
||||
->fetchAll('id');
|
||||
|
||||
$actions = array('editcard', 'movecard', 'copycard', 'startcard', 'finishcard', 'activatecard', 'cancelcard', 'closecard', 'archivecard', 'deletecard', 'setcardcolor');
|
||||
$cardGroup = array();
|
||||
foreach($cards as $card)
|
||||
{
|
||||
$card->actions = array();
|
||||
foreach($actions as $action)
|
||||
{
|
||||
if(common::hasPriv('kanban', $action)) $card->actions[] = $action;
|
||||
}
|
||||
|
||||
$cardGroup[$card->lane]['column' . $card->column][] = $card;
|
||||
}
|
||||
|
||||
return $cardGroup;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get Kanban by execution id.
|
||||
*
|
||||
@@ -1519,6 +1550,7 @@ class kanbanModel extends model
|
||||
->setDefault('estimate', $oldCard->estimate)
|
||||
->setIF(!empty($this->post->assignedTo) and $oldCard->assignedTo != $this->post->assignedTo, 'assignedDate', $now)
|
||||
->setIF(is_numeric($this->post->estimate), 'estimate', (float)$this->post->estimate)
|
||||
->join('assignedTo', ',')
|
||||
->remove('uid')
|
||||
->get();
|
||||
|
||||
@@ -1642,17 +1674,24 @@ class kanbanModel extends model
|
||||
$actions = '';
|
||||
$actions .= "<div class='btn-group'>";
|
||||
$actions .= "<a href='javascript:fullScreen();' id='fullScreenBtn' class='btn btn-link'><i class='icon icon-fullscreen'></i> {$this->lang->kanban->fullScreen}</a>";
|
||||
$actions .= "<a data-toggle='dropdown' class='btn btn-link dropdown-toggle setting' type='button'>" . '<i class="icon icon-cog-outline"></i> ' . $this->lang->kanban->setting . '</a>';
|
||||
$actions .= "<ul id='kanbanActionMenu' class='dropdown-menu text-left'>";
|
||||
if(common::hasPriv('kanban', 'createRegion')) $actions .= '<li>' . html::a(helper::createLink('kanban', 'createRegion', "kanbanID=$kanban->id", '', true), '<i class="icon icon-plus"></i>' . $this->lang->kanban->createRegion, '', "class='iframe btn btn-link'") . '</li>';
|
||||
$printSettingBtn = (common::hasPriv('kanban', 'createRegion') or common::hasPriv('kanban', 'edit') or common::hasPriv('kanban', 'close') or common::hasPriv('kanban', 'delete'));
|
||||
if($printSettingBtn)
|
||||
{
|
||||
$actions .= "<a data-toggle='dropdown' class='btn btn-link dropdown-toggle setting' type='button'>" . '<i class="icon icon-cog-outline"></i> ' . $this->lang->kanban->setting . '</a>';
|
||||
$actions .= "<ul id='kanbanActionMenu' class='dropdown-menu text-left'>";
|
||||
if(common::hasPriv('kanban', 'createRegion')) $actions .= '<li>' . html::a(helper::createLink('kanban', 'createRegion', "kanbanID=$kanban->id", '', true), '<i class="icon icon-plus"></i>' . $this->lang->kanban->createRegion, '', "class='iframe btn btn-link'") . '</li>';
|
||||
|
||||
$kanbanActions = '';
|
||||
if(common::hasPriv('kanban', 'edit')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'edit', "kanbanID=$kanban->id", '', true), '<i class="icon icon-edit"></i>' . $this->lang->kanban->edit, '', "class='iframe btn btn-link'") . '</li>';
|
||||
if(common::hasPriv('kanban', 'close')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'close', "kanbanID=$kanban->id", '', true), '<i class="icon icon-off"></i>' . $this->lang->kanban->close, '', "class='iframe btn btn-link'") . '</li>';
|
||||
if(common::hasPriv('kanban', 'delete')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'delete', "kanbanID=$kanban->id"), '<i class="icon icon-trash"></i>' . $this->lang->kanban->delete, 'hiddenwin', "class='btn btn-link'") . '</li>';
|
||||
if($kanbanActions) $actions .= "<div class='divider'></div>" . $kanbanActions;
|
||||
$kanbanActions = '';
|
||||
if(common::hasPriv('kanban', 'edit')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'edit', "kanbanID=$kanban->id", '', true), '<i class="icon icon-edit"></i>' . $this->lang->kanban->edit, '', "class='iframe btn btn-link' data-width='75%'") . '</li>';
|
||||
if(common::hasPriv('kanban', 'close')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'close', "kanbanID=$kanban->id", '', true), '<i class="icon icon-off"></i>' . $this->lang->kanban->close, '', "class='iframe btn btn-link'") . '</li>';
|
||||
if(common::hasPriv('kanban', 'delete')) $kanbanActions .= '<li>' . html::a(helper::createLink('kanban', 'delete', "kanbanID=$kanban->id"), '<i class="icon icon-trash"></i>' . $this->lang->kanban->delete, 'hiddenwin', "class='btn btn-link'") . '</li>';
|
||||
if($kanbanActions)
|
||||
{
|
||||
$actions .= common::hasPriv('kanban', 'createRegion') ? "<div class='divider'></div>" . $kanbanActions : $kanbanActions;
|
||||
}
|
||||
$actions .= "</ul>";
|
||||
}
|
||||
|
||||
$actions .= "</ul>";
|
||||
$actions .= "</div>";
|
||||
|
||||
$this->lang->headerActions = $actions;
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
<tr>
|
||||
<td colspan='3' class='text-center form-actions'>
|
||||
<?php echo html::submitButton($lang->kanban->close);?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->create;?></h2>
|
||||
</div>
|
||||
<form class='form-indicator main-form' method='post' target='hiddenwin' id='dataform'>
|
||||
<form class='form-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
|
||||
<table class='table table-form'>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanban->space;?></th>
|
||||
@@ -58,7 +58,6 @@
|
||||
<tr>
|
||||
<td colspan='3' class='text-center form-actions'>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -38,9 +38,9 @@
|
||||
<th><?php echo $lang->kanbancard->beginAndEnd;?></th>
|
||||
<td colspan='2'>
|
||||
<div class='input-group'>
|
||||
<?php echo html::input('begin', '', "class='form-control form-date form-datetime' placeholder='{$lang->kanbancard->begin}'");?>
|
||||
<?php echo html::input('begin', '', "class='form-control form-date' placeholder='{$lang->kanbancard->begin}'");?>
|
||||
<span class='input-group-addon fix-border'>~</span>
|
||||
<?php echo html::input('end', '', "class='form-control form-date form-datetime' placeholder='{$lang->kanbancard->end}'");?>
|
||||
<?php echo html::input('end', '', "class='form-control form-date' placeholder='{$lang->kanbancard->end}'");?>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
@@ -48,7 +48,18 @@
|
||||
<th><?php echo $lang->kanbancard->name;?></th>
|
||||
<td colspan='2'>
|
||||
<div class='required required-wrapper'></div>
|
||||
<?php echo html::input('name', '', "class='form-control'");?>
|
||||
<div class='input-group title-group'>
|
||||
<?php echo html::input('name', '', "class='form-control'");?>
|
||||
<span class="input-group-addon fix-border br-0"><?php echo $lang->kanbancard->pri;?></span>
|
||||
<div class="input-group-btn pri-selector" data-type="pri">
|
||||
<button type="button" class="btn dropdown-toggle br-0" data-toggle="dropdown">
|
||||
<span class="pri-text"><span class="label-pri label-pri-3" title="3">3</span></span> <span class="caret"></span>
|
||||
</button>
|
||||
<div class='dropdown-menu pull-right'>
|
||||
<?php echo html::select('pri', $lang->kanbancard->priList, 3, "class='form-control' data-provide='labelSelector' data-label-class='label-pri'");?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -65,4 +76,13 @@
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$('#pri').on('change', function()
|
||||
{
|
||||
var $select = $(this);
|
||||
var $selector = $select.closest('.pri-selector');
|
||||
var value = $select.val();
|
||||
$selector.find('.pri-text').html('<span class="label-pri label-pri-' + value + '" title="' + value + '">' + value + '</span>');
|
||||
});
|
||||
</script>
|
||||
<?php include '../../common/view/footer.lite.html.php';?>
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.lite.html.php';?>
|
||||
<?php js::set('colorList',$config->kanban->laneColorList);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='center-block'>
|
||||
<div class='main-header'>
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<?php include '../../common/view/kindeditor.html.php';?>
|
||||
<?php js::set('colorList',$config->kanban->laneColorList);?>
|
||||
<div id='mainContent' class='main-content'>
|
||||
<div class='main-header'>
|
||||
<h2>
|
||||
@@ -8,9 +9,9 @@
|
||||
</div>
|
||||
<form class='load-indicator main-form' method='post' target='hiddenwin'>
|
||||
<table class='table table-form'>
|
||||
<tbody>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th class="w-140px"><?php echo $lang->kanbanlane->name;?></th>
|
||||
<th><?php echo $lang->kanbanlane->name;?></th>
|
||||
<td>
|
||||
<div class='required required-wrapper'></div>
|
||||
<?php echo html::input('name', '', "class='form-control'");?>
|
||||
@@ -28,13 +29,13 @@
|
||||
<th><?php echo $lang->kanbanlane->color;?></th>
|
||||
<td>
|
||||
<div id='color-picker'></div>
|
||||
<?php echo html::input('color', '#3DC6FD', "class='hidden'");?>
|
||||
<?php echo html::input('color', '#7EC5FF', "class='hidden'");?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='text-center form-actions' colspan='2'>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->createSpace;?></h2>
|
||||
</div>
|
||||
<form class='form-indicator main-form' method='post' target='hiddenwin' id='dataform'>
|
||||
<form class='form-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
|
||||
<table class='table table-form'>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbanspace->name;?></th>
|
||||
@@ -54,7 +54,6 @@
|
||||
<tr>
|
||||
<td colspan='3' class='text-center form-actions'>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->edit;?></h2>
|
||||
</div>
|
||||
<form class='form-indicator main-form' method='post' target='hiddenwin' id='dataform'>
|
||||
<form class='form-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
|
||||
<table class='table table-form'>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanban->space;?></th>
|
||||
@@ -58,7 +58,6 @@
|
||||
<tr>
|
||||
<td colspan='3' class='text-center form-actions'>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<?php include '../../common/view/kindeditor.html.php';?>
|
||||
<div id="mainContent" class="main-content fade">
|
||||
<form method='post' enctype='multipart/form-data' target='hiddenwin' id='dataform'>
|
||||
<form class='main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanbancard->edit;?></h2>
|
||||
</div>
|
||||
@@ -48,15 +48,15 @@
|
||||
<table class="table table-form">
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->assignedTo;?></th>
|
||||
<td><?php echo html::select('assignedTo', $allUsers, $card->assignedTo, "class='form-control chosen' multiple");?></td>
|
||||
<td><?php echo html::select('assignedTo[]', $allUsers, $card->assignedTo, "class='form-control chosen' multiple");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->begin;?></th>
|
||||
<td><?php echo html::input('begin', helper::isZeroDate($card->begin) ? '' : $card->begin, "class='form-control form-datetime'");?></td>
|
||||
<td><?php echo html::input('begin', helper::isZeroDate($card->begin) ? '' : $card->begin, "class='form-control form-date'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->end;?></th>
|
||||
<td><?php echo html::input('end', helper::isZeroDate($card->end) ? '' : $card->end, "class='form-control form-datetime'");?></td>
|
||||
<td><?php echo html::input('end', helper::isZeroDate($card->end) ? '' : $card->end, "class='form-control form-date'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->pri;?></th>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<div class='main-header'>
|
||||
<h2><?php echo $lang->kanban->editSpace;?></h2>
|
||||
</div>
|
||||
<form class='form-indicator main-form' method='post' target='hiddenwin' id='dataform'>
|
||||
<form class='form-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
|
||||
<table class='table table-form'>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbanspace->name;?></th>
|
||||
@@ -55,7 +55,6 @@
|
||||
<tr>
|
||||
<td colspan='3' class='text-center form-actions'>
|
||||
<?php echo html::submitButton();?>
|
||||
<?php echo html::commonButton($lang->cancel, "data-dismiss='modal'", 'btn btn-wide');?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
@@ -21,8 +21,8 @@
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
<div class="btn-toolbar pull-right">
|
||||
<?php common::printLink('kanban', 'create', '', '<i class="icon icon-plus"></i> ' . $lang->kanban->create, '', 'class="btn btn-secondary iframe"', '', true);?>
|
||||
<?php common::printLink('kanban', 'createSpace', '', '<i class="icon icon-plus"></i> ' . $lang->kanban->createSpace, '', 'class="btn btn-primary iframe"', '', true);?>
|
||||
<?php common::printLink('kanban', 'create', '', '<i class="icon icon-plus"></i> ' . $lang->kanban->create, '', 'class="btn btn-secondary iframe" data-width="75%"', '', true);?>
|
||||
<?php common::printLink('kanban', 'createSpace', '', '<i class="icon icon-plus"></i> ' . $lang->kanban->createSpace, '', 'class="btn btn-primary iframe" data-width="75%"', '', true);?>
|
||||
</div>
|
||||
</div>
|
||||
<div id='mainContent'>
|
||||
@@ -45,8 +45,8 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class='spaceActions pull-right'>
|
||||
<?php common::printLink('kanban', 'create', "spaceID={$space->id}", '<i class="icon icon-plus"></i> ' . $lang->kanban->create, '', "class='iframe'", '', true);?>
|
||||
<?php common::printLink('kanban', 'editSpace', "spaceID={$space->id}", '<i class="icon icon-cog-outline"></i> ' . $lang->kanban->setting, '', "class='iframe'", '', true);?>
|
||||
<?php common::printLink('kanban', 'create', "spaceID={$space->id}", '<i class="icon icon-plus"></i> ' . $lang->kanban->create, '', "class='iframe' data-width='75%'", '', true);?>
|
||||
<?php common::printLink('kanban', 'editSpace', "spaceID={$space->id}", '<i class="icon icon-cog-outline"></i> ' . $lang->kanban->setting, '', "class='iframe' data-width='75%'", '', true);?>
|
||||
<?php common::printLink('kanban', 'closeSpace', "spaceID={$space->id}", '<i class="icon icon-off"></i> ' . $lang->close, '', "class='iframe'", '', true);?>
|
||||
<?php common::printLink('kanban', 'deleteSpace', "spaceID={$space->id}", '<i class="icon icon-trash"></i> ' . $lang->delete, 'hiddenwin', '', '', true);?>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,126 @@
|
||||
<?php
|
||||
/**
|
||||
* The viewcard of kanban module of ZenTaoPMS.
|
||||
*
|
||||
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
|
||||
* @license ZPL (http://zpl.pub/page/zplv12.html)
|
||||
* @author Mengyi Liu <liumengyi@easycorp.ltd>
|
||||
* @package kanban
|
||||
* @version $Id: viewcard.html.php 4903 2021-12-13 16:25:59Z $
|
||||
* @link https://www.zentao.net
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<?php include '../../common/view/kindeditor.html.php';?>
|
||||
<div id="mainMenu" class="clearfix">
|
||||
<div class="btn-toolbar pull-left">
|
||||
<div class='main-header'>
|
||||
<div class="page-title">
|
||||
<span class="label label-id"><?php echo $card->id?></span>
|
||||
<span class="text" title='<?php echo $card->name;?>'><?php echo $card->name;?></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="mainContent" class="main-row">
|
||||
<div class='main-col col-8'>
|
||||
<div class='cell'>
|
||||
<div class='detail'>
|
||||
<div class='detail-title'><?php echo $lang->kanbancard->desc;?></div>
|
||||
<div class="detail-content article-content"><?php echo $card->desc;?></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class='cell'>
|
||||
<?php $actionFormLink = $this->createLink('action', 'comment', "objectType=kanbancard&objectID=$card->id");?>
|
||||
<?php include '../../common/view/action.html.php';?>
|
||||
</div>
|
||||
<div class='main-actions'>
|
||||
<div class="btn-toolbar">
|
||||
<?php if(!$card->deleted):?>
|
||||
<?php
|
||||
common::printLink('kanban', 'assigntocard', "cardID=$card->id", "<i class='icon icon-hand-right'></i><span class='text'>{$lang->kanbancard->assign}</span>", '', "class='btn btn-link iframe' title='{$lang->kanbancard->assign}'", true, true);
|
||||
common::printLink('kanban', 'archivecard', "cardID=$card->id", "<i class='icon icon-ban-circle'></i><span class='text'>{$lang->kanbancard->archive}</span>", '', "class='btn btn-link iframe' title='{$lang->kanbancard->archive}'", true, true);
|
||||
|
||||
echo "<div class='divider'></div>";
|
||||
|
||||
common::printLink('kanban', 'editcard', "cardID=$card->id", '<i class="icon icon-edit"></i>', '', "class='btn btn-link iframe' data-width='80%' title='{$lang->kanbancard->edit}'", true, true);
|
||||
common::printLink('kanban', 'copycard', "cardID=$card->id", '<i class="icon icon-copy"></i>', '', "class='btn btn-link iframe' title='{$lang->kanbancard->copy}'", true, true);
|
||||
common::printLink('kanban', 'deletecard', "cardID=$card->id", '<i class="icon icon-trash"></i>', '', "class='btn btn-link iframe' title='{$lang->kanbancard->delete}'",true, true);
|
||||
?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class='side-col col-4'>
|
||||
<div class='cell'>
|
||||
<div class='detail'>
|
||||
<div class='main-header'>
|
||||
<?php echo $lang->kanbancard->legendBasicInfo;?>
|
||||
</div>
|
||||
<table class="table table-data">
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->assignedTo;?></th>
|
||||
<td>
|
||||
<?php $assignedToPairs = array_filter(explode(',', $card->assignedTo));?>
|
||||
<?php if(!empty($assignedToPairs)):?>
|
||||
<div class='kanban-members pull-left'>
|
||||
<?php foreach($assignedToPairs as $member):?>
|
||||
<div title="<?php echo $users[$member];?>">
|
||||
<?php echo html::smallAvatar(array('avatar' => $usersAvatar[$member], 'account' => $member)); ?>
|
||||
</div>
|
||||
<?php endforeach;?>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->space;?></th>
|
||||
<td><?php echo $space->name;?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->kanban;?></th>
|
||||
<td><?php echo $kanban->name;?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->begin;?></th>
|
||||
<td><?php echo helper::isZeroDate($card->begin) ? '' : $card->begin;?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->end;?></th>
|
||||
<td><?php echo helper::isZeroDate($card->end) ? '' : $card->end;?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->pri;?></th>
|
||||
<td><span class='label-pri <?php echo 'label-pri-' . $card->pri;?>' title='<?php echo zget($lang->kanbancard->priList, $card->pri);?>'><?php echo zget($lang->kanbancard->priList, $card->pri);?></span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->estimate;?></th>
|
||||
<td><?php echo round($card->estimate, 2) . ' ' . $lang->kanbancard->lblHour;?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class='cell'>
|
||||
<div class='detail'>
|
||||
<div class='main-header'>
|
||||
<?php echo $lang->kanbancard->legendLifeTime;?>
|
||||
</div>
|
||||
<table class="table table-data">
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->createdBy;?></th>
|
||||
<td><?php echo zget($users, $card->createdBy) . $lang->at . $card->createdDate;?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->archivedBy;?></th>
|
||||
<td><?php echo $card->archivedBy ? zget($users, $card->archivedBy) . $lang->at . $card->archivedDate : '';?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th><?php echo $lang->kanbancard->lastEditedBy;?></th>
|
||||
<td><?php echo $card->lastEditedBy ? zget($users, $card->lastEditedBy) . $lang->at . $card->lastEditedDate : '';?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
@@ -64,7 +64,13 @@ class programplan extends control
|
||||
$products = $this->loadModel('product')->getProducts($projectID);
|
||||
$this->lang->modulePageNav = $this->product->select($products, $this->productID, 'programplan', 'browse', $type, 0, 0, '', false);
|
||||
|
||||
if(common::hasPriv('programplan', 'create')) $this->lang->TRActions = html::a($this->createLink('programplan', 'create', "projectID=$projectID"), "<i class='icon icon-sm icon-plus'></i> " . $this->lang->programplan->create, '', "class='btn btn-primary'");
|
||||
$this->lang->TRActions = "<button class='btn btn-link' data-toggle='dropdown'><i class='icon icon-export muted'></i> <span class='text'>" . $this->lang->export . "</span> <span class='caret'></span></button>";
|
||||
$this->lang->TRActions .= "<ul class='dropdown-menu' id='exportActionMenu'>";
|
||||
$this->lang->TRActions .= "<li><a href='javascript:exportGantt()'>" . $this->lang->execution->gantt->exportImg . "</a></li>";
|
||||
$this->lang->TRActions .= "<li><a href='javascript:exportGantt(" . '"pdf"' . ")'>" . $this->lang->execution->gantt->exportPDF . "</a></li>";
|
||||
$this->lang->TRActions .= "</ul>";
|
||||
|
||||
if(common::hasPriv('programplan', 'create')) $this->lang->TRActions .= html::a($this->createLink('programplan', 'create', "projectID=$projectID"), "<i class='icon icon-sm icon-plus'></i> " . $this->lang->programplan->create, '', "class='btn btn-primary'");
|
||||
|
||||
$selectCustom = 0; // Display date and task settings.
|
||||
$dateDetails = 1; // Gantt chart detail date display.
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<style>#dropMenu{z-index:99999;}</style>
|
||||
<?php js::set('browseType', $type);?>
|
||||
<div id='mainContent' class='main-table'>
|
||||
<div class='main-table'>
|
||||
<?php if(empty($plans)):?>
|
||||
<div class="table-empty-tip">
|
||||
<p>
|
||||
|
||||
@@ -26,18 +26,18 @@ form {display: block; margin-top: 0em; margin-block-end: 1em;}
|
||||
<?php js::set('dateDetails', $dateDetails);?>
|
||||
<?php js::set('module', $app->rawModule);?>
|
||||
<?php js::set('method', $app->rawMethod);?>
|
||||
|
||||
<div id='mainContent' class='main-content load-indicator' data-loading='<?php echo $lang->programplan->exporting;?>'>
|
||||
<form class="main-form form-ajax">
|
||||
<div class="example">
|
||||
<?php echo html::commonButton($lang->programplan->full, 'id="fullScreenBtn"', 'btn btn-primary btn-sm')?>
|
||||
<?php if($app->rawModule == 'review' and $app->rawMethod == 'assess') unset($lang->programplan->stageCustom->date); ?>
|
||||
<?php echo html::checkbox('stageCustom', $lang->programplan->stageCustom, $selectCustom);?>
|
||||
</div>
|
||||
</form>
|
||||
<form class="main-form form-ajax">
|
||||
<div class="example">
|
||||
<?php echo html::commonButton($lang->programplan->full, 'id="fullScreenBtn"', 'btn btn-primary btn-sm')?>
|
||||
<?php if($app->rawModule == 'review' and $app->rawMethod == 'assess') unset($lang->programplan->stageCustom->date); ?>
|
||||
<?php echo html::checkbox('stageCustom', $lang->programplan->stageCustom, $selectCustom);?>
|
||||
</div>
|
||||
</form>
|
||||
<div id='ganttContainer'>
|
||||
<div class='gantt' id='ganttView'></div>
|
||||
</div>
|
||||
<a id='ganttDownload' download='gantt-export-<?php echo $projectID;?>.png'></a>
|
||||
</div>
|
||||
<script>
|
||||
var scriptLoadedMap = {};
|
||||
@@ -164,7 +164,7 @@ function drawGanttToCanvas(exportType, successCallback, errorCallback)
|
||||
function exportGantt(exportType)
|
||||
{
|
||||
var $mainContent = $('#mainContent');
|
||||
$mainContent.addClass('loading').css('height', Math.max(200, Math.floor($(window).height() - $('#footer').outerHeight() - $('#header').outerHeight() - $('#mainMenu').outerHeight() - 38)));
|
||||
$mainContent.addClass('loading').css('height', Math.max(200, Math.floor($(window).height() - $('#footer').outerHeight() - $('#header').outerHeight() - 38)));
|
||||
$('#ganttExportDate').text(new Date().format('yyyy-MM-dd hh:mm:ss'));
|
||||
var afterFinish = function(url)
|
||||
{
|
||||
|
||||
@@ -1240,11 +1240,11 @@ class projectModel extends model
|
||||
public function suspend($projectID)
|
||||
{
|
||||
$oldProject = $this->getById($projectID);
|
||||
$now = helper::now();
|
||||
$project = fixer::input('post')
|
||||
->setDefault('status', 'suspended')
|
||||
->setDefault('lastEditedBy', $this->app->user->account)
|
||||
->setDefault('lastEditedDate', $now)
|
||||
->setDefault('lastEditedDate', helper::now())
|
||||
->setDefault('suspendedDate', helper::today())
|
||||
->remove('comment')->get();
|
||||
|
||||
$this->dao->update(TABLE_PROJECT)->data($project)
|
||||
@@ -1272,6 +1272,7 @@ class projectModel extends model
|
||||
->setDefault('status', 'doing')
|
||||
->setDefault('lastEditedBy', $this->app->user->account)
|
||||
->setDefault('lastEditedDate', $now)
|
||||
->setIF($oldProject->realBegan == '0000-00-00', 'realBegan', helper::today())
|
||||
->remove('comment,readjustTime,readjustTask')
|
||||
->get();
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
table td, table th {overflow: hidden; white-space: nowrap; text-overflow: ellipsis;}
|
||||
.c-phone {width: 120px;}
|
||||
.c-email {width: 200px;}
|
||||
.c-name {width: 120px;}
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
<th class='c-id'>
|
||||
<?php common::printOrderLink('id', $orderBy, $vars, $lang->idAB);?>
|
||||
</th>
|
||||
<th><?php echo $lang->stakeholder->name;?></th>
|
||||
<th class="c-name"><?php echo $lang->stakeholder->name;?></th>
|
||||
<th class="c-type"><?php echo $lang->stakeholder->common . $lang->stakeholder->type;?></th>
|
||||
<th class="c-phone"><?php echo $lang->stakeholder->phone;?></th>
|
||||
<th class="c-qq"><?php echo $lang->stakeholder->qq;?></th>
|
||||
|
||||
+24
-5
@@ -22,9 +22,28 @@ class weeklyModel extends model
|
||||
public function getPageNav($project, $date)
|
||||
{
|
||||
$date = date('Ymd', strtotime($this->getThisMonday($date)));
|
||||
$begin = $project->begin;
|
||||
$weeks = $this->getWeekPairs($begin);
|
||||
$current = zget($weeks, $date, '');
|
||||
switch($project->status)
|
||||
{
|
||||
case 'wait':
|
||||
$begin = helper::now();
|
||||
$end = $begin;
|
||||
break;
|
||||
case 'doing':
|
||||
$begin = $project->realBegan != '0000-00-00' ? $project->realBegan : $date;
|
||||
$end = $date;
|
||||
break;
|
||||
case 'suspended':
|
||||
$begin = $project->realBegan != '0000-00-00' ? $project->realBegan : $project->suspendedDate;
|
||||
$end = $project->suspendedDate;
|
||||
break;
|
||||
case 'closed':
|
||||
$begin = $project->realBegan != '0000-00-00' ? $project->realBegan : $project->realEnd;
|
||||
$end = $project->realEnd;
|
||||
break;
|
||||
}
|
||||
|
||||
$weeks = $this->getWeekPairs($begin, $end);
|
||||
$current = zget($weeks, $date, current($weeks));
|
||||
$selectHtml = "<div class='btn-group angle-btn'>";
|
||||
$selectHtml .= html::a('###', $this->lang->weekly->common . $this->lang->colon . $project->name, '', "class='btn'");
|
||||
$selectHtml .= '</div>';
|
||||
@@ -49,9 +68,9 @@ class weeklyModel extends model
|
||||
* @access public
|
||||
* @return array
|
||||
*/
|
||||
public function getWeekPairs($begin)
|
||||
public function getWeekPairs($begin, $end = '')
|
||||
{
|
||||
$sn = $this->getWeekSN($begin, date('Y-m-d'));
|
||||
$sn = $end != '' ? $this->getWeekSN($begin, $end) : $this->getWeekSN($begin, date('Y-m-d'));
|
||||
$weeks = array();
|
||||
for($i = 0; $i <= $sn; $i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user