Skip to content

Commit

Permalink
Refactoring.
Browse files Browse the repository at this point in the history
  • Loading branch information
binodnp committed Mar 1, 2017
1 parent a29fe58 commit 4689672
Show file tree
Hide file tree
Showing 38 changed files with 955 additions and 50 deletions.
1 change: 0 additions & 1 deletion Controllers/Reports/ShiftController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ namespace MixERP.HRM.Controllers.Reports
public class AttendanceReportController : DashboardController
{
[Route("dashboard/hrm/reports/attendances")]
[RestrictAnonymous]
[MenuPolicy]
public ActionResult Index()
{
Expand Down
6 changes: 6 additions & 0 deletions Controllers/Services/AttachmentController.cs
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
using System.Net;
using System.Web.Mvc;
using System.Web.UI;
using Frapid.Areas;
using Frapid.Areas.Authorization;
using Frapid.Areas.Conventions.Attachments;
using Frapid.Framework.Extensions;
using Frapid.WebsiteBuilder;
using Serilog;
using Frapid.Areas.CSRF;
using Frapid.Areas.Caching;

namespace MixERP.HRM.Controllers.Services
{
[AntiForgery]
public class AttachmentController : FrapidController
{
[RestrictAnonymous]
[Route("dashboard/hrm/services/attachments")]
[HttpPost]
public ActionResult Post()
Expand All @@ -35,7 +39,9 @@ public ActionResult Post()
}
}

[RestrictAnonymous]
[Route("dashboard/hrm/services/attachments/{*path}")]
[FrapidOutputCache(ProfileName = "StaticFile.xml", Location = OutputCacheLocation.Client)]
public ActionResult AttachmentResult(string path)
{
int width = this.Request.QueryString["width"].To<int>();
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/EducationLevelController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ namespace MixERP.HRM.Controllers.Setup
{
public class EducationLevelController : DashboardController
{
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[Route("dashboard/hrm/setup/education-levels")]
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/EmployeeTypeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class EmployeeTypeController : DashboardController
{
[Route("dashboard/hrm/setup/employee-types")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/EmploymentStatusController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class EmploymentStatusController : DashboardController
{
[Route("dashboard/hrm/setup/employment-statuses")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/ExitTypeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class ExitTypeController : DashboardController
{
[Route("dashboard/hrm/setup/exit-types")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/IdentificationTypeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class IdentificationTypeController : DashboardController
{
[Route("dashboard/hrm/setup/identification-types")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/JobTitleController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class JobTitleController : DashboardController
{
[Route("dashboard/hrm/setup/job-titles")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/LeaveBenefitController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class LeaveBenefitController : DashboardController
{
[Route("dashboard/hrm/setup/leave-benefits")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/LeaveTypeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class LeaveTypeController : DashboardController
{
[Route("dashboard/hrm/setup/leave-types")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/MaritalStatusController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class MaritalStatusController : DashboardController
{
[Route("dashboard/hrm/setup/marital-statuses")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/NationalityController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class NationalityController : DashboardController
{
[Route("dashboard/hrm/setup/nationalities")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/OfficeHourController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class OfficeHourController : DashboardController
{
[Route("dashboard/hrm/setup/office-hours")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/PayGradeController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class PayGradeController : DashboardController
{
[Route("dashboard/hrm/setup/pay-grades")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/ShiftController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class ShiftController : DashboardController
{
[Route("dashboard/hrm/setup/shifts")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Setup/SocialNetworkController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Setup
public class SocialNetworkController : DashboardController
{
[Route("dashboard/hrm/setup/social-networks")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/AttendanceController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class AttendanceController : DashboardController
{
[Route("dashboard/hrm/tasks/attendance")]
[RestrictAnonymous]
[MenuPolicy]
public async Task<ActionResult> IndexAsync()
{
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/ContractController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class ContractController : DashboardController
{
[Route("dashboard/hrm/tasks/contracts")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
7 changes: 0 additions & 7 deletions Controllers/Tasks/EmployeesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class EmployeeController: DashboardController
{
[Route("dashboard/hrm/tasks/employees")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -21,7 +20,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/tasks/employees/experiences")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
[ScrudFactory]
public ActionResult DisplayExpriences()
Expand All @@ -30,7 +28,6 @@ public ActionResult DisplayExpriences()
}

[Route("dashboard/hrm/tasks/employees/identification-details")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
[ScrudFactory]
public ActionResult DisplayIdentificationDetails()
Expand All @@ -39,7 +36,6 @@ public ActionResult DisplayIdentificationDetails()
}

[Route("dashboard/hrm/tasks/employees/leave-application")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
[ScrudFactory]
public ActionResult DisplayLeaveApplication()
Expand All @@ -48,7 +44,6 @@ public ActionResult DisplayLeaveApplication()
}

[Route("dashboard/hrm/tasks/employees/qualifications")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
[ScrudFactory]
public ActionResult DisplayQualifications()
Expand All @@ -57,7 +52,6 @@ public ActionResult DisplayQualifications()
}

[Route("dashboard/hrm/tasks/employees/social-networks")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
[ScrudFactory]
public ActionResult DisplaySocialNetworks()
Expand All @@ -66,7 +60,6 @@ public ActionResult DisplaySocialNetworks()
}

[Route("dashboard/hrm/tasks/employee-info/{employeeId}")]
[RestrictAnonymous]
[MenuPolicy(OverridePath = "/dashboard/hrm/tasks/employees")]
public async Task<ActionResult> EmployeeInfoAsync(int employeeId)
{
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/ExitController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class ExitController : DashboardController
{
[Route("dashboard/hrm/tasks/exits")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/LeaveApplicationController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class LeaveApplicationController : DashboardController
{
[Route("dashboard/hrm/tasks/leave-applications")]
[RestrictAnonymous]
[MenuPolicy]
public ActionResult Index()
{
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/ResignationController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class ResignationController : DashboardController
{
[Route("dashboard/hrm/tasks/resignations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
1 change: 0 additions & 1 deletion Controllers/Tasks/TerminationController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace MixERP.HRM.Controllers.Tasks
public class TerminationController : DashboardController
{
[Route("dashboard/hrm/tasks/terminations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand Down
2 changes: 0 additions & 2 deletions Controllers/Verifications/ContractVerificationController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace MixERP.HRM.Controllers.Verifications
public class ContractVerificationController : DashboardController
{
[Route("dashboard/hrm/verification/contracts")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -26,7 +25,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/verification/contracts")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[HttpPut]
Expand Down
2 changes: 0 additions & 2 deletions Controllers/Verifications/ExitVerificationController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace MixERP.HRM.Controllers.Verifications
public class ExitVerificationController : DashboardController
{
[Route("dashboard/hrm/verification/exits")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -26,7 +25,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/verification/exits")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[HttpPut]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace MixERP.HRM.Controllers.Verifications
public class LeaveApplicationVerificationController : DashboardController
{
[Route("dashboard/hrm/verification/leave-applications")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -26,7 +25,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/verification/leave-applications")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[HttpPut]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace MixERP.HRM.Controllers.Verifications
public class ResignationVerificationController : DashboardController
{
[Route("dashboard/hrm/verification/resignations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -26,7 +25,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/verification/resignations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[HttpPut]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace MixERP.HRM.Controllers.Verifications
public class TerminationVerificationController : DashboardController
{
[Route("dashboard/hrm/verification/terminations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
public ActionResult Index()
Expand All @@ -26,7 +25,6 @@ public ActionResult Index()
}

[Route("dashboard/hrm/verification/terminations")]
[RestrictAnonymous]
[MenuPolicy]
[ScrudFactory]
[HttpPut]
Expand Down
4 changes: 4 additions & 0 deletions MixERP.HRM.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="DevTrends.MvcDonutCaching, Version=1.3.0.0, Culture=neutral, PublicKeyToken=73c58d802958a09f, processorArchitecture=MSIL">
<HintPath>packages\MvcDonutCaching.1.3.0\lib\net40\DevTrends.MvcDonutCaching.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Frapid.ApplicationState, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\bin\Frapid.ApplicationState.dll</HintPath>
Expand Down
2 changes: 1 addition & 1 deletion Views/web.config
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<add namespace="Frapid.Messaging" />
<add namespace="Frapid.WebsiteBuilder" />
<add namespace="MixERP.HRM" />
</namespaces>
<add namespace="DevTrends.MvcDonutCaching" /></namespaces>
</pages>
</system.web.webPages.razor>

Expand Down
1 change: 1 addition & 0 deletions packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
<package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="1.0.2" targetFramework="net46" />
<package id="Microsoft.Net.Compilers" version="1.3.2" targetFramework="net46" developmentDependency="true" />
<package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net46" />
<package id="MvcDonutCaching" version="1.3.0" targetFramework="net46" />
<package id="Serilog" version="2.3.0" targetFramework="net46" />
</packages>
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Getting started with DevTrends.MvcDonutCaching
----------------------------------------------

Find out how to use DevTrends.MvcDonutCaching by visiting https://github.com/moonpyk/mvcdonutcaching

Please report all bugs and feature requests on GitHub.
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<configuration>
<system.web.webPages.razor>
<pages>
<namespaces>
<add namespace="DevTrends.MvcDonutCaching" />
</namespaces>
</pages>
</system.web.webPages.razor>
</configuration>
Loading

0 comments on commit 4689672

Please sign in to comment.