将加盟机构信息、机构加盟申请、机构信息变更三个功能中搜索条件进行变更:企业名称、联系人合并为一个查询组件,查询时同时模糊匹配企业名称、联系人、联系电话
This commit is contained in:
parent
96ea2254d5
commit
e2174bfb05
|
|
@ -12,6 +12,7 @@ import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.nu.modules.orgapplyinfo.entity.OrgAllInfo;
|
import com.nu.modules.orgapplyinfo.entity.OrgAllInfo;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.system.query.QueryGenerator;
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
import org.jeecg.common.system.query.QueryRuleEnum;
|
import org.jeecg.common.system.query.QueryRuleEnum;
|
||||||
|
|
@ -79,6 +80,10 @@ public class OrgApplyInfoController extends JeecgController<OrgApplyInfo, IOrgAp
|
||||||
QueryWrapper<OrgApplyInfo> queryWrapper = QueryGenerator.initQueryWrapper(orgApplyInfo, req.getParameterMap(), customeRuleMap);
|
QueryWrapper<OrgApplyInfo> queryWrapper = QueryGenerator.initQueryWrapper(orgApplyInfo, req.getParameterMap(), customeRuleMap);
|
||||||
queryWrapper.in("status", new String[]{"1", "2", "3"});
|
queryWrapper.in("status", new String[]{"1", "2", "3"});
|
||||||
Page<OrgApplyInfo> page = new Page<OrgApplyInfo>(pageNo, pageSize);
|
Page<OrgApplyInfo> page = new Page<OrgApplyInfo>(pageNo, pageSize);
|
||||||
|
if (StringUtils.isNotBlank(orgApplyInfo.getTitle())) {
|
||||||
|
String value = orgApplyInfo.getTitle();
|
||||||
|
queryWrapper.and(c -> c.like("com_name", value).or().like("org_leader", value).or().like("org_leader_phone", value));
|
||||||
|
}
|
||||||
IPage<OrgApplyInfo> pageList = orgApplyInfoService.page(page, queryWrapper);
|
IPage<OrgApplyInfo> pageList = orgApplyInfoService.page(page, queryWrapper);
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
@ -106,6 +111,10 @@ public class OrgApplyInfoController extends JeecgController<OrgApplyInfo, IOrgAp
|
||||||
QueryWrapper<OrgApplyInfo> queryWrapper = QueryGenerator.initQueryWrapper(orgApplyInfo, req.getParameterMap(), customeRuleMap);
|
QueryWrapper<OrgApplyInfo> queryWrapper = QueryGenerator.initQueryWrapper(orgApplyInfo, req.getParameterMap(), customeRuleMap);
|
||||||
queryWrapper.in("status", new String[]{"4", "5"});
|
queryWrapper.in("status", new String[]{"4", "5"});
|
||||||
Page<OrgApplyInfo> page = new Page<OrgApplyInfo>(pageNo, pageSize);
|
Page<OrgApplyInfo> page = new Page<OrgApplyInfo>(pageNo, pageSize);
|
||||||
|
if (StringUtils.isNotBlank(orgApplyInfo.getTitle())) {
|
||||||
|
String value = orgApplyInfo.getTitle();
|
||||||
|
queryWrapper.and(c -> c.like("com_name", value).or().like("org_leader", value).or().like("org_leader_phone", value));
|
||||||
|
}
|
||||||
IPage<OrgApplyInfo> pageList = orgApplyInfoService.page(page, queryWrapper);
|
IPage<OrgApplyInfo> pageList = orgApplyInfoService.page(page, queryWrapper);
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
@ -271,8 +280,8 @@ public class OrgApplyInfoController extends JeecgController<OrgApplyInfo, IOrgAp
|
||||||
|
|
||||||
@GetMapping(value = "/getOrgByOpenId")
|
@GetMapping(value = "/getOrgByOpenId")
|
||||||
public Result<IPage<OrgAllInfo>> getOrgByOpenId(@RequestParam(value = "openId", defaultValue = "", required = false) String openId,
|
public Result<IPage<OrgAllInfo>> getOrgByOpenId(@RequestParam(value = "openId", defaultValue = "", required = false) String openId,
|
||||||
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
@RequestParam(name = "pageSize", defaultValue = "8") Integer pageSize) {
|
@RequestParam(name = "pageSize", defaultValue = "8") Integer pageSize) {
|
||||||
IPage<OrgAllInfo> page = new Page<>(pageNo, pageSize);
|
IPage<OrgAllInfo> page = new Page<>(pageNo, pageSize);
|
||||||
IPage<OrgAllInfo> resultPage = orgApplyInfoService.getOrgByOpenId(page, openId);
|
IPage<OrgAllInfo> resultPage = orgApplyInfoService.getOrgByOpenId(page, openId);
|
||||||
return Result.OK(resultPage);
|
return Result.OK(resultPage);
|
||||||
|
|
|
||||||
|
|
@ -254,5 +254,8 @@ public class OrgApplyInfo implements Serializable {
|
||||||
private java.lang.String workOrderStatus;
|
private java.lang.String workOrderStatus;
|
||||||
private java.lang.String workOrderId;
|
private java.lang.String workOrderId;
|
||||||
|
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,11 @@
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
<if test="title != null and title != ''">
|
<if test="title != null and title != ''">
|
||||||
AND d.depart_name LIKE CONCAT('%', #{title}, '%')
|
AND (
|
||||||
|
d.depart_name LIKE CONCAT('%', #{title}, '%')
|
||||||
|
OR o.org_leader LIKE CONCAT('%', #{title}, '%')
|
||||||
|
OR o.org_leader_phone LIKE CONCAT('%', #{title}, '%')
|
||||||
|
)
|
||||||
</if>
|
</if>
|
||||||
</where>
|
</where>
|
||||||
order by (d.org_code + 0) asc
|
order by (d.org_code + 0) asc
|
||||||
|
|
@ -111,7 +115,7 @@
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
<if test="invited !=null and invited != ''">
|
<if test="invited !=null and invited != ''">
|
||||||
and eo.apply_type in
|
and eo.apply_type in
|
||||||
<foreach collection="invited.split(',')" item="item" open="(" separator="," close=")">
|
<foreach collection="invited.split(',')" item="item" open="(" separator="," close=")">
|
||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
|
|
@ -123,20 +127,20 @@
|
||||||
order by eo.create_time DESC
|
order by eo.create_time DESC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!-- <choose>-->
|
<!-- <choose>-->
|
||||||
<!-- <when test='status != null and status == "2"'>-->
|
<!-- <when test='status != null and status == "2"'>-->
|
||||||
<!-- ORDER BY (d.org_code + 0) ASC-->
|
<!-- ORDER BY (d.org_code + 0) ASC-->
|
||||||
<!-- </when>-->
|
<!-- </when>-->
|
||||||
<!-- <otherwise>-->
|
<!-- <otherwise>-->
|
||||||
<!-- ORDER BY-->
|
<!-- ORDER BY-->
|
||||||
<!-- eo.iz_history desc,-->
|
<!-- eo.iz_history desc,-->
|
||||||
<!-- CASE eo.status-->
|
<!-- CASE eo.status-->
|
||||||
<!-- WHEN '2' THEN 1-->
|
<!-- WHEN '2' THEN 1-->
|
||||||
<!-- WHEN '1' THEN 2-->
|
<!-- WHEN '1' THEN 2-->
|
||||||
<!-- WHEN '3' THEN 3-->
|
<!-- WHEN '3' THEN 3-->
|
||||||
<!-- ELSE 4-->
|
<!-- ELSE 4-->
|
||||||
<!-- END,-->
|
<!-- END,-->
|
||||||
<!-- eo.create_time DESC-->
|
<!-- eo.create_time DESC-->
|
||||||
<!-- </otherwise>-->
|
<!-- </otherwise>-->
|
||||||
<!-- </choose>-->
|
<!-- </choose>-->
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue