As discussed in the comments, since you're reusing the
PY_History_TransactionTAB
class, and it doesn't contain an
Emp_FullName
property, you'll need to extract the
EmployeeMaster
from the first record in the group:
FilteredReport = ReportData.Select(x => new PY_History_TransactionTAB
{
EmployeeCode = x.Key.EmployeeCode,
EmployeeMaster = x.First().EmployeeMaster,
H_SalaryDays = x.Sum(y => y.H_SalaryDays ?? 0),
H_NET_Overtime = x.Sum(y => y.H_NET_Overtime),
H_Overtime_Amount = x.Sum(y => y.H_Overtime_Amount),
H_SL_Breakup1 = x.Sum(y => y.H_SL_Breakup1 ?? 0),
H_OT_Allowance1 = x.Sum(y => y.H_OT_Allowance1 ?? 0),
}).ToList();