|
@@ -66,6 +66,7 @@ class QualityIndicatorJobParameter{
|
|
|
|
|
|
|
|
public String checkMonth(){
|
|
public String checkMonth(){
|
|
|
LocalDate nowDate = LocalDate.now();
|
|
LocalDate nowDate = LocalDate.now();
|
|
|
|
|
+// nowDate = nowDate.minusMonths(5);
|
|
|
if(nowDate.getDayOfMonth()>= month[1]){
|
|
if(nowDate.getDayOfMonth()>= month[1]){
|
|
|
nowDate = nowDate.minusMonths(1);
|
|
nowDate = nowDate.minusMonths(1);
|
|
|
return nowDate.format(DateTimeFormatter.ofPattern("yyyy年M月份"));
|
|
return nowDate.format(DateTimeFormatter.ofPattern("yyyy年M月份"));
|
|
@@ -75,6 +76,7 @@ class QualityIndicatorJobParameter{
|
|
|
|
|
|
|
|
public String checkQuarter(){
|
|
public String checkQuarter(){
|
|
|
LocalDate nowDate = LocalDate.now();
|
|
LocalDate nowDate = LocalDate.now();
|
|
|
|
|
+// nowDate = nowDate.minusMonths(5);
|
|
|
int monthNum = nowDate.getMonthValue();
|
|
int monthNum = nowDate.getMonthValue();
|
|
|
LocalDate firstDayOfQuarter;
|
|
LocalDate firstDayOfQuarter;
|
|
|
if (monthNum <= 3) {
|
|
if (monthNum <= 3) {
|
|
@@ -94,13 +96,14 @@ class QualityIndicatorJobParameter{
|
|
|
}
|
|
}
|
|
|
if(nowDate.compareTo(firstDayOfQuarter)>=0){
|
|
if(nowDate.compareTo(firstDayOfQuarter)>=0){
|
|
|
nowDate = nowDate.minusMonths(3);
|
|
nowDate = nowDate.minusMonths(3);
|
|
|
- return nowDate.format(DateTimeFormatter.ofPattern("yyyy第Q季度"));
|
|
|
|
|
|
|
+ return nowDate.format(DateTimeFormatter.ofPattern("yyyy年第Q季度"));
|
|
|
}
|
|
}
|
|
|
return null;
|
|
return null;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public String checkHalfYear(){
|
|
public String checkHalfYear(){
|
|
|
LocalDate nowDate = LocalDate.now();
|
|
LocalDate nowDate = LocalDate.now();
|
|
|
|
|
+// nowDate = nowDate.minusMonths(5);
|
|
|
int monthNum = nowDate.getMonthValue();
|
|
int monthNum = nowDate.getMonthValue();
|
|
|
LocalDate firstDayOfHalfYear;
|
|
LocalDate firstDayOfHalfYear;
|
|
|
if (monthNum <= 6) {
|
|
if (monthNum <= 6) {
|
|
@@ -123,6 +126,7 @@ class QualityIndicatorJobParameter{
|
|
|
}
|
|
}
|
|
|
public String checkYear(){
|
|
public String checkYear(){
|
|
|
LocalDate nowDate = LocalDate.now();
|
|
LocalDate nowDate = LocalDate.now();
|
|
|
|
|
+// nowDate = nowDate.minusMonths(5);
|
|
|
LocalDate firstDayOfHalfYear = LocalDate.of(nowDate.getYear(), Month.JANUARY, 1);
|
|
LocalDate firstDayOfHalfYear = LocalDate.of(nowDate.getYear(), Month.JANUARY, 1);
|
|
|
if(year[0]>1) {
|
|
if(year[0]>1) {
|
|
|
firstDayOfHalfYear = firstDayOfHalfYear.plusMonths(year[0]-1);
|
|
firstDayOfHalfYear = firstDayOfHalfYear.plusMonths(year[0]-1);
|