[Backend] Added function to format a time string to whatever format you want.