| | |
| | | package com.zy.erp.kingdee.utils; |
| | | |
| | | import java.text.ParseException; |
| | | import java.text.SimpleDateFormat; |
| | | import java.time.LocalDateTime; |
| | | import java.time.format.DateTimeFormatter; |
| | | import java.util.Date; |
| | | |
| | | public class KingDeeUtil { |
| | | |
| | | //对美国时间进行转换 |
| | | public static Date KingDeeDate(String jsonArrayDate) throws ParseException { |
| | | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); |
| | | |
| | | DateTimeFormatter dateFormat = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss.SSS"); |
| | | DateTimeFormatter formatter = DateTimeFormatter.ISO_LOCAL_DATE_TIME; |
| | | LocalDateTime dateTime = LocalDateTime.parse(jsonArrayDate, formatter); |
| | | String format = dateFormat.format(dateTime); |
| | | return sdf.parse(format); |
| | | } |
| | | |
| | | |
| | | |
| | | } |