Fix search in audit date strings
Fix search in audit date strings

The DateTime objects from the database were not always converted to
ISO-strings properly. With custom dialect-based functions the formatting
is done in the SQL statement.

Working on #2334

privacyidea/privacyidea,privacyidea/privacyidea,privacyidea/privacyidea,privacyidea/privacyidea,privacyidea/privacyidea,privacyidea/privacyidea