Add mime data to restored image (#11962)

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
This commit is contained in:
Christoph Weitkamp 2022-01-04 16:52:56 +01:00 committed by GitHub
parent ef46e126b4
commit 0988c040a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -480,6 +480,12 @@ public class JdbcBaseDAO {
logger.debug("JDBC::storeItemValueProvider: DateTimeItem: '{}'", d);
vo.setValue(d);
break;
case "IMAGEITEM":
vo.setValueTypes(getSqlTypes().get(itemType), java.lang.String.class);
String encodedString = item.getState().toFullString();
logger.debug("JDBC::storeItemValueProvider: ImageItem: '{}'", encodedString);
vo.setValue(encodedString);
break;
default:
// All other items should return the best format by default
vo.setValueTypes(getSqlTypes().get(itemType), java.lang.String.class);