From c0c2c59ea318805e9021d8bb8ceb5b7f91f93cb1 Mon Sep 17 00:00:00 2001
From: Naz <2022755409@student.uitm.edu.my>
Date: Tue, 22 Apr 2025 17:21:41 +0800
Subject: [PATCH] edit
---
.../Controllers/OvertimeController.cs | 4 +
Areas/OTcalculate/Models/OtStatusModel.cs | 36 +++++
.../OTcalculate/Views/HrDashboard/Rate.cshtml | 4 +-
.../Views/Overtime/OtRecords.cshtml | 137 +++++++++++++-----
.../Views/Overtime/OtStatus.cshtml | 123 ++++++++++++++++
Controllers/API/OvertimeAPI.cs | 98 +++++++++++++
DBContext/CentralSystemContext.cs | 2 +
Views/Shared/_Layout.cshtml | 5 +
.../OT_15_2025_4_638809276784755591.pdf | Bin 0 -> 71450 bytes
.../OT_15_2025_4_638809289066407421.pdf | Bin 0 -> 71450 bytes
.../OT_15_2025_4_638809289682209687.pdf | Bin 0 -> 72070 bytes
.../OT_15_2025_4_638809323916424471.pdf | Bin 0 -> 71450 bytes
.../OT_15_2025_4_638809389078270198.pdf | Bin 0 -> 71450 bytes
.../OT_15_2025_4_638809392040377761.pdf | Bin 0 -> 71450 bytes
.../OT_1_2025_4_638809164154988965.pdf | Bin 0 -> 71450 bytes
.../OT_1_2025_4_638809168067665769.pdf | Bin 0 -> 71450 bytes
16 files changed, 366 insertions(+), 43 deletions(-)
create mode 100644 Areas/OTcalculate/Models/OtStatusModel.cs
create mode 100644 Areas/OTcalculate/Views/Overtime/OtStatus.cshtml
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809276784755591.pdf
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809289066407421.pdf
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809289682209687.pdf
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809323916424471.pdf
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809389078270198.pdf
create mode 100644 wwwroot/Media/Overtime/OT_15_2025_4_638809392040377761.pdf
create mode 100644 wwwroot/Media/Overtime/OT_1_2025_4_638809164154988965.pdf
create mode 100644 wwwroot/Media/Overtime/OT_1_2025_4_638809168067665769.pdf
diff --git a/Areas/OTcalculate/Controllers/OvertimeController.cs b/Areas/OTcalculate/Controllers/OvertimeController.cs
index cf8cd32..c5596ae 100644
--- a/Areas/OTcalculate/Controllers/OvertimeController.cs
+++ b/Areas/OTcalculate/Controllers/OvertimeController.cs
@@ -20,5 +20,9 @@ namespace PSTW_CentralSystem.Areas.OTcalculate.Controllers
return View();
}
+ public IActionResult OtSTatus()
+ {
+ return View();
+ }
}
}
diff --git a/Areas/OTcalculate/Models/OtStatusModel.cs b/Areas/OTcalculate/Models/OtStatusModel.cs
new file mode 100644
index 0000000..278dd1b
--- /dev/null
+++ b/Areas/OTcalculate/Models/OtStatusModel.cs
@@ -0,0 +1,36 @@
+using System.ComponentModel.DataAnnotations;
+using System.ComponentModel.DataAnnotations.Schema;
+
+namespace PSTW_CentralSystem.Areas.OTcalculate.Models
+{
+ [Table("otstatus")]
+ public class OtStatusModel
+ {
+ [Key]
+ public int StatusId { get; set; }
+
+ [Required]
+ public int UserId { get; set; }
+
+ [Required]
+ public int Month { get; set; }
+
+ [Required]
+ public int Year { get; set; }
+
+ public DateTime SubmitDate { get; set; }
+
+ public string HodStatus { get; set; } = "Pending";
+
+ // JSON array of ApprovalUpdateLog
+ public string? HodUpdate { get; set; }
+
+ public string HrStatus { get; set; } = "Pending";
+
+ // JSON array of ApprovalUpdateLog
+ public string? HrUpdate { get; set; }
+
+ public string? FilePath { get; set; }
+ }
+
+}
diff --git a/Areas/OTcalculate/Views/HrDashboard/Rate.cshtml b/Areas/OTcalculate/Views/HrDashboard/Rate.cshtml
index f141866..06c4170 100644
--- a/Areas/OTcalculate/Views/HrDashboard/Rate.cshtml
+++ b/Areas/OTcalculate/Views/HrDashboard/Rate.cshtml
@@ -1,6 +1,4 @@
-
-
-@{
+@{
ViewData["Title"] = "Rate Update";
Layout = "~/Views/Shared/_Layout.cshtml";
}
diff --git a/Areas/OTcalculate/Views/Overtime/OtRecords.cshtml b/Areas/OTcalculate/Views/Overtime/OtRecords.cshtml
index 1d777f9..d372cba 100644
--- a/Areas/OTcalculate/Views/Overtime/OtRecords.cshtml
+++ b/Areas/OTcalculate/Views/Overtime/OtRecords.cshtml
@@ -104,7 +104,7 @@
-
+
@@ -134,7 +134,7 @@
{{ record.otDescription }}
- |
+ |
@@ -167,10 +167,33 @@
- |