Esempio n. 1
0
 private void UserDaysChecked(DaysChecked d)
 {
     if (d.monday)
     {
         days.Add("Monday");
     }
     if (d.tuesday)
     {
         days.Add("Tuesday");
     }
     if (d.wednesday)
     {
         days.Add("Wednesday");
     }
     if (d.thursday)
     {
         days.Add("Thursday");
     }
     if (d.friday)
     {
         days.Add("Friday");
     }
     if (d.saturday)
     {
         days.Add("Saturday");
     }
     if (d.sunday)
     {
         days.Add("Sunday");
     }
 }
Esempio n. 2
0
        // sending Creator Information to the database and returning unique code page
        public IActionResult Page4(DaysChecked d)
        {
            // take unique code and connect to DB and check if it has been taken, if not add, if so try again
            UserDaysChecked(d);

            ViewBag.message = "Controller to View";

            foreach (var item in d.daysAvaiable)
            {
                Console.WriteLine(item);
            }
            return(View());
        }