add exportEntityTypes importEntityTypes

This commit is contained in:
Efstratios Giannopoulos 2024-04-17 17:56:16 +03:00
parent e99a35a100
commit 442cf7b860
2 changed files with 6 additions and 1 deletions

View File

@ -12,6 +12,7 @@ import eu.eudat.commonmodels.models.descriptiotemplate.DescriptionTemplateModel;
import eu.eudat.commonmodels.models.dmpblueprint.*;
import eu.eudat.commonmodels.models.dmpreference.DmpReferenceModel;
import eu.eudat.commonmodels.models.reference.ReferenceModel;
import eu.eudat.file.transformer.enums.FileTransformerEntityType;
import eu.eudat.file.transformer.interfaces.FileTransformerClient;
import eu.eudat.file.transformer.interfaces.FileTransformerConfiguration;
import eu.eudat.file.transformer.model.enums.FileFormats;
@ -47,6 +48,9 @@ public class WordFileTransformerService implements FileTransformerClient {
new FileFormat(FileFormats.PDF.getValue(), true, "fa-file-pdf-o"),
new FileFormat(FileFormats.DOCX.getValue(), true, "fa-file-word-o"));
private final static List<FileTransformerEntityType> FILE_TRANSFORMER_ENTITY_TYPES = List.of(
FileTransformerEntityType.Dmp, FileTransformerEntityType.Description);
private final WordFileTransformerServiceProperties wordFileTransformerServiceProperties;
private final PdfService pdfService;
private final WordBuilder wordBuilder;
@ -126,6 +130,7 @@ public class WordFileTransformerService implements FileTransformerClient {
configuration.setFileTransformerId(this.wordFileTransformerServiceProperties.getTransformerId());
configuration.setExportVariants(FILE_FORMATS);
configuration.setImportVariants(null);
configuration.setExportEntityTypes(FILE_TRANSFORMER_ENTITY_TYPES);
configuration.setUseSharedStorage(this.wordFileTransformerServiceProperties.isUseSharedStorage());
return configuration;
}

View File

@ -25,7 +25,7 @@
<dependency>
<groupId>gr.cite.opendmp</groupId>
<artifactId>file-transformer-base</artifactId>
<version>0.0.11</version>
<version>0.0.12</version>
</dependency>
<dependency>
<groupId>org.yaml</groupId>