Commit 3c56cf65bb537661fca3cc7d4bfa37b42c9e81a5
1 parent
5544f66bda
Exists in
master
and in
6 other branches
1
Showing 1 changed file with 13 additions and 8 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/RiskReportFacade.java
View file @
3c56cf6
| ... | ... | @@ -766,26 +766,31 @@ |
| 766 | 766 | if (countRequest.getAgeRange() != null && countRequest.getAgeRange() != 0) { |
| 767 | 767 | int s = 0; |
| 768 | 768 | int e = 0; |
| 769 | + int d=0; | |
| 769 | 770 | if (countRequest.getAgeRange() == 1) { |
| 770 | 771 | s = 0; |
| 771 | 772 | e = 21; |
| 773 | + d=1; | |
| 772 | 774 | } else if (countRequest.getAgeRange() == 2) { |
| 773 | - s = 22; | |
| 774 | - e = 31; | |
| 775 | + s = 21; | |
| 776 | + e = 30; | |
| 777 | + d=0; | |
| 775 | 778 | } else if (countRequest.getAgeRange() == 3) { |
| 776 | - s = 32; | |
| 779 | + s = 30; | |
| 777 | 780 | e = 41; |
| 781 | + d=1; | |
| 778 | 782 | } else if (countRequest.getAgeRange() == 4) { |
| 779 | - s = 42; | |
| 783 | + s = 41; | |
| 780 | 784 | e = 100; |
| 785 | + d=0; | |
| 781 | 786 | } |
| 782 | 787 | |
| 783 | 788 | Date start = DateUtil.addYear(currentDate, -s); |
| 784 | - patientsQuery.setBirthEnd(start); | |
| 785 | - System.out.println(DateUtil.getyyyy_MM_dd(start)); | |
| 789 | + patientsQuery.setBirthEnd(DateUtil.addDay(start,d)); | |
| 790 | + System.out.println(DateUtil.getyyyy_MM_dd(DateUtil.addDay(start,d))); | |
| 786 | 791 | Date end = DateUtil.addYear(currentDate, -e); |
| 787 | - patientsQuery.setBirthStart(DateUtil.addDay(end,1)); | |
| 788 | - System.out.println(DateUtil.getyyyy_MM_dd(DateUtil.addDay(end,1))); | |
| 792 | + patientsQuery.setBirthStart(DateUtil.addDay(end,d)); | |
| 793 | + System.out.println(DateUtil.getyyyy_MM_dd(DateUtil.addDay(end,d))); | |
| 789 | 794 | |
| 790 | 795 | } |
| 791 | 796 |