public IActionResult Index()
        {
            int HaftaNo(DateTime Tarih)
            {
                DayOfWeek day = CultureInfo.InvariantCulture.Calendar.GetDayOfWeek(Tarih);

                if (day >= DayOfWeek.Monday && day <= DayOfWeek.Wednesday)
                {
                    Tarih = Tarih.AddDays(3);
                }
                return(CultureInfo.InvariantCulture.Calendar.GetWeekOfYear(Tarih, CalendarWeekRule.FirstFourDayWeek, DayOfWeek.Monday));
            }

            var result = sevkiyatManager.GunlukSevkiyatlariListele(DateTime.Now.Year, HaftaNo(DateTime.Now), (int)DateTime.Now.DayOfWeek);

            return(View(result));
        }
Пример #2
0
        public ActionResult Ara(int haftaNo, int yil, int gun)
        {
            int HaftaNo(DateTime Tarih)
            {
                DayOfWeek day = CultureInfo.InvariantCulture.Calendar.GetDayOfWeek(Tarih);

                if (day >= DayOfWeek.Monday && day <= DayOfWeek.Wednesday)
                {
                    Tarih = Tarih.AddDays(3);
                }
                return(CultureInfo.InvariantCulture.Calendar.GetWeekOfYear(Tarih, CalendarWeekRule.FirstFourDayWeek, DayOfWeek.Monday));
            }

            var result = sevkiyatManager.GunlukSevkiyatlariListele(yil, haftaNo, gun);

            return(View(result));
        }