package com.test.jyj.shared.util;
import java.time.LocalDateTime;
public class DateTimeFormatter {
public static String LocalDateTimeToYYYYmmDD(LocalDateTime selectedDate) {
return selectedDate.format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd"));
}
public static String LocalDateTimeToYYYYmmDDHHmmSS(LocalDateTime selectedDate) {
return selectedDate.format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd hh:mm:ss"));
}
public static String LocalDateTimeToYYYYmmDDHHmm(LocalDateTime selectedDate) {
return selectedDate.format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd hh:mm"));
}
}