//отображение списка компаний public ActionResult Index() { Selects sel = new Selects(); ViewBag.New = sel.SelectCompanies(); return(View()); }
//отображение формы добавления работника public ActionResult FormAddWorker() { Selects sel = new Selects(); ViewBag.positions = sel.SelectPositions(); ViewBag.companies = sel.SelectCompanies(); return(View()); }
public ActionResult FormUpWorker(int id, string first_name, string last_name, string patronymic, string date_of_registration, string position_id, string company_id) { Selects sel = new Selects(); ViewBag.positions = sel.SelectPositions(); ViewBag.companies = sel.SelectCompanies(); ViewBag.id_w = id; ViewBag.first_w = first_name; ViewBag.last_w = last_name; ViewBag.pat_w = patronymic; ViewBag.date_w = DateTime.Parse(date_of_registration).Date; ViewBag.pos_w = position_id; ViewBag.com_id = company_id; return(View()); }