diff --git a/db/zentao.sql b/db/zentao.sql index eff40072fb..711fa9e07a 100644 --- a/db/zentao.sql +++ b/db/zentao.sql @@ -6002,8 +6002,6 @@ INSERT INTO `zt_config` (`owner`, `module`, `section`, `key`, `value`) VALUES (' INSERT INTO `zt_config` (`owner`, `module`, `section`, `key`, `value`) VALUES ('system', 'project', '', 'unitList', 'CNY,USD'); INSERT INTO `zt_config` (`owner`, `module`, `section`, `key`, `value`) VALUES ('system', 'project', '', 'defaultCurrency', 'CNY'); INSERT INTO `zt_config` (`owner`, `module`, `section`, `key`, `value`) VALUES ('system', 'story', '', 'reviewRules', 'allpass'); -INSERT INTO `zt_config` (`vision`,`owner`, `module`, `section`, `key`, `value`) VALUES ('lite','system', 'project', '', 'unitList', 'CNY,USD'); -INSERT INTO `zt_config` (`vision`,`owner`, `module`, `section`, `key`, `value`) VALUES ('lite','system', 'project', '', 'defaultCurrency', 'CNY'); -- DROP TABLE IF EXISTS `zt_im_chat`; CREATE TABLE IF NOT EXISTS `zt_im_chat` ( `id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT, diff --git a/extension/lite/project/ext/view/edit.lite.html.hook.php b/extension/lite/project/ext/view/edit.lite.html.hook.php deleted file mode 100644 index 294fb97412..0000000000 --- a/extension/lite/project/ext/view/edit.lite.html.hook.php +++ /dev/null @@ -1,3 +0,0 @@ - diff --git a/extension/lite/todo/ext/lang/zh-cn/lite.php b/extension/lite/todo/ext/lang/zh-cn/lite.php index c3f4110cde..636eb24d3c 100644 --- a/extension/lite/todo/ext/lang/zh-cn/lite.php +++ b/extension/lite/todo/ext/lang/zh-cn/lite.php @@ -1,6 +1,7 @@ todo->typeList['task'] = '任务'; +if($this->config->visions == ',lite,') unset($lang->todo->typeList['feedback']); unset($lang->todo->typeList['bug']); unset($lang->todo->typeList['testtask']); unset($lang->todo->typeList['review']); diff --git a/module/block/view/todoblock.html.php b/module/block/view/todoblock.html.php index 5ba7617301..2c55aa2355 100644 --- a/module/block/view/todoblock.html.php +++ b/module/block/view/todoblock.html.php @@ -22,7 +22,7 @@ if(!$selfCall) die(include('./todolist.html.php')); .block-todoes .todoes > li {position: relative; padding: 5px 10px 5px 35px; list-style: none; white-space:nowrap; overflow: auto; overflow-x:hidden;} .block-todoes .todoes > li:hover {background-color: #e9f2fb;} .block-todoes .todo-title {padding: 5px 15px 5px 5px;} -.titleBox {width: 700px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block;} +.titleBox {max-width: 700px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block;} .block-todoes .todo-pri {margin: 0 5px;} .block-todoes .todo-time {display: inline-block; padding: 0 5px; font-size: 12px; color: #8e939a; width: 95px;} .block-todoes .todo-check {position: absolute; top: 5px; left: 10px; display: block; width: 20px; height: 20px; font-size: 20px; color: transparent; cursor: pointer; background: #fff; border: 2px solid #eee; border-radius: 50%;} diff --git a/module/doc/model.php b/module/doc/model.php index bc7774264c..3962d4ae98 100644 --- a/module/doc/model.php +++ b/module/doc/model.php @@ -1530,9 +1530,9 @@ class docModel extends model { $issueIdList = $this->dao->select('id')->from(TABLE_ISSUE)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); $meetingIdList = $this->dao->select('id')->from(TABLE_MEETING)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); - $designIdList = $this->dao->select('id')->from(TABLE_DESIGN)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); } + $designIdList = $this->dao->select('id')->from(TABLE_DESIGN)->where('project')->eq($objectID)->andWhere('deleted')->eq('0')->andWhere('project')->in($this->app->user->view->projects)->get(); $executionIdList = $this->loadModel('execution')->getIdList($objectID); $taskPairs = $this->dao->select('id')->from(TABLE_TASK)->where('execution')->in($executionIdList)->andWhere('deleted')->eq('0')->andWhere('execution')->in($this->app->user->view->sprints)->fetchPairs('id'); if(!empty($taskPairs)) $taskIdList = implode(',', $taskPairs); diff --git a/module/execution/css/task.css b/module/execution/css/task.css index c821cffd61..203c981c71 100644 --- a/module/execution/css/task.css +++ b/module/execution/css/task.css @@ -6,3 +6,4 @@ th.c-deadline {text-align: center;} .c-estimate {text-align: right;} .c-consumed {text-align: right;} .c-left {text-align: right;} +.table-footer {z-index: 1;} diff --git a/module/execution/js/kanban.js b/module/execution/js/kanban.js index 1a147c3d9d..0526035b56 100644 --- a/module/execution/js/kanban.js +++ b/module/execution/js/kanban.js @@ -363,6 +363,8 @@ function findDropColumns($element, $root) var laneType = $element.closest('.kanban-lane').data().lane.type; var kanbanRules = window.kanbanDropRules ? window.kanbanDropRules[laneType] : null; + hideKanbanAction(); + if(!kanbanRules) return $root.find('.kanban-lane-col:not([data-type="' + col.type + '"])'); var colRules = kanbanRules[col.type]; @@ -993,23 +995,27 @@ function changeCardColType(cardID, fromColID, toColID, fromLaneID, toLaneID, car */ function deleteCard(objectType, objectID, regionID) { - var objectLang = objectType + 'Lang'; - var result = confirm(window[objectLang].confirmDelete) ? true : false; - - if(!result) return false; - if(!objectID) return false; - - var url = createLink('kanban', 'deleteObjectCard', 'objectType=' + objectType + '&objectID=' + objectID + '®ionID=' + regionID); - return $.ajax( + $.zui.ContextMenu.hide(); + setTimeout(function() { - method: 'post', - dataType: 'json', - url: url, - success: function(data) + var objectLang = objectType + 'Lang'; + var result = confirm(window[objectLang].confirmDelete) ? true : false; + + if(!result) return false; + if(!objectID) return false; + + var url = createLink('kanban', 'deleteObjectCard', 'objectType=' + objectType + '&objectID=' + objectID + '®ionID=' + regionID); + return $.ajax( { - updateRegion(regionID, data[regionID]); - } - }); + method: 'post', + dataType: 'json', + url: url, + success: function(data) + { + updateRegion(regionID, data[regionID]); + } + }); + }, 200) } /** diff --git a/module/execution/js/taskkanban.js b/module/execution/js/taskkanban.js index 2627d3dd92..31001c0e6a 100644 --- a/module/execution/js/taskkanban.js +++ b/module/execution/js/taskkanban.js @@ -515,6 +515,8 @@ function findDropColumns($element, $root) var kanbanID = $root.data('id'); var kanbanRules = window.kanbanDropRules ? window.kanbanDropRules[kanbanID] : null; + $.zui.ContextMenu.hide(); + if(!kanbanRules) return $root.find('.kanban-lane-col:not([data-type="' + col.type + '"])'); var colRules = kanbanRules[col.type]; @@ -1238,3 +1240,8 @@ function resetKanbanHeight() $('.kanban-lane').css('height', height -2); } + +$(document).on('click', '.dropdown-menu', function() +{ + $.zui.ContextMenu.hide(); +}); diff --git a/module/kanban/js/view.js b/module/kanban/js/view.js index 89800ac5d2..435eb6e5af 100644 --- a/module/kanban/js/view.js +++ b/module/kanban/js/view.js @@ -1592,7 +1592,7 @@ function resetRegionHeight(fold) } } -$('.dropdown-menu').click(function() +$(document).on('click', '.dropdown-menu', function() { $.zui.ContextMenu.hide(); -}) +}); diff --git a/module/project/model.php b/module/project/model.php index 9e38401331..013cdc7fe0 100644 --- a/module/project/model.php +++ b/module/project/model.php @@ -118,9 +118,11 @@ class projectModel extends model public function saveState($projectID = 0, $projects = array()) { if(defined('TUTORIAL')) return $projectID; - + if($projectID == 0 and $this->cookie->lastProject) $projectID = $this->cookie->lastProject; - if($projectID == 0 and $this->session->project == '') $projectID = key($projects); + if(($projectID == 0 and (int)$this->session->project == 0) or !isset($projects[$projectID])) $projectID = key($projects); + if($projectID == 0) $projectID = key($projects); + $this->session->set('project', (int)$projectID, $this->app->tab); if(!isset($projects[$this->session->project])) diff --git a/module/task/control.php b/module/task/control.php index 25ce86ce2a..53fa320eef 100644 --- a/module/task/control.php +++ b/module/task/control.php @@ -368,11 +368,11 @@ class task extends control if($story) { $moduleID = $story->module; - $stories = $this->story->getExecutionStoryPairs($executionID, 0, 'all', $moduleID, 'short'); + $stories = $this->story->getExecutionStoryPairs($executionID, 0, 'all', $moduleID, 'short', 'unclosed'); } else { - $stories = $this->story->getExecutionStoryPairs($executionID, 0, 'all', 0, 'short'); + $stories = $this->story->getExecutionStoryPairs($executionID, 0, 'all', 0, 'short', 'unclosed'); } $members = $this->loadModel('user')->getTeamMemberPairs($executionID, 'execution', 'nodeleted');