Converted the date into DB format in model classes