Beispiel #1
0
        public ActionResult ListItems()
        {
            var year  = Request["year"];
            var y     = string.IsNullOrEmpty(year) ? DateTime.Now.Year : int.Parse(year);
            var model = new ModelGeneralVoteItem
            {
                ListItems    = _api.GeneralListTotal(y, UserItem.AgencyID),
                LstMonthItem = ConvertDateItem.ListMonthinYear(y),
                ListUser     = _userApi.GetListSimple(UserItem.AgencyID)
            };

            return(View(model));
        }
		public ActionResult ListItems(int month = 0, int year = 0)
		{
			if (month == 0 || year == 0)
			{
				month = DateTime.Now.Month;
				year = DateTime.Now.Year;
			}
			var model = new ModelDNUserTimeJobItem
			{
				ListItems = _timeJob.GetAllByMonth(month, year, UserItem.AgencyID),
				DayItems = ConvertDateItem.ListDayInMonth(new DateTime(year, month, 1))
			};
			return View(model);
		}