Beispiel #1
0
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            sales_collector sales_collector = _collectorService.GetById(id);

            if (sales_collector == null)
            {
                return(HttpNotFound());
            }

            ViewBag.collector_sales_person_id = new SelectList(_employeeService.GetAll().Where(e => e.deleted != true), "emp_id", "emp_code");
            ViewBag.collector_profession_id   = new SelectList(_professionService.GetAll().Where(e => e.deleted != true).OrderByDescending(p => p.profession_id), "profession_id", "profession_name");
            ViewBag.collector_branch_id       = new SelectList(_branchService.GetAll(), "branch_id", "branch_name");

            return(View(sales_collector));
        }