Fix JMS metadata complaining of no date class.

The JMS metadata library currently used to handle serialization for the new
REST API was erroring out on fields that are set as a date class as the
metadata library has no date class. To fix this, I've modified the code that
generates the JMS metadata for determining which class to use for a field to
set the JMS type to datetime if the php type is set to date, which corrects
the problem.
Merge pull request #2994 from giant-rabbit/feature/JMSTypeDateFix

Fix JMS metadata complaining of no date class.