Example #1
0
        // GET: Search
        public ActionResult Index()
        {
            string userName = User.Identity.Name.Substring(5);


            API.UsersController usersController = new API.UsersController();

            Models.User userDetails = usersController.Get(userName);

            ViewBag.UserId = userDetails.userId;


            return(View());
        }
        // GET: Incidents
        public ActionResult Index()
        {
            string userName      = User.Identity.Name.Substring(5);
            string userIpAddress = Request.UserHostName;



            API.UsersController usersController = new API.UsersController();

            Models.User userDetails = usersController.Get(userName);

            ViewBag.UserId      = userDetails.userId;
            ViewBag.StaffName   = userDetails.firstName + " " + userDetails.lastName;
            ViewBag.StaffTitle  = userDetails.jobTitle;
            ViewBag.StaffEmail  = userDetails.eMail;
            ViewBag.StationName = Helpers.Converters.GetComputerName(userIpAddress);

            return(View());
        }
Example #3
0
        // GET: Home
        public ActionResult Index()
        {
            string userName = User.Identity.Name.Substring(5);


            API.UsersController usersController = new API.UsersController();

            Models.User userDetails = usersController.Get(userName);
            usersController.Dispose();

            ViewBag.UserId   = userDetails.userId;
            ViewBag.Greeting = userDetails.firstName;


            System.Web.HttpBrowserCapabilitiesBase browser = Request.Browser;

            ViewBag.Browser = browser.Browser;

            return(View());
        }