package com.panzhihua.service_community.dao;
|
|
import org.apache.ibatis.annotations.Mapper;
|
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Select;
|
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.panzhihua.common.model.dtos.community.ComExServicemanDTO;
|
import com.panzhihua.common.model.vos.community.ComExServicemanVO;
|
import com.panzhihua.service_community.model.dos.ComExServicemanDO;
|
|
/**
|
* @description: 退役军人
|
* @author: txb
|
* @date: 2021/7/15 14:00
|
*/
|
@Mapper
|
public interface ComExServicemanDAO extends BaseMapper<ComExServicemanDO> {
|
|
@Select("<script> " + " SELECT " + " id, " + " com_name AS comName, " + " legal_person AS legalPerson, "
|
+ " leader, " + " contacts_phone AS contactsPhone, " + " scope, " + " credit_code AS creditCode, "
|
+ " province_adcode AS provinceAdcode, " + " city_adcode AS cityAdcode, "
|
+ " district_adcode AS districtAdcode, " + " address, " + " create_at AS createAt " + "FROM "
|
+ " com_ex_serviceman where 1=1"
|
+ "<if test='pageComMngRealCompanyDTO.legalPerson != null and pageComMngRealCompanyDTO.legalPerson.trim() != ""'>"
|
+ " and t.legal_person LIKE concat( #{pageComMngRealCompanyDTO.legalPerson}, '%' ) " + " </if> "
|
+ "<if test='pageComMngRealCompanyDTO.comName != null and pageComMngRealCompanyDTO.comName.trim() != ""'>"
|
+ " and t.com_name LIKE concat( '%',#{pageComMngRealCompanyDTO.comName}, '%' ) " + " </if> "
|
+ "<if test='pageComMngRealCompanyDTO.communityId != null and pageComMngRealCompanyDTO.communityId != 0'>"
|
+ " and t.community_id = ${pageComMngRealCompanyDTO.communityId} " + " </if> " + " order by t.create_at desc"
|
+ "</script>")
|
IPage<ComExServicemanVO> pageQueryComExServiceman(Page page,
|
@Param(value = "comExServicemanDTO") ComExServicemanDTO comExServicemanDTO);
|
}
|