|
@ -322,8 +322,12 @@ public class StatisticsAllService extends BaseService {
|
|
|
|
|
|
int num = 0;
|
|
int num = 0;
|
|
int taskNum = 0;
|
|
int taskNum = 0;
|
|
String redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
|
|
|
|
|
|
String redisNum = "";
|
|
|
|
try {
|
|
|
|
redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
}catch (Exception e){
|
|
|
|
redisNum = "";
|
|
|
|
}
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
if (peopleNum != null) {
|
|
if (peopleNum != null) {
|
|
@ -397,8 +401,12 @@ public class StatisticsAllService extends BaseService {
|
|
map.put("amount", map.get("amount") != null ? Long.valueOf(map.get("amount").toString()) : 0L);
|
|
map.put("amount", map.get("amount") != null ? Long.valueOf(map.get("amount").toString()) : 0L);
|
|
|
|
|
|
if (!low_level.equals("1")) {
|
|
if (!low_level.equals("1")) {
|
|
String redisNum = redisTemplate.opsForValue().get("people:num:" + map.get("code").toString());
|
|
|
|
|
|
|
|
|
|
String redisNum = "";
|
|
|
|
try {
|
|
|
|
redisNum = redisTemplate.opsForValue().get("people:num:" + map.get("code").toString());
|
|
|
|
}catch (Exception e){
|
|
|
|
redisNum = "";
|
|
|
|
}
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(map.get("code").toString(), Calendar.getInstance().get(Calendar.YEAR));
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(map.get("code").toString(), Calendar.getInstance().get(Calendar.YEAR));
|
|
if (peopleNum != null) {
|
|
if (peopleNum != null) {
|
|
@ -502,8 +510,12 @@ public class StatisticsAllService extends BaseService {
|
|
map.put("amount", map.get("amount") != null ? Long.valueOf(map.get("amount").toString()) : 0L);
|
|
map.put("amount", map.get("amount") != null ? Long.valueOf(map.get("amount").toString()) : 0L);
|
|
|
|
|
|
if (!low_level.equals("1")) {
|
|
if (!low_level.equals("1")) {
|
|
String redisNum = redisTemplate.opsForValue().get("people:num:" + map.get("code").toString());
|
|
|
|
|
|
|
|
|
|
String redisNum = "";
|
|
|
|
try {
|
|
|
|
redisNum = redisTemplate.opsForValue().get("people:num:" + map.get("code").toString());
|
|
|
|
}catch (Exception e){
|
|
|
|
redisNum = "";
|
|
|
|
}
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(map.get("code").toString(), Calendar.getInstance().get(Calendar.YEAR));
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(map.get("code").toString(), Calendar.getInstance().get(Calendar.YEAR));
|
|
if (peopleNum != null) {
|
|
if (peopleNum != null) {
|
|
@ -1407,7 +1419,12 @@ public class StatisticsAllService extends BaseService {
|
|
JSONObject json = new JSONObject();
|
|
JSONObject json = new JSONObject();
|
|
|
|
|
|
if (level > 1 && StringUtils.isEmpty(lowCode)) {
|
|
if (level > 1 && StringUtils.isEmpty(lowCode)) {
|
|
String redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
|
|
String redisNum = "";
|
|
|
|
try {
|
|
|
|
redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
}catch (Exception e){
|
|
|
|
redisNum = "";
|
|
|
|
}
|
|
|
|
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
@ -1422,8 +1439,12 @@ public class StatisticsAllService extends BaseService {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (!StringUtils.isEmpty(lowCode)) {
|
|
if (!StringUtils.isEmpty(lowCode)) {
|
|
String redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
|
|
|
|
|
|
String redisNum = "";
|
|
|
|
try {
|
|
|
|
redisNum = redisTemplate.opsForValue().get("people:num:" + area);
|
|
|
|
}catch (Exception e){
|
|
|
|
redisNum = "";
|
|
|
|
}
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
if (StringUtils.isEmpty(redisNum)) {
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
PopulationBase peopleNum = peopleNumDao.findByCodeAndYear(area, Calendar.getInstance().get(Calendar.YEAR));
|
|
if (peopleNum != null) {
|
|
if (peopleNum != null) {
|