update 使@Translation注解生效
This commit is contained in:
+3
-2
@@ -36,8 +36,9 @@ public class SysDictItemServiceImpl extends ServiceImpl<SysDictItemMapper, SysDi
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<SysDictItem> getDictItemAll() {
|
public List<SysDictItem> getDictItemAll() {
|
||||||
// return sysDictItemMapper.getDictItemAll();
|
//return sysDictItemMapper.getDictItemAll();
|
||||||
return null;
|
return sysDictItemMapper.selectItemsAll();
|
||||||
|
//return null;
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* 查询所有数据字典信息
|
* 查询所有数据字典信息
|
||||||
|
|||||||
@@ -108,6 +108,7 @@ public class LawsNewsFeed implements Serializable {
|
|||||||
|
|
||||||
@ApiModelProperty(value = "推送范围")
|
@ApiModelProperty(value = "推送范围")
|
||||||
@TableField(exist = false)
|
@TableField(exist = false)
|
||||||
|
@Dict(dictTable = "sys_user", dicCode = "id", dicText = "name_work_no")
|
||||||
private String pushRange;
|
private String pushRange;
|
||||||
|
|
||||||
@ApiModelProperty(value = "是否可以编辑和删除")
|
@ApiModelProperty(value = "是否可以编辑和删除")
|
||||||
|
|||||||
+12
@@ -11,7 +11,9 @@ import com.jero.modules.laws.standard.entity.LawsPushRange;
|
|||||||
import com.jero.modules.laws.standard.mapper.LawsNewsFeedMapper;
|
import com.jero.modules.laws.standard.mapper.LawsNewsFeedMapper;
|
||||||
import com.jero.modules.laws.standard.service.ILawsNewsFeedService;
|
import com.jero.modules.laws.standard.service.ILawsNewsFeedService;
|
||||||
import com.jero.modules.laws.standard.service.ILawsPushRangeService;
|
import com.jero.modules.laws.standard.service.ILawsPushRangeService;
|
||||||
|
import com.jero.modules.system.entity.SysUser;
|
||||||
import com.spire.ms.System.Collections.ArrayList;
|
import com.spire.ms.System.Collections.ArrayList;
|
||||||
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
import org.apache.shiro.SecurityUtils;
|
import org.apache.shiro.SecurityUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
@@ -218,6 +220,16 @@ public class LawsNewsFeedServiceImpl extends ServiceImpl<LawsNewsFeedMapper, Law
|
|||||||
lawsNewsFeed.setReadCount(lawsNewsFeed.getReadCount() + 1);
|
lawsNewsFeed.setReadCount(lawsNewsFeed.getReadCount() + 1);
|
||||||
updateById(lawsNewsFeed);
|
updateById(lawsNewsFeed);
|
||||||
}
|
}
|
||||||
|
// 如果是指定用户推送
|
||||||
|
if (1 == lawsNewsFeed.getPushRangeFlag()) {
|
||||||
|
LambdaQueryWrapper<LawsPushRange> queryWrapper = new LambdaQueryWrapper<>();
|
||||||
|
queryWrapper.eq(LawsPushRange::getUniqueRelationFlag, id);
|
||||||
|
List<LawsPushRange> pushRangeList = lawsPushRangeService.list(queryWrapper);
|
||||||
|
if (CollectionUtils.isNotEmpty(pushRangeList)) {
|
||||||
|
List<String> userIdList = pushRangeList.stream().map(LawsPushRange::getUserId).collect(Collectors.toList());
|
||||||
|
lawsNewsFeed.setPushRange(StringUtils.join(userIdList, ","));
|
||||||
|
}
|
||||||
|
}
|
||||||
return lawsNewsFeed;
|
return lawsNewsFeed;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user