吴学文 лет назад: 6
Родитель
Сommit
73c05f1c52

+ 230 - 0
Api/src/main/java/com/java110/api/listener/owner/ApplicationKeyListener.java

@@ -0,0 +1,230 @@
+package com.java110.api.listener.owner;
+
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
+import com.java110.api.listener.AbstractServiceApiDataFlowListener;
+import com.java110.core.annotation.Java110Listener;
+import com.java110.core.context.DataFlowContext;
+import com.java110.core.factory.GenerateCodeFactory;
+import com.java110.core.smo.file.IFileInnerServiceSMO;
+import com.java110.core.smo.owner.IOwnerRoomRelInnerServiceSMO;
+import com.java110.dto.OwnerRoomRelDto;
+import com.java110.dto.file.FileDto;
+import com.java110.entity.center.AppService;
+import com.java110.event.service.api.ServiceDataFlowEvent;
+import com.java110.utils.constant.*;
+import com.java110.utils.exception.ListenerExecuteException;
+import com.java110.utils.util.Assert;
+import com.java110.utils.util.DateUtil;
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.http.HttpHeaders;
+import org.springframework.http.HttpMethod;
+import org.springframework.http.ResponseEntity;
+
+import java.util.List;
+
+/**
+ * @ClassName ApplicationKeyListener
+ * @Description 钥匙申请类
+ * @Author wuxw
+ * @Date 2019/4/26 14:51
+ * @Version 1.0
+ * add by wuxw 2019/4/26
+ **/
+
+@Java110Listener("applicationKeyListener")
+public class ApplicationKeyListener extends AbstractServiceApiDataFlowListener {
+
+
+    @Autowired
+    private IFileInnerServiceSMO fileInnerServiceSMOImpl;
+
+    @Autowired
+    private IOwnerRoomRelInnerServiceSMO ownerRoomRelInnerServiceSMOImpl;
+
+    private static Logger logger = LoggerFactory.getLogger(ApplicationKeyListener.class);
+
+    @Override
+    public String getServiceCode() {
+        return ServiceCodeConstant.SERVICE_CODE_APPLICATION_KEY;
+    }
+
+    @Override
+    public HttpMethod getHttpMethod() {
+        return HttpMethod.POST;
+    }
+
+    @Override
+    public void soService(ServiceDataFlowEvent event) {
+
+        logger.debug("ServiceDataFlowEvent : {}", event);
+
+        DataFlowContext dataFlowContext = event.getDataFlowContext();
+        AppService service = event.getAppService();
+
+        String paramIn = dataFlowContext.getReqData();
+
+        //校验数据
+        validate(paramIn);
+        JSONObject paramObj = JSONObject.parseObject(paramIn);
+
+        HttpHeaders header = new HttpHeaders();
+        dataFlowContext.getRequestCurrentHeaders().put(CommonConstant.HTTP_ORDER_TYPE_CD, "D");
+        JSONArray businesses = new JSONArray();
+
+        //添加小区楼
+        businesses.add(addMember(paramObj));
+
+
+        FileDto fileDto = new FileDto();
+        fileDto.setFileId(GenerateCodeFactory.getGeneratorId(GenerateCodeFactory.CODE_PREFIX_file_id));
+        fileDto.setFileName(fileDto.getFileId());
+        fileDto.setContext(paramObj.getString("ownerPhoto"));
+        fileDto.setSuffix("jpeg");
+        fileDto.setCommunityId(paramObj.getString("communityId"));
+        if (fileInnerServiceSMOImpl.saveFile(fileDto) < 1) {
+            throw new ListenerExecuteException(ResponseConstant.RESULT_PARAM_ERROR, "保存文件出错");
+        }
+        paramObj.put("ownerPhotoId", fileDto.getFileId());
+
+        businesses.add(addOwnerPhoto(paramObj, dataFlowContext));
+
+
+        /*if ("ON".equals(MappingCache.getValue("SAVE_MACHINE_TRANSLATE_FLAG"))) {
+            addMachineTranslate(paramObj, dataFlowContext);
+        }*/
+
+        JSONObject paramInObj = super.restToCenterProtocol(businesses, dataFlowContext.getRequestCurrentHeaders());
+
+        //将 rest header 信息传递到下层服务中去
+        super.freshHttpHeader(header, dataFlowContext.getRequestCurrentHeaders());
+
+
+        ResponseEntity<String> responseEntity = this.callService(dataFlowContext, service.getServiceCode(), paramInObj);
+
+        dataFlowContext.setResponseEntity(responseEntity);
+
+    }
+
+
+    /**
+     * 添加小区楼信息
+     * <p>
+     * * name:'',
+     * *                 age:'',
+     * *                 link:'',
+     * *                 sex:'',
+     * *                 remark:''
+     *
+     * @param paramInJson 接口调用放传入入参
+     * @return 订单服务能够接受的报文
+     */
+    private JSONObject addMember(JSONObject paramInJson) {
+
+        //根据房屋ID查询业主ID,自动生成成员ID
+        OwnerRoomRelDto ownerRoomRelDto = new OwnerRoomRelDto();
+        ownerRoomRelDto.setRoomId(paramInJson.getString("roomId"));
+        List<OwnerRoomRelDto> ownerRoomRelDtoList = ownerRoomRelInnerServiceSMOImpl.queryOwnerRoomRels(ownerRoomRelDto);
+
+        Assert.listOnlyOne(ownerRoomRelDtoList, "根据房屋查询不到业主信息或查询到多条");
+        paramInJson.put("ownerId", ownerRoomRelDtoList.get(0).getOwnerId());
+
+
+        String memberId = GenerateCodeFactory.getGeneratorId(GenerateCodeFactory.CODE_PREFIX_ownerId);
+        paramInJson.put("memberId", memberId);
+
+
+        JSONObject business = JSONObject.parseObject("{\"datas\":{}}");
+        business.put(CommonConstant.HTTP_BUSINESS_TYPE_CD, BusinessTypeConstant.BUSINESS_TYPE_SAVE_OWNER_INFO);
+        business.put(CommonConstant.HTTP_SEQ, DEFAULT_SEQ);
+        business.put(CommonConstant.HTTP_INVOKE_MODEL, CommonConstant.HTTP_INVOKE_MODEL_S);
+        JSONObject businessOwner = new JSONObject();
+        businessOwner.putAll(paramInJson);
+        businessOwner.put("ownerTypeCd", "1004");//临时人员
+        businessOwner.put("state", "1000");//待审核
+        business.getJSONObject(CommonConstant.HTTP_BUSINESS_DATAS).put("businessOwner", businessOwner);
+
+        return business;
+    }
+
+
+    /**
+     * 添加物业费用
+     *
+     * @param paramInJson     接口调用放传入入参
+     * @param dataFlowContext 数据上下文
+     * @return 订单服务能够接受的报文
+     */
+    private JSONObject addOwnerPhoto(JSONObject paramInJson, DataFlowContext dataFlowContext) {
+
+
+        JSONObject business = JSONObject.parseObject("{\"datas\":{}}");
+        business.put(CommonConstant.HTTP_BUSINESS_TYPE_CD, BusinessTypeConstant.BUSINESS_TYPE_SAVE_FILE_REL);
+        business.put(CommonConstant.HTTP_SEQ, DEFAULT_SEQ + 2);
+        business.put(CommonConstant.HTTP_INVOKE_MODEL, CommonConstant.HTTP_INVOKE_MODEL_S);
+        JSONObject businessUnit = new JSONObject();
+        businessUnit.put("fileRelId", "-1");
+        businessUnit.put("relTypeCd", "10000");
+        businessUnit.put("saveWay", "table");
+        businessUnit.put("objId", paramInJson.getString("memberId"));
+        businessUnit.put("fileRealName", paramInJson.getString("ownerPhotoId"));
+        businessUnit.put("fileSaveName", paramInJson.getString("ownerPhotoId"));
+        business.getJSONObject(CommonConstant.HTTP_BUSINESS_DATAS).put("businessFileRel", businessUnit);
+
+        return business;
+    }
+
+
+    /**
+     * 数据校验
+     * <p>
+     * name:'',
+     * age:'',
+     * link:'',
+     * sex:'',
+     * remark:''
+     *
+     * @param paramIn "communityId": "7020181217000001",
+     *                "memberId": "3456789",
+     *                "memberTypeCd": "390001200001"
+     */
+    private void validate(String paramIn) {
+        Assert.jsonObjectHaveKey(paramIn, "name", "请求报文中未包含name");
+        Assert.jsonObjectHaveKey(paramIn, "roomId", "请求报文中未包含房屋信息");
+        Assert.jsonObjectHaveKey(paramIn, "age", "请求报文中未包含age");
+        Assert.jsonObjectHaveKey(paramIn, "link", "请求报文中未包含link");
+        Assert.jsonObjectHaveKey(paramIn, "sex", "请求报文中未包含sex");
+        //Assert.jsonObjectHaveKey(paramIn, "ownerTypeCd", "请求报文中未包含sex"); //这个不需要 这个直接写成钥匙申请,临时人员
+        Assert.jsonObjectHaveKey(paramIn, "communityId", "请求报文中未包含communityId");
+        Assert.jsonObjectHaveKey(paramIn, "idCard", "请求报文中未包含身份证号");
+        Assert.jsonObjectHaveKey(paramIn, "ownerPhoto", "请求报文中未包含照片信息");
+       /* Assert.jsonObjectHaveKey(paramIn, "startTime", "请求报文中未包含开始时间"); 这块打算放在业主属性表中
+        Assert.jsonObjectHaveKey(paramIn, "endTime", "请求报文中未包含结束时间");*/
+    }
+
+
+    @Override
+    public int getOrder() {
+        return 0;
+    }
+
+
+    public IFileInnerServiceSMO getFileInnerServiceSMOImpl() {
+        return fileInnerServiceSMOImpl;
+    }
+
+    public void setFileInnerServiceSMOImpl(IFileInnerServiceSMO fileInnerServiceSMOImpl) {
+        this.fileInnerServiceSMOImpl = fileInnerServiceSMOImpl;
+    }
+
+    public IOwnerRoomRelInnerServiceSMO getOwnerRoomRelInnerServiceSMOImpl() {
+        return ownerRoomRelInnerServiceSMOImpl;
+    }
+
+    public void setOwnerRoomRelInnerServiceSMOImpl(IOwnerRoomRelInnerServiceSMO ownerRoomRelInnerServiceSMOImpl) {
+        this.ownerRoomRelInnerServiceSMOImpl = ownerRoomRelInnerServiceSMOImpl;
+    }
+}

+ 2 - 1
Api/src/main/java/com/java110/api/listener/owner/SaveOwnerListener.java

@@ -160,6 +160,7 @@ public class SaveOwnerListener extends AbstractServiceApiDataFlowListener {
         business.put(CommonConstant.HTTP_INVOKE_MODEL, CommonConstant.HTTP_INVOKE_MODEL_S);
         JSONObject businessOwner = new JSONObject();
         businessOwner.putAll(paramInJson);
+        businessOwner.put("state", "2000");
         business.getJSONObject(CommonConstant.HTTP_BUSINESS_DATAS).put("businessOwner", businessOwner);
 
         return business;
@@ -289,7 +290,7 @@ public class SaveOwnerListener extends AbstractServiceApiDataFlowListener {
         Assert.jsonObjectHaveKey(paramIn, "age", "请求报文中未包含age");
         Assert.jsonObjectHaveKey(paramIn, "link", "请求报文中未包含link");
         Assert.jsonObjectHaveKey(paramIn, "sex", "请求报文中未包含sex");
-        Assert.jsonObjectHaveKey(paramIn, "ownerTypeCd", "请求报文中未包含sex");
+        Assert.jsonObjectHaveKey(paramIn, "ownerTypeCd", "请求报文中未包含类型");
         Assert.jsonObjectHaveKey(paramIn, "communityId", "请求报文中未包含communityId");
         Assert.jsonObjectHaveKey(paramIn, "idCard", "请求报文中未包含身份证号");
 

+ 2 - 0
UserService/src/main/java/com/java110/user/listener/owner/AbstractOwnerBusinessServiceDataFlowListener.java

@@ -49,6 +49,7 @@ public abstract class AbstractOwnerBusinessServiceDataFlowListener extends Abstr
         businessOwnerInfo.put("ownerTypeCd", businessOwnerInfo.get("owner_type_cd"));
         businessOwnerInfo.put("communityId", businessOwnerInfo.get("community_id"));
         businessOwnerInfo.put("idCard", businessOwnerInfo.get("id_card"));
+        businessOwnerInfo.put("state", businessOwnerInfo.get("state"));
         businessOwnerInfo.remove("bId");
         businessOwnerInfo.put("statusCd", statusCd);
     }
@@ -85,6 +86,7 @@ public abstract class AbstractOwnerBusinessServiceDataFlowListener extends Abstr
         currentOwnerInfo.put("ownerTypeCd", currentOwnerInfo.get("owner_type_cd"));
         currentOwnerInfo.put("communityId", currentOwnerInfo.get("community_id"));
         currentOwnerInfo.put("idCard", currentOwnerInfo.get("id_card"));
+        currentOwnerInfo.put("state", currentOwnerInfo.get("state"));
 
 
         currentOwnerInfo.put("operate", StatusConstant.OPERATE_DEL);

+ 1 - 0
WebService/src/main/resources/components/communityPackage/audit-community-manage/auditCommunityManage.html

@@ -1,4 +1,5 @@
 <div id="component">
+
     <div class="row">
         <div class="col-lg-12">
             <div class="ibox">

+ 130 - 0
WebService/src/main/resources/components/ownerPackage/audit-applicationKey-manage/auditApplicationKeyManage.html

@@ -0,0 +1,130 @@
+<div id="component">
+    <div class="row">
+        <div class="col-lg-12">
+            <div class="ibox ">
+                <div class="ibox-title">
+                    <h5>查询条件</h5>
+                    <div class="ibox-tools" style="top:10px;">
+                        <button type="button" class="btn btn-link btn-sm" style="margin-right:10px;"
+                                v-on:click="_moreCondition()">{{auditApplicationKeyManageInfo.moreCondition == true?'隐藏':'更多'}}
+                        </button>
+                    </div>
+                </div>
+                <div class="ibox-content">
+                    <div class="row">
+
+                        <div class="col-sm-4">
+                            <div class="form-group">
+                                <input type="text" placeholder="请输入姓名"
+                                       v-model="auditApplicationKeyManageInfo.conditions.name" class=" form-control">
+                            </div>
+                        </div>
+                        <div class="col-sm-3">
+                            <div class="form-group">
+                                <input type="text" placeholder="请输入手机号码"
+                                       v-model="auditApplicationKeyManageInfo.conditions.tel" class=" form-control">
+                            </div>
+                        </div>
+                        <div class="col-sm-4">
+                            <div class="form-group">
+                                <input type="number" placeholder="请输入用户类型"
+                                       v-model="auditApplicationKeyManageInfo.conditions.typeCd" class=" form-control">
+                            </div>
+                        </div>
+
+                        <div class="col-sm-1">
+                            <button type="button" class="btn btn-primary btn-sm" v-on:click="_queryOwnerMethod()"><i
+                                    class="glyphicon glyphicon-search"></i> 查询
+                            </button>
+                        </div>
+
+                    </div>
+                    <div class="row" v-if="auditApplicationKeyManageInfo.moreCondition == true">
+                        <div class="col-sm-4">
+                            <div class="form-group">
+                                <input type="number" placeholder="请输入用户类型"
+                                       v-model="auditApplicationKeyManageInfo.conditions.typeCd" class=" form-control">
+                            </div>
+                        </div>
+                        <div class="col-sm-4">
+                            <div class="form-group">
+                                <input type="text" placeholder="请输入身份证号"
+                                       v-model="auditApplicationKeyManageInfo.conditions.idCard" class=" form-control">
+                            </div>
+                        </div>
+
+
+                    </div>
+
+
+                </div>
+            </div>
+        </div>
+    </div>
+    <div class="row">
+        <div class="col-lg-12">
+            <div class="ibox">
+                <div class="ibox-title">
+                    <h5>审核钥匙</h5>
+                    <div class="ibox-tools" style="top:10px;">
+
+                    </div>
+                </div>
+                <div class="ibox-content">
+
+                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
+                        <thead>
+                        <tr>
+                            <th>姓名</th>
+                            <th>手机号码</th>
+                            <th>用户类型</th>
+                            <th>身份证号</th>
+                            <th>所属位置</th>
+                            <th>具体位置</th>
+                            <th>申请时间</th>
+                            <th>结束时间</th>
+                            <th>状态</th>
+                            <th class="text-right">操作</th>
+                        </tr>
+                        </thead>
+                        <tbody>
+                        <tr v-for="applicationKey in auditApplicationKeyManageInfo.applicationKeys">
+                            <td>{{applicationKey.name}}</td>
+                            <td>{{applicationKey.tel}}</td>
+                            <td>{{applicationKey.typeCd}}</td>
+                            <td>{{applicationKey.idCard}}</td>
+                            <td>{{applicationKey.locationTypeName}}</td>
+                            <td>{{applicationKey.locationObjName}}</td>
+                            <td>{{applicationKey.startTime}}</td>
+                            <td>{{applicationKey.endTime}}</td>
+                            <td>{{applicationKey.stateName}}</td>
+                            <td>
+                                <div class="btn-group">
+                                    <button class="btn-white btn btn-xs"
+                                            v-on:click="_openAuditApplicationKeyModal(applicationKey)">审核
+                                    </button>
+                                </div>
+
+
+                        </tr>
+                        </tbody>
+                        <tfoot>
+                        <tr>
+                            <td colspan="7">
+                                <ul class="pagination float-right"></ul>
+                            </td>
+                        </tr>
+                        </tfoot>
+                    </table>
+                    <!-- 分页 -->
+                    <vc:create name="pagination"></vc:create>
+                </div>
+            </div>
+        </div>
+    </div>
+    <vc:create name="audit"
+               callBackListener="auditApplicationKeyManage"
+               callBackFunction="notifyAuditInfo"
+    ></vc:create>
+
+</div>

+ 94 - 0
WebService/src/main/resources/components/ownerPackage/audit-applicationKey-manage/auditApplicationKeyManage.js

@@ -0,0 +1,94 @@
+/**
+    入驻小区
+**/
+(function(vc){
+    var DEFAULT_PAGE = 1;
+    var DEFAULT_ROWS = 10;
+    vc.extends({
+        data:{
+            auditApplicationKeyManageInfo:{
+                applicationKeys:[],
+                total:0,
+                records:1,
+                currentApplicationKeyId:'',
+                moreCondition:false,
+                conditions:{
+                    name:'',
+                    tel:'',
+                    typeCd:'',
+                    idCard:''
+                }
+            }
+        },
+        _initMethod:function(){
+            vc.component._listApplicationKeys(DEFAULT_PAGE, DEFAULT_ROWS);
+        },
+        _initEvent:function(){
+            vc.on('auditApplicationKeyManage','listApplicationKey',function(_param){
+                  vc.component._listApplicationKeys(DEFAULT_PAGE, DEFAULT_ROWS);
+            });
+            vc.on('auditApplicationKeyManage','notifyAuditInfo',function(_auditInfo){
+                  vc.component._auditApplicationKeyState(_auditInfo);
+            });
+             vc.on('pagination','page_event',function(_currentPage){
+                vc.component._listApplicationKeys(_currentPage,DEFAULT_ROWS);
+            });
+        },
+        methods:{
+            _listApplicationKeys:function(_page, _rows){
+                var param = {
+                    params:{
+                        page:_page,
+                        row:_rows
+                    }
+
+               }
+               //发送get请求
+               vc.http.get('auditApplicationKeyManage',
+                            'list',
+                             param,
+                             function(json,res){
+                                var _auditApplicationKeyManageInfo=JSON.parse(json);
+                                vc.component.auditApplicationKeyManageInfo.total = _auditApplicationKeyManageInfo.total;
+                                vc.component.auditApplicationKeyManageInfo.records = _auditApplicationKeyManageInfo.records;
+                                vc.component.auditApplicationKeyManageInfo.applicationKeys = _auditApplicationKeyManageInfo.applicationKeys;
+                                vc.emit('pagination','init',{
+                                    total:vc.component.auditApplicationKeyManageInfo.records,
+                                    currentPage:_page
+                                });
+                             },function(errInfo,error){
+                                console.log('请求失败处理');
+                             }
+                           );
+            },
+            _openAuditApplicationKeyModal:function(_applicationKey){
+                vc.component.auditApplicationKeyManageInfo.currentApplicationKeyId = _applicationKey.applicationKeyId;
+                vc.emit('audit','openAuditModal',{});
+            },
+            _auditApplicationKeyState:function(_auditInfo){
+                _auditInfo.applicationKeyId = vc.component.auditApplicationKeyManageInfo.currentApplicationKeyId;
+                vc.http.post(
+                    'auditApplicationKeyManage',
+                    'audit',
+                    JSON.stringify(_auditInfo),
+                    {
+                        emulateJSON:true
+                     },
+                     function(json,res){
+                        //vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
+                        if(res.status == 200){
+                            //关闭model
+                             vc.component._listApplicationKeys(DEFAULT_PAGE, DEFAULT_ROWS);
+                            return ;
+                        }
+                        vc.message(json);
+                     },
+                     function(errInfo,error){
+                        console.log('请求失败处理');
+                        vc.message(errInfo);
+                });
+            }
+
+        }
+    });
+})(window.vc);

+ 24 - 7
java110-db/src/main/resources/mapper/user/OwnerServiceDaoImplMapper.xml

@@ -7,9 +7,9 @@
     <!-- 保存业主信息 add by wuxw 2018-07-03 -->
     <insert id="saveBusinessOwnerInfo" parameterType="Map">
         insert into business_building_owner(
-        operate,sex,name,link,remark,owner_id,b_id,user_id,age,member_id,owner_type_cd,community_id,id_card
+        operate,sex,name,link,remark,owner_id,b_id,user_id,age,member_id,owner_type_cd,community_id,id_card,state
         ) values (
-        #{operate},#{sex},#{name},#{link},#{remark},#{ownerId},#{bId},#{userId},#{age},#{memberId},#{ownerTypeCd},#{communityId},#{idCard}
+        #{operate},#{sex},#{name},#{link},#{remark},#{ownerId},#{bId},#{userId},#{age},#{memberId},#{ownerTypeCd},#{communityId},#{idCard},#{state}
         )
     </insert>
 
@@ -19,7 +19,7 @@
         select t.operate,t.sex,t.name,t.link,t.remark,t.owner_id,t.owner_id ownerId,t.b_id,t.b_id bId,
         t.user_id,t.user_id userId,t.age,t.member_id,t.member_id memberId,t.owner_type_cd,
         t.owner_type_cd ownerTypeCd,t.community_id,t.community_id communityId,
-        t.id_card, t.id_card idCard
+        t.id_card, t.id_card idCard,t.state
         from business_building_owner t
         where 1 =1
         <if test="operate !=null and operate != ''">
@@ -55,6 +55,9 @@
         <if test="age !=null and age != ''">
             and t.age= #{age}
         </if>
+        <if test="state !=null and state != ''">
+            and t.state= #{state}
+        </if>
         <if test="memberId !=null and memberId != ''">
             and t.member_id= #{memberId}
         </if>
@@ -68,9 +71,9 @@
     <!-- 保存业主信息至 instance表中 add by wuxw 2018-07-03 -->
     <insert id="saveOwnerInfoInstance" parameterType="Map">
         insert into building_owner(
-        sex,name,link,status_cd,remark,owner_id,b_id,user_id,age,member_id,owner_type_cd,community_id,id_card
+        sex,name,link,status_cd,remark,owner_id,b_id,user_id,age,member_id,owner_type_cd,community_id,id_card,state
         ) select t.sex,t.name,t.link,'0',t.remark,t.owner_id,t.b_id,t.user_id,t.age,t.member_id,t.owner_type_cd,
-        t.community_id communityId,t.id_card
+        t.community_id communityId,t.id_card,state
         from business_building_owner t where 1=1
         and t.operate= 'ADD'
         <if test="sex !=null">
@@ -109,7 +112,9 @@
         <if test="ownerTypeCd !=null and ownerTypeCd != ''">
             and t.owner_type_cd= #{ownerTypeCd}
         </if>
-
+        <if test="state !=null and state != ''">
+            and t.state= #{state}
+        </if>
     </insert>
 
 
@@ -119,7 +124,7 @@
         t.owner_id,t.owner_id ownerId,t.b_id,t.b_id bId,
         t.user_id,t.user_id userId,t.age,t.member_id,t.member_id memberId,t.owner_type_cd,
         t.owner_type_cd ownerTypeCd,t.create_time createTime,t.community_id,
-        t.community_id communityId,t.id_card, t.id_card idCard
+        t.community_id communityId,t.id_card, t.id_card idCard,t.state
         from building_owner t
         where 1 =1
         <if test="sex !=null">
@@ -155,6 +160,9 @@
         <if test="age !=null and age != ''">
             and t.age= #{age}
         </if>
+        <if test="state !=null and state != ''">
+            and t.state= #{state}
+        </if>
         <if test="memberId !=null and memberId != ''">
             and t.member_id= #{memberId}
         </if>
@@ -211,6 +219,9 @@
         <if test="age !=null and age != ''">
             and t.age= #{age}
         </if>
+        <if test="state !=null and state != ''">
+            and t.state= #{state}
+        </if>
         <if test="memberId !=null and memberId != ''">
             and t.member_id= #{memberId}
         </if>
@@ -254,6 +265,9 @@
         <if test="age !=null and age != ''">
             , t.age= #{age}
         </if>
+        <if test="state !=null and state != ''">
+            , t.state= #{state}
+        </if>
         <if test="idCard !=null and idCard != ''">
             , t.id_card = #{idCard}
         </if>
@@ -308,6 +322,9 @@
         <if test="age !=null and age != ''">
             and t.age= #{age}
         </if>
+        <if test="state !=null and state != ''">
+            and t.state= #{state}
+        </if>
         <if test="memberId !=null and memberId != ''">
             and t.member_id= #{memberId}
         </if>

+ 2 - 0
java110-utils/src/main/java/com/java110/utils/constant/ServiceCodeConstant.java

@@ -425,6 +425,8 @@ public class ServiceCodeConstant {
     // 保存业主信息
     public static final String SERVICE_CODE_SAVE_OWNER = "owner.saveOwner";
 
+    public static final String SERVICE_CODE_APPLICATION_KEY = "owner.applicationKey";
+
     // 编辑业主信息
     public static final String SERVICE_CODE_EDIT_OWNER = "owner.editOwner";