Making the user time calculation functions generic

Earlier we had the the function which were calculating for today and
this month. Now the day, month and year can be specified.