DateTimeTool.cs 591 B

1234567891011121314151617181920212223
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace Y.Utils.BaseUtils
  7. {
  8. public class DateTimeTool
  9. {
  10. public static DateTime TodayDate()
  11. {
  12. DateTime today = DateTime.Now;
  13. DateTime result = new DateTime(today.Year, today.Month, today.Day);
  14. return result;
  15. }
  16. public static DateTime TodayDate(DateTime today)
  17. {
  18. DateTime result = new DateTime(today.Year, today.Month, today.Day);
  19. return result;
  20. }
  21. }
  22. }