stage->batchCreate;?>

@@ -19,10 +20,10 @@ - + - - + + From e00d70491b9b9eabb6c8d2906b0548ef3498ab17 Mon Sep 17 00:00:00 2001 From: tanghucheng Date: Tue, 26 Apr 2022 13:47:34 +0800 Subject: [PATCH 09/23] * Fix bug . --- module/stage/config.php | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 module/stage/config.php diff --git a/module/stage/config.php b/module/stage/config.php new file mode 100644 index 0000000000..f77eb68cd9 --- /dev/null +++ b/module/stage/config.php @@ -0,0 +1,5 @@ +stage->create = new stdclass(); +$config->stage->edit = new stdclass(); +$config->stage->create->requiredFields = 'name,percent,type'; +$config->stage->edit->requiredFields = 'name,percent,type'; From 681850b9691a1e539f52d20bd440a93423c51e8b Mon Sep 17 00:00:00 2001 From: hufangzhou Date: Tue, 26 Apr 2022 14:10:36 +0800 Subject: [PATCH 10/23] * Fix bug #15645. --- module/api/js/common.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/module/api/js/common.js b/module/api/js/common.js index 0a18e788bc..d52f04a318 100644 --- a/module/api/js/common.js +++ b/module/api/js/common.js @@ -415,7 +415,10 @@ try { }, del(data, index) { if(data.length <= 1) return; - data.splice(index, 1) + for(let i = index+1; i < data.length; i++){ + if(data[i].sub == data[index].sub) return data.splice(index, i - index) + } + data.splice(index, data.length - index) }, changeType() { if (!this.params[this.structType] || this.params[this.structType].length > 0) { From 7688d211d32cbda2898e41d2deb21f56482f7fe5 Mon Sep 17 00:00:00 2001 From: zenggang Date: Tue, 26 Apr 2022 06:21:15 +0000 Subject: [PATCH 11/23] * Fix bug#21981 --- module/programplan/lang/en.php | 1 + module/programplan/lang/zh-cn.php | 1 + module/programplan/model.php | 3 +++ 3 files changed, 5 insertions(+) diff --git a/module/programplan/lang/en.php b/module/programplan/lang/en.php index ddd4931d7f..e9ef5a18f4 100644 --- a/module/programplan/lang/en.php +++ b/module/programplan/lang/en.php @@ -79,3 +79,4 @@ $lang->programplan->error->planFinishSmall = 'The "End" date must be > the "Begi $lang->programplan->error->percentOver = 'The sum of "Workload %" cannot exceed 100%.'; $lang->programplan->error->createdTask = 'The task is decomposed. Sub stages cannot be added.'; $lang->programplan->error->parentWorkload = 'The sum of the workload in the sub stage cannot be > that in the parent stage: %s.'; +$lang->programplan->error->sameName = 'Stage name cannot be the same!'; diff --git a/module/programplan/lang/zh-cn.php b/module/programplan/lang/zh-cn.php index c67b97931a..494b212d51 100644 --- a/module/programplan/lang/zh-cn.php +++ b/module/programplan/lang/zh-cn.php @@ -80,3 +80,4 @@ $lang->programplan->error->percentOver = '工作量占比累计不应当超 $lang->programplan->error->createdTask = '已分解任务,不可添加子阶段'; $lang->programplan->error->parentWorkload = '子阶段的工作量之和不能大于父阶段的工作量:%s'; $lang->programplan->error->parentDuration = '子阶段计划开始、计划完成不能超过父阶段'; +$lang->programplan->error->sameName = '阶段名称不能相同!'; diff --git a/module/programplan/model.php b/module/programplan/model.php index 3fefb2d7c9..3f522166b4 100644 --- a/module/programplan/model.php +++ b/module/programplan/model.php @@ -433,6 +433,9 @@ class programplanModel extends model $parentACL = $parentStage->acl; } + $names = array_filter($names); + if(count(array_unique($names)) != count($names)) return dao::$errors['message'][] = $this->lang->programplan->error->sameName; + $datas = array(); foreach($names as $key => $name) { From e8b57c9889f4900cf891854e62e7fc3c1b1ae9ac Mon Sep 17 00:00:00 2001 From: liyuchun <563917701@qq.com> Date: Tue, 26 Apr 2022 06:28:57 +0000 Subject: [PATCH 12/23] * Fix bug #17230. --- module/upgrade/control.php | 6 +++--- module/upgrade/model.php | 35 +++++++++++++++++++++++++++++++---- 2 files changed, 34 insertions(+), 7 deletions(-) diff --git a/module/upgrade/control.php b/module/upgrade/control.php index 823f95fb62..5cbf1357fc 100644 --- a/module/upgrade/control.php +++ b/module/upgrade/control.php @@ -83,7 +83,7 @@ class upgrade extends control $version = str_replace(array(' ', '.'), array('', '_'), $this->config->installedVersion); $version = strtolower($version); - if($this->config->visions == ',lite,') + if($this->config->visions == ',lite,') { $installedVersion = str_replace('.', '_', $this->config->installedVersion); $version = array_search($installedVersion, $this->config->upgrade->liteVersion); @@ -92,7 +92,7 @@ class upgrade extends control { if(strpos($key, 'lite') === false) unset($this->lang->upgrade->fromVersions[$key]); } - + $this->config->version = ($this->config->edition == 'biz' ? 'LiteVIP' : 'Lite') . $this->config->liteVersion; } @@ -640,7 +640,7 @@ class upgrade extends control $this->dao->update(TABLE_PROJECT)->set('name')->eq($projectName)->where('id')->eq($projectID)->exec(); } - return print(js::closeModal('parent.parent', '')); + return print(js::reload('parent.parent', '')); } $objectGroup = array(); diff --git a/module/upgrade/model.php b/module/upgrade/model.php index 68ffad56fe..da338659d6 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -4528,6 +4528,33 @@ class upgradeModel extends model if(isset($data->projectName) and $data->projectType == 'execution' and empty($data->projectName)) return print(js::alert(sprintf($this->lang->error->notempty, $this->lang->upgrade->projectName))); + if($data->projectType == 'project') + { + $projectPairs = $this->dao->select('id,name')->from(TABLE_EXECUTION) ->where('deleted')->eq('0') + ->andWhere('id')->in($projectIdList) + ->fetchPairs(); + + $projectNames = array(); + $duplicateList = ''; + foreach($projectPairs as $projectID => $projectName) + { + if(isset($projectNames[$projectName])) + { + $duplicateList .= "$projectID,"; + $duplicateList .= "{$projectNames[$projectName]},"; + continue; + } + + $projectNames[$projectName] = $projectID; + } + + if($duplicateList) + { + echo ""; + die; + } + } + /* Insert program. */ $program = new stdclass(); $program->name = $data->programName; @@ -6183,22 +6210,22 @@ class upgradeModel extends model } } - /** + /** * Update the project status. * * @access public * @return void - */ + */ public function updateProjectStatus() { - $projects = $this->dao->select('*')->from(TABLE_PROJECT) + $projects = $this->dao->select('*')->from(TABLE_PROJECT) ->where('deleted')->eq('0') ->andWhere('status')->eq('doing') ->andWhere('type')->eq('project') ->andWhere('realBegan')->eq('0000-00-00') ->fetchAll('id'); - if(empty($projects)) return; + if(empty($projects)) return; $projectIDList = array_keys($projects); From 01d59f0d28dbe505d2d8ff555bda25dfe41432ca Mon Sep 17 00:00:00 2001 From: mayue Date: Tue, 26 Apr 2022 06:35:36 +0000 Subject: [PATCH 13/23] * Fix bug #22004. --- module/story/css/track.css | 1 + module/story/view/track.html.php | 7 ++----- 2 files changed, 3 insertions(+), 5 deletions(-) create mode 100644 module/story/css/track.css diff --git a/module/story/css/track.css b/module/story/css/track.css new file mode 100644 index 0000000000..7408dc06fc --- /dev/null +++ b/module/story/css/track.css @@ -0,0 +1 @@ +.table td {text-align: center;} diff --git a/module/story/view/track.html.php b/module/story/view/track.html.php index 734e04d856..e5b53e557d 100644 --- a/module/story/view/track.html.php +++ b/module/story/view/track.html.php @@ -40,11 +40,9 @@ - URAndSR):?> - + app->rawModule == 'projectstory'): ?> @@ -84,7 +81,7 @@ $story):?> ';?> - From ec28d24b8d504c9f66ca6c397b2b491d2d413208 Mon Sep 17 00:00:00 2001 From: tianshujie Date: Tue, 26 Apr 2022 14:38:09 +0800 Subject: [PATCH 14/23] * Fix bug #13146. --- module/story/model.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/module/story/model.php b/module/story/model.php index 26807f63fb..41ec97f02b 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -457,14 +457,14 @@ class storyModel extends model $stories = $result['data']; $module = 0; - $plan = 0; + $plan = ''; $pri = 0; $source = ''; foreach($stories->title as $i => $title) { $module = $stories->module[$i] == 'ditto' ? $module : $stories->module[$i]; - $plan = isset($stories->plan[$i]) ? ($stories->plan[$i] == 'ditto' ? $plan : $stories->plan[$i]) : 0; + $plan = isset($stories->plan[$i]) ? ($stories->plan[$i] == 'ditto' ? $plan : $stories->plan[$i]) : ''; $pri = $stories->pri[$i] == 'ditto' ? $pri : $stories->pri[$i]; $source = $stories->source[$i] == 'ditto' ? $source : $stories->source[$i]; $stories->module[$i] = (int)$module; @@ -1520,7 +1520,7 @@ class storyModel extends model $newStory = new stdClass(); $newStory->parent = '-1'; - $newStory->plan = 0; + $newStory->plan = ''; $newStory->lastEditedBy = $this->app->user->account; $newStory->lastEditedDate = $now; $newStory->childStories = trim($oldStory->childStories . ',' . $childStories, ','); @@ -1624,7 +1624,7 @@ class storyModel extends model $story->duplicateStory = $data->duplicateStoryIDList[$storyID] ? $data->duplicateStoryIDList[$storyID] : $oldStory->duplicateStory; $story->childStories = $data->childStoriesIDList[$storyID] ? $data->childStoriesIDList[$storyID] : $oldStory->childStories; - if($story->closedReason != 'done') $story->plan = 0; + if($story->closedReason != 'done') $story->plan = ''; $stories[$storyID] = $story; unset($story); From 5e6290cda4bee599eda3a096bab6461ab21bcd66 Mon Sep 17 00:00:00 2001 From: zhengrunyu Date: Tue, 26 Apr 2022 14:40:32 +0800 Subject: [PATCH 15/23] * Fix api for chartdata. --- api/v1/entries/execution.php | 4 ++++ api/v1/entries/stories.php | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/api/v1/entries/execution.php b/api/v1/entries/execution.php index a328cb12b3..fcd380534b 100644 --- a/api/v1/entries/execution.php +++ b/api/v1/entries/execution.php @@ -99,6 +99,10 @@ class executionEntry extends Entry $dynamics = $data->data->dynamics; $execution->dynamics = $this->loadModel('action')->processDynamicForAPI($dynamics); break; + case 'chartdata': + list($dateList, $interval) = $this->loadModel('execution')->getDateList($execution->begin, $execution->end, 'noweekend', '0', 'Y-m-d'); + $execution->chartData = $this->execution->buildBurnData($executionID, $dateList, 'noweekend', 'left'); + break; } } diff --git a/api/v1/entries/stories.php b/api/v1/entries/stories.php index fa64edb6c2..2ca9ac9340 100644 --- a/api/v1/entries/stories.php +++ b/api/v1/entries/stories.php @@ -24,7 +24,7 @@ class storiesEntry extends entry if(!$productID) return $this->sendError(400, 'Need product id.'); $control = $this->loadController('product', 'browse'); - $control->browse($productID, $this->param('branch', ''), $this->param('status', 'unclosed'), 0, $this->param('type', 'story'), $this->param('order', 'id_desc'), 0, $this->param('limit', 20), $this->param('page', 1)); + $control->browse($productID, $this->param('branch', ''), $this->param('status', 'unclosed'), 0, $this->param('type', 'story'), $this->param('order', 'id_desc'), 0, $this->param('limit', '100'), $this->param('page', 1)); $data = $this->getData(); if(!$data or !isset($data->status)) return $this->sendError(400, 'error'); From d288ef5b119ab71593a25b4a3d2086e2ad3d581c Mon Sep 17 00:00:00 2001 From: zhengrunyu Date: Tue, 26 Apr 2022 14:45:40 +0800 Subject: [PATCH 16/23] * Fix api for stories limit. --- api/v1/entries/stories.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/v1/entries/stories.php b/api/v1/entries/stories.php index 2ca9ac9340..fa64edb6c2 100644 --- a/api/v1/entries/stories.php +++ b/api/v1/entries/stories.php @@ -24,7 +24,7 @@ class storiesEntry extends entry if(!$productID) return $this->sendError(400, 'Need product id.'); $control = $this->loadController('product', 'browse'); - $control->browse($productID, $this->param('branch', ''), $this->param('status', 'unclosed'), 0, $this->param('type', 'story'), $this->param('order', 'id_desc'), 0, $this->param('limit', '100'), $this->param('page', 1)); + $control->browse($productID, $this->param('branch', ''), $this->param('status', 'unclosed'), 0, $this->param('type', 'story'), $this->param('order', 'id_desc'), 0, $this->param('limit', 20), $this->param('page', 1)); $data = $this->getData(); if(!$data or !isset($data->status)) return $this->sendError(400, 'error'); From 928149db30c1e820c89afe75a66192784106a1d2 Mon Sep 17 00:00:00 2001 From: = <=> Date: Tue, 26 Apr 2022 14:50:30 +0800 Subject: [PATCH 17/23] * Feedback api. --- api/v1/entries/feedbacks.php | 125 +++++++++++++++++++++++++++++++++++ config/routes.php | 2 + 2 files changed, 127 insertions(+) create mode 100644 api/v1/entries/feedbacks.php diff --git a/api/v1/entries/feedbacks.php b/api/v1/entries/feedbacks.php new file mode 100644 index 0000000000..536ebf27bb --- /dev/null +++ b/api/v1/entries/feedbacks.php @@ -0,0 +1,125 @@ + + * @package entries + * @version 1 + * @link http://www.zentao.net + */ +class feedbacksEntry extends entry +{ + /** + * GET method. + * + * @param int $projectID + * @access public + * @return void + */ + public function get() + { + a('yes');die; + $control = $this->loadController('feedback', 'admin'); + $control->admin(); + $data = $this->getData(); + a($data);die; + + if(!$data or !isset($data->status)) return $this->sendError(400, 'error'); + if(isset($data->status) and $data->status == 'fail') return $this->sendError(400, $data->message); + + $executions = $data->data->executionStats; + $pager = $data->data->pager; + $projects = $data->data->projects; + + $data = array(); + $data['page'] = $pager->pageID; + $data['total'] = $pager->recTotal; + $data['limit'] = $pager->recPerPage; + $data['executions'] = $result; + if(!empty($withProject)) $data['projects'] = $projects; + + return $this->send(200, $data); + } + + /** + * POST method. + * + * @param int $projectID + * @access public + * @return void + */ + public function post($projectID = 0) + { + $fields = 'project,code,name,begin,end,lifetime,desc,days'; + $this->batchSetPost($fields); + + $projectID = $this->param('project', $projectID); + $this->setPost('project', $projectID); + $this->setPost('acl', $this->request('acl', 'private')); + $this->setPost('PO', $this->request('PO', '')); + $this->setPost('PM', $this->request('PM', '')); + $this->setPost('QD', $this->request('QD', '')); + $this->setPost('RD', $this->request('RD', '')); + $this->setPost('whitelist', $this->request('whitelist', array())); + $this->setPost('products', $this->request('products', array())); + $this->setPost('plans', $this->request('plans', array())); + + $control = $this->loadController('execution', 'create'); $this->requireFields('name,code,begin,end,days'); + $control->create($projectID); + + $data = $this->getData(); + if(isset($data->result) and $data->result == 'fail') return $this->sendError(400, $data->message); + + $execution = $this->loadModel('execution')->getByID($data->id); + + $this->send(201, $this->format($execution, 'openedBy:user,openedDate:time,lastEditedBy:user,lastEditedDate:time,closedBy:user,closedDate:time,canceledBy:user,canceledDate:time,PM:user,PO:user,RD:user,QD:user,whitelist:userList,begin:date,end:date,realBegan:date,realEnd:date,deleted:bool')); + } + + /** + * Get drop menu. + * + * @access public + * @return void + */ + public function getDropMenu() + { + $control = $this->loadController('execution', 'ajaxGetDropMenu'); + $control->ajaxGetDropMenu($this->request('executionID', 0), $this->request('module', 'execution'), $this->request('method', 'task'), $this->request('extra', '')); + + $data = $this->getData(); + if(isset($data->result) and $data->result == 'fail') return $this->sendError(400, $data->message); + + $account = $this->app->user->account; + $projects = $data->data->projects; + $dropMenu = array('involved' => array(), 'other' => array(), 'closed' => array()); + foreach($data->data->executions as $projectID => $projectExecutions) + { + foreach($projectExecutions as $execution) + { + if(helper::diffDate(date('Y-m-d'), $execution->end) > 0) $execution->delay = true; + $teams = $execution->teams; + $execution = $this->filterFields($execution, 'id,project,model,type,name,code,status,PM,delay'); + + $projectName = zget($projects, $execution->project, ''); + if($projectName) $execution->name = $projectName . '/' . $execution->name; + + if($execution->status == 'closed') + { + $dropMenu['closed'][] = $execution; + } + elseif($execution->status != 'done' and $execution->status != 'closed' and ($execution->PM == $account or isset($teams->$account))) + { + $dropMenu['involved'][] = $execution; + } + else + { + $dropMenu['other'][] = $execution; + } + } + } + + $this->send(200, $dropMenu); + } +} diff --git a/config/routes.php b/config/routes.php index 23156d702d..bad7129397 100644 --- a/config/routes.php +++ b/config/routes.php @@ -16,6 +16,8 @@ $routes['/tabs/:module'] = 'tabs'; $routes['/files'] = 'files'; $routes['/files/:id'] = 'file'; +$routes['/feedbacks'] = 'feedbacks'; + $routes['/options/:type'] = 'options'; $routes['/configurations'] = 'configs'; From dc6d0493fb383b0fe38850c178404c9ac4d85132 Mon Sep 17 00:00:00 2001 From: zhouxin Date: Tue, 26 Apr 2022 07:02:36 +0000 Subject: [PATCH 18/23] * Fix bug #2607. --- module/dev/lang/zh-cn.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/dev/lang/zh-cn.php b/module/dev/lang/zh-cn.php index e32df540b9..c3d0954b9a 100644 --- a/module/dev/lang/zh-cn.php +++ b/module/dev/lang/zh-cn.php @@ -60,7 +60,7 @@ $lang->dev->tableList['projectstory'] = '项目' . $lang->SRCommon; $lang->dev->tableList['execution'] = $lang->executionCommon; $lang->dev->tableList['release'] = '发布'; $lang->dev->tableList['story'] = $lang->SRCommon; -$lang->dev->tableList['storyspec'] = "{$lang->SRCommon}描述"; +$lang->dev->tableList['storyspec'] = "需求描述"; $lang->dev->tableList['task'] = '任务'; $lang->dev->tableList['taskestimate'] = '任务预计'; $lang->dev->tableList['team'] = '团队'; From 2fe95ae6598930f70c9d734ddcb6d9267d8bfe57 Mon Sep 17 00:00:00 2001 From: = <=> Date: Tue, 26 Apr 2022 15:06:22 +0800 Subject: [PATCH 19/23] * Feedback api. --- api/v1/entries/feedbacks.php | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/api/v1/entries/feedbacks.php b/api/v1/entries/feedbacks.php index 536ebf27bb..1eeb8c2636 100644 --- a/api/v1/entries/feedbacks.php +++ b/api/v1/entries/feedbacks.php @@ -20,25 +20,27 @@ class feedbacksEntry extends entry */ public function get() { - a('yes');die; $control = $this->loadController('feedback', 'admin'); - $control->admin(); + $control->admin($this->param('status', 'unclosed'), 0, $this->param('orderBy', 'id_desc'), 0, $this->param('limit', 20), $this->param('page', 1)); $data = $this->getData(); - a($data);die; if(!$data or !isset($data->status)) return $this->sendError(400, 'error'); if(isset($data->status) and $data->status == 'fail') return $this->sendError(400, $data->message); - $executions = $data->data->executionStats; - $pager = $data->data->pager; - $projects = $data->data->projects; + $feedbacks = $data->data->feedbacks; + $pager = $data->data->pager; + + $result = array(); + foreach($feedbacks as $feedback) + { + $result[] = $this->format($feedback, 'openedBy:user,openedDate:time,reviewedBy:user,reviewedDate:time,processedBy:user,processedDate:time,closedBy:user,closedDate:time,editedBy:user,editedDate:time,mailto:userList,deleted:bool'); + } $data = array(); - $data['page'] = $pager->pageID; - $data['total'] = $pager->recTotal; - $data['limit'] = $pager->recPerPage; - $data['executions'] = $result; - if(!empty($withProject)) $data['projects'] = $projects; + $data['page'] = $pager->pageID; + $data['total'] = $pager->recTotal; + $data['limit'] = $pager->recPerPage; + $data['feedbacks'] = $result; return $this->send(200, $data); } From 2633b5c23cc6f9b1f2c754fba3c769df5697a7d0 Mon Sep 17 00:00:00 2001 From: zhengrunyu Date: Tue, 26 Apr 2022 15:14:22 +0800 Subject: [PATCH 20/23] * Fix bug when create task and story error. --- module/story/control.php | 2 +- module/task/control.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/module/story/control.php b/module/story/control.php index 0e6a275007..11d75168ca 100644 --- a/module/story/control.php +++ b/module/story/control.php @@ -978,7 +978,7 @@ class story extends control $version = $this->dao->findById($storyID)->from(TABLE_STORY)->fetch('version'); $files = $this->loadModel('file')->saveUpload($story->type, $storyID, $version); - if(empty($files) and $this->post->uid != '') $files = $this->file->getPairs($_SESSION['album']['used'][$this->post->uid]); + if(empty($files) and $this->post->uid != '' and isset($_SESSION['album']['used'][$this->post->uid])) $files = $this->file->getPairs($_SESSION['album']['used'][$this->post->uid]); if($this->post->comment != '' or !empty($changes) or !empty($files)) { diff --git a/module/task/control.php b/module/task/control.php index 8608103802..132f3f5f71 100644 --- a/module/task/control.php +++ b/module/task/control.php @@ -465,7 +465,7 @@ class task extends control $changes = $this->task->update($taskID); if(dao::isError()) return print(js::error(dao::getError())); $files = $this->loadModel('file')->saveUpload('task', $taskID); - if(empty($files) and $this->post->uid != '') $files = $this->file->getPairs($_SESSION['album']['used'][$this->post->uid]); + if(empty($files) and $this->post->uid != '' and isset($_SESSION['album']['used'][$this->post->uid])) $files = $this->file->getPairs($_SESSION['album']['used'][$this->post->uid]); } $task = $this->task->getById($taskID); From 4c031465dcf249ed514102efab53f2e623830cde Mon Sep 17 00:00:00 2001 From: liyuchun <563917701@qq.com> Date: Tue, 26 Apr 2022 07:38:12 +0000 Subject: [PATCH 21/23] * Fix bug #22005. --- db/update16.5.sql | 1 + db/zentao.sql | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/db/update16.5.sql b/db/update16.5.sql index ae5b49e6c4..afb1d27fd1 100644 --- a/db/update16.5.sql +++ b/db/update16.5.sql @@ -43,6 +43,7 @@ ALTER TABLE `zt_opportunity` MODIFY COLUMN `prevention` mediumtext NOT NULL; ALTER TABLE `zt_opportunity` MODIFY COLUMN `resolution` mediumtext NOT NULL; ALTER TABLE `zt_trainplan` MODIFY COLUMN `summary` mediumtext NOT NULL; ALTER TABLE `zt_gapanalysis` MODIFY COLUMN `analysis` mediumtext NOT NULL; +ALTER TABLE `zt_bug` MODIFY COLUMN `entry` text NOT NULL; ALTER TABLE `zt_file` MODIFY COLUMN `title` varchar(255) NOT NULL; diff --git a/db/zentao.sql b/db/zentao.sql index 0b680fb3e3..37d7525b6f 100644 --- a/db/zentao.sql +++ b/db/zentao.sql @@ -206,7 +206,7 @@ CREATE TABLE IF NOT EXISTS `zt_bug` ( `result` mediumint(8) unsigned NOT NULL, `repo` mediumint(8) unsigned NOT NULL, `mr` mediumint(8) unsigned NOT NULL, - `entry` varchar(255) NOT NULL, + `entry` text NOT NULL, `lines` varchar(10) NOT NULL, `v1` varchar(40) NOT NULL, `v2` varchar(40) NOT NULL, From df378ff26f328750617b4c9765fa26b94cfa41fc Mon Sep 17 00:00:00 2001 From: renying Date: Tue, 26 Apr 2022 07:44:38 +0000 Subject: [PATCH 22/23] Fixbug#19044 --- module/story/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/story/model.php b/module/story/model.php index 26807f63fb..1796e00396 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -2690,7 +2690,7 @@ class storyModel extends model { $storyQuery = str_replace($allBranch, '1', $storyQuery); } - elseif($branch !== 'all') + elseif($branch !== 'all' and $queryProductID != 'all') { if($branch and strpos($storyQuery, '`branch` =') === false) $storyQuery .= " AND `branch` in($branch)"; } From ece5cdbd21e442641e1852975db2eaef377e1054 Mon Sep 17 00:00:00 2001 From: liyuchun <563917701@qq.com> Date: Tue, 26 Apr 2022 07:48:53 +0000 Subject: [PATCH 23/23] * Adjsut code. --- module/upgrade/model.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/module/upgrade/model.php b/module/upgrade/model.php index da338659d6..4b37cc7b82 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -4530,7 +4530,8 @@ class upgradeModel extends model if($data->projectType == 'project') { - $projectPairs = $this->dao->select('id,name')->from(TABLE_EXECUTION) ->where('deleted')->eq('0') + $projectPairs = $this->dao->select('id,name')->from(TABLE_EXECUTION) + ->where('deleted')->eq('0') ->andWhere('id')->in($projectIdList) ->fetchPairs();
stage->id;?>stage->id;?> stage->name;?>stage->percent;?>stage->type;?>stage->percent;?>stage->type;?>
story->story;?>> - app->rawModule == 'projectstory'): ?> - story->tasks;?> + parent) and $story->parent > 0):?>lang->story->childrenAB;?> createLink($module, 'view', "storyID=$storyID"), $story->title, '',"title='$story->title' data-app='$tab'");?>