updated date code for occurrences and related template