| | |
| | | |
| | | |
| | | <sql id="selectArticle"> |
| | | select |
| | | id, |
| | | title, |
| | | type, |
| | | content, |
| | | url, |
| | | video_url, |
| | | source_id, |
| | | source_name, |
| | | article_type, |
| | | recommend, |
| | | publish, |
| | | iscomment, |
| | | view_number, |
| | | create_time, |
| | | update_time, |
| | | update_user, |
| | | create_user, |
| | | is_deleted, |
| | | article_range, |
| | | building, |
| | | unit |
| | | from |
| | | jczz_article |
| | | select id, |
| | | title, |
| | | type, |
| | | content, |
| | | url, |
| | | video_url, |
| | | source_id, |
| | | source_name, |
| | | article_type, |
| | | recommend, |
| | | publish, |
| | | iscomment, |
| | | view_number, |
| | | create_time, |
| | | update_time, |
| | | update_user, |
| | | create_user, |
| | | is_deleted, |
| | | article_range, |
| | | building, |
| | | unit |
| | | from jczz_article |
| | | </sql> |
| | | |
| | | |
| | |
| | | |
| | | <if test="article.districtId != null and article.districtId != ''"> |
| | | and (ja.article_range like concat('%',#{article.districtId},'%') |
| | | or ja.article_range is null or ja.article_range = '') |
| | | or ja.article_range is null or ja.article_range = '') |
| | | </if> |
| | | |
| | | <if test="article.userId != null"> |
| | | and (jpd.user_ids like concat('%',#{article.userId},'%') |
| | | OR jpd.user_ids IS NULL or jpd.user_ids = '') |
| | | OR jpd.user_ids IS NULL or jpd.user_ids = '') |
| | | </if> |
| | | |
| | | <if test="article.building != null and article.building != ''"> |
| | |
| | | LEFT JOIN blade_region br on br.`code` = jd.community_code |
| | | where 1=1 |
| | | and ja.is_deleted = 0 |
| | | <if test="article.propertyFlag!=null "> |
| | | <if test="article.communityName!=null and article.communityName!=''"> |
| | | and br.`village_name` like concat('%',#{article.communityName},'%') |
| | | </if> |
| | | |
| | | <if test="article.streetName!=null and article.streetName!=''"> |
| | | and br.town_name like concat('%',#{article.streetName},'%') |
| | | </if> |
| | | <if test="article.communityName!=null and article.communityName!=''"> |
| | | and br.`village_name` like concat('%',#{article.communityName},'%') |
| | | </if> |
| | | |
| | | <if test="article.streetName!=null and article.streetName!=''"> |
| | | and br.town_name like concat('%',#{article.streetName},'%') |
| | | </if> |
| | | |
| | | <if test="article.title!=null and article.title!=''"> |
| | | and ja.title like concat('%',#{article.title},'%') |
| | |
| | | <foreach collection="article.districtIdList" separator=" or article_range like" item="id">'%${id}%' |
| | | </foreach> |
| | | ) |
| | | <!-- and ja.district_id in--> |
| | | <!-- <foreach collection="article.districtIdList" index="index" item="item" open="(" separator="," close=")">--> |
| | | <!-- #{item}--> |
| | | <!-- </foreach>--> |
| | | <!-- and ja.district_id in--> |
| | | <!-- <foreach collection="article.districtIdList" index="index" item="item" open="(" separator="," close=")">--> |
| | | <!-- #{item}--> |
| | | <!-- </foreach>--> |
| | | </if> |
| | | order by ja.create_time desc |
| | | </select> |
| | |
| | | </select> |
| | | |
| | | <update id="upcomment"> |
| | | update jczz_article set iscomment = #{type} |
| | | where id in(${ids}) |
| | | update jczz_article |
| | | set iscomment = #{type} |
| | | where id in (${ids}) |
| | | </update> |
| | | |
| | | <!--个人资讯--> |
| | |
| | | @ApiModelProperty(value = "小区id") |
| | | private String districtId; |
| | | /** |
| | | * 负责人姓名 |
| | | * 负责人id |
| | | */ |
| | | @ApiModelProperty(value = "负责人id") |
| | | private String principal; |
| | |
| | | jpc.name as propertyCompanyName, |
| | | br.name communityName, |
| | | br.name streetName, |
| | | jg.grid_name |
| | | jg.grid_name, |
| | | bu.name principalName |
| | | FROM |
| | | jczz_property_company_district jpcd |
| | | LEFT JOIN jczz_district jd ON jd.id = jpcd.district_id AND jd.is_deleted = 0 |
| | |
| | | LEFT JOIN blade_region br on br.code= jd.community_code |
| | | LEFT JOIN jczz_grid_range jgr on jgr.district_code=jd.id |
| | | LEFT JOIN jczz_grid jg on jg.id = jgr.grid_id |
| | | LEFT JOIN blade_user bu on bu.id = jpcd.principal |
| | | where jpcd.is_deleted = 0 |
| | | <if test="propertyCompanyDistrict.communityName!=null and propertyCompanyDistrict.communityName!=''"> |
| | | and br.name like concat('%', #{propertyCompanyDistrict.communityName},'%') |
| | |
| | | */ |
| | | package org.springblade.modules.property.vo; |
| | | |
| | | import org.springblade.modules.property.entity.PropertyCompanyDistrictEntity; |
| | | import org.springblade.core.tool.node.INode; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import org.springblade.modules.property.entity.PropertyCompanyDistrictEntity; |
| | | |
| | | import java.util.List; |
| | | |
| | |
| | | // 机构 |
| | | private String deptId; |
| | | |
| | | /** |
| | | * 负责人名称 |
| | | */ |
| | | @ApiModelProperty(value = "负责人名称") |
| | | private String principalName; |
| | | |
| | | |
| | | } |
| | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import lombok.AllArgsConstructor; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.apache.logging.log4j.util.Strings; |
| | | import org.flowable.idm.engine.impl.persistence.entity.UserEntity; |
| | | import org.springblade.common.cache.DictCache; |
| | |
| | | @Override |
| | | public List<User> getUserInfoByPropertyId(String propertyCompanyId, String roleId) { |
| | | // 查询物业公司,获取物业公司的机构 |
| | | if(StringUtils.isBlank(propertyCompanyId)){ |
| | | return new ArrayList<>(); |
| | | } |
| | | IPropertyCompanyService bean = SpringUtil.getBean(IPropertyCompanyService.class); |
| | | PropertyCompanyEntity one = bean.getOne(Wrappers.<PropertyCompanyEntity>lambdaQuery().eq(PropertyCompanyEntity::getId, propertyCompanyId)); |
| | | return baseMapper.getUserInfoByPropertyId(one.getDeptId().toString(), roleId); |