Merge branch 'develop_master' into FOTON
This commit is contained in:
+22
-12
@@ -1158,18 +1158,21 @@ public class SearchCenterServiceImpl implements SearchCenterService {
|
|||||||
List<Map<String, Object>> result = new ArrayList<>();
|
List<Map<String, Object>> result = new ArrayList<>();
|
||||||
SearchRequestBuilder searchRequestBuilder;
|
SearchRequestBuilder searchRequestBuilder;
|
||||||
BoolQueryBuilder boolQueryBuilder = QueryBuilders.boolQuery();
|
BoolQueryBuilder boolQueryBuilder = QueryBuilders.boolQuery();
|
||||||
|
BoolQueryBuilder boolSelectValue = new BoolQueryBuilder();
|
||||||
|
|
||||||
// 记录搜索记录到数据库中
|
// 记录搜索记录到数据库中
|
||||||
if(StringUtils.isNotEmpty(searchInfoEO.getSelectValue())){
|
if(StringUtils.isNotEmpty(searchInfoEO.getSelectValue())){
|
||||||
boolQueryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
boolSelectValue.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
||||||
"title"
|
"title"
|
||||||
).minimumShouldMatch("100%").field("title",10f));
|
).minimumShouldMatch("100%").field("title",10f));
|
||||||
boolQueryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
boolSelectValue.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
||||||
"textContent"
|
"textContent"
|
||||||
).minimumShouldMatch("100%").field("title",10f));
|
).minimumShouldMatch("100%").field("title",10f));
|
||||||
boolQueryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
boolSelectValue.should(QueryBuilders.multiMatchQuery(searchInfoEO.getSelectValue(),
|
||||||
"textItems"
|
"textItems"
|
||||||
).minimumShouldMatch("100%").field("title",10f));
|
).minimumShouldMatch("100%").field("title",10f));
|
||||||
boolQueryBuilder.should(QueryBuilders.wildcardQuery("title.keyword","*"+searchInfoEO.getSelectValue()+"*"));
|
boolSelectValue.should(QueryBuilders.wildcardQuery("title.keyword","*"+searchInfoEO.getSelectValue()+"*"));
|
||||||
|
boolQueryBuilder.must(boolSelectValue);
|
||||||
}
|
}
|
||||||
//在结果中检索
|
//在结果中检索
|
||||||
if (StringUtils.isNotEmpty(searchInfoEO.getResultKeyword())) {
|
if (StringUtils.isNotEmpty(searchInfoEO.getResultKeyword())) {
|
||||||
@@ -1177,14 +1180,21 @@ public class SearchCenterServiceImpl implements SearchCenterService {
|
|||||||
boolQueryBuilder.must(multiQuery);
|
boolQueryBuilder.must(multiQuery);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(StringUtils.isNotBlank(searchInfoEO.getNYLXCLASS())){
|
BoolQueryBuilder queryBuilder = new BoolQueryBuilder();
|
||||||
boolQueryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getNYLXCLASS(),
|
if(StringUtils.isNotBlank(searchInfoEO.getNYLXCLASS()) || StringUtils.isNotBlank(searchInfoEO.getCLLX())){
|
||||||
"textContent"
|
if(StringUtils.isNotBlank(searchInfoEO.getNYLXCLASS())){
|
||||||
).minimumShouldMatch("100%").field("title",10f));
|
queryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getNYLXCLASS(),
|
||||||
}else if(StringUtils.isNotBlank(searchInfoEO.getCLLX())){
|
"textContent"
|
||||||
boolQueryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getCLLX(),
|
).minimumShouldMatch("100%").field("title",10f));
|
||||||
"textContent"
|
}
|
||||||
).minimumShouldMatch("100%").field("title",10f));
|
|
||||||
|
if(StringUtils.isNotBlank(searchInfoEO.getCLLX())){
|
||||||
|
queryBuilder.should(QueryBuilders.multiMatchQuery(searchInfoEO.getCLLX(),
|
||||||
|
"textContent"
|
||||||
|
).minimumShouldMatch("100%").field("title",10f));
|
||||||
|
}
|
||||||
|
|
||||||
|
boolQueryBuilder.must(queryBuilder);
|
||||||
}
|
}
|
||||||
|
|
||||||
HighlightBuilder hiBuilder=new HighlightBuilder();
|
HighlightBuilder hiBuilder=new HighlightBuilder();
|
||||||
|
|||||||
@@ -94,6 +94,10 @@ public class EsRevisePlan extends BasePage {
|
|||||||
//企标类别
|
//企标类别
|
||||||
private String standType;
|
private String standType;
|
||||||
|
|
||||||
|
// 标准编号
|
||||||
|
private String standNum;
|
||||||
|
|
||||||
|
|
||||||
@ApiModelProperty(value = "企标类别")
|
@ApiModelProperty(value = "企标类别")
|
||||||
private String esMatingRelations;
|
private String esMatingRelations;
|
||||||
private String esStandRelations;
|
private String esStandRelations;
|
||||||
|
|||||||
+6
@@ -80,6 +80,12 @@ public class TsInstitutionController extends BaseController<TsInstitution> {
|
|||||||
return Result.success();
|
return Result.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation("根据部门ID获取部门下所有用户")
|
||||||
|
@GetMapping("/getInstitutionIdToDept")
|
||||||
|
public List<TsInstitution> getInstitutionIdToDept(String institutionIds,String userName){
|
||||||
|
return tsInstitutionService.getInstitutionIdToDept(institutionIds,userName);
|
||||||
|
}
|
||||||
|
|
||||||
@ApiOperation("获得下一级的部门和人员")
|
@ApiOperation("获得下一级的部门和人员")
|
||||||
@GetMapping("/getNext")
|
@GetMapping("/getNext")
|
||||||
public List<TsInstitution> getNext(String institutionId,String userName){
|
public List<TsInstitution> getNext(String institutionId,String userName){
|
||||||
|
|||||||
@@ -29,6 +29,8 @@ public interface TsInstitutionDao extends BaseMapper<TsInstitution> {
|
|||||||
*/
|
*/
|
||||||
List<TsInstitution> selectNextUser(@Param("institutionId") String institutionId,@Param("userName") String userName);
|
List<TsInstitution> selectNextUser(@Param("institutionId") String institutionId,@Param("userName") String userName);
|
||||||
|
|
||||||
|
List<TsInstitution> selectNextUsers(@Param("institutionIds") List<String> institutionIds,@Param("userName") String userName);
|
||||||
|
|
||||||
List<TsInstitution> selectNextUserByIds(@Param("ids") List<String> ids);
|
List<TsInstitution> selectNextUserByIds(@Param("ids") List<String> ids);
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
@@ -37,6 +37,8 @@ public interface ITsInstitutionService extends IService<TsInstitution> {
|
|||||||
*/
|
*/
|
||||||
public List<TsInstitution> getNext(String institutionId,String userName);
|
public List<TsInstitution> getNext(String institutionId,String userName);
|
||||||
|
|
||||||
|
public List<TsInstitution> getInstitutionIdToDept(String institutionIds,String userName);
|
||||||
|
|
||||||
public List<TsInstitution> getNextById(String ids);
|
public List<TsInstitution> getNextById(String ids);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
+7
@@ -200,6 +200,13 @@ public class TsInstitutionServiceImpl extends ServiceImpl<TsInstitutionDao, TsIn
|
|||||||
batchInsert(tsInstitutions);
|
batchInsert(tsInstitutions);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<TsInstitution> getInstitutionIdToDept(String institutionIds,String userName){
|
||||||
|
List<String> strings=new ArrayList<>(Arrays.asList(institutionIds.split(",")));
|
||||||
|
List<TsInstitution> tsUsers=tsInstitutionDao.selectNextUsers(strings,userName);
|
||||||
|
return tsUsers;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 通过部门id获得这个部门下的下一级部门
|
* 通过部门id获得这个部门下的下一级部门
|
||||||
* @return
|
* @return
|
||||||
|
|||||||
+5
-1
@@ -118,7 +118,11 @@ public class SarPublicIdeaAllController extends BaseController<SarPublicIdeaAll>
|
|||||||
response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx");
|
response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx");
|
||||||
List<SarPublicIdeaAll> data=new ArrayList<>();
|
List<SarPublicIdeaAll> data=new ArrayList<>();
|
||||||
if (!StringUtils.isEmpty(cid)){
|
if (!StringUtils.isEmpty(cid)){
|
||||||
data=sarPublicIdeaAllDao.getPublicAllIdea(cid,type);
|
if (null!=type) {
|
||||||
|
data = sarPublicIdeaAllDao.getPublicAllIdea(cid, type);
|
||||||
|
}else {
|
||||||
|
data = sarPublicIdeaAllDao.getPublicAllIdeaExport(cid,type);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
List<GetExcelDto> standExcel=new ArrayList<>();
|
List<GetExcelDto> standExcel=new ArrayList<>();
|
||||||
List<GetExcelDto2> standExcel2=new ArrayList<>();
|
List<GetExcelDto2> standExcel2=new ArrayList<>();
|
||||||
|
|||||||
@@ -28,4 +28,6 @@ public interface SarPublicIdeaAllDao extends BaseMapper<SarPublicIdeaAll> {
|
|||||||
Integer getAllDataByIdeaCount( @Param("ideaId")String ideaId);
|
Integer getAllDataByIdeaCount( @Param("ideaId")String ideaId);
|
||||||
|
|
||||||
List<SarPublicIdeaAll> getPublicAllIdea(@Param("cid") String cid,@Param("type")String type);
|
List<SarPublicIdeaAll> getPublicAllIdea(@Param("cid") String cid,@Param("type")String type);
|
||||||
|
|
||||||
|
List<SarPublicIdeaAll> getPublicAllIdeaExport(@Param("cid") String cid,@Param("type")String type);
|
||||||
}
|
}
|
||||||
|
|||||||
+13
-5
@@ -47,11 +47,19 @@ public class SarPublicIdeaServiceImpl extends ServiceImpl<SarPublicIdeaDao, SarP
|
|||||||
public IPage<SarPublicIdea> selectAllP(Integer p, Integer size, String category, String cname, Date start, Date end, String type) {
|
public IPage<SarPublicIdea> selectAllP(Integer p, Integer size, String category, String cname, Date start, Date end, String type) {
|
||||||
QueryWrapper<SarPublicIdea> list = new QueryWrapper<>();
|
QueryWrapper<SarPublicIdea> list = new QueryWrapper<>();
|
||||||
if ("1".equals(type)) {
|
if ("1".equals(type)) {
|
||||||
list.like(StringUtils.isNotEmpty(category), "category", category)
|
if (start!=null && end !=null){
|
||||||
.like(StringUtils.isNotEmpty(cname), "cid", cname)
|
list.like(StringUtils.isNotEmpty(category), "category", category)
|
||||||
.ge(start != null, "start_time", start)
|
.like(StringUtils.isNotEmpty(cname), "cid", cname)
|
||||||
.le(end != null, "end_time", end)
|
.ge(start != null, "start_time", start)
|
||||||
.orderByDesc("start_time");
|
.le(end != null, "end_time", end)
|
||||||
|
.orderByDesc("start_time");
|
||||||
|
}else {
|
||||||
|
list.like(StringUtils.isNotEmpty(category), "category", category)
|
||||||
|
.like(StringUtils.isNotEmpty(cname), "cid", cname)
|
||||||
|
.le(start != null, "start_time", start)
|
||||||
|
.ge(end != null, "end_time", end)
|
||||||
|
.orderByDesc("start_time");
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
list.like(StringUtils.isNotEmpty(category), "category", category)
|
list.like(StringUtils.isNotEmpty(category), "category", category)
|
||||||
.like(StringUtils.isNotEmpty(cname), "cname", cname)
|
.like(StringUtils.isNotEmpty(cname), "cname", cname)
|
||||||
|
|||||||
@@ -210,6 +210,7 @@
|
|||||||
es_revise_plan.buss_sort,
|
es_revise_plan.buss_sort,
|
||||||
sar_bussioness_stand.STAND_CODE as rqbName,
|
sar_bussioness_stand.STAND_CODE as rqbName,
|
||||||
sar_bussioness_stand.STAND_SORT as standType,
|
sar_bussioness_stand.STAND_SORT as standType,
|
||||||
|
sar_bussioness_stand.stand_number as standNum,
|
||||||
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
|
(select group_concat(ts_institution.name) from ts_institution where find_in_set(ts_institution.id,unit)) as unitName,
|
||||||
(SELECT GROUP_CONCAT(UNAME) from ts_user WHERE find_in_set(USID,drafter) ) as drafterName,
|
(SELECT GROUP_CONCAT(UNAME) from ts_user WHERE find_in_set(USID,drafter) ) as drafterName,
|
||||||
(SELECT GROUP_CONCAT(ts_dictype.DIC_TYPE_NAME) from ts_dictype WHERE find_in_set(ts_dictype.DIC_TYPE_CODE,area) ) as areaName,
|
(SELECT GROUP_CONCAT(ts_dictype.DIC_TYPE_NAME) from ts_dictype WHERE find_in_set(ts_dictype.DIC_TYPE_CODE,area) ) as areaName,
|
||||||
|
|||||||
@@ -35,6 +35,26 @@
|
|||||||
WHERE parent_id=#{institutionId}
|
WHERE parent_id=#{institutionId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="selectNextUsers" resultMap="TsUser">
|
||||||
|
select ts_user.EMAIL,ts_user.ACCOUNT,ts_user.CREATION_TIME,ts_user.DISABLE_FLAG,ts_user.EXT_INFO,ts_user.USID,
|
||||||
|
ts_user.INSTITUTION_ID,t2.name as INSTITUTION_NAME,ts_user.MODIFY_TIME,ts_user.OPER_USER,ts_user.PASSWORD,ts_user.PHONE,
|
||||||
|
ts_user.POSITION_ID,ts_user.POSITION_NAME,ts_user.SEX,ts_user.SSO_ID,ts_user.STATE,ts_user.UNLOCK_FLAG,ts_user.USER_SOURCE,
|
||||||
|
ts_user.USER_TYPE,ts_user.VALID_FLAG,ts_user.WORK_NUM,concat(ts_user.UNAME,concat(concat("(",ts_user.ACCOUNT),")")) as uname,
|
||||||
|
ts_institution.name as unit,ts_institution.id as unitId
|
||||||
|
from ts_user
|
||||||
|
left join ts_institution ON ts_institution.id = (SELECT parent_id from ts_institution WHERE id = ts_user.INSTITUTION_ID)
|
||||||
|
left join ts_institution t2 on t2.id=ts_user.INSTITUTION_ID
|
||||||
|
WHERE 1=1
|
||||||
|
<if test="institutionIds != null and institutionIds.size()> 0 ">
|
||||||
|
and ts_user.INSTITUTION_ID in
|
||||||
|
<foreach collection="institutionIds" index="index" item="item" open="(" separator="," close=")">
|
||||||
|
#{item}
|
||||||
|
</foreach>
|
||||||
|
|
||||||
|
</if>
|
||||||
|
order by ts_institution.id
|
||||||
|
</select>
|
||||||
|
|
||||||
<!-- 只查询这个部门下的子一级人员-->
|
<!-- 只查询这个部门下的子一级人员-->
|
||||||
<select id="selectNextUser" resultMap="TsUser">
|
<select id="selectNextUser" resultMap="TsUser">
|
||||||
select ts_user.EMAIL,ts_user.ACCOUNT,ts_user.CREATION_TIME,ts_user.DISABLE_FLAG,ts_user.EXT_INFO,ts_user.USID,
|
select ts_user.EMAIL,ts_user.ACCOUNT,ts_user.CREATION_TIME,ts_user.DISABLE_FLAG,ts_user.EXT_INFO,ts_user.USID,
|
||||||
|
|||||||
@@ -46,4 +46,19 @@
|
|||||||
</if>
|
</if>
|
||||||
ORDER BY part_code ASC
|
ORDER BY part_code ASC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<select id="getPublicAllIdeaExport" resultType="com.adc.da.slrs.sarStandIdea.entity.SarPublicIdeaAll">
|
||||||
|
SELECT sar_public_idea_all.id,reason,ts_institution.name as deptName,old_text,new_text,dept_id,part_code,user_name,user_id,content,idea_id,cid,chapter_name,wk_flag,sar_public_idea_all.state
|
||||||
|
FROM sar_public_idea_all
|
||||||
|
left join ts_user on ts_user.USID=sar_public_idea_all.user_id
|
||||||
|
left join ts_institution on ts_institution.id=ts_user.INSTITUTION_ID
|
||||||
|
WHERE cid = #{cid}
|
||||||
|
<if test="null==type or ''==type">
|
||||||
|
and sar_public_idea_all.wk_flag is null
|
||||||
|
</if>
|
||||||
|
<if test="null!=type and type != ''">
|
||||||
|
and sar_public_idea_all.wk_flag ='1'
|
||||||
|
</if>
|
||||||
|
ORDER BY part_code ASC
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|||||||
Reference in New Issue
Block a user