Browse Source

巡查期间立项数

master
zxc 4 years ago
parent
commit
ac97acf5b2
  1. 29
      epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/dto/form/PatrolProjectFormDTO.java
  2. 14
      epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java
  3. 10
      epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java
  4. 12
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java
  5. 9
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java
  6. 8
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java
  7. 11
      epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java
  8. 12
      epmet-module/gov-project/gov-project-server/src/main/resources/mapper/ProjectDao.xml

29
epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/dto/form/PatrolProjectFormDTO.java

@ -0,0 +1,29 @@
package com.epmet.dto.form;
import lombok.Data;
import java.io.Serializable;
import java.util.Date;
/**
* @Author zxc
* @DateTime 2021/7/1 10:10 上午
* @DESC
*/
@Data
public class PatrolProjectFormDTO implements Serializable {
private static final long serialVersionUID = 7244072033926913678L;
private String userId;
/**
* 巡查开始时间
*/
private Date patrolStartTime;
/**
* 巡查结束时间
*/
private Date patrolEndTime;
}

14
epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/GovProjectOpenFeignClient.java

@ -4,10 +4,7 @@ import com.epmet.commons.tools.constant.ServiceConstant;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.ProjectCategoryDTO;
import com.epmet.dto.ProjectDTO;
import com.epmet.dto.form.DelCategoryFormDTO;
import com.epmet.dto.form.ProcessListFormDTO;
import com.epmet.dto.form.ProjectByCreateTopicUserFormDTO;
import com.epmet.dto.form.ProjectListFromDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.*;
import com.epmet.feign.fallback.GovProjectOpenFeignClientFallback;
import com.epmet.resi.mine.dto.from.MyPartProjectsFormDTO;
@ -86,4 +83,13 @@ public interface GovProjectOpenFeignClient {
**/
@PostMapping("gov/project/projectcategory/getprojectcategorylist")
Result<List<ProjectCategoryDTO>> getProjectCategoryList(@RequestBody DelCategoryFormDTO formDTO);
/**
* @Description 查询巡查期间的立项数
* @Param formDTO
* @author zxc
* @date 2021/7/1 10:16 上午
*/
@PostMapping("gov/project/project/patrolproject")
Result<Integer> selectPatrolProject(@RequestBody PatrolProjectFormDTO formDTO);
}

10
epmet-module/gov-project/gov-project-client/src/main/java/com/epmet/feign/fallback/GovProjectOpenFeignClientFallback.java

@ -5,10 +5,7 @@ import com.epmet.commons.tools.utils.ModuleUtils;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.ProjectCategoryDTO;
import com.epmet.dto.ProjectDTO;
import com.epmet.dto.form.DelCategoryFormDTO;
import com.epmet.dto.form.ProcessListFormDTO;
import com.epmet.dto.form.ProjectByCreateTopicUserFormDTO;
import com.epmet.dto.form.ProjectListFromDTO;
import com.epmet.dto.form.*;
import com.epmet.dto.result.*;
import com.epmet.feign.GovProjectOpenFeignClient;
import com.epmet.resi.mine.dto.from.MyPartProjectsFormDTO;
@ -78,4 +75,9 @@ public class GovProjectOpenFeignClientFallback implements GovProjectOpenFeignCli
public Result<List<ProjectCategoryDTO>> getProjectCategoryList(DelCategoryFormDTO formDTO) {
return ModuleUtils.feignConError(ServiceConstant.GOV_PROJECT_SERVER, "getProjectCategoryList", formDTO);
}
@Override
public Result<Integer> selectPatrolProject(PatrolProjectFormDTO formDTO) {
return ModuleUtils.feignConError(ServiceConstant.GOV_PROJECT_SERVER, "selectPatrolProject", formDTO);
}
}

12
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/controller/ProjectController.java

@ -222,4 +222,16 @@ public class ProjectController {
projectService.platformCallBack(formDTO);
return new Result();
}
/**
* @Description 查询巡查期间的立项数
* @Param formDTO
* @author zxc
* @date 2021/7/1 10:16 上午
*/
@PostMapping("patrolproject")
public Result<Integer> selectPatrolProject(@RequestBody PatrolProjectFormDTO formDTO){
return new Result<Integer>().ok(projectService.selectPatrolProject(formDTO));
}
}

9
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/dao/ProjectDao.java

@ -21,6 +21,7 @@ import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.ProjectDTO;
import com.epmet.dto.ProjectStaffDTO;
import com.epmet.dto.form.LatestListFormDTO;
import com.epmet.dto.form.PatrolProjectFormDTO;
import com.epmet.dto.form.ProjectListFromDTO;
import com.epmet.dto.form.ShiftProjectsFromDTO;
import com.epmet.dto.result.*;
@ -164,4 +165,12 @@ public interface ProjectDao extends BaseDao<ProjectEntity> {
* @date 2021/5/14 1:59 下午
*/
List<MassesDiscontentResultDTO> selectProjectIdByTime(@Param("agencyId")String agencyId,@Param("endDate")Integer endDate,@Param("startDate")Integer startDate);
/**
* @Description 查询巡查期间的立项数
* @Param formDTO
* @author zxc
* @date 2021/7/1 10:16 上午
*/
Integer selectPatrolProject(PatrolProjectFormDTO formDTO);
}

8
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/ProjectService.java

@ -295,4 +295,12 @@ public interface ProjectService extends BaseService<ProjectEntity> {
* @return void
*/
void platformCallBack(PlatformCallBackFormDTO formDTO);
/**
* @Description 查询巡查期间的立项数
* @Param formDTO
* @author zxc
* @date 2021/7/1 10:16 上午
*/
Integer selectPatrolProject(PatrolProjectFormDTO formDTO);
}

11
epmet-module/gov-project/gov-project-server/src/main/java/com/epmet/service/impl/ProjectServiceImpl.java

@ -2694,4 +2694,15 @@ public class ProjectServiceImpl extends BaseServiceImpl<ProjectDao, ProjectEntit
return UUID.randomUUID().toString().replace("-", "") + "." + FilenameUtils.getExtension(url);
}
/**
* @Description 查询巡查期间的立项数
* @Param formDTO
* @author zxc
* @date 2021/7/1 10:16 上午
*/
@Override
public Integer selectPatrolProject(PatrolProjectFormDTO formDTO) {
return baseDao.selectPatrolProject(formDTO);
}
}

12
epmet-module/gov-project/gov-project-server/src/main/resources/mapper/ProjectDao.xml

@ -300,4 +300,16 @@
AND `STATUS` = 'closed'
</select>
<!-- 查询巡查期间的立项数 -->
<select id="selectPatrolProject" resultType="java.lang.Integer">
SELECT
COUNT(1)
FROM
project
WHERE DEL_FLAG = '0'
AND CREATED_TIME BETWEEN #{patrolStartTime} AND #{patrolEndTime}
AND ORIGIN = 'agency'
AND CREATED_BY = #{userId}
</select>
</mapper>
Loading…
Cancel
Save