Sum of Working Hours of All Attendance in a Month


I want to add a custom field in Salary Slip, where in that field I want to fetch sum of “Working hours” for all attendance in this month.

Please suggest how its possible?

I added a field “custom_total_working_hours” in Salary Slip Doctype.