|
|
@ -11,6 +11,7 @@ import java.time.LocalDate; |
|
|
|
import java.time.LocalDateTime; |
|
|
|
import java.time.LocalTime; |
|
|
|
import java.time.ZoneId; |
|
|
|
import java.time.temporal.TemporalAdjusters; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Date; |
|
|
|
import java.util.HashMap; |
|
|
@ -31,12 +32,14 @@ public class BsSgcEquipmentMonitoringService extends BaseService<BsSgcEquipmentM |
|
|
|
|
|
|
|
public List<HashMap> getMaterialOutputStatistics(String proNo, String timeType) { |
|
|
|
LocalDateTime start = null; |
|
|
|
LocalDateTime now = LocalDate.now().atStartOfDay(); |
|
|
|
LocalDateTime now = null; |
|
|
|
if(timeType.equals("1")){ //年
|
|
|
|
start = LocalDate.now().withDayOfYear(1).atStartOfDay(); |
|
|
|
timeType = "M"; |
|
|
|
now = LocalDate.now().with(TemporalAdjusters.lastDayOfYear()).atTime(LocalTime.MAX); |
|
|
|
timeType = "m"; |
|
|
|
}else if(timeType.equals("2")){ //月
|
|
|
|
start = LocalDate.now().withDayOfMonth(1).atStartOfDay(); |
|
|
|
now = LocalDate.now().with(TemporalAdjusters.lastDayOfMonth()).atTime(LocalTime.MAX); |
|
|
|
timeType = "d"; |
|
|
|
}else if(timeType.equals("3")){ //日
|
|
|
|
LocalDate today = LocalDate.now(); |
|
|
|