From 8850328fd4b7f5ba64b7a39585d969ae4d462ae3 Mon Sep 17 00:00:00 2001 From: mahan Date: Tue, 13 Jan 2026 16:08:13 +0330 Subject: [PATCH] add GetEditDetails controller method --- .../RollCall/CaseHistoryController.cs | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/ServiceHost/Areas/Client/Controllers/RollCall/CaseHistoryController.cs b/ServiceHost/Areas/Client/Controllers/RollCall/CaseHistoryController.cs index 6ecead24..5dea4b3f 100644 --- a/ServiceHost/Areas/Client/Controllers/RollCall/CaseHistoryController.cs +++ b/ServiceHost/Areas/Client/Controllers/RollCall/CaseHistoryController.cs @@ -43,4 +43,25 @@ public class CaseHistoryController : ClientBaseController return _rollCallApplication.ManualEdit(command); } + // [HttpGet("edit")] + // public ActionResult<> GetEditDetails(string date,long employeeId) + // { + // var result = _rollCallApplication.GetWorkshopEmployeeRollCallsForDate(_workshopId, employeeId, date); + // //var dates = _rollCallApplication.GetEditableDatesForManualEdit(date.ToGeorgianDateTime()); + // var name = _rollCallEmployeeApplication.GetByEmployeeIdAndWorkshopId(employeeId, _workshopId); + // + // var total = new TimeSpan(result.Sum(x => + // (x.EndDate!.Value.Ticks - x.StartDate!.Value.Ticks))); + // + // var command = new EmployeeRollCallsViewModel() + // { + // EmployeeFullName = name.EmployeeFullName, + // EmployeeId = employeeId, + // DateFa = date, + // //EditableDates = dates, + // RollCalls = result, + // TotalRollCallsDuration = total.ToFarsiHoursAndMinutes("-") + // }; + // } + } \ No newline at end of file