Report-510 and REPORT-512

https://tickets.openmrs.org/browse/REPORT-510

https://tickets.openmrs.org/browse/REPORT-512