diff --git a/module/custom/control.php b/module/custom/control.php index 22f29cbd22..15008bb0cf 100644 --- a/module/custom/control.php +++ b/module/custom/control.php @@ -522,7 +522,7 @@ class custom extends control if(!isset($this->config->maxVersion)) $this->loadModel('setting')->setItem('system.custom.hourPoint', $this->post->hourPoint); $this->app->loadLang('common'); - $locate = inlink('flow'); + $locate = $this->config->systemMode == 'new' ? inlink('flow') : 'top'; $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => $locate)); } diff --git a/module/dept/view/browse.html.php b/module/dept/view/browse.html.php index 7d937bc132..8a7eaf808c 100644 --- a/module/dept/view/browse.html.php +++ b/module/dept/view/browse.html.php @@ -66,7 +66,7 @@ - + createLink('company', 'browse'), $lang->goback, '', "class='btn btn-back btn-wide'");?> diff --git a/module/execution/control.php b/module/execution/control.php index 9c201ab31c..c23163d4d3 100644 --- a/module/execution/control.php +++ b/module/execution/control.php @@ -1872,6 +1872,43 @@ class execution extends control */ public function executionKanban() { + $this->loadModel('project'); + $projects = $this->project->getPairsByProgram(0, 'noclosed'); + $executions = $this->project->getStats(); + + $teams = $this->dao->select('root,account')->from(TABLE_TEAM) + ->where('root')->in($this->app->user->view->sprints) + ->andWhere('type')->eq('execution') + ->fetchGroup('root', 'account'); + + $projectCount = 0; + $kanbanGroup = array(); + $statusCount = array(); + foreach(array_keys($projects) as $projectID) + { + foreach(array_keys($this->lang->execution->statusList) as $status) + { + if(!isset($statusCount[$status])) $statusCount[$status] = 0; + foreach($executions as $execution) + { + if($execution->status == $status) + { + if(isset($teams[$execution->id][$this->app->user->account])) $kanbanGroup[0][$status][$execution->id] = $execution; + if($execution->project == $projectID) $kanbanGroup[$projectID][$status][$execution->id] = $execution; + } + } + $statusCount[$status] += isset($kanbanGroup[$projectID][$status]) ? count($kanbanGroup[$projectID][$status]) : 0; + } + $projectCount++; + } + ksort($kanbanGroup); + + $this->view->title = $this->lang->execution->executionKanban; + $this->view->kanbanGroup = $kanbanGroup; + $this->view->projects = $projects; + $this->view->projectCount = $projectCount; + $this->view->statusCount = $statusCount; + $this->display(); } diff --git a/module/execution/css/executionkanban.css b/module/execution/css/executionkanban.css new file mode 100644 index 0000000000..71abe57304 --- /dev/null +++ b/module/execution/css/executionkanban.css @@ -0,0 +1,29 @@ +.main-table tbody > tr > td {border-bottom: 2px solid #fff;} +.boards {display: table; table-layout: fixed; width: 100%; min-width: 140px;} +.boards .board:not(:last-child), .board-project {border-right: 2px solid #fff;} +.board {display: table-cell; width: 25%; padding: 10px; transition: background-color .2s, opacity .2s; vertical-align: top;} +.board-item {border: 1px solid #EBEBEB; padding: 5px 10px; cursor: move; border-radius: 2px; background-color: #fff;} +.board-item.disabled {cursor: not-allowed;} +.board-item:hover {border-color: #ccc;} +.board-item > .title {line-height: 25px; max-height: 40px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; text-overflow: ellipsis; word-break: break-all;} +.board-item + .board-item {margin-top: 10px;} +.boards-wrapper {overflow: auto;} +.board-item .btn {padding: 2px 10px 2px 23px; font-size: 12px; position: relative; left: -2px; height: 24px;} + +#kanban {overflow-y: auto;} +#kanban .label-pri {width: 16px; height: 16px; line-height: 12px; min-width: 16px; font-size: 12px; padding: 0;} +#kanban tbody > tr > td {line-height: 24px;} +#kanban .table-grouped tbody > tr:hover {background: transparent;} +#kanban .group-info > span + span {display: inline-block; margin-left: 8px;} +#kanban th.c-board {color: #3c4353; font-weight: bold;} +#kanban .fix-table-copy-wrapper {overflow: visible !important;} +#kanban .fix-table-copy-wrapper th.c-board {color: #ddd;} +#kanban .group-title {word-break: break-all; line-height: 16px; padding: 3px 0; display: block;} + +#kanban thead > tr > th:not(:last-child) {border-right: 2px solid #efefef;} + +.table-grouped > tbody > tr, +.table-grouped > tbody > tr:hover {background: #fff !important;} + +.table-row .table-col:last-child {width: 30px;} +.table-row .table-col:first-child {overflow: hidden; text-overflow: ellipsis; white-space: nowrap;} diff --git a/module/execution/lang/zh-cn.php b/module/execution/lang/zh-cn.php index 4b7bbbd144..7c76f78319 100644 --- a/module/execution/lang/zh-cn.php +++ b/module/execution/lang/zh-cn.php @@ -405,6 +405,13 @@ $lang->execution->featureBar['all']['doing'] = $lang->execution->statusList[ $lang->execution->featureBar['all']['suspended'] = $lang->execution->statusList['suspended']; $lang->execution->featureBar['all']['closed'] = $lang->execution->statusList['closed']; +$lang->execution->myExecutions = '我参与的'; +$lang->execution->doingProject = '进行中的项目'; +$lang->execution->kanbanColType['wait'] = $lang->execution->statusList['wait'] . '的' . $lang->execution->common; +$lang->execution->kanbanColType['doing'] = $lang->execution->statusList['doing'] . '的' . $lang->execution->common; +$lang->execution->kanbanColType['suspended'] = $lang->execution->statusList['suspended'] . '的' . $lang->execution->common; +$lang->execution->kanbanColType['closed'] = $lang->execution->statusList['closed'] . '的' . $lang->execution->common; + $lang->execution->treeLevel = array(); $lang->execution->treeLevel['all'] = '全部展开'; $lang->execution->treeLevel['root'] = '全部折叠'; @@ -416,3 +423,11 @@ $lang->execution->action->opened = '$date, 由 $actor 创建 $lang->execution->action->managed = '$date, 由 $actor 维护。$extra' . "\n"; $lang->execution->action->edited = '$date, 由 $actor 编辑。$extra' . "\n"; $lang->execution->action->extra = '相关产品为 %s。'; + +$lang->execution->statusColorList = array(); +$lang->execution->statusColorList['wait'] = '#0991FF'; +$lang->execution->statusColorList['doing'] = '#0BD986'; +$lang->execution->statusColorList['suspended'] = '#fdc137'; +$lang->execution->statusColorList['closed'] = '#838A9D'; + +$lang->execution->boardColorList = '#F1F3F5,#ECF4FD,#F6EDF7,#FFEDED,#FFF7EB,#FFF7E1'; diff --git a/module/execution/view/executionkanban.html.php b/module/execution/view/executionkanban.html.php new file mode 100644 index 0000000000..de38ce2666 --- /dev/null +++ b/module/execution/view/executionkanban.html.php @@ -0,0 +1,94 @@ + + +
+ + + + + execution->kanbanColType as $status => $col):?> + + + + + + + $executionList):?> + + + + + + + +
execution->doingProject . ' (' . $projectCount . ')';?>
+
+
+ execution->myExecutions : zget($projects, $projectID);?> + +
+
+
+
+
+ execution->kanbanColType as $colStatus => $col):?> +
+ + +
delay)) echo "style='border-left: 3px solid #ff0000';";?>> +
+
+ createLink('execution', 'task', "executionID=$execution->id"), $execution->name, '', 'class="title kanbaniframe" title="' . $execution->name . '"'); + } + else + { + echo "{$execution->name}"; + } + ?> +
+
+ +
+
+
hours->progress;?>
+
+
+ +
+
+
+ + +
+ +
+
+
+
+ + diff --git a/module/product/control.php b/module/product/control.php index 0dd8659e71..9f2c6d8a3e 100644 --- a/module/product/control.php +++ b/module/product/control.php @@ -587,11 +587,11 @@ class product extends control if(!empty($this->config->user->moreLink)) $this->config->moreLinks["RD"] = $this->config->user->moreLink; /* Get product lines by programs.*/ - $programs = $this->program->getPairs(); + $programs = $this->program->getTopPairs(); $lines = array(); - foreach($programs as $programID => $program) + foreach($programs as $id => $program) { - $lines[$programID] = array('') + $this->product->getLinePairs($programID); + $lines[$id] = array('') + $this->product->getLinePairs($id); } $this->view->title = $this->lang->product->batchEdit; @@ -602,6 +602,7 @@ class product extends control $this->view->poUsers = $poUsers; $this->view->qdUsers = $qdUsers; $this->view->rdUsers = $rdUsers; + $this->view->programID = $programID; $this->view->programs = array('') + $programs; unset($this->lang->product->typeList['']); diff --git a/module/product/view/batchedit.html.php b/module/product/view/batchedit.html.php index 0a4bda918b..3c4716187e 100755 --- a/module/product/view/batchedit.html.php +++ b/module/product/view/batchedit.html.php @@ -58,7 +58,7 @@ '>product->PO;?> '>product->QD;?> '>product->RD;?> - '>product->type;?> + '>product->type;?> '>product->status;?> '>product->desc;?> '>product->acl;?> @@ -73,12 +73,12 @@ ?> - ' style='overflow:visible'>program, "class='form-control chosen' onchange='loadProductLines(this.value, $productID)'");?> + ' style='overflow:visible'>program, "class='form-control picker-select' onchange='loadProductLines(this.value, $productID)'");?> name, "class='form-control'");?> - ' style='overflow:visible' id="line_">program]) ? $lines[$products[$productID]->program] : '', $products[$productID]->line, "class='form-control chosen'");?> - ' style='overflow:visible'>PO, "class='form-control chosen'");?> - ' style='overflow:visible'>QD, "class='form-control chosen'");?> - ' style='overflow:visible'>RD, "class='form-control chosen'");?> + ' style='overflow:visible' id="line_">program]) ? $lines[$products[$productID]->program] : '', $products[$productID]->line, "class='form-control picker-select'");?> + ' style='overflow:visible'>PO, "class='form-control picker-select'");?> + ' style='overflow:visible'>QD, "class='form-control picker-select'");?> + ' style='overflow:visible'>RD, "class='form-control picker-select'");?> '>product->typeList, $products[$productID]->type, "class='form-control'");?> '>product->statusList, $products[$productID]->status, "class='form-control'");?> '>desc), "rows='1' class='form-control autosize'");?> @@ -95,7 +95,8 @@ - + app->openApp == 'product' ? $this->createLink('product', 'all') : $this->createLink('program', 'product', "programID=$programID");?> + goback, '', 'class="btn btn-back btn-wide"');?> diff --git a/module/user/lang/de.php b/module/user/lang/de.php index 22a2adde58..db8a4768a2 100644 --- a/module/user/lang/de.php +++ b/module/user/lang/de.php @@ -121,8 +121,8 @@ $lang->user->testTask2Him = 'Build'; $lang->user->case2Him = 'Fall zugeordnet'; $lang->user->caseByHim = 'Fall geöffnet'; -$lang->user->errorDeny = "Sorry, Ihr Zugang zu %s von %s wurde verweigert. Bitte kontaktieren Sie Ihren Administrator um Zugriff zu erhalten. Klicken Sie auf Zurück."; -$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Click Back to return."; +$lang->user->errorDeny = "Sorry, your access to %s of %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; +$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; $lang->user->loginFailed = "Login fehlgeschlagen. Bitte prüfen Sie Ihren Benutzernamen und das Passwort."; $lang->user->lockWarning = "Sie haben %s Versuche."; $lang->user->loginLocked = "Bitte kontaktieren Sie den Administrator um Ihr Konto entsperren zu lassen oder versuchen Sie in %s Minuten noch ein mal."; diff --git a/module/user/lang/en.php b/module/user/lang/en.php index 832665ba4f..0cc1448dca 100644 --- a/module/user/lang/en.php +++ b/module/user/lang/en.php @@ -122,8 +122,8 @@ $lang->user->testTask2Him = 'RequestsAssignedTo%s'; $lang->user->case2Him = 'CasesAssignedTo%s'; $lang->user->caseByHim = 'CasesCreatedBy%s'; -$lang->user->errorDeny = "Sorry, your access to %s of %s is denied. Please contact your Admin to get privileges. Click Back to return."; -$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Click Back to return."; +$lang->user->errorDeny = "Sorry, your access to %s of %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; +$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; $lang->user->loginFailed = "Login failed. Please check your account and password."; $lang->user->lockWarning = "You can try %s times."; $lang->user->loginLocked = "Please contact the administrator to unlock your account or try %s minutes later."; diff --git a/module/user/lang/fr.php b/module/user/lang/fr.php index 65c8bf70cb..a45e743490 100644 --- a/module/user/lang/fr.php +++ b/module/user/lang/fr.php @@ -121,8 +121,8 @@ $lang->user->testTask2Him = 'Recette assignée à %s'; $lang->user->case2Him = 'CasTest assigné à %s'; $lang->user->caseByHim = 'CasTest créé par %s'; -$lang->user->errorDeny = "Désolé, votre accès à %s of %s est refusé. Veuillez contacter votre administrateur pour obtenir des privilèges. Cliquez sur Retour pour revenir."; -$lang->user->errorView = "Désolé, votre accès en consultation %s est refusé. Veuillez contacter votre administrateur pour obtenir des privilèges. Cliquez sur Retour pour revenir."; +$lang->user->errorDeny = "Sorry, your access to %s of %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; +$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; $lang->user->loginFailed = "Echec de connexion. Vérifiez votre login et mot de passe."; $lang->user->lockWarning = "Vous avez %s essais."; $lang->user->loginLocked = "Votre compte est bloqué. Contactez l'administrateur pour débloquer votre compte ou attendez %s minutes pour une nouvelle tentative."; diff --git a/module/user/lang/vi.php b/module/user/lang/vi.php index 68e1d9a2af..14fa1d8620 100644 --- a/module/user/lang/vi.php +++ b/module/user/lang/vi.php @@ -121,8 +121,8 @@ $lang->user->testTask2Him = 'Nhận yêu cầu'; $lang->user->case2Him = 'Nhận tình huống'; $lang->user->caseByHim = 'Tạo tình huống'; -$lang->user->errorDeny = "Xin lỗi, truy cập của bạn tới %s of %s bị từ chối. Vui lòng liên lạc quản trị của bạn để nhận quyền. Click Trở lại."; -$lang->user->errorView = "Xin lỗi, truy cập của bạn xem %s bị từ chối. Vui lòng liên lạc quản trị của bạn để nhận quyền. Click Trở lại."; +$lang->user->errorDeny = "Sorry, your access to %s of %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; +$lang->user->errorView = "Sorry, your access view %s is denied. Please contact your Admin to get privileges. Return to home page or login again."; $lang->user->loginFailed = "Đăng nhập thất bại. Vui lòng kiểm tra tài khoản và mật khẩu của bạn."; $lang->user->lockWarning = "Bạn có thể thử %s lần."; $lang->user->loginLocked = "Vui lòng liên hệ với quản trị viên để mở khóa tài khoản của bạn hoặc thử lại %s phút sau."; diff --git a/module/user/lang/zh-cn.php b/module/user/lang/zh-cn.php index a43467e8f2..4c1e11feb7 100644 --- a/module/user/lang/zh-cn.php +++ b/module/user/lang/zh-cn.php @@ -122,8 +122,8 @@ $lang->user->testTask2Him = '%s负责的'; $lang->user->case2Him = '指派给%s'; $lang->user->caseByHim = '由%s创建'; -$lang->user->errorDeny = "抱歉,您无权访问『%s』模块的『%s』功能。请联系管理员获取权限。点击后退返回上页。"; -$lang->user->errorView = "抱歉,您无权访问『%s』视图。请联系管理员获取权限。点击后退返回上页。"; +$lang->user->errorDeny = "抱歉,您无权访问『%s』模块的『%s』功能。请联系管理员获取权限。请回到地盘或重新登录。"; +$lang->user->errorView = "抱歉,您无权访问『%s』视图。请联系管理员获取权限。请回到地盘或重新登录。"; $lang->user->loginFailed = "登录失败,请检查您的用户名或密码是否填写正确。"; $lang->user->lockWarning = "您还有%s次尝试机会。"; $lang->user->loginLocked = "密码尝试次数太多,请联系管理员解锁,或%s分钟后重试。";