public DataKPI11 SetEndDate([FromRoute] string userId, [FromBody] DateYTD start, [FromServices] DatabaseContext dc) { var d = GetActualFiltersForUser(userId); d.EndDate = start; d.EndDate.GenerateId(); return(d); }
public static DateYTD operator +(DateYTD op, int nrMonths) { var dt = new DateYTD(); dt.Year = op.Year; dt.Month = op.Month; dt.Month += nrMonths; while (dt.Month > 12) { dt.Month = dt.Month - 12; dt.Year++; } dt.GenerateId(); return(dt); }