HTML-449: Updated velocity methods to accept string

Changed definition of allEncounters() and latestEncounter to accept strings.

Used utility method instead of private method as adviced
Merge branch 'HTML-449'

Conflicts:
	api-tests/src/test/java/org/openmrs/module/htmlformentry/VelocityFunctionsTest.java