CompanyController.cs 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. using System.Threading.Tasks;
  2. using System.Web.Mvc;
  3. using Abp.Web.Mvc.Authorization;
  4. using Abp.Runtime.Caching;
  5. using IwbZero.Auditing;
  6. using ShwasherSys.BaseSysInfo.States;
  7. using ShwasherSys.BasicInfo.Departments;
  8. using ShwasherSys.BasicInfo.Dutys;
  9. using ShwasherSys.BasicInfo.FixedAssetTypeInfo;
  10. using ShwasherSys.CompanyInfo.FixedAssetInfo;
  11. namespace ShwasherSys.Controllers
  12. {
  13. [AbpMvcAuthorize, AuditLog("公司管理信息")]
  14. public class CompanyController : ShwasherControllerBase
  15. {
  16. public CompanyController(IStatesAppService statesAppService, ICacheManager cacheManager, IDutysAppService dutiesAppService, IDepartmentsAppService departmentsAppService, IFixedAssetTypeAppService fixedAssetTypeAppService, IFixedAssetAppService fixedAssetAppService)
  17. {
  18. DutiesAppService = dutiesAppService;
  19. DepartmentsAppService = departmentsAppService;
  20. FixedAssetTypeAppService = fixedAssetTypeAppService;
  21. FixedAssetAppService = fixedAssetAppService;
  22. CacheManager = cacheManager;
  23. StatesAppService = statesAppService;
  24. }
  25. protected IDutysAppService DutiesAppService { get; }
  26. protected IDepartmentsAppService DepartmentsAppService { get; }
  27. protected IFixedAssetTypeAppService FixedAssetTypeAppService { get; }
  28. protected IFixedAssetAppService FixedAssetAppService { get; }
  29. [AbpMvcAuthorize]
  30. public ActionResult Employee()
  31. {
  32. ViewBag.Duty = DutiesAppService.GetDutysSelects();
  33. ViewBag.Department = DepartmentsAppService.GetDepartmentsSelects();
  34. return View();
  35. }
  36. [AbpMvcAuthorize]
  37. public ActionResult Performance()
  38. {
  39. ViewBag.WorkType = StatesAppService.GetSelectLists("Performance", "WorkType");
  40. return View();
  41. }
  42. [AbpMvcAuthorize]
  43. public async Task<ActionResult> FixedAsset()
  44. {
  45. ViewBag.FixedAssetType = await FixedAssetTypeAppService.GetSelectList();
  46. return View();
  47. }
  48. [AbpMvcAuthorize]
  49. public ActionResult LicenseDocument()
  50. {
  51. ViewBag.LicenseGroup = StatesAppService.GetSelectLists("LicenseType", "Type");
  52. return View();
  53. }
  54. [AbpMvcAuthorize]
  55. public ActionResult Mold()
  56. {
  57. return View();
  58. }
  59. [AbpMvcAuthorize]
  60. public async Task<ActionResult> DeviceMgPlan()
  61. {
  62. ViewBag.FixedAsset =await FixedAssetAppService.GetSelectListName();
  63. ViewBag.PlanType = StatesAppService.GetSelectLists("Maintain", "Type");
  64. return View();
  65. }
  66. [AbpMvcAuthorize]
  67. public ActionResult MaintainRecord()
  68. {
  69. ViewBag.MaintainType = StatesAppService.GetSelectLists("Maintain", "Type");
  70. ViewBag.MaintainState = StatesAppService.GetSelectLists("Maintain", "State");
  71. return View();
  72. }
  73. }
  74. }