生产管理

This commit is contained in:
qianhao.xu
2024-12-03 14:35:59 +08:00
parent 5e522c6e00
commit aab3a3b58d
41 changed files with 4616 additions and 2 deletions

View File

@@ -0,0 +1,38 @@
using System;
namespace Infrastructure.Converter;
public class DOANConvertDate
{
/// <summary>
/// 日期转本地日期
/// </summary>
/// <param name="handleDate"></param>
/// <returns></returns>
public static DateTime ConvertLocalDate(DateTime handleDate)
{
if (handleDate.Kind == DateTimeKind.Utc)
{
handleDate = handleDate.ToLocalTime();
}
return handleDate.Date;
}
/// <summary>
/// 日期转本地日期
/// </summary>
/// <param name="handleDate"></param>
/// <returns></returns>
public static DateTime ConvertLocalDateTime(DateTime handleDate)
{
if (handleDate.Kind == DateTimeKind.Utc)
{
handleDate = handleDate.ToLocalTime();
}
return handleDate;
}
}