huanghongfa
2021-01-18 a678b6d79e52c4e1b99905aa9145474d8498e2de
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
37
38
39
40
41
42
43
44
45
46
47
package com.panzhihua.service_community.dao;
 
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.vos.community.ComActDynVO;
import com.panzhihua.common.model.vos.community.ComMngStructAreaVO;
import com.panzhihua.service_community.model.dos.ComMngStructAreaDO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
 
/**
 * @program: springcloud_k8s_panzhihuazhihuishequ
 * @description: 小区
 * @author: huang.hongfa weixin hhf9596 qq 959656820
 * @create: 2020-12-14 17:00
 **/
@Mapper
public interface ComMngStructAreaDAO extends BaseMapper<ComMngStructAreaDO> {
    //    @Select("<script> " +
//            " <where>" +
//            "<if test='nameCn != null and nameCn.trim() != &quot;&quot;'>" +
//            " </if> " +
//            "<if test='nameCn != null and nameCn.trim() != &quot;&quot;'>" +
//            " </if> " +
//            "<if test='nameCn != null and nameCn.trim() != &quot;&quot;'>" +
//            " </if> " +
//            " </where>" +
//            "</script>")
    @Select("<script> " +
            "SELECT\n" +
            "id,\n" +
            "area_name,\n" +
            "area_code,\n" +
            "address_detail,\n" +
            "create_at \n" +
            "FROM\n" +
            "com_mng_struct_area \n" +
            "WHERE\n" +
            "community_id = #{comMngStructAreaVO.communityId} \n" +
            "<if test='comMngStructAreaVO.areaName != null and comMngStructAreaVO.areaName.trim() != &quot;&quot;'>" +
            "AND area_name = #{comMngStructAreaVO.areaName}" +
            " </if> " +
            "</script>")
    IPage<ComMngStructAreaVO> pageArea(Page page, @Param("comMngStructAreaVO") ComMngStructAreaVO comMngStructAreaVO);
}