-
Notifications
You must be signed in to change notification settings - Fork 0
/
HomeController.cs
65 lines (53 loc) · 1.57 KB
/
HomeController.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using System.Web.Security;
using Denial_Coding.BAL.Generics;
using Denial_Coding.BAL.Managers;
using Denial_Coding.BAL.ViewModels;
namespace Denial_Coding.Controllers
{
public class HomeController : Controller
{
IUserMenuService managerObj = new UserMenuManager();
public ActionResult Index()
{
return View();
}
public ActionResult About()
{
ViewBag.Message = "Your application description page.";
return View();
}
public ActionResult Contact()
{
ViewBag.Message = "Your contact page.";
return View();
}
public ActionResult Home()
{
return View(managerObj.GetProject_locationList());
}
[HttpPost]
public ActionResult LoadClientMenu(UserMenuModel model)
{
return RedirectToAction("ImportIndex", "Import", model);
}
#region SignOut
/// <summary>
/// This function used to logout from application and kill all the sessions
/// </summary>
/// <returns></returns>
public ActionResult SignOut()
{
Session[Constants.UserName] = null;
Session.Clear();
Session.Abandon();
FormsAuthentication.SignOut();
return RedirectToAction("Home");
}
#endregion
}
}