From e24e6c318ef90db3ed3d506283ca8864a0e173e3 Mon Sep 17 00:00:00 2001 From: daitingting Date: Thu, 22 Mar 2018 14:03:05 +0800 Subject: [PATCH 01/10] * Add changelog for 9.8.2. --- doc/CHANGELOG | 95 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 95 insertions(+) diff --git a/doc/CHANGELOG b/doc/CHANGELOG index 69c8d06801..d0555a0fa5 100644 --- a/doc/CHANGELOG +++ b/doc/CHANGELOG @@ -1,3 +1,98 @@ +2018-03-21 9.8.2.stable +完成的需求 +2853 计划日期待定是开始日期和结束日期都是待定 +2852 指派给我的区块中待办直接弹窗即可 +2850 调整导出数据页面的样式 +2849 消息发送设置页面样式调整 +2848 发布列表页面的版本链接不应该新开窗口 +2847 搜索表单字段检索下拉的菜单没有必要这么长 +2846 修改日志里面去掉版本之前的v +2845 调整待办批量添加页面的样式 +2844 计划列表页面将任务,bug,工时字段放在结束日期字段后面 +2836 产品批量编辑增加产品线字段 +2831 禅道国际版不需要单独列gmail发信功能 + +修复的Bug +1460 父子任务中,有子任务删除,剩余未删除子任务全部完成关闭后,不会更新父任务状态 +1459 搜索条件保存多菜单栏后,搜索条件不生效 +1458 企业版-运维-翻译 +1457 测试-测试单,可以对运维项目提测,但运维项目没有版本 +1456 用例库导入的模版文件格式不对 +1455 组织-动态 搜索下拉列表数据重复 +1454 产品描述中的图片再编辑产品后无法显示 +1453 需求列表,统计数量异常 +1452 项目-任务-导出问题。 +1451 控制面板 修改密码 翻译累赘 需要简化 +1448 个人档案中,对email地址未做格式验证 +1447 国际版中,我的地盘存在一个汉字 +1446 任务日志页面的ID有重复 +1445 文档编辑器选择编号格式无法正常显示 +1444 用户表真实姓名字段的长度需要加长 +1442 子任务取消,父任务无法点击完成。 +1441 项目关联需求(该需求关联产品,项目关联产品),看不到部分需求。 +1439 钉钉集成确认、解决bug,指派后消息中没有@显示 +1438 csv导入用例提示的行数错误 +1437 用例搜索结果的值选项中有“忽略” +1436 文档库的统计数字和列出的数字不一致 +1435 添加用户时,用户名不符合规范提示信息不清楚 +1434 云禅道我的地盘指派给我的区块不显示内容,但可以点击 +1433 点击创建子任务按钮,弹出窗口容易和批量创建任务混淆,建议区分。 +1432 项目概况,编辑,产品名称展示优化。 +1431 后台自定义内容丢失 +1430 9.8.1批量创建需求,功能异常。 +1428 批量创建需求问题。 +1427 待办点击待办名称-删除按钮删除,弹出页面显示异常 +1426 项目-任务,多人任务,团队成员上限。新建与编辑不一致。 +1425 确认一下组织-用户中查看指派给他的任务和我的地盘中的查询规则是否一致 +1424 项目任务,完成,默认指派人应该是任务的创建者。 +1423 项目-测试单中提交测试,测试报告名称编号会显示所有项目版本 +1422 产品线删除后,所有页面产品所属产品线显示产品线编号 +1421 测试bug,保存搜索条件功能,异常。 +1420 指派人员开始任务,剩余工时填写0,完成任务时,完成者会显示创建人 +1419 IE11浏览器,点击需求的任务数,不弹窗(部分)。 +1418 通过解决bug选择解决版本,对版本提测生成测试单,不显示相关bug +1417 关联需求显示的需求列表优先级没有按照后台自定义设置内容显示 +1416 父任务关闭后,子任务会同步关闭,但是子任务指派人不会指派给closed +1415 延期的子任务,不会在项目-任务-已延期列表中显示 +1414 测试管理工具用例导出功能异常 +1413 钉钉集成创建任务消息中没有@显示 +1412 自定义bug优先级,存在问题。 +1411 用例库导入用例模块如果层级比较多无法展示 +1410 如果产品比较多查询性能问题需要排查一下 +1409 Bug添加搜索菜单,无法正常搜索。 +1408 测试-测试单查看概况没有显示版本的下载地址 +1407 任务列表选中统计的工时会把父子任务的工时重复统计 +1406 ie下日历无法正常点击选择日期 +1405 首页、任务列表、燃尽图、项目概况的剩余工时计算规则不一致 +1404 创建项目页面关联计划会显示过期的计划 +1403 项目按照计划关联需求会把没有关联的计划也列出来 +1401 后台-自定义-用户-职位,键值大于10个字符,可以正常保存,编辑用户选择职位时会提示字符数限制 +1400 子任务完成后,不会指派回任务创建者 +1399 测试报告参与人默认会显示已经移除关联的用例执行人 +1398 创建测试单可以不选择 版本直接提交 +1396 项目-测试单下,没有测试单时,会有一条测试报告,内容为空 +1395 Bug激活,提示问题(解决日期、关闭日期) +1394 模块层数比较多显示不全 +1393 用例删除后,用例覆盖率统计时还是会统计这条用例 +1392 项目关联需求页面所属产品显示有问题 +1391 备注重复提交没有做内容验证 +1390 用例导出后,步骤、预期,会多出一行空行。专业版excel导出有同样问题 +1389 搜索保存菜单记录的有问题 +1387 后台-自定义-需求-评审流程,设置强制评审人员,保存不上 +1380 超级model调用如果某个参数的值中有 英文逗号只能传输第一个逗号之前的数据 +1379 任务列表,任务条数大于每页显示条数时,新建子任务会显示在最后一页 +1376 测试用例导入csv文件,预期和步骤包含符号时,需要加句号导入才能显示 +1372 统计报表统计和自定义内容不统一 +1370 后台自定义中的键值没有做检查 +1368 任务选择模块后,添加子任务保存后,停留在批量添加页面 +1363 后台自定义日期必填项无效 +1359 看板,未开始的任务,不能拖拽到进行中。 +1357 Bug列表,自定义列,勾选全局,点击保存;不生效。 +1346 用例执行的实际情况输入框,一旦输入内容就会显示滚动条会挡住输入的内容 +1339 父任务标题过长时,标题后面的折叠标签不显示 +1333 项目关闭后,状态为已完成,并且数据库中相关字段未更新 +1008 我的地盘首页的待办点击后跳转到组织-用户-待办页面 + 2018-01-17 9.8.stable 完成的需求 683 todo增加转需求,bug或者任务的功能 From 38219cede9258542eb13cae04bd2203ce682c633 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 22 Mar 2018 14:17:09 +0800 Subject: [PATCH 02/10] * fix for width. --- module/search/view/buildform.html.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/search/view/buildform.html.php b/module/search/view/buildform.html.php index 81f6499ae9..6cf6e45adf 100644 --- a/module/search/view/buildform.html.php +++ b/module/search/view/buildform.html.php @@ -44,7 +44,7 @@ include '../../common/view/chosen.html.php'; #searchlite {line-height: 127px} #searchform.showmore #searchmore, #searchform #searchlite {display: none;} #searchform.showmore #searchlite, #searchform #searchmore {display: inline-block;} -#searchform .chosen-container[id^="field"] .chosen-drop{min-width: 120px;} +#searchform .chosen-container[id^="field"] .chosen-drop{min-width: 140px;} #searchform [id^="valueBox"] .chosen-container .chosen-single{max-width: 170px;} #searchform [id^="valueBox"] .chosen-container .chosen-drop{min-width: 400px;} #searchform .chosen-container .chosen-drop ul.chosen-results li{white-space:normal} From fb223a3bd76f92e71be6f70839cdb13dae23276a Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 22 Mar 2018 14:29:27 +0800 Subject: [PATCH 03/10] * adjust for check has custom pri. --- module/bug/view/create.html.php | 4 ++-- module/story/view/create.html.php | 2 +- module/task/view/create.html.php | 4 ++-- module/testcase/view/create.html.php | 2 +- module/testsuite/view/createcase.html.php | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/module/bug/view/create.html.php b/module/bug/view/create.html.php index 62330cdb1a..23f32cafaa 100644 --- a/module/bug/view/create.html.php +++ b/module/bug/view/create.html.php @@ -165,7 +165,7 @@ js::set('confirmDeleteTemplate', $lang->bug->confirmDeleteTemplate); $hasCustomSeverity = false; foreach($lang->bug->severityList as $severityKey => $severityValue) { - if(!empty($severityKey) and ($severityKey != $severityValue or strlen($severityKey) != strlen($severityValue))) + if(!empty($severityKey) and (string)$severityKey != (string)$severityValue) { $hasCustomSeverity = true; break; @@ -190,7 +190,7 @@ js::set('confirmDeleteTemplate', $lang->bug->confirmDeleteTemplate); $hasCustomPri = false; foreach($lang->bug->priList as $priKey => $priValue) { - if(!empty($priKey) and ($priKey != $priValue or strlen($priKey) != strlen($priValue))) + if(!empty($priKey) and (string)$priKey != (string)$priValue) { $hasCustomPri = true; break; diff --git a/module/story/view/create.html.php b/module/story/view/create.html.php index 01921eb89b..0f1e3eec71 100644 --- a/module/story/view/create.html.php +++ b/module/story/view/create.html.php @@ -113,7 +113,7 @@ $hasCustomPri = false; foreach($lang->story->priList as $priKey => $priValue) { - if(!empty($priKey) and ($priKey != $priValue or strlen($priKey) != strlen($priValue))) + if(!empty($priKey) and (string)$priKey != (string)$priValue) { $hasCustomPri = true; break; diff --git a/module/task/view/create.html.php b/module/task/view/create.html.php index 5863db6299..0ac596761c 100644 --- a/module/task/view/create.html.php +++ b/module/task/view/create.html.php @@ -43,7 +43,7 @@ assignedTo, "class='form-control chosen'");?> - + @@ -90,7 +90,7 @@ $hasCustomPri = false; foreach($lang->task->priList as $priKey => $priValue) { - if(!empty($priKey) and ($priKey != $priValue or strlen($priKey) != strlen($priValue))) + if(!empty($priKey) and (string)$priKey != (string)$priValue) { $hasCustomPri = true; break; diff --git a/module/testcase/view/create.html.php b/module/testcase/view/create.html.php index 3c30db426b..e972abb32a 100644 --- a/module/testcase/view/create.html.php +++ b/module/testcase/view/create.html.php @@ -101,7 +101,7 @@ $hasCustomPri = false; foreach($lang->testcase->priList as $priKey => $priValue) { - if(!empty($priKey) and ($priKey != $priValue or strlen($priKey) != strlen($priValue))) + if(!empty($priKey) and (string)$priKey != (string)$priValue) { $hasCustomPri = true; break; diff --git a/module/testsuite/view/createcase.html.php b/module/testsuite/view/createcase.html.php index 4f5d40a6f5..3291cbaa3a 100644 --- a/module/testsuite/view/createcase.html.php +++ b/module/testsuite/view/createcase.html.php @@ -78,7 +78,7 @@ $hasCustomPri = false; foreach($lang->testcase->priList as $priKey => $priValue) { - if(!empty($priKey) and ($priKey != $priValue or strlen($priKey) != strlen($priValue))) + if(!empty($priKey) and (string)$priKey != (string)$priValue) { $hasCustomPri = true; break; From a0204a58e99d2d92d022baad5803eab7fc80943d Mon Sep 17 00:00:00 2001 From: daitingting Date: Thu, 22 Mar 2018 14:30:28 +0800 Subject: [PATCH 04/10] * Display pri value for short type. --- 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 624250069c..131c5e6b4d 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -1962,7 +1962,7 @@ class storyModel extends model { if($type == 'short') { - $property = '[p' . $story->pri . ', ' . $story->estimate . 'h]'; + $property = '[p' . (!empty($this->lang->story->priList[$story->pri]) ? $this->lang->story->priList[$story->pri] : 0) . ', ' . $story->estimate . 'h]'; } else { From ad1a24089df2fc50dde598d596dd5ee8990a5cf6 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 22 Mar 2018 15:00:55 +0800 Subject: [PATCH 05/10] * code for plan getpairs with unexpired. --- module/productplan/model.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/module/productplan/model.php b/module/productplan/model.php index 2a47aa9f13..a4ac4410a7 100644 --- a/module/productplan/model.php +++ b/module/productplan/model.php @@ -117,16 +117,18 @@ class productplanModel extends model ->where('product')->in($product) ->andWhere('deleted')->eq(0) ->beginIF($branch)->andWhere("branch")->in("0,$branch")->fi() - ->beginIF($expired == 'unexpired')->andWhere('end')->gt($date)->fi() + ->beginIF($expired == 'unexpired')->andWhere('end')->ge($date)->fi() ->orderBy('begin desc') ->fetchPairs(); - if($expired == 'unexpired' and empty($plans)) + if($expired == 'unexpired') { - $plans = $this->dao->select('id,CONCAT(title, " [", begin, " ~ ", end, "]") as title')->from(TABLE_PRODUCTPLAN) + $plans += $this->dao->select('id,CONCAT(title, " [", begin, " ~ ", end, "]") as title')->from(TABLE_PRODUCTPLAN) ->where('product')->in($product) ->andWhere('deleted')->eq(0) + ->andWhere('end')->lt($date) ->beginIF($branch)->andWhere("branch")->in("0,$branch")->fi() + ->beginIF($plans)->andWhere("id")->notIN(array_keys($plans))->fi() ->orderBy('begin desc') ->limit(5) ->fetchPairs(); From 4d475eef594c7522d8445e5c0445ef57d7f98196 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 22 Mar 2018 15:11:52 +0800 Subject: [PATCH 06/10] * fix error for deleted branch in link story. --- module/project/model.php | 1 + 1 file changed, 1 insertion(+) diff --git a/module/project/model.php b/module/project/model.php index 2ef1fb26b7..50742242dc 100644 --- a/module/project/model.php +++ b/module/project/model.php @@ -1081,6 +1081,7 @@ class projectModel extends model $productType = $product->type; if($product->branch) { + if(!isset($branchGroups[$product->id][$product->branch])) continue; $branchPairs[$product->branch] = (count($products) > 1 ? $product->name . '/' : '') . $branchGroups[$product->id][$product->branch]; } else From 3027a4fd3bd977cee54a7aaf10a4fc52e54f4fca Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 22 Mar 2018 15:28:50 +0800 Subject: [PATCH 07/10] * adjust for team padding in modal. --- module/task/css/create.css | 4 +++- module/task/css/edit.css | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/module/task/css/create.css b/module/task/css/create.css index 21e7dcdaab..d14b89ef57 100644 --- a/module/task/css/create.css +++ b/module/task/css/create.css @@ -14,4 +14,6 @@ #taskPlanCol, #mailCol {width: 50%} #planAndMailCell.has-mail-col #taskPlanCol {padding-right: 5px;} #planAndMailCell.has-mail-col #taskPlanCol + #mailCol {padding-left: 5px;} -.input-group-addon input[type='checkBox']{} \ No newline at end of file +.input-group-addon input[type='checkBox']{} + +#modalTeam .modal-content{padding:8px 25px;} diff --git a/module/task/css/edit.css b/module/task/css/edit.css index 865ead609b..783273dc00 100644 --- a/module/task/css/edit.css +++ b/module/task/css/edit.css @@ -3,3 +3,6 @@ #finishedDate.form-control.form-date {width: 218px!important} #canceledDate.form-control.form-date {width: 218px!important} #closedDate.form-control.form-date {width: 218px!important} + +#modalTeam .modal-content{padding:8px 25px;} +#modalTeam .modal-content .table{border:none;} From 867849c2544c00ae69f925a3f45eb995a35354b2 Mon Sep 17 00:00:00 2001 From: daitingting Date: Thu, 22 Mar 2018 15:42:57 +0800 Subject: [PATCH 08/10] * Optimize future function for productplan. --- module/productplan/js/create.js | 26 ++++++++----- module/productplan/js/edit.js | 49 +++++++++++++------------ module/productplan/lang/zh-cn.php | 15 ++++---- module/productplan/model.php | 16 ++++---- module/productplan/view/create.html.php | 11 +++++- module/productplan/view/edit.html.php | 12 +++++- module/productplan/view/view.html.php | 6 ++- 7 files changed, 81 insertions(+), 54 deletions(-) diff --git a/module/productplan/js/create.js b/module/productplan/js/create.js index 8f4168c49d..480f5822d2 100644 --- a/module/productplan/js/create.js +++ b/module/productplan/js/create.js @@ -35,16 +35,8 @@ function computeEndDate(delta) currentBeginDate = beginDate.toString('yyyy-MM-dd'); endDate = beginDate.addDays(delta - 1).toString('yyyy-MM-dd'); - if(delta == 9999) - { - $('#begin').attr("disabled", "disabled"); - $('#end').val('').attr("disabled", "disabled"); - } - else - { - $('#begin').val(currentBeginDate).removeAttr('disabled') - $('#end').val(endDate).removeAttr('disabled'); - } + $('#begin').val(currentBeginDate); + $('#end').val(endDate); } $('#begin').on('change', function() @@ -57,3 +49,17 @@ $('#end').on('change', function() { $("input:radio[name='delta']").attr("checked", false); }); + +$('#future').on('change', function() +{ + if($(this).prop('checked')) + { + $('#begin').val('').attr('disabled', 'disabled'); + $('#end').val('').parents('tr').hide(); + } + else + { + $('#begin').removeAttr('disabled'); + $('#end').val('').parents('tr').show(); + } +}); diff --git a/module/productplan/js/edit.js b/module/productplan/js/edit.js index 1816e040e5..284db982cd 100644 --- a/module/productplan/js/edit.js +++ b/module/productplan/js/edit.js @@ -23,33 +23,34 @@ function convertStringToDate(dateString) function computeEndDate(delta) { beginDate = $('#begin').val(); - delta = parseInt(delta); + if(!beginDate) return; - if(delta == 9999) + delta = parseInt(delta); + beginDate = convertStringToDate(beginDate); + if((delta == 7 || delta == 14) && (beginDate.getDay() == 1)) { - $('#begin').attr("disabled", "disabled"); - $('#end').val('').attr("disabled","disabled"); + delta = (weekend == 2) ? (delta - 2) : (delta - 1); + } + + currentBeginDate = beginDate.toString('yyyy-MM-dd'); + endDate = beginDate.addDays(delta - 1).toString('yyyy-MM-dd'); + + $('#begin').val(currentBeginDate); + $('#end').val(endDate).datetimepicker('update'); +} + +$('#future').on('change', function() +{ + if($(this).prop('checked')) + { + $('#begin').val('').attr('disabled', 'disabled'); + $('#end').val('').parents('tr').hide(); } else { - if(beginDate) - { - beginDate = convertStringToDate(beginDate); - if((delta == 7 || delta == 14) && (beginDate.getDay() == 1)) - { - delta = (weekend == 2) ? (delta - 2) : (delta - 1); - } - - currentBeginDate = beginDate.toString('yyyy-MM-dd'); - endDate = beginDate.addDays(delta - 1).toString('yyyy-MM-dd'); - } - else - { - currentBeginDate = ''; - endDate = ''; - } - - $('#begin').val(currentBeginDate).removeAttr('disabled') - $('#end').val(endDate).removeAttr('disabled').datetimepicker('update'); + $('#begin').removeAttr('disabled'); + $('#end').val('').parents('tr').show(); } -} +}); + +$('#future').change(); diff --git a/module/productplan/lang/zh-cn.php b/module/productplan/lang/zh-cn.php index 97102a30ab..41a8a79e21 100644 --- a/module/productplan/lang/zh-cn.php +++ b/module/productplan/lang/zh-cn.php @@ -52,14 +52,13 @@ $lang->productplan->bugs = 'Bug数'; $lang->productplan->hour = '工时'; $lang->productplan->project = $lang->projectCommon; -$lang->productplan->endList[7] = '一星期'; -$lang->productplan->endList[14] = '两星期'; -$lang->productplan->endList[31] = '一个月'; -$lang->productplan->endList[62] = '两个月'; -$lang->productplan->endList[93] = '三个月'; -$lang->productplan->endList[186] = '半年'; -$lang->productplan->endList[365] = '一年'; -$lang->productplan->endList[9999] = '待定'; +$lang->productplan->endList[7] = '一星期'; +$lang->productplan->endList[14] = '两星期'; +$lang->productplan->endList[31] = '一个月'; +$lang->productplan->endList[62] = '两个月'; +$lang->productplan->endList[93] = '三个月'; +$lang->productplan->endList[186] = '半年'; +$lang->productplan->endList[365] = '一年'; $lang->productplan->errorNoTitle = 'ID %s 标题不能为空'; $lang->productplan->errorNoBegin = 'ID %s 开始时间不能为空'; diff --git a/module/productplan/model.php b/module/productplan/model.php index 2a47aa9f13..a95cfe5cb2 100644 --- a/module/productplan/model.php +++ b/module/productplan/model.php @@ -159,16 +159,16 @@ class productplanModel extends model public function create() { $plan = fixer::input('post')->stripTags($this->config->productplan->editor->create['id'], $this->config->allowedTags) - ->setIF($this->post->delta == 9999 || empty($_POST['end']), 'end', '2030-01-01') - ->setIF($this->post->delta == 9999 || empty($_POST['begin']), 'begin', '2030-01-01') - ->remove('delta,uid') + ->setIF($this->post->future || empty($_POST['begin']), 'begin', '2030-01-01') + ->setIF($this->post->future || empty($_POST['end']), 'end', '2030-01-01') + ->remove('delta,uid,future') ->get(); $plan = $this->loadModel('file')->processImgURL($plan, $this->config->productplan->editor->create['id'], $this->post->uid); $this->dao->insert(TABLE_PRODUCTPLAN) ->data($plan) ->autoCheck() ->batchCheck($this->config->productplan->create->requiredFields, 'notempty') - ->checkIF($this->post->delta != 9999 && !empty($_POST['begin']) && !empty($_POST['end']), 'end', 'gt', $plan->begin) + ->checkIF(!$this->post->future && !empty($_POST['begin']) && !empty($_POST['end']), 'end', 'gt', $plan->begin) ->exec(); if(!dao::isError()) { @@ -190,9 +190,9 @@ class productplanModel extends model { $oldPlan = $this->dao->findByID((int)$planID)->from(TABLE_PRODUCTPLAN)->fetch(); $plan = fixer::input('post')->stripTags($this->config->productplan->editor->edit['id'], $this->config->allowedTags) - ->setIF($this->post->delta == 9999 || $this->post->end == '', 'end', '2030-01-01') - ->setIF($this->post->delta == 9999 || empty($_POST['begin']), 'begin', '2030-01-01') - ->remove('delta,uid') + ->setIF($this->post->future || empty($_POST['begin']), 'begin', '2030-01-01') + ->setIF($this->post->future || empty($_POST['end']), 'end', '2030-01-01') + ->remove('delta,uid,future') ->get(); $plan = $this->loadModel('file')->processImgURL($plan, $this->config->productplan->editor->edit['id'], $this->post->uid); @@ -200,7 +200,7 @@ class productplanModel extends model ->data($plan) ->autoCheck() ->batchCheck($this->config->productplan->edit->requiredFields, 'notempty') - ->checkIF($this->post->delta != 9999 && !empty($_POST['begin']) && !empty($_POST['end']), 'end', 'gt', $plan->begin) + ->checkIF(!$this->post->future && !empty($_POST['begin']) && !empty($_POST['end']), 'end', 'gt', $plan->begin) ->where('id')->eq((int)$planID) ->exec(); if(!dao::isError()) diff --git a/module/productplan/view/create.html.php b/module/productplan/view/create.html.php index 33d69af724..d29137a360 100644 --- a/module/productplan/view/create.html.php +++ b/module/productplan/view/create.html.php @@ -43,7 +43,16 @@ productplan->begin;?> - + +
+ + + + +
+ productplan->end;?> diff --git a/module/productplan/view/edit.html.php b/module/productplan/view/edit.html.php index 6edc8f72a5..78ae352f54 100644 --- a/module/productplan/view/edit.html.php +++ b/module/productplan/view/edit.html.php @@ -41,7 +41,17 @@ productplan->begin;?> - begin != '2030-01-01' ? formatTime($plan->begin) : '', "class='form-control form-date'");?> + +
+ begin != '2030-01-01' ? formatTime($plan->begin) : '', "class='form-control form-date'");?> + begin == '2030-01-01' || $plan->end == '2030-01-01' ? "checked='checked'" : '';?> + + + +
+ productplan->end;?> diff --git a/module/productplan/view/view.html.php b/module/productplan/view/view.html.php index df56628229..22d048b38f 100644 --- a/module/productplan/view/view.html.php +++ b/module/productplan/view/view.html.php @@ -20,7 +20,9 @@ icons['plan']);?> id;?> title;?> type !== 'normal') echo "" . $branches[$branch] . '';?> - begin . '~' . $plan->end;?> + + begin == '2030-01-01' || $plan->end == '2030-01-01') ? $lang->productplan->future : $plan->begin . '~' . $plan->end;?> + deleted):?> plan->deleted;?> @@ -403,7 +405,7 @@ productplan->begin;?> - begin;?> + begin == '2030-01-01' ? $lang->productplan->future : $plan->begin;?> productplan->end;?> From 19bb7f1f1e4b1df7a1c9fad00f3824700cd9b750 Mon Sep 17 00:00:00 2001 From: daitingting Date: Thu, 22 Mar 2018 15:45:49 +0800 Subject: [PATCH 09/10] * Adjust params for page function. --- module/story/model.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/story/model.php b/module/story/model.php index 131c5e6b4d..a6ea673cfe 100644 --- a/module/story/model.php +++ b/module/story/model.php @@ -1615,8 +1615,8 @@ class storyModel extends model ->where($sql) ->beginIF($productID != 'all' and $productID != '')->andWhere('t1.`product`')->eq((int)$productID)->fi() ->andWhere('deleted')->eq(0) - ->orderBy($orderBy, 't1.id') - ->page($pager) + ->orderBy($orderBy) + ->page($pager, 't1.id') ->fetchAll('id'); if(!$tmpStories) return array(); From 5786761b69ebf802119e146a60030a9d94a18bd8 Mon Sep 17 00:00:00 2001 From: daitingting Date: Thu, 22 Mar 2018 16:22:32 +0800 Subject: [PATCH 10/10] * Adjust codes. --- module/webhook/config.php | 2 ++ module/webhook/model.php | 13 ++++++++----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/module/webhook/config.php b/module/webhook/config.php index df7384e81f..3a014363fd 100644 --- a/module/webhook/config.php +++ b/module/webhook/config.php @@ -16,3 +16,5 @@ $config->webhook->objectTypes['bug'] = array('opened', 'edited', 'commen $config->webhook->objectTypes['case'] = array('opened', 'edited', 'commented', 'reviewed', 'confirmed'); $config->webhook->objectTypes['testtask'] = array('opened', 'edited', 'started', 'blocked', 'closed', 'activated'); $config->webhook->objectTypes['todo'] = array('opened', 'edited'); + +$config->webhook->needAssignTypes = array('story', 'task', 'bug', 'todo'); diff --git a/module/webhook/model.php b/module/webhook/model.php index c053433e9d..58075f3447 100644 --- a/module/webhook/model.php +++ b/module/webhook/model.php @@ -227,13 +227,16 @@ class webhookModel extends model $mobile = ''; $email = ''; - foreach($users as $user) + if(in_array($objectType, $this->config->webhook->needAssignTypes) && !empty($object->assignedTo)) { - if($user->account == $object->assignedTo) + foreach($users as $user) { - $mobile = $user->mobile; - $email = $user->email; - break; + if($user->account == $object->assignedTo) + { + $mobile = $user->mobile; + $email = $user->email; + break; + } } } $action->text = $text;