mitao
2025-02-21 31573d6180d15ef65ed0df9c2732495f40b12663
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
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() != &quot;&quot;'>"
        + " and t.legal_person LIKE concat( #{pageComMngRealCompanyDTO.legalPerson}, '%' )  " + " </if> "
        + "<if test='pageComMngRealCompanyDTO.comName != null and pageComMngRealCompanyDTO.comName.trim() != &quot;&quot;'>"
        + " 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);
}