Trunk 4446: Support deriving auto_expire_date from duration and duration units for Drug Orders

Changes for ticket https://issues.openmrs.org/browse/TRUNK-4446
I think you should throw an exception if an invalid code is passed in instead of returning null