验收产品,测试人开发
This commit is contained in:
17
pom.xml
17
pom.xml
@@ -99,13 +99,6 @@
|
|||||||
<version>1.5.2</version>
|
<version>1.5.2</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.alibaba</groupId>
|
|
||||||
<artifactId>easyexcel</artifactId>
|
|
||||||
<version>3.0.5</version>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.tencentcloudapi</groupId>
|
<groupId>com.tencentcloudapi</groupId>
|
||||||
@@ -293,11 +286,11 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
<dependency>
|
<!-- <dependency>-->
|
||||||
<groupId>org.apache.commons</groupId>
|
<!-- <groupId>org.apache.commons</groupId>-->
|
||||||
<artifactId>commons-pool2</artifactId>
|
<!-- <artifactId>commons-pool2</artifactId>-->
|
||||||
<version>2.8.1</version>
|
<!-- <version>2.8.1</version>-->
|
||||||
</dependency>
|
<!-- </dependency>-->
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
|||||||
@@ -15,26 +15,24 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
|
|||||||
@RestControllerAdvice
|
@RestControllerAdvice
|
||||||
public class GlobalExceptionHandler {
|
public class GlobalExceptionHandler {
|
||||||
|
|
||||||
@Value("spring.application.name")
|
@Value("${spring.application.name}")
|
||||||
private String application;
|
private String application;
|
||||||
|
|
||||||
@ExceptionHandler(Exception.class)
|
@ExceptionHandler(Exception.class)
|
||||||
public Result bizExceptionHandler(Exception e, HttpServletRequest request) {
|
public Result bizExceptionHandler(Exception e, HttpServletRequest request) {
|
||||||
log.error("发生业务异常!原因是: {}", e.getMessage());
|
log.error("系统发生异常!应用: {}, 请求路径: {}, 异常类型: {}, 异常原因: {}",
|
||||||
log.error(application +"发生了异常 ,异常信息 ,{}",e);
|
application, request.getRequestURI(), e.getClass().getSimpleName(), e.getMessage(), e);
|
||||||
return Result.fail(Code.FAIL);
|
return Result.fail(Code.FAIL);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ExceptionHandler(BusinessException.class)
|
@ExceptionHandler(BusinessException.class)
|
||||||
public Result bizExceptionHandler(BusinessException e, HttpServletRequest request) {
|
public Result bizExceptionHandler(BusinessException e, HttpServletRequest request) {
|
||||||
log.error("发生业务异常!原因是: {}", e.getMessage());
|
log.error("业务异常!应用: {}, 请求路径: {}, 异常原因: {}",
|
||||||
log.error(application +"发生了异常 ,异常信息 ,{}",e);
|
application, request.getRequestURI(), e.getMessage());
|
||||||
if(e.code==null){
|
if(e.code==null){
|
||||||
return Result.fail(e.value);
|
return Result.fail(e.value);
|
||||||
}else{
|
}else{
|
||||||
return Result.fail(e.code);
|
return Result.fail(e.code);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,9 +17,6 @@ public class WebMvcConfig implements WebMvcConfigurer {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void addResourceHandlers(ResourceHandlerRegistry registry) {
|
public void addResourceHandlers(ResourceHandlerRegistry registry) {
|
||||||
for (int i =0;i<200;i++){
|
|
||||||
log.info("win");
|
|
||||||
}
|
|
||||||
String os = System.getProperty("os.name");
|
String os = System.getProperty("os.name");
|
||||||
if (os.toLowerCase().startsWith("win")) { //如果是Windows系统
|
if (os.toLowerCase().startsWith("win")) { //如果是Windows系统
|
||||||
log.info("win");
|
log.info("win");
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ import com.alibaba.excel.write.style.column.LongestMatchColumnWidthStyleStrategy
|
|||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
|
import com.sa.zentao.constants.ExportConstants;
|
||||||
import com.sa.zentao.dao.*;
|
import com.sa.zentao.dao.*;
|
||||||
import com.sa.zentao.entity.ZtProject;
|
import com.sa.zentao.entity.ZtProject;
|
||||||
import com.sa.zentao.entity.ZtProjectproduct;
|
import com.sa.zentao.entity.ZtProjectproduct;
|
||||||
@@ -71,7 +72,7 @@ public class ZtStoryController {
|
|||||||
|
|
||||||
@RequestMapping(value = "/storyExport", method = RequestMethod.POST)
|
@RequestMapping(value = "/storyExport", method = RequestMethod.POST)
|
||||||
public void storyExport(@RequestBody ZtProjectQo qo, jakarta.servlet.ServletResponse response){
|
public void storyExport(@RequestBody ZtProjectQo qo, jakarta.servlet.ServletResponse response){
|
||||||
qo.setPageSize(1000000);
|
qo.setPageSize(ExportConstants.MAX_EXPORT_SIZE);
|
||||||
PageInfo<ZtStoryDTO> p = ztStoryService.pageList(qo);
|
PageInfo<ZtStoryDTO> p = ztStoryService.pageList(qo);
|
||||||
List<ZtStoryDTO> list = p.getList();
|
List<ZtStoryDTO> list = p.getList();
|
||||||
List<Integer> feedbackIds = list.stream().filter(o -> o.getFeedback() != null && o.getFeedback() != 0).map(o -> o.getFeedback()).collect(Collectors.toList());
|
List<Integer> feedbackIds = list.stream().filter(o -> o.getFeedback() != null && o.getFeedback() != 0).map(o -> o.getFeedback()).collect(Collectors.toList());
|
||||||
@@ -82,12 +83,12 @@ public class ZtStoryController {
|
|||||||
|
|
||||||
ZtStoryFeedback ztStoryFeedback = feedbackMap.get(ztStoryUserDTO.getFeedback());
|
ZtStoryFeedback ztStoryFeedback = feedbackMap.get(ztStoryUserDTO.getFeedback());
|
||||||
if (ztStoryFeedback != null) {
|
if (ztStoryFeedback != null) {
|
||||||
String reName=ztStoryFeedback.getId()+":"+ztStoryFeedback.getSpec();
|
String reName=ztStoryFeedback.getId()+ExportConstants.STRING_SEPARATOR+ztStoryFeedback.getSpec();
|
||||||
String reUrl = url+"/#/product-feedback-info/"+ztStoryFeedback.getId();
|
String reUrl = url+"/#/product-feedback-info/"+ztStoryFeedback.getId();
|
||||||
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
||||||
HyperlinkData hyperlinkData = new HyperlinkData();
|
HyperlinkData hyperlinkData = new HyperlinkData();
|
||||||
try {
|
try {
|
||||||
hyperlinkData.setAddress(reUrl.replace(" ", "%20"));
|
hyperlinkData.setAddress(reUrl.replace(" ", ExportConstants.URL_SPACE_ENCODE));
|
||||||
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
||||||
hyperlink.setHyperlinkData(hyperlinkData);
|
hyperlink.setHyperlinkData(hyperlinkData);
|
||||||
ztStoryUserDTO.setFeedbackSpecUrl(hyperlink );
|
ztStoryUserDTO.setFeedbackSpecUrl(hyperlink );
|
||||||
@@ -96,12 +97,12 @@ public class ZtStoryController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(ztStoryUserDTO.getParent()!=null&&ztStoryUserDTO.getParent()!=0){
|
if(ztStoryUserDTO.getParent()!=null&&ztStoryUserDTO.getParent()!=0){
|
||||||
String reName = ztStoryUserDTO.getParent()+":"+ztStoryUserDTO.getParentName();
|
String reName = ztStoryUserDTO.getParent()+ExportConstants.STRING_SEPARATOR+ztStoryUserDTO.getParentName();
|
||||||
String reUrl = url+"/#/product-story-info/"+ztStoryUserDTO.getParent();
|
String reUrl = url+"/#/product-story-info/"+ztStoryUserDTO.getParent();
|
||||||
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
||||||
HyperlinkData hyperlinkData = new HyperlinkData();
|
HyperlinkData hyperlinkData = new HyperlinkData();
|
||||||
try {
|
try {
|
||||||
hyperlinkData.setAddress(reUrl.replace(" ", "%20"));
|
hyperlinkData.setAddress(reUrl.replace(" ", ExportConstants.URL_SPACE_ENCODE));
|
||||||
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
||||||
hyperlink.setHyperlinkData(hyperlinkData);
|
hyperlink.setHyperlinkData(hyperlinkData);
|
||||||
ztStoryUserDTO.setParentNameUrl(hyperlink);
|
ztStoryUserDTO.setParentNameUrl(hyperlink);
|
||||||
@@ -110,12 +111,12 @@ public class ZtStoryController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(ztStoryUserDTO.getUserStory()!=null&&ztStoryUserDTO.getUserStory()!=0){
|
if(ztStoryUserDTO.getUserStory()!=null&&ztStoryUserDTO.getUserStory()!=0){
|
||||||
String reName=ztStoryUserDTO.getUserStory()+":"+ztStoryUserDTO.getUserStoryName();
|
String reName=ztStoryUserDTO.getUserStory()+ExportConstants.STRING_SEPARATOR+ztStoryUserDTO.getUserStoryName();
|
||||||
String reUrl = url+"/#/product-user-story-info/"+ztStoryUserDTO.getUserStory();
|
String reUrl = url+"/#/product-user-story-info/"+ztStoryUserDTO.getUserStory();
|
||||||
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
||||||
HyperlinkData hyperlinkData = new HyperlinkData();
|
HyperlinkData hyperlinkData = new HyperlinkData();
|
||||||
try {
|
try {
|
||||||
hyperlinkData.setAddress(reUrl.replace(" ", "%20"));
|
hyperlinkData.setAddress(reUrl.replace(" ", ExportConstants.URL_SPACE_ENCODE));
|
||||||
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
||||||
hyperlink.setHyperlinkData(hyperlinkData);
|
hyperlink.setHyperlinkData(hyperlinkData);
|
||||||
ztStoryUserDTO.setUserStoryNameUrl(hyperlink);
|
ztStoryUserDTO.setUserStoryNameUrl(hyperlink);
|
||||||
@@ -123,12 +124,12 @@ public class ZtStoryController {
|
|||||||
ztStoryUserDTO.setUserStoryNameUrl(null);
|
ztStoryUserDTO.setUserStoryNameUrl(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
String reName=ztStoryUserDTO.getId()+":"+ztStoryUserDTO.getTitle();
|
String reName=ztStoryUserDTO.getId()+ExportConstants.STRING_SEPARATOR+ztStoryUserDTO.getTitle();
|
||||||
String reUrl = url+"/#/product-story-info/"+ztStoryUserDTO.getId();
|
String reUrl = url+"/#/product-story-info/"+ztStoryUserDTO.getId();
|
||||||
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
WriteCellData<String> hyperlink = new WriteCellData<>(reName);
|
||||||
HyperlinkData hyperlinkData = new HyperlinkData();
|
HyperlinkData hyperlinkData = new HyperlinkData();
|
||||||
try {
|
try {
|
||||||
hyperlinkData.setAddress(reUrl.replace(" ", "%20"));
|
hyperlinkData.setAddress(reUrl.replace(" ", ExportConstants.URL_SPACE_ENCODE));
|
||||||
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
hyperlinkData.setHyperlinkType(HyperlinkData.HyperlinkType.URL);
|
||||||
hyperlink.setHyperlinkData(hyperlinkData);
|
hyperlink.setHyperlinkData(hyperlinkData);
|
||||||
ztStoryUserDTO.setStoryUrl(hyperlink);
|
ztStoryUserDTO.setStoryUrl(hyperlink);
|
||||||
@@ -137,7 +138,7 @@ public class ZtStoryController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(!StringUtils.isEmpty(ztStoryUserDTO.getReviewedbyName())){
|
if(!StringUtils.isEmpty(ztStoryUserDTO.getReviewedbyName())){
|
||||||
ztStoryUserDTO.setReviewedbyName(ztStoryUserDTO.getReviewedbyName().replaceAll(",",""));
|
ztStoryUserDTO.setReviewedbyName(ztStoryUserDTO.getReviewedbyName().replaceAll(ExportConstants.ID_SEPARATOR, ExportConstants.COMMA_REPLACE));
|
||||||
}
|
}
|
||||||
ztStoryUserDTO.setStatus(StoryStatusEnums.transfer(ztStoryUserDTO.getStatus())==null?null:StoryStatusEnums.transfer(ztStoryUserDTO.getStatus()).getDesc());
|
ztStoryUserDTO.setStatus(StoryStatusEnums.transfer(ztStoryUserDTO.getStatus())==null?null:StoryStatusEnums.transfer(ztStoryUserDTO.getStatus()).getDesc());
|
||||||
ztStoryUserDTO.setStage(StoryStageEnums.transfer(ztStoryUserDTO.getStage())==null?null:StoryStageEnums.transfer(ztStoryUserDTO.getStage()).getDesc());
|
ztStoryUserDTO.setStage(StoryStageEnums.transfer(ztStoryUserDTO.getStage())==null?null:StoryStageEnums.transfer(ztStoryUserDTO.getStage()).getDesc());
|
||||||
@@ -145,10 +146,10 @@ public class ZtStoryController {
|
|||||||
ztStoryUserDTO.setYsFlagName(ztStoryUserDTO.getYsFlag()==1?"通过":"不通过");
|
ztStoryUserDTO.setYsFlagName(ztStoryUserDTO.getYsFlag()==1?"通过":"不通过");
|
||||||
}
|
}
|
||||||
if(!StringUtils.isEmpty(ztStoryUserDTO.getUserStoryName())){
|
if(!StringUtils.isEmpty(ztStoryUserDTO.getUserStoryName())){
|
||||||
ztStoryUserDTO.setUserStoryName(ztStoryUserDTO.getUserStoryId()+":"+ztStoryUserDTO.getUserStoryName());
|
ztStoryUserDTO.setUserStoryName(ztStoryUserDTO.getUserStoryId()+ExportConstants.STRING_SEPARATOR+ztStoryUserDTO.getUserStoryName());
|
||||||
}
|
}
|
||||||
if(ztStoryUserDTO.getParent()!=null&&ztStoryUserDTO.getParent()!=0){
|
if(ztStoryUserDTO.getParent()!=null&&ztStoryUserDTO.getParent()!=0){
|
||||||
ztStoryUserDTO.setParentName(ztStoryUserDTO.getParent()+":"+ztStoryUserDTO.getParentName());
|
ztStoryUserDTO.setParentName(ztStoryUserDTO.getParent()+ExportConstants.STRING_SEPARATOR+ztStoryUserDTO.getParentName());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -159,7 +160,7 @@ public class ZtStoryController {
|
|||||||
.registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
|
.registerWriteHandler(new LongestMatchColumnWidthStyleStrategy())
|
||||||
.needHead(Boolean.TRUE).build();
|
.needHead(Boolean.TRUE).build();
|
||||||
|
|
||||||
WriteSheet writeSheet = EasyExcel.writerSheet(0, "sheet1")
|
WriteSheet writeSheet = EasyExcel.writerSheet(0, ExportConstants.SHEET_NAME)
|
||||||
.head(ZtStoryDTO.class)
|
.head(ZtStoryDTO.class)
|
||||||
.needHead(Boolean.TRUE).build();
|
.needHead(Boolean.TRUE).build();
|
||||||
|
|
||||||
|
|||||||
@@ -140,7 +140,7 @@ public class ZtStoryUserController {
|
|||||||
eq.in(ZtStoryUser::getStatus, UserStoryEnums.JH.getCode(),UserStoryEnums.CFM.getCode(),UserStoryEnums.KFZ.getCode());
|
eq.in(ZtStoryUser::getStatus, UserStoryEnums.JH.getCode(),UserStoryEnums.CFM.getCode(),UserStoryEnums.KFZ.getCode());
|
||||||
}
|
}
|
||||||
eq.select(ZtStoryUser::getId,ZtStoryUser::getTitle,ZtStoryUser::getProduct,
|
eq.select(ZtStoryUser::getId,ZtStoryUser::getTitle,ZtStoryUser::getProduct,
|
||||||
ZtStoryUser::getOpenedby,ZtStoryUser::getAssignedto,ZtStoryUser::getYsUser
|
ZtStoryUser::getOpenedby,ZtStoryUser::getAssignedto,ZtStoryUser::getYsUser,ZtStoryUser::getProductUser
|
||||||
);
|
);
|
||||||
List<ZtStoryUser> list = storyUserService.list(eq
|
List<ZtStoryUser> list = storyUserService.list(eq
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -3,15 +3,33 @@ package com.sa.zentao.dao;
|
|||||||
|
|
||||||
public class BusinessException extends RuntimeException {
|
public class BusinessException extends RuntimeException {
|
||||||
|
|
||||||
|
|
||||||
public BusinessException(Code code){
|
public BusinessException(Code code){
|
||||||
super(code.getValue());
|
super(code.getValue());
|
||||||
this.code=code;
|
this.code=code;
|
||||||
}
|
}
|
||||||
|
|
||||||
public BusinessException(String value){
|
public BusinessException(String value){
|
||||||
super(value);
|
super(value);
|
||||||
this.value=value;
|
this.value=value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public BusinessException(Code code, String message){
|
||||||
|
super(message);
|
||||||
|
this.code=code;
|
||||||
|
this.value=message;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BusinessException(String value, Throwable cause){
|
||||||
|
super(value, cause);
|
||||||
|
this.value=value;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BusinessException(Code code, String message, Throwable cause){
|
||||||
|
super(message, cause);
|
||||||
|
this.code=code;
|
||||||
|
this.value=message;
|
||||||
|
}
|
||||||
|
|
||||||
public String value;
|
public String value;
|
||||||
public Code code;
|
public Code code;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,11 @@ public enum Code {
|
|||||||
SUCCESS(0, "成功"),
|
SUCCESS(0, "成功"),
|
||||||
FAIL(-1, "失败"),
|
FAIL(-1, "失败"),
|
||||||
CFTJ(-2, "重复添加"),
|
CFTJ(-2, "重复添加"),
|
||||||
PLEASELOGIN(401, "请登录");
|
PLEASELOGIN(401, "请登录"),
|
||||||
|
PARAM_ERROR(400, "参数错误"),
|
||||||
|
NOT_FOUND(404, "资源不存在"),
|
||||||
|
FORBIDDEN(403, "无权限访问"),
|
||||||
|
INTERNAL_ERROR(500, "系统内部错误");
|
||||||
|
|
||||||
private Integer code;
|
private Integer code;
|
||||||
private String value;
|
private String value;
|
||||||
|
|||||||
@@ -63,6 +63,8 @@ public class ZtProjectQo extends BaseQo {
|
|||||||
|
|
||||||
private String status;
|
private String status;
|
||||||
|
|
||||||
|
private List<String> statusList;
|
||||||
|
|
||||||
private List<String> stageList;
|
private List<String> stageList;
|
||||||
|
|
||||||
private String title;
|
private String title;
|
||||||
|
|||||||
@@ -7,7 +7,9 @@ import com.sa.zentao.entity.*;
|
|||||||
import com.sa.zentao.enums.ActionStatus;
|
import com.sa.zentao.enums.ActionStatus;
|
||||||
import com.sa.zentao.enums.ActionType;
|
import com.sa.zentao.enums.ActionType;
|
||||||
import com.sa.zentao.enums.KanbanCellType;
|
import com.sa.zentao.enums.KanbanCellType;
|
||||||
|
import com.sa.zentao.enums.KanbanColumnType;
|
||||||
import com.sa.zentao.enums.ProjectTypeEnums;
|
import com.sa.zentao.enums.ProjectTypeEnums;
|
||||||
|
import com.sa.zentao.utils.KanbanStageMapping;
|
||||||
import com.sa.zentao.mapper.ZtKanbancolumnMapper;
|
import com.sa.zentao.mapper.ZtKanbancolumnMapper;
|
||||||
import com.sa.zentao.mapper.ZtKanbanlaneMapper;
|
import com.sa.zentao.mapper.ZtKanbanlaneMapper;
|
||||||
import com.sa.zentao.qo.KanbanQo;
|
import com.sa.zentao.qo.KanbanQo;
|
||||||
@@ -255,14 +257,14 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
this.kanbancellService.updateById(tokanbancell);
|
this.kanbancellService.updateById(tokanbancell);
|
||||||
|
|
||||||
ActionType type= null;
|
ActionType type= null;
|
||||||
if("story".equalsIgnoreCase(tabType)){
|
if(KanbanCellType.STORY.getValue().equalsIgnoreCase(tabType)){
|
||||||
type=ActionType.XQ;
|
type=ActionType.XQ;
|
||||||
//需求
|
//需求
|
||||||
// storyChange(qo);
|
// storyChange(qo);
|
||||||
|
|
||||||
//testing 测试中
|
//testing 测试中
|
||||||
}
|
}
|
||||||
if("bug".equalsIgnoreCase(tabType)){
|
if(KanbanCellType.BUG.getValue().equalsIgnoreCase(tabType)){
|
||||||
type=ActionType.BUG;
|
type=ActionType.BUG;
|
||||||
//bug
|
//bug
|
||||||
// bugChange(qo);
|
// bugChange(qo);
|
||||||
@@ -273,7 +275,7 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
//closed 关闭
|
//closed 关闭
|
||||||
|
|
||||||
}
|
}
|
||||||
if("task".equalsIgnoreCase(tabType)){
|
if(KanbanCellType.TASK.getValue().equalsIgnoreCase(tabType)){
|
||||||
type=ActionType.RW;
|
type=ActionType.RW;
|
||||||
//task
|
//task
|
||||||
// taskChange(qo);
|
// taskChange(qo);
|
||||||
@@ -285,7 +287,7 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
//完成有新任务回退到进行中
|
//完成有新任务回退到进行中
|
||||||
|
|
||||||
//
|
//
|
||||||
// if("canceled".equalsIgnoreCase(statusType)){
|
// if(KanbanColumnType.TASK_CANCEL.getValue().equalsIgnoreCase(statusType)){
|
||||||
// //取消
|
// //取消
|
||||||
// }
|
// }
|
||||||
|
|
||||||
@@ -346,7 +348,7 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
@Override
|
@Override
|
||||||
public void addStory(Integer id, List<ZtStory> ztStories) {
|
public void addStory(Integer id, List<ZtStory> ztStories) {
|
||||||
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
||||||
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, "story"));
|
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, KanbanCellType.STORY.getValue()));
|
||||||
|
|
||||||
List<ZtKanbancolumnDTO> ztKanbancolumnDTOS = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
List<ZtKanbancolumnDTO> ztKanbancolumnDTOS = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
||||||
|
|
||||||
@@ -399,7 +401,7 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
public void addTask(Integer id, List<ZtTask> asList) {
|
public void addTask(Integer id, List<ZtTask> asList) {
|
||||||
|
|
||||||
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
||||||
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, "task"));
|
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, KanbanCellType.TASK.getValue()));
|
||||||
|
|
||||||
List<ZtKanbancolumnDTO> kanbancolumnList = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
List<ZtKanbancolumnDTO> kanbancolumnList = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
||||||
|
|
||||||
@@ -425,11 +427,13 @@ public class ZtKanbanlaneServiceImpl extends ServiceImpl<ZtKanbanlaneMapper, ZtK
|
|||||||
@Override
|
@Override
|
||||||
public void addBug(Integer id, List<ZtBug> asList) {
|
public void addBug(Integer id, List<ZtBug> asList) {
|
||||||
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
ZtKanbanlane lane = this.baseMapper.selectOne(new QueryWrapper<ZtKanbanlane>().lambda()
|
||||||
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, "bug"));
|
.eq(ZtKanbanlane::getExecution, id).eq(ZtKanbanlane::getType, KanbanCellType.BUG.getValue()));
|
||||||
|
|
||||||
List<ZtKanbancolumnDTO> ztKanbancolumnDTOS = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
List<ZtKanbancolumnDTO> ztKanbancolumnDTOS = this.kanbancolumnMapper.listByLaneIds(Arrays.asList(lane.getId()));
|
||||||
|
|
||||||
List<ZtKanbancolumnDTO> backlog = ztKanbancolumnDTOS.stream().filter(o -> o.getType().equals("unconfirmed")).collect(Collectors.toList());
|
List<ZtKanbancolumnDTO> backlog = ztKanbancolumnDTOS.stream()
|
||||||
|
.filter(o -> o.getType().equals(KanbanColumnType.BUG_UNCONFIRMED.getValue()))
|
||||||
|
.collect(Collectors.toList());
|
||||||
ZtKanbancolumnDTO ztKanbancolumnDTO = backlog.get(0);
|
ZtKanbancolumnDTO ztKanbancolumnDTO = backlog.get(0);
|
||||||
|
|
||||||
ZtKanbancell kanbancell = this.kanbancellService.getOne(new QueryWrapper<ZtKanbancell>().lambda()
|
ZtKanbancell kanbancell = this.kanbancellService.getOne(new QueryWrapper<ZtKanbancell>().lambda()
|
||||||
|
|||||||
@@ -313,8 +313,11 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
|||||||
public void projectClose(ZtProjectDTO dto) {
|
public void projectClose(ZtProjectDTO dto) {
|
||||||
|
|
||||||
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
||||||
if (ztProject == null || "closed".equalsIgnoreCase(ztProject.getStatus())) {
|
if (ztProject == null) {
|
||||||
throw new BusinessException("未查询到");
|
throw new BusinessException("未查询到项目,项目ID: " + dto.getId());
|
||||||
|
}
|
||||||
|
if ("closed".equalsIgnoreCase(ztProject.getStatus())) {
|
||||||
|
throw new BusinessException("项目已关闭,无法重复关闭,项目ID: " + dto.getId());
|
||||||
}
|
}
|
||||||
ztProject.setRealEnd(dto.getClosedDate());
|
ztProject.setRealEnd(dto.getClosedDate());
|
||||||
ztProject.setLastEditedDate(new Date());
|
ztProject.setLastEditedDate(new Date());
|
||||||
@@ -350,6 +353,7 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@Transactional
|
||||||
public void projectStart(ZtProjectDTO dto) {
|
public void projectStart(ZtProjectDTO dto) {
|
||||||
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
||||||
if (ztProject == null || !"wait".equalsIgnoreCase(ztProject.getStatus())) {
|
if (ztProject == null || !"wait".equalsIgnoreCase(ztProject.getStatus())) {
|
||||||
@@ -385,8 +389,11 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
|||||||
@Override
|
@Override
|
||||||
public void projectDeleted(ZtProjectDTO dto) {
|
public void projectDeleted(ZtProjectDTO dto) {
|
||||||
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
||||||
if (ztProject == null || "1".equalsIgnoreCase(ztProject.getDeleted())) {
|
if (ztProject == null) {
|
||||||
throw new BusinessException("未查询到");
|
throw new BusinessException("未查询到项目,项目ID: " + dto.getId());
|
||||||
|
}
|
||||||
|
if ("1".equalsIgnoreCase(ztProject.getDeleted())) {
|
||||||
|
throw new BusinessException("项目已删除,无法重复删除,项目ID: " + dto.getId());
|
||||||
}
|
}
|
||||||
ztProject.setDeleted("1");
|
ztProject.setDeleted("1");
|
||||||
ztProject.setCanceledBy(RiskUserThreadLocal.get().getName());
|
ztProject.setCanceledBy(RiskUserThreadLocal.get().getName());
|
||||||
@@ -421,8 +428,11 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
|||||||
@Override
|
@Override
|
||||||
public void projectActivated(ZtProjectDTO dto) {
|
public void projectActivated(ZtProjectDTO dto) {
|
||||||
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
||||||
if (ztProject == null || !"closed".equalsIgnoreCase(ztProject.getStatus())) {
|
if (ztProject == null) {
|
||||||
throw new BusinessException("未查询到");
|
throw new BusinessException("未查询到项目,项目ID: " + dto.getId());
|
||||||
|
}
|
||||||
|
if (!"closed".equalsIgnoreCase(ztProject.getStatus())) {
|
||||||
|
throw new BusinessException("项目未关闭,无法激活,当前状态: " + ztProject.getStatus() + ",项目ID: " + dto.getId());
|
||||||
}
|
}
|
||||||
LambdaUpdateWrapper<ZtProject> updateWrapper = new UpdateWrapper<ZtProject>().lambda().set(ZtProject::getStatus, "doing")
|
LambdaUpdateWrapper<ZtProject> updateWrapper = new UpdateWrapper<ZtProject>().lambda().set(ZtProject::getStatus, "doing")
|
||||||
.set(ZtProject::getRealEnd,null)
|
.set(ZtProject::getRealEnd,null)
|
||||||
@@ -457,8 +467,11 @@ public class ZtProjectServiceImpl extends ServiceImpl<ZtProjectMapper, ZtProject
|
|||||||
@Override
|
@Override
|
||||||
public void projectSuspended(ZtProjectDTO dto) {
|
public void projectSuspended(ZtProjectDTO dto) {
|
||||||
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
ZtProject ztProject = this.baseMapper.selectById(dto.getId());
|
||||||
if (ztProject == null || !"wait".equalsIgnoreCase(ztProject.getStatus())) {
|
if (ztProject == null) {
|
||||||
throw new BusinessException("未查询到");
|
throw new BusinessException("未查询到项目,项目ID: " + dto.getId());
|
||||||
|
}
|
||||||
|
if (!"wait".equalsIgnoreCase(ztProject.getStatus())) {
|
||||||
|
throw new BusinessException("项目状态不是等待状态,无法挂起,当前状态: " + ztProject.getStatus() + ",项目ID: " + dto.getId());
|
||||||
}
|
}
|
||||||
ztProject.setStatus("suspended");
|
ztProject.setStatus("suspended");
|
||||||
ztProject.setLastEditedBy(RiskUserThreadLocal.get().getName());
|
ztProject.setLastEditedBy(RiskUserThreadLocal.get().getName());
|
||||||
|
|||||||
@@ -368,9 +368,9 @@ public class ZtReleaseServiceImpl extends ServiceImpl<ZtReleaseMapper, ZtRelease
|
|||||||
List<ZtStory> ztStories = CollectionUtils.isEmpty(storyList)?new ArrayList<>():storyService.listByIds(storyList);
|
List<ZtStory> ztStories = CollectionUtils.isEmpty(storyList)?new ArrayList<>():storyService.listByIds(storyList);
|
||||||
|
|
||||||
List<ZtBug> bugs =CollectionUtils.isEmpty(bugList)?new ArrayList<>(): bugService.listByIds(bugList);
|
List<ZtBug> bugs =CollectionUtils.isEmpty(bugList)?new ArrayList<>(): bugService.listByIds(bugList);
|
||||||
long notTested = ztStories.stream().filter(o -> !o.getStage().equals(StoryStageEnums.productVerified.getValue())).count();
|
List<ZtStory> notProductYsList = ztStories.stream().filter(o -> !o.getStage().equals(StoryStageEnums.productVerified.getValue())).toList();
|
||||||
if(notTested>0){
|
if(!CollectionUtils.isEmpty(notProductYsList)){
|
||||||
throw new BusinessException("当前需求存在未测试完成的请检查");
|
throw new BusinessException("当前需求存在未产品验收的需求请检查 id="+notProductYsList.get(0).getId()+" name="+notProductYsList.get(0).getTitle());
|
||||||
}
|
}
|
||||||
//'active','resolved','closed'?
|
//'active','resolved','closed'?
|
||||||
long count = bugs.stream().filter(o -> !Arrays.asList("resolved","closed").contains(o.getStatus())).count();
|
long count = bugs.stream().filter(o -> !Arrays.asList("resolved","closed").contains(o.getStatus())).count();
|
||||||
@@ -391,8 +391,6 @@ public class ZtReleaseServiceImpl extends ServiceImpl<ZtReleaseMapper, ZtRelease
|
|||||||
}
|
}
|
||||||
if(!CollectionUtils.isEmpty(ztStories)){
|
if(!CollectionUtils.isEmpty(ztStories)){
|
||||||
sendReleaseMail(ztStories);
|
sendReleaseMail(ztStories);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
actionService.addAction(ActionType.FB, ActionStatus.FBSB, ztRelease.getId(), ztRelease.getProduct() + "", ztRelease.getProject(), null,
|
actionService.addAction(ActionType.FB, ActionStatus.FBSB, ztRelease.getId(), ztRelease.getProduct() + "", ztRelease.getProject(), null,
|
||||||
|
|||||||
@@ -980,16 +980,16 @@ public class ZtStoryServiceImpl extends ServiceImpl<ZtStoryMapper, ZtStory> impl
|
|||||||
public void testSubmitVerified(ZtStoryDTO qo) {
|
public void testSubmitVerified(ZtStoryDTO qo) {
|
||||||
ZtStory ztStory = this.baseMapper.selectById(qo.getId());
|
ZtStory ztStory = this.baseMapper.selectById(qo.getId());
|
||||||
if(ztStory==null){
|
if(ztStory==null){
|
||||||
throw new BusinessException("未查询到需求");
|
throw new BusinessException("未查询到需求,需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
if(!StoryStatusEnums.active.getValue().equals(ztStory.getStatus())){
|
if(!StoryStatusEnums.active.getValue().equals(ztStory.getStatus())){
|
||||||
throw new BusinessException("需求状态不对");
|
throw new BusinessException("需求状态不是激活状态,无法提交验收,当前状态: " + ztStory.getStatus() + ",需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
if(!StoryStageEnums.tested.getValue().equals(ztStory.getStage())){
|
if(!StoryStageEnums.tested.getValue().equals(ztStory.getStage())){
|
||||||
throw new BusinessException("需求状态不对");
|
throw new BusinessException("需求阶段不是测试完毕,无法提交验收,当前阶段: " + ztStory.getStage() + ",需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
if(!ObjectUtil.equal(ztStory.getInnerYsFlag(),1)){
|
if(!ObjectUtil.equal(ztStory.getInnerYsFlag(),1)){
|
||||||
throw new BusinessException("无需内部验收,不需要提交");
|
throw new BusinessException("无需内部验收,不需要提交,需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
//产品验收中
|
//产品验收中
|
||||||
ztStory.setStage(StoryStageEnums.productWaitVerified.getValue());
|
ztStory.setStage(StoryStageEnums.productWaitVerified.getValue());
|
||||||
@@ -1014,16 +1014,16 @@ public class ZtStoryServiceImpl extends ServiceImpl<ZtStoryMapper, ZtStory> impl
|
|||||||
public void storyProductUserYs(ZtStoryDTO qo) {
|
public void storyProductUserYs(ZtStoryDTO qo) {
|
||||||
ZtStory ztStory = this.baseMapper.selectById(qo.getId());
|
ZtStory ztStory = this.baseMapper.selectById(qo.getId());
|
||||||
if(ztStory==null){
|
if(ztStory==null){
|
||||||
throw new BusinessException("未查询到需求");
|
throw new BusinessException("未查询到需求,需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
if(!StoryStatusEnums.active.getValue().equals(ztStory.getStatus())){
|
if(!StoryStatusEnums.active.getValue().equals(ztStory.getStatus())){
|
||||||
throw new BusinessException("需求状态不对");
|
throw new BusinessException("需求状态不是激活状态,无法验收,当前状态: " + ztStory.getStatus() + ",需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
if(!StoryStageEnums.productWaitVerified.getValue().equals(ztStory.getStage())){
|
if(!StoryStageEnums.productWaitVerified.getValue().equals(ztStory.getStage())){
|
||||||
throw new BusinessException("需求状态不对");
|
throw new BusinessException("需求阶段不是待验收状态,无法验收,当前阶段: " + ztStory.getStage() + ",需求ID: " + qo.getId());
|
||||||
}
|
}
|
||||||
//产品验收中
|
//产品验收中
|
||||||
ztStory.setStage(StoryStageEnums.productWaitVerified.getValue());
|
ztStory.setStage(StoryStageEnums.productVerified.getValue());
|
||||||
ztStory.setLasteditedby(RiskUserThreadLocal.get().getName());
|
ztStory.setLasteditedby(RiskUserThreadLocal.get().getName());
|
||||||
ztStory.setLastediteddate(new Date());
|
ztStory.setLastediteddate(new Date());
|
||||||
ztStory.setInnerYsTime(new Date());
|
ztStory.setInnerYsTime(new Date());
|
||||||
@@ -1490,16 +1490,10 @@ public class ZtStoryServiceImpl extends ServiceImpl<ZtStoryMapper, ZtStory> impl
|
|||||||
@Override
|
@Override
|
||||||
public void taskFinishChangeStatus(Integer story, String finishBy, TaskType type, Boolean cancelFlag) {
|
public void taskFinishChangeStatus(Integer story, String finishBy, TaskType type, Boolean cancelFlag) {
|
||||||
ZtStory ztStory = this.getById(story);
|
ZtStory ztStory = this.getById(story);
|
||||||
if(ztStory == null) {
|
if(ztStory == null|| story == 0) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (ztStory != null && ztStory.getStatus().equals("closed")) {
|
if (ztStory.getStatus().equals("closed")) {
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (type != TaskType.test && type != TaskType.devel) {
|
|
||||||
// return;
|
|
||||||
}
|
|
||||||
if (story == null || story == 0) {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (cancelFlag && type == TaskType.devel) {
|
if (cancelFlag && type == TaskType.devel) {
|
||||||
|
|||||||
@@ -158,7 +158,13 @@
|
|||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal == 'WGB' ">
|
<if test="qo.searchVal == 'WGB' ">
|
||||||
and s.status != 'closed'
|
and s.status != 'closed'
|
||||||
|
</if>
|
||||||
|
<if test="qo.searchVal != null and qo.searchVal == 'WDCP' ">
|
||||||
|
and s.product_user = #{qo.userName}
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="qo.searchVal != null and qo.searchVal == 'WCS' ">
|
||||||
|
and s.test_user = #{qo.userName}
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
||||||
and s.assignedTo= #{qo.userName}
|
and s.assignedTo= #{qo.userName}
|
||||||
@@ -280,9 +286,14 @@
|
|||||||
open="(" close=")" separator=",">
|
open="(" close=")" separator=",">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
|
||||||
</if>
|
</if>
|
||||||
|
<if test="qo.statusList != null and qo.statusList.size() > 0">
|
||||||
|
and s.status in
|
||||||
|
<foreach collection="qo.statusList" item="id" index="index"
|
||||||
|
open="(" close=")" separator=",">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
group by s.id
|
group by s.id
|
||||||
|
|
||||||
|
|
||||||
@@ -382,38 +393,12 @@
|
|||||||
pt.name productName
|
pt.name productName
|
||||||
from zt_story s
|
from zt_story s
|
||||||
|
|
||||||
left join zt_storyreview v on s.id = v.story and s.version = v.version
|
left join zt_storyreview v on s.id = v.story and s.version = v.version
|
||||||
left join zt_projectstory pstory on s.id = pstory.story and pstory.`type` = 'project'
|
left join zt_projectstory pstory on s.id = pstory.story and pstory.`type` = 'project'
|
||||||
left join zt_project pj on pstory.project = pj.id
|
left join zt_project pj on pstory.project = pj.id
|
||||||
left join zt_product pt on s.product = pt.id
|
left join zt_product pt on s.product = pt.id
|
||||||
left join zt_projectstory ps on s.id = ps.story
|
left join zt_projectstory ps on s.id = ps.story
|
||||||
WHERE 1=1
|
WHERE 1=1
|
||||||
|
|
||||||
|
|
||||||
<!-- <if test="qo.startDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[>=]]> #{qo.startDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<!-- <if test="qo.endDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[<=]]> #{qo.endDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<!-- <if test="qo.startDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[>=]]> #{qo.startDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<!-- <if test="qo.endDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[<=]]> #{qo.endDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<if test="qo.testUser != null and qo.testUser != '' ">
|
|
||||||
and s.test_user like concat('%', #{qo.testUser}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="qo.productUser != null and qo.productUser != '' ">
|
|
||||||
and s.product_user like concat('%', #{qo.productUser}, '%')
|
|
||||||
</if>
|
|
||||||
<!-- <if test="qo.startDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[>=]]> #{qo.startDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<!-- <if test="qo.endDate !=null">-->
|
|
||||||
<!-- and s.openedDate <![CDATA[<=]]> #{qo.endDate}-->
|
|
||||||
<!-- </if>-->
|
|
||||||
<if test="qo.pri != null and qo.pri != '' ">
|
<if test="qo.pri != null and qo.pri != '' ">
|
||||||
and s.pri = #{qo.pri}
|
and s.pri = #{qo.pri}
|
||||||
</if>
|
</if>
|
||||||
@@ -425,7 +410,7 @@
|
|||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'WYS' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WYS' ">
|
||||||
and s.ys_user = #{qo.userName}
|
and s.ys_user = #{qo.userName}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.stage != null and qo.stage != '' ">
|
<if test="qo.stage != null and qo.stage != '' ">
|
||||||
@@ -450,47 +435,48 @@
|
|||||||
<if test="qo.name != null and qo.name != '' ">
|
<if test="qo.name != null and qo.name != '' ">
|
||||||
and s.title like concat('%', #{qo.name}, '%')
|
and s.title like concat('%', #{qo.name}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
<if test="qo.testUser != null and qo.testUser != '' ">
|
||||||
|
and s.test_user like concat('%', #{qo.testUser}, '%')
|
||||||
|
</if>
|
||||||
<if test="qo.productUser != null and qo.productUser != '' ">
|
<if test="qo.productUser != null and qo.productUser != '' ">
|
||||||
and s.product_user like concat('%', #{qo.productUser}, '%')
|
and s.product_user like concat('%', #{qo.productUser}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.testUser != null and qo.testUser != '' ">
|
|
||||||
and s.assignedTo like concat('%', #{qo.testUser}, '%')
|
|
||||||
</if>
|
|
||||||
<if test="qo.productName != null and qo.productName != '' ">
|
<if test="qo.productName != null and qo.productName != '' ">
|
||||||
and pt.name like concat('%', #{qo.productName}, '%')
|
and pt.name like concat('%', #{qo.productName}, '%')
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.project != null ">
|
<if test="qo.project != null ">
|
||||||
and ps.project =#{qo.project}
|
and ps.project =#{qo.project}
|
||||||
and ps.type= 'project'
|
and ps.type= 'project'
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.execution != null ">
|
<if test="qo.execution != null ">
|
||||||
and ps.project =#{qo.execution}
|
and ps.project =#{qo.execution}
|
||||||
and ps.type= 'execution'
|
and ps.type= 'execution'
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.moduleId != null ">
|
<if test="qo.moduleId != null ">
|
||||||
and s.module =#{qo.moduleId}
|
and s.module =#{qo.moduleId}
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'ALL' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'ALL' ">
|
||||||
|
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
|
||||||
and s.status !='closed'
|
and s.status !='closed'
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
||||||
and s.assignedTo = #{qo.userName}
|
and s.assignedTo = #{qo.userName}
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="qo.kfz == 1 ">
|
||||||
|
<if test="qo.userName != null and qo.userName != '' ">
|
||||||
|
|
||||||
|
and
|
||||||
|
(s.assignedTo = #{qo.userName}
|
||||||
|
or s.openedBy = #{qo.userName}
|
||||||
|
)
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.kfz == 1 ">
|
</if>
|
||||||
<if test="qo.userName != null and qo.userName != '' ">
|
|
||||||
|
|
||||||
and
|
|
||||||
(s.assignedTo = #{qo.userName}
|
|
||||||
or s.openedBy = #{qo.userName}
|
|
||||||
)
|
|
||||||
</if>
|
|
||||||
|
|
||||||
</if>
|
|
||||||
|
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WCJ' ">
|
||||||
and s.openedBy = #{qo.userName}
|
and s.openedBy = #{qo.userName}
|
||||||
@@ -503,6 +489,9 @@
|
|||||||
<if test="qo.searchVal != null and qo.searchVal == 'WDCP' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WDCP' ">
|
||||||
and s.product_user = #{qo.userName}
|
and s.product_user = #{qo.userName}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="qo.searchVal != null and qo.searchVal == 'WCS' ">
|
||||||
|
and s.test_user = #{qo.userName}
|
||||||
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'WCC' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WCC' ">
|
||||||
and s.assignedTo = #{qo.userName}
|
and s.assignedTo = #{qo.userName}
|
||||||
</if>
|
</if>
|
||||||
@@ -522,7 +511,7 @@
|
|||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchVal == 'WZP' ">
|
<if test="qo.searchVal == 'WZP' ">
|
||||||
and s.status = '11'
|
and s.status = '11'
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchVal == 'WPS' ">
|
<if test="qo.searchVal == 'WPS' ">
|
||||||
@@ -533,10 +522,12 @@
|
|||||||
<if test="qo.searchVal == 'PSZ' ">
|
<if test="qo.searchVal == 'PSZ' ">
|
||||||
and s.status = 'reviewing'
|
and s.status = 'reviewing'
|
||||||
</if>
|
</if>
|
||||||
|
<if test="qo.searchVal == 'WYS' ">
|
||||||
|
and s.ys_user = #{qo.userName}
|
||||||
|
</if>
|
||||||
<if test="qo.searchVal == 'DYS' ">
|
<if test="qo.searchVal == 'DYS' ">
|
||||||
|
|
||||||
and ( s.stage = 'released'
|
and ( s.stage = 'released'
|
||||||
and s.ys_flag =0)
|
and s.ys_flag =0)
|
||||||
or (s.stage = 'verified' and s.ys_flag =2)
|
or (s.stage = 'verified' and s.ys_flag =2)
|
||||||
</if>
|
</if>
|
||||||
@@ -548,53 +539,53 @@
|
|||||||
|
|
||||||
<if test="qo.searchCode != null and qo.searchCode != '' ">
|
<if test="qo.searchCode != null and qo.searchCode != '' ">
|
||||||
|
|
||||||
-- //项目名称
|
-- //项目名称
|
||||||
<if test="qo.searchCode=='xmmc' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='xmmc' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and pj.name like concat('%', #{qo.searchValue}, '%')
|
and pj.name like concat('%', #{qo.searchValue}, '%')
|
||||||
</if>
|
</if>
|
||||||
-- 项目id
|
-- 项目id
|
||||||
<if test="qo.searchCode=='xmid' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='xmid' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and pj.id =#{qo.searchValue}
|
and pj.id =#{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
-- //需求名称
|
-- //需求名称
|
||||||
<if test="qo.searchCode=='xqmc' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='xqmc' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.title like concat('%', #{qo.searchValue}, '%')
|
and s.title like concat('%', #{qo.searchValue}, '%')
|
||||||
</if>
|
</if>
|
||||||
-- 需求id
|
-- 需求id
|
||||||
<if test="qo.searchCode=='xqid' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='xqid' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.id =#{qo.searchValue}
|
and s.id =#{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
-- 状态
|
-- 状态
|
||||||
<if test="qo.searchCode=='zt' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='zt' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.stage =#{qo.searchValue}
|
and s.stage =#{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
-- 项目描述
|
-- 项目描述
|
||||||
<if test="qo.searchCode=='xmms' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='xmms' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and sp.`spec` =#{qo.searchValue}
|
and sp.`spec` =#{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
-- 负责人
|
-- 负责人
|
||||||
|
|
||||||
<if test="qo.searchCode=='fzr' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='fzr' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.assignedTo =#{qo.searchValue}
|
and s.assignedTo =#{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchCode=='jhwc' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='jhwc' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.plan_end_date ${qo.searchValue}
|
and s.plan_end_date ${qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchCode=='sjks' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='sjks' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.start_date ${qo.searchValue}
|
and s.start_date ${qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchCode=='sjwc' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='sjwc' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.end_date ${qo.searchValue}
|
and s.end_date ${qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchCode=='yscj' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='yscj' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.openedBy = #{qo.searchValue}
|
and s.openedBy = #{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
<if test="qo.searchCode=='ysgb' and qo.searchValue != null and qo.searchValue != '' ">
|
<if test="qo.searchCode=='ysgb' and qo.searchValue != null and qo.searchValue != '' ">
|
||||||
and s.closedBy = #{qo.searchValue}
|
and s.closedBy = #{qo.searchValue}
|
||||||
</if>
|
</if>
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
@@ -613,7 +604,13 @@
|
|||||||
open="(" close=")" separator=",">
|
open="(" close=")" separator=",">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
</if>
|
||||||
|
<if test="qo.statusList != null and qo.statusList.size() > 0">
|
||||||
|
and s.status in
|
||||||
|
<foreach collection="qo.statusList" item="id" index="index"
|
||||||
|
open="(" close=")" separator=",">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
|
||||||
@@ -623,7 +620,7 @@
|
|||||||
<when test="qo.orderName != '' and qo.orderName != null ">
|
<when test="qo.orderName != '' and qo.orderName != null ">
|
||||||
<choose>
|
<choose>
|
||||||
<when test="qo.orderSort != '' and qo.orderSort != null ">
|
<when test="qo.orderSort != '' and qo.orderSort != null ">
|
||||||
order by s.${qo.orderName} ${qo.orderSort}
|
order by s.${qo.orderName} ${qo.orderSort}
|
||||||
</when>
|
</when>
|
||||||
<otherwise>
|
<otherwise>
|
||||||
order by s.id desc
|
order by s.id desc
|
||||||
@@ -643,7 +640,6 @@
|
|||||||
</select>
|
</select>
|
||||||
<select id="allStoryPageList" resultType="com.sa.zentao.dao.ZtStoryDTO">
|
<select id="allStoryPageList" resultType="com.sa.zentao.dao.ZtStoryDTO">
|
||||||
|
|
||||||
|
|
||||||
select s.id,
|
select s.id,
|
||||||
s.vision,
|
s.vision,
|
||||||
s.parent,
|
s.parent,
|
||||||
@@ -1008,8 +1004,15 @@
|
|||||||
</if>
|
</if>
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'WGB' ">
|
||||||
and s.status !='closed'
|
and s.status !='closed'
|
||||||
|
|
||||||
</if>
|
</if>
|
||||||
|
|
||||||
|
<if test="qo.searchVal != null and qo.searchVal == 'WDCP' ">
|
||||||
|
and s.product_user = #{qo.userName}
|
||||||
|
</if>
|
||||||
|
<if test="qo.searchVal != null and qo.searchVal == 'WCS' ">
|
||||||
|
and s.test_user = #{qo.userName}
|
||||||
|
</if>
|
||||||
|
|
||||||
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
<if test="qo.searchVal != null and qo.searchVal == 'ZGW' ">
|
||||||
and s.assignedTo = #{qo.userName}
|
and s.assignedTo = #{qo.userName}
|
||||||
</if>
|
</if>
|
||||||
@@ -1090,8 +1093,15 @@
|
|||||||
open="(" close=")" separator=",">
|
open="(" close=")" separator=",">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
|
||||||
</if>
|
</if>
|
||||||
|
<if test="qo.statusList != null and qo.statusList.size() > 0">
|
||||||
|
and s.status in
|
||||||
|
<foreach collection="qo.statusList" item="id" index="index"
|
||||||
|
open="(" close=")" separator=",">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
|
|
||||||
group by s.id
|
group by s.id
|
||||||
|
|
||||||
<choose>
|
<choose>
|
||||||
@@ -1351,14 +1361,17 @@
|
|||||||
|
|
||||||
<select id="storyReleaseOnTimeByProducts" resultType="java.util.Map">
|
<select id="storyReleaseOnTimeByProducts" resultType="java.util.Map">
|
||||||
select (SELECT count(1) waitRelease from zt_story
|
select (SELECT count(1) waitRelease from zt_story
|
||||||
WHERE plan_end_date >=#{startTime} and plan_end_date <= #{endTime} AND product in
|
WHERE plan_end_date >=#{startTime} and plan_end_date <= #{endTime}
|
||||||
|
and status not in ('closed')
|
||||||
|
AND product in
|
||||||
<foreach collection="pIds" item="id" index="index"
|
<foreach collection="pIds" item="id" index="index"
|
||||||
open="(" close=")" separator=",">
|
open="(" close=")" separator=",">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>) planReleaseStoryNum,
|
</foreach>) planReleaseStoryNum,
|
||||||
(SELECT count(1) waitRelease from zt_story
|
(SELECT count(1) waitRelease from zt_story
|
||||||
WHERE plan_end_date >=#{startTime} and plan_end_date <=#{endTime} and releasedDate >=#{startTime}
|
WHERE plan_end_date >=#{startTime} and plan_end_date <=#{endTime} and releasedDate >=#{startTime}
|
||||||
and releasedDate <=#{endTime}
|
and releasedDate <=#{endTime}
|
||||||
|
and status not in ('closed')
|
||||||
AND product in
|
AND product in
|
||||||
<foreach collection="pIds" item="id" index="index"
|
<foreach collection="pIds" item="id" index="index"
|
||||||
open="(" close=")" separator=",">
|
open="(" close=")" separator=",">
|
||||||
|
|||||||
Reference in New Issue
Block a user