MonthlyTimeSegment.cs 601 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 OASystem.Domain.ViewModels.Statistics
  7. {
  8. public class MonthlyTimeSegment
  9. {
  10. public DateTime Start { get; private set; }
  11. public DateTime End { get; private set; }
  12. public MonthlyTimeSegment(int year, int month)
  13. {
  14. DateTime startOfMonth = new DateTime(year, month, 1);
  15. DateTime endOfMonth = startOfMonth.AddMonths(1).AddDays(-1);
  16. Start = startOfMonth;
  17. End = endOfMonth;
  18. }
  19. }
  20. }