| | |
| | | HouseholdEntity householdEntity = new HouseholdEntity(); |
| | | HouseholdEntity entity = new HouseholdEntity(); |
| | | if (parameter instanceof MapperMethod.ParamMap) { |
| | | entity = (HouseholdEntity) ((MapperMethod.ParamMap) parameter).get("param1"); |
| | | if (entity != null && entity.getId() != null) { |
| | | setHouseholdInfo(householdEntity, entity); |
| | | esParam.setTableId(entity.getId().toString()); |
| | | elasticsearchDocumentService.update(esParam, entity, EsTableConstant.householdList); |
| | | try { |
| | | entity = (HouseholdEntity) ((MapperMethod.ParamMap) parameter).get("param1"); |
| | | if (entity != null && entity.getId() != null) { |
| | | setHouseholdInfo(householdEntity, entity); |
| | | esParam.setTableId(entity.getId().toString()); |
| | | elasticsearchDocumentService.update(esParam, entity, EsTableConstant.householdList); |
| | | } |
| | | } catch (Exception e) { |
| | | entity = (HouseholdEntity) ((MapperMethod.ParamMap) parameter).get("et"); |
| | | if (entity != null && entity.getId() != null) { |
| | | setHouseholdInfo(householdEntity, entity); |
| | | esParam.setTableId(entity.getId().toString()); |
| | | elasticsearchDocumentService.update(esParam, entity, EsTableConstant.householdList); |
| | | } |
| | | } |
| | | } else { |
| | | entity = (HouseholdEntity) parameter; |
| | |
| | | } |
| | | // 删除处理 |
| | | if (sqlType.equals("DELETE")) { |
| | | List<Long> list = (List<Long>) ((MapperMethod.ParamMap) parameter).get("param1"); |
| | | esParam.setTableId(list.get(0).toString()); |
| | | elasticsearchDocumentService.removeByQuery(esParam); |
| | | if (parameter instanceof MapperMethod.ParamMap) { |
| | | List<Long> list = (List<Long>) ((MapperMethod.ParamMap) parameter).get("param1"); |
| | | esParam.setTableId(list.get(0).toString()); |
| | | elasticsearchDocumentService.removeByQuery(esParam); |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | /** |
| | | * 是否删除 |
| | | */ |
| | | @TableLogic |
| | | // @TableLogic |
| | | @ApiModelProperty("是否已删除 0:否 1:是") |
| | | private Integer isDeleted; |
| | | |
| | |
| | | @TableField("volunteer_org") |
| | | private String volunteerOrg; |
| | | |
| | | |
| | | @ApiModelProperty(value = "房东名称", example = "") |
| | | @TableField("landlord_name") |
| | | private String landlordName; |
| | | |
| | | |
| | | @ApiModelProperty(value = "房东电话", example = "") |
| | | @TableField("landlord_phone") |
| | | private String landlordPhone; |
| | | |
| | | @ApiModelProperty(value = "房东身份证", example = "") |
| | | @TableField("landlord_id_card") |
| | | private String landlordIdCard; |
| | | |
| | | |
| | | } |
| | |
| | | |
| | | <include refid="filterData"/> |
| | | |
| | | order by jhr.create_time desc,jhr.id desc |
| | | order by jhr.id desc |
| | | </select> |
| | | |
| | | <!--查询房屋出租情况--> |
| | | <select id="getHouseRentalListByCode" resultMap="houseRentalTenant"> |
| | | select |
| | | jhr.*, |
| | | if(termination_time is null,if(date_format(jhr.due_time,'%Y-%m-%d') >= date_format(now(),'%Y-%m-%d'),0,1),2) as status, |
| | | jht.id as tenantId, |
| | | jht.* |
| | | select jhr.*, |
| | | if(termination_time is null, |
| | | if(date_format(jhr.due_time, '%Y-%m-%d') >= date_format(now(), '%Y-%m-%d'), 0, 1), 2) as status, |
| | | jht.id as tenantId, |
| | | jht.* |
| | | from jczz_house_rental jhr |
| | | left join jczz_household jht on jhr.id = jht.housing_rental_id and jht.is_deleted = 0 |
| | | left join jczz_household jht on jhr.id = jht.housing_rental_id and jht.is_deleted = 0 |
| | | where 1 = 1 |
| | | and jhr.is_deleted = 0 |
| | | and jhr.house_code = #{code} |
| | | and jhr.is_deleted = 0 |
| | | and jhr.house_code = #{code} |
| | | order by jhr.id desc |
| | | </select> |
| | | |
| | | <sql id="filterHouseGrid"> |
| | |
| | | <if test="household.confirmFlag != null "> |
| | | and jh.confirm_flag = #{household.confirmFlag} |
| | | </if> |
| | | <if test="household.relationship != null "> |
| | | and jh.relationship = #{household.relationship} |
| | | </if> |
| | | <if test="household.townStreetName!=null and household.townStreetName!=''"> |
| | | and jda.town_street_name like concat('%',#{household.townStreetName},'%') |
| | | </if> |
| | |
| | | jpp.confirm_notion, |
| | | br.town_name as townStreetName, |
| | | br.name as neiName, |
| | | jp.place_name, |
| | | jp.location, |
| | | jc.category_name |
| | | FROM |
| | | jczz_place_practitioner jpp |
| | |
| | | */ |
| | | private String neiName; |
| | | |
| | | @ApiModelProperty(value = "场所名称", example = "") |
| | | private String placeName; |
| | | |
| | | @ApiModelProperty(value = "场所地址", example = "") |
| | | private String location; |
| | | |
| | | } |