From 0976ce4cd565d99e4dbe2727fd517847ea2cb3d5 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 22 Jul 2022 10:09:27 +0800 Subject: [PATCH 1/5] * Fix bug #25567. --- module/story/view/edit.html.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/module/story/view/edit.html.php b/module/story/view/edit.html.php index d3bed5546f..ced03a5862 100644 --- a/module/story/view/edit.html.php +++ b/module/story/view/edit.html.php @@ -216,7 +216,8 @@ story->assignedTo;?> - assignedTo, 'class="form-control chosen"');?> + status == 'closed' ? $users + array('closed' => 'Closed') : $users;?> + assignedTo, 'class="form-control chosen"');?> From 5818db887ff8b2168a2d8b6d277c7ce6510b15fd Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 22 Jul 2022 10:28:42 +0800 Subject: [PATCH 2/5] * Fix bug #25122. --- module/task/model.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/task/model.php b/module/task/model.php index 6e4bbfd708..6f8d4795ac 100644 --- a/module/task/model.php +++ b/module/task/model.php @@ -1823,7 +1823,7 @@ class taskModel extends model if(!empty($task->team)) { - $myConsumed = $task->team[$task->assignedTo]->consumed; + $myConsumed = $task->team[$this->app->user->account]->consumed; $newTeamInfo = new stdClass(); $newTeamInfo->consumed = $myConsumed + $consumed; @@ -1831,7 +1831,7 @@ class taskModel extends model $this->dao->update(TABLE_TEAM)->data($newTeamInfo) ->where('root')->eq($taskID) ->andWhere('type')->eq('task') - ->andWhere('account')->eq($task->assignedTo) + ->andWhere('account')->eq($this->app->user->account) ->exec(); $data = $this->computeHours4Multiple($task, $data); From 29a889ddcffe37ca8a49291bbd2c45cd4fcafbf0 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 22 Jul 2022 12:03:23 +0800 Subject: [PATCH 3/5] * Fix bug #24702. --- module/testcase/js/common.js | 10 +++++----- module/testcase/view/batchcreate.html.php | 6 +++--- module/testcase/view/batchedit.html.php | 2 +- module/testcase/view/create.html.php | 2 +- module/testcase/view/edit.html.php | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/module/testcase/js/common.js b/module/testcase/js/common.js index b9f686ff18..f08c4ac4d7 100644 --- a/module/testcase/js/common.js +++ b/module/testcase/js/common.js @@ -131,7 +131,7 @@ function setStories() productID = $('#product').val(); branch = $('#branch').val(); if(typeof(branch) == 'undefined') branch = 0; - link = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branch + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=50&type=full&hasParent=1&executionID=' + executionID); + link = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branch + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=0&type=full&hasParent=1&executionID=' + executionID); $.get(link, function(stories) { @@ -141,7 +141,7 @@ function setStories() $('#story').val(value); $('#story_chosen').remove(); $('#story').next('.picker').remove(); - $("#story").chosen(); + $("#story").picker(); }); } @@ -364,7 +364,7 @@ function loadStories(productID, moduleID, num) { var branchIDName = (config.currentMethod == 'batchcreate' || config.currentMethod == 'showimport') ? '#branch' : '#branches'; var branchID = $(branchIDName + num).val(); - var storyLink = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branchID + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=50&type=full&hasParent=1&executionID=0&number=' + num); + var storyLink = createLink('story', 'ajaxGetProductStories', 'productID=' + productID + '&branch=' + branchID + '&moduleID=' + moduleID + '&storyID=0&onlyOption=false&status=noclosed&limit=0&type=full&hasParent=1&executionID=0&number=' + num); $.get(storyLink, function(stories) { if(!stories) stories = ''; @@ -378,7 +378,7 @@ function loadStories(productID, moduleID, num) $('#story' + i + "_chosen").remove(); $('#story' + i).next('.picker').remove(); $('#story' + i).attr('name', 'story[' + i + ']'); - $('#story' + i).chosen(); + $('#story' + i).picker(); } } else @@ -387,7 +387,7 @@ function loadStories(productID, moduleID, num) $('#story' + num + "_chosen").remove(); $('#story' + num).next('.picker').remove(); $('#story' + num).attr('name', 'story[' + num + ']'); - $('#story' + num).chosen(); + $('#story' + num).picker(); } }); } diff --git a/module/testcase/view/batchcreate.html.php b/module/testcase/view/batchcreate.html.php index 86afac21b6..ac496f4a04 100644 --- a/module/testcase/view/batchcreate.html.php +++ b/module/testcase/view/batchcreate.html.php @@ -90,7 +90,7 @@ branchBox'> moduleBox' style='overflow:visible'> - storyBox' style='overflow:visible'> id : '', 'class="form-control chosen"');?> + storyBox' style='overflow:visible'> id : '', 'class="form-control picker-select"');?>
@@ -141,7 +141,7 @@ %s branchBox'> moduleBox' style='overflow:visible'> - storyBox' style='overflow:visible'> + storyBox' style='overflow:visible'>
@@ -180,7 +180,7 @@ branchBox'> moduleBox' style='overflow:visible'> - storyBox' style='overflow:visible'> id : '', 'class="form-control chosen"');?> + storyBox' style='overflow:visible'> id : '', 'class="form-control picker-select"');?>
diff --git a/module/testcase/view/batchedit.html.php b/module/testcase/view/batchedit.html.php index a3a38b0cf0..5549ccc491 100644 --- a/module/testcase/view/batchedit.html.php +++ b/module/testcase/view/batchedit.html.php @@ -97,7 +97,7 @@ ' style='overflow:visible'> '/')), $cases[$caseID]->module, "class='form-control chosen' onchange='loadStories($productID, this.value, $caseID)'");?> - ' style='overflow:visible'>story, "class='form-control chosen'");?> + ' style='overflow:visible'>story, "class='form-control picker-select'");?>
diff --git a/module/testcase/view/create.html.php b/module/testcase/view/create.html.php index 4bfecdb21c..e9a6f9a188 100644 --- a/module/testcase/view/create.html.php +++ b/module/testcase/view/create.html.php @@ -84,7 +84,7 @@ foreach(explode(',', $config->testcase->create->requiredFields) as $field) testcase->lblStory;?>
- searchMore . '"');?> + searchMore . '"');?> diff --git a/module/testcase/view/edit.html.php b/module/testcase/view/edit.html.php index 449d189d30..07d9a0a0d6 100644 --- a/module/testcase/view/edit.html.php +++ b/module/testcase/view/edit.html.php @@ -204,7 +204,7 @@ testcase->story;?> -
story, 'class="form-control chosen"');?>
+
story, 'class="form-control picker-select"');?>
From 69049288982c05b7a660495a38bef364ae473e73 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 22 Jul 2022 13:25:09 +0800 Subject: [PATCH 4/5] * Fix bug #25389. --- module/upgrade/model.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/module/upgrade/model.php b/module/upgrade/model.php index fd58531ebe..f0868da70f 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -5038,7 +5038,7 @@ class upgradeModel extends model public function computeObjectMembers() { $this->app->loadLang('user'); - $projects = $this->dao->select('id,days')->from(TABLE_PROJECT)->where('type')->eq('project')->fetchAll('id'); + $projects = $this->dao->select('id,days,PM')->from(TABLE_PROJECT)->where('type')->eq('project')->fetchAll('id'); $projectIdList = array_keys($projects); /* Get product and sprint team. */ @@ -5091,7 +5091,9 @@ class upgradeModel extends model $projectMember = array_filter($projectMember); $project = zget($projects, $projectID, ''); - $members = implode(',', $projectMember); + + if(!empty($project) and !isset($projectMember[$project->PM])) $projectMember[$project->PM] = $project->PM; + $members = implode(',', $projectMember); $this->dao->update(TABLE_DOCLIB) ->set('users')->eq($members) From 3db92860742124c578e668e2f5daa7afbf9a59a5 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Fri, 22 Jul 2022 13:28:02 +0800 Subject: [PATCH 5/5] * Fix bug #25398. --- module/user/css/login.css | 1 + 1 file changed, 1 insertion(+) diff --git a/module/user/css/login.css b/module/user/css/login.css index f983807e03..d6ece8764a 100644 --- a/module/user/css/login.css +++ b/module/user/css/login.css @@ -24,3 +24,4 @@ html[lang='en'] #loginPanel .table-form > tbody > tr > th {width: 80px;} .table-row-extension .alert {margin-bottom: 0px !important;} .table-row-extension .content {color: #3c4353;} .table-row-extension .expired-tips {cursor: pointer;} +[lang^=fr] #loginPanel .table-form > tbody > tr > th {width: 100px;}