Search in sources :

Example 1 with BulkInfo

use of it.cnr.bulkinfo.BulkInfo in project cool-jconon by consiglionazionaledellericerche.

the class PrintService method addContentToCmisObject.

public void addContentToCmisObject(ApplicationModel applicationBulk, CmisObject cmisObject, Locale locale) {
    BulkInfo bulkInfo = bulkInfoService.find(cmisObject.getType().getId());
    String title = bulkInfo.getLongDescription();
    if (title == null || title.length() == 0)
        title = cmisObject.getType().getDisplayName();
    Map<String, Object> parameters = new HashMap<String, Object>();
    final Gson gson = new GsonBuilder().setDateFormat("yyyy-MM-dd'T'HH:mm:ss").excludeFieldsWithoutExposeAnnotation().registerTypeAdapter(GregorianCalendar.class, new JsonSerializer<GregorianCalendar>() {

        @Override
        public JsonElement serialize(GregorianCalendar src, Type typeOfSrc, JsonSerializationContext context) {
            return context.serialize(src.getTime());
        }
    }).create();
    List<Pair<String, String>> fields = new ArrayList<Pair<String, String>>();
    fields.addAll(getFields(cmisObject, applicationBulk));
    applicationBulk.getProperties().put("fields", new PrintDetailBulk(null, null, null, fields, null));
    String json = "{\"properties\":" + gson.toJson(applicationBulk.getProperties()) + "}";
    JRGzipVirtualizer vir = new JRGzipVirtualizer(100);
    final ResourceBundle resourceBundle = ResourceBundle.getBundle("net.sf.jasperreports.view.viewer", locale);
    try {
        JRDataSource datasource = new JsonDataSource(new ByteArrayInputStream(json.getBytes(StandardCharsets.UTF_8)), "properties");
        parameters.put(JRParameter.REPORT_LOCALE, locale);
        parameters.put(JRParameter.REPORT_RESOURCE_BUNDLE, resourceBundle);
        parameters.put(JRParameter.REPORT_DATA_SOURCE, datasource);
        parameters.put(JRParameter.REPORT_VIRTUALIZER, vir);
        parameters.put("DIR_IMAGE", new ClassPathResource(PRINT_RESOURCE_PATH).getPath());
        parameters.put("SUBREPORT_DIR", new ClassPathResource(PRINT_RESOURCE_PATH).getPath());
        parameters.put("title", title);
        ClassLoader classLoader = ClassLoader.getSystemClassLoader();
        parameters.put(JRParameter.REPORT_CLASS_LOADER, classLoader);
        JasperReport jasperReport = cacheRepository.jasperReport(PRINT_RESOURCE_PATH + "prodotti.jrxml", jasperCompileManager());
        JasperPrint jasperPrint = jasperFillManager().fill(jasperReport, parameters);
        InputStream stream = new ByteArrayInputStream(JasperExportManager.exportReportToPdf(jasperPrint));
        ContentStream contentStream = new ContentStreamImpl(cmisObject.getName(), new BigInteger(String.valueOf(stream.available())), "application/pdf", stream);
        ((Document) cmisObject).setContentStream(contentStream, true);
    } catch (Exception e) {
        LOGGER.error("Error during print report for object: " + cmisObject.getId(), e);
    }
}
Also used : ContentStreamImpl(org.apache.chemistry.opencmis.commons.impl.dataobjects.ContentStreamImpl) PDDocument(org.apache.pdfbox.pdmodel.PDDocument) ContentStream(org.apache.chemistry.opencmis.commons.data.ContentStream) PDPageContentStream(org.apache.pdfbox.pdmodel.PDPageContentStream) BulkInfo(it.cnr.bulkinfo.BulkInfo) Pair(it.cnr.cool.util.Pair) JsonDataSource(net.sf.jasperreports.engine.data.JsonDataSource) JRGzipVirtualizer(net.sf.jasperreports.engine.fill.JRGzipVirtualizer) ClassPathResource(org.springframework.core.io.ClassPathResource) JSONException(org.json.JSONException) CmisObjectNotFoundException(org.apache.chemistry.opencmis.commons.exceptions.CmisObjectNotFoundException) WriterException(com.google.zxing.WriterException) ParseException(java.text.ParseException) CMISApplicationException(it.cnr.cool.web.scripts.exception.CMISApplicationException) CoolUserFactoryException(it.cnr.cool.exception.CoolUserFactoryException) NotImplementedException(org.apache.commons.lang3.NotImplementedException) CmisStreamNotSupportedException(org.apache.chemistry.opencmis.commons.exceptions.CmisStreamNotSupportedException) ClientMessageException(it.cnr.cool.web.scripts.exception.ClientMessageException) ACLType(it.cnr.cool.cmis.model.ACLType) Type(java.lang.reflect.Type) BigInteger(java.math.BigInteger) PDImageXObject(org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject) JSONObject(org.json.JSONObject) PrintDetailBulk(it.cnr.si.cool.jconon.model.PrintDetailBulk)

Example 2 with BulkInfo

use of it.cnr.bulkinfo.BulkInfo in project cool-jconon by consiglionazionaledellericerche.

the class ApplicationService method validateAspects.

protected List<JSONErrorPair> validateAspects(Map<String, Object> map, Folder call, Folder application, Session cmisSession) {
    List<JSONErrorPair> listError = new ArrayList<JSONErrorPair>();
    List<String> listAspect = getDichiarazioniList(call, application);
    for (String aspect : listAspect) {
        BulkInfo bulkInfoAspect = bulkInfoService.find(aspect);
        FieldProperty flag = null;
        if (bulkInfoAspect != null) {
            for (FieldProperty fieldProperty : bulkInfoAspect.getForm(aspect)) {
                if (fieldProperty.isRadioGroupType() || fieldProperty.isCheckboxType()) {
                    flag = fieldProperty;
                    break;
                }
            }
            for (FieldProperty fieldProperty : bulkInfoAspect.getForm(aspect)) {
                if (flag != null) {
                    if (!fieldProperty.equals(flag) && fieldProperty.getAttributes().get("class").contains(flag.getName() + '_' + map.get(flag.getProperty())) && !fieldProperty.isNullable() && !Optional.ofNullable(fieldProperty.getAttributes().get("class")).map(s -> s.contains("double_show")).orElse(Boolean.FALSE)) {
                        addError(listError, map, fieldProperty.getProperty(), cmisSession.getTypeDefinition(aspect).getPropertyDefinitions().get(fieldProperty.getProperty()).getDisplayName());
                    } else {
                        if (fieldProperty.equals(flag) && !fieldProperty.isNullable()) {
                            addError(listError, map, fieldProperty.getProperty(), cmisSession.getTypeDefinition(aspect).getPropertyDefinitions().get(fieldProperty.getProperty()).getDisplayName());
                        }
                    }
                } else {
                    if (!fieldProperty.isNullable()) {
                        addError(listError, map, fieldProperty.getProperty(), cmisSession.getTypeDefinition(aspect).getPropertyDefinitions().get(fieldProperty.getProperty()).getDisplayName());
                    }
                }
            }
        }
    }
    return listError;
}
Also used : JsonObject(com.google.gson.JsonObject) Order(it.cnr.si.opencmis.criteria.Order) LoggerFactory(org.slf4j.LoggerFactory) Autowired(org.springframework.beans.factory.annotation.Autowired) GroupService(it.cnr.cool.security.service.GroupService) BigDecimal(java.math.BigDecimal) JSONException(org.json.JSONException) CriteriaFactory(it.cnr.si.opencmis.criteria.CriteriaFactory) JSONObject(org.json.JSONObject) OperationContextUtils(org.apache.chemistry.opencmis.client.util.OperationContextUtils) CoolPropertyIds(it.cnr.cool.cmis.model.CoolPropertyIds) BigInteger(java.math.BigInteger) HttpStatus(org.apache.commons.httpclient.HttpStatus) PrintParameterModel(it.cnr.si.cool.jconon.model.PrintParameterModel) ContentStream(org.apache.chemistry.opencmis.commons.data.ContentStream) PropertyDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDefinition) it.cnr.cool.util(it.cnr.cool.util) CompetitionFolderService(it.cnr.si.cool.jconon.service.cache.CompetitionFolderService) Response(org.apache.chemistry.opencmis.client.bindings.spi.http.Response) PolicyType(it.cnr.cool.cmis.model.PolicyType) CMISApplicationException(it.cnr.cool.web.scripts.exception.CMISApplicationException) QueueService(it.cnr.si.cool.jconon.service.QueueService) ACLType(it.cnr.cool.cmis.model.ACLType) Collectors(java.util.stream.Collectors) ZoneId(java.time.ZoneId) CMISUser(it.cnr.cool.security.service.impl.alfresco.CMISUser) MailService(it.cnr.cool.mail.MailService) JsonArray(com.google.gson.JsonArray) Choice(org.apache.chemistry.opencmis.commons.definitions.Choice) Stream(java.util.stream.Stream) OperationContextImpl(org.apache.chemistry.opencmis.client.runtime.OperationContextImpl) PropertyIds(org.apache.chemistry.opencmis.commons.PropertyIds) LocalDate(java.time.LocalDate) Entry(java.util.Map.Entry) CoolUserFactoryException(it.cnr.cool.exception.CoolUserFactoryException) FieldProperty(it.cnr.bulkinfo.BulkInfoImpl.FieldProperty) it.cnr.si.cool.jconon.util(it.cnr.si.cool.jconon.util) java.util(java.util) LocalDateTime(java.time.LocalDateTime) ContentStreamImpl(org.apache.chemistry.opencmis.commons.impl.dataobjects.ContentStreamImpl) SimpleDateFormat(java.text.SimpleDateFormat) BaseTypeId(org.apache.chemistry.opencmis.commons.enums.BaseTypeId) Function(java.util.function.Function) InitializingBean(org.springframework.beans.factory.InitializingBean) PrintService(it.cnr.si.cool.jconon.service.PrintService) JsonElement(com.google.gson.JsonElement) Value(org.springframework.beans.factory.annotation.Value) it.cnr.cool.cmis.service(it.cnr.cool.cmis.service) GroupsEnum(it.cnr.cool.security.GroupsEnum) Criteria(it.cnr.si.opencmis.criteria.Criteria) Service(org.springframework.stereotype.Service) SiperService(it.cnr.si.cool.jconon.service.SiperService) StreamSupport(java.util.stream.StreamSupport) Restrictions(it.cnr.si.opencmis.criteria.restrictions.Restrictions) UrlBuilder(org.apache.chemistry.opencmis.commons.impl.UrlBuilder) IncludeRelationships(org.apache.chemistry.opencmis.commons.enums.IncludeRelationships) TypeService(it.cnr.si.cool.jconon.service.TypeService) org.apache.chemistry.opencmis.client.api(org.apache.chemistry.opencmis.client.api) UnfileObject(org.apache.chemistry.opencmis.commons.enums.UnfileObject) VersioningState(org.apache.chemistry.opencmis.commons.enums.VersioningState) org.apache.chemistry.opencmis.commons.exceptions(org.apache.chemistry.opencmis.commons.exceptions) Logger(org.slf4j.Logger) BindingSession(org.apache.chemistry.opencmis.client.bindings.spi.BindingSession) org.apache.poi.hssf.usermodel(org.apache.poi.hssf.usermodel) it.cnr.si.cool.jconon.cmis.model(it.cnr.si.cool.jconon.cmis.model) BulkInfo(it.cnr.bulkinfo.BulkInfo) ClientMessageException(it.cnr.cool.web.scripts.exception.ClientMessageException) Output(org.apache.chemistry.opencmis.client.bindings.spi.http.Output) ApplicationContext(org.springframework.context.ApplicationContext) CallService(it.cnr.si.cool.jconon.service.call.CallService) java.io(java.io) BulkInfoCoolService(it.cnr.cool.service.BulkInfoCoolService) UserService(it.cnr.cool.security.service.UserService) I18nService(it.cnr.cool.service.I18nService) FieldProperty(it.cnr.bulkinfo.BulkInfoImpl.FieldProperty) BulkInfo(it.cnr.bulkinfo.BulkInfo)

Example 3 with BulkInfo

use of it.cnr.bulkinfo.BulkInfo in project cool-jconon by consiglionazionaledellericerche.

the class ApplicationService method validateBaseTableMap.

protected List<JSONErrorPair> validateBaseTableMap(Map<String, Object> map, Folder call, Folder application, Session cmisSession) {
    List<JSONErrorPair> listError = new ArrayList<JSONErrorPair>();
    listError.addAll(validateAspects(map, call, application, cmisSession));
    List<String> listSezioniDomanda = getSezioniDomandaList(call);
    BulkInfo bulkInfo = bulkInfoService.find(JCONONFolderType.JCONON_APPLICATION.value().replace(":", "_"));
    for (String sezione : listSezioniDomanda) {
        for (FieldProperty fieldProperty : bulkInfo.getForm(sezione)) {
            if (Optional.ofNullable(fieldProperty.getProperty()).isPresent() && Optional.ofNullable(fieldProperty.getAttribute("visible")).filter(x -> x.equalsIgnoreCase("true")).isPresent()) {
                // TAB DATI ANAGRAFICI - Controlli particolari
                if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value())) {
                    addError(listError, map, fieldProperty.getProperty());
                    if (map.get(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value()) != null) {
                        if ((Boolean) map.get(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value())) {
                            addError(listError, map, JCONONPropertyIds.APPLICATION_CODICE_FISCALE.value());
                            Object codiceFiscale = map.get(JCONONPropertyIds.APPLICATION_CODICE_FISCALE.value());
                            if (codiceFiscale != null) {
                                // controllo formale della validita' del codice fiscale
                                controllaCodiceFiscale(map, application);
                            }
                        } else
                            addError(listError, map, JCONONPropertyIds.APPLICATION_NAZIONE_CITTADINANZA.value());
                    }
                } else if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_CODICE_FISCALE.value()) || fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_NAZIONE_CITTADINANZA.value())) {
                    LOGGER.debug("field " + fieldProperty.getProperty());
                } else if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_CAP_RESIDENZA.value())) {
                    if (map.get(JCONONPropertyIds.APPLICATION_NAZIONE_RESIDENZA.value()) != null && ((String) map.get(JCONONPropertyIds.APPLICATION_NAZIONE_RESIDENZA.value())).toUpperCase().equals("ITALIA"))
                        addError(listError, map, JCONONPropertyIds.APPLICATION_CAP_RESIDENZA.value());
                } else if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_CAP_COMUNICAZIONI.value())) {
                    if (map.get(JCONONPropertyIds.APPLICATION_NAZIONE_COMUNICAZIONI.value()) != null && ((String) map.get(JCONONPropertyIds.APPLICATION_NAZIONE_COMUNICAZIONI.value())).toUpperCase().equals("ITALIA"))
                        addError(listError, map, JCONONPropertyIds.APPLICATION_CAP_COMUNICAZIONI.value());
                } else if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_EMAIL_COMUNICAZIONI.value())) {
                    if (application == null || application.getPropertyValue(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value()) == null || application.getPropertyValue(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value()).equals(Boolean.FALSE))
                        addError(listError, map, JCONONPropertyIds.APPLICATION_EMAIL_COMUNICAZIONI.value());
                } else if (fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_EMAIL_PEC_COMUNICAZIONI.value())) {
                    if (application == null || application.getPropertyValue(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value()) == null || application.getPropertyValue(JCONONPropertyIds.APPLICATION_FL_CITTADINO_ITALIANO.value()).equals(Boolean.TRUE))
                        addError(listError, map, JCONONPropertyIds.APPLICATION_EMAIL_PEC_COMUNICAZIONI.value());
                } else
                    addError(listError, map, fieldProperty.getProperty(), application.getType().getPropertyDefinitions().get(fieldProperty.getProperty()).getDisplayName());
                if ((fieldProperty.isRadioGroupType() || fieldProperty.isCheckboxType()) && !fieldProperty.getProperty().equals(JCONONPropertyIds.APPLICATION_SESSO.value()) && map.get(fieldProperty.getProperty()) != null) {
                    Collection<FieldProperty> radioForm = bulkInfo.getForm(fieldProperty.getProperty() + ((Boolean) map.get(fieldProperty.getProperty()) ? "_true" : "_false").replace(":", "_"));
                    if (radioForm != null && !radioForm.isEmpty()) {
                        for (FieldProperty radioFieldProperty : bulkInfo.getForm(fieldProperty.getProperty() + ((Boolean) map.get(fieldProperty.getProperty()) ? "_true" : "_false").replace(":", "_"))) {
                            if (!radioFieldProperty.isNullable())
                                addError(listError, map, radioFieldProperty.getProperty(), application.getType().getPropertyDefinitions().get(radioFieldProperty.getProperty()).getDisplayName());
                        }
                    }
                }
            }
        }
    }
    List<String> properties = call.getPropertyValue(JCONONPropertyIds.CALL_ELENCO_FIELD_NOT_REQUIRED.value());
    if (properties != null) {
        for (String property : properties) {
            for (Iterator<JSONErrorPair> iterator = listError.iterator(); iterator.hasNext(); ) {
                JSONErrorPair error = iterator.next();
                if (error.getFirst().startsWith(property))
                    iterator.remove();
            }
        }
    }
    return listError;
}
Also used : FieldProperty(it.cnr.bulkinfo.BulkInfoImpl.FieldProperty) BulkInfo(it.cnr.bulkinfo.BulkInfo) JsonObject(com.google.gson.JsonObject) JSONObject(org.json.JSONObject) UnfileObject(org.apache.chemistry.opencmis.commons.enums.UnfileObject)

Example 4 with BulkInfo

use of it.cnr.bulkinfo.BulkInfo in project cool-jconon by consiglionazionaledellericerche.

the class PrintService method getSezioni.

private Map<String, List<Pair<String, String>>> getSezioni(List<String> propertyValue, Session cmisSession) {
    Map<String, List<Pair<String, String>>> sezioni = new LinkedHashMap<String, List<Pair<String, String>>>();
    for (String type : propertyValue) {
        BulkInfo bulkInfo = bulkInfoService.find(type);
        String sezione = bulkInfo.getShortDescription();
        if (sezione == null || sezione.length() == 0)
            sezione = cmisSession.getTypeDefinition(type).getDisplayName();
        String sottoSezione = bulkInfo.getLongDescription();
        String queryName = bulkInfo.getCmisQueryName();
        if (sezioni.containsKey(sezione)) {
            sezioni.get(sezione).add(new Pair<String, String>(sottoSezione, queryName));
        } else {
            List<Pair<String, String>> lista = new ArrayList<Pair<String, String>>();
            lista.add(new Pair<String, String>(Optional.ofNullable(sottoSezione).orElse(sezione), queryName));
            sezioni.put(sezione, lista);
        }
    }
    return sezioni;
}
Also used : BulkInfo(it.cnr.bulkinfo.BulkInfo) List(java.util.List) Pair(it.cnr.cool.util.Pair)

Example 5 with BulkInfo

use of it.cnr.bulkinfo.BulkInfo in project cool-jconon by consiglionazionaledellericerche.

the class PrintService method getFields.

@SuppressWarnings("unchecked")
private List<Pair<String, String>> getFields(CmisObject riga, ApplicationModel applicationModel) {
    BulkInfo bulkInfo = bulkInfoService.find(riga.getType().getId());
    List<Pair<String, String>> results = new ArrayList<Pair<String, String>>();
    if (bulkInfo == null) {
        for (Property<?> property : riga.getProperties()) {
            if (!property.getDefinition().isInherited() && !property.getDefinition().getId().startsWith("cm:owner")) {
                results.add(new Pair<String, String>(property.getDisplayName(), property.getValueAsString()));
            }
        }
        results.add(new Pair<String, String>(riga.getProperty(PropertyIds.NAME).getDisplayName(), riga.getProperty(PropertyIds.NAME).getValueAsString()));
    } else {
        for (FieldProperty fieldProperty : bulkInfo.getForm("default")) {
            String value;
            Object objValue = riga.getPropertyValue(fieldProperty.getProperty());
            if (riga.getProperty(fieldProperty.getProperty()) != null) {
                PropertyDefinition<?> propertyDefinition = riga.getProperty(fieldProperty.getProperty()).getDefinition();
                Cardinality cardinality = propertyDefinition.getCardinality();
                if ((cardinality.equals(Cardinality.SINGLE) && objValue != null) || (cardinality.equals(Cardinality.MULTI) && objValue != null && !((List<Object>) objValue).isEmpty())) {
                    // != null
                    if (cardinality.equals(Cardinality.MULTI)) {
                        value = StringUtils.collectionToDelimitedString(((Collection<?>) objValue), ", ");
                    } else {
                        if (propertyDefinition instanceof PropertyDateTimeDefinition) {
                            value = new SimpleDateFormat("dd/MM/yyyy", Locale.ITALY).format(((GregorianCalendar) objValue).getTime());
                        } else if (propertyDefinition instanceof PropertyDecimalDefinition) {
                            value = new NumberStyleFormatter("").print((BigDecimal) objValue, Locale.ITALY);
                        } else if (propertyDefinition instanceof PropertyBooleanDefinition) {
                            if (!Boolean.valueOf(objValue.toString()))
                                continue;
                            value = "";
                        } else {
                            value = objValue.toString();
                        }
                    }
                    String message = displayValue(fieldProperty, value, applicationModel);
                    if (Optional.ofNullable(fieldProperty).flatMap(fieldProperty1 -> Optional.ofNullable(fieldProperty1.getAttribute("widget"))).map(s -> !s.equals("ui.sedi")).orElse(Boolean.TRUE)) {
                        results.add(new Pair<String, String>(applicationModel.getMessage(getLabel(fieldProperty, applicationModel)), message));
                    }
                }
            }
        }
    }
    return results;
}
Also used : Color(java.awt.Color) Order(it.cnr.si.opencmis.criteria.Order) ApplicationService(it.cnr.si.cool.jconon.service.application.ApplicationService) Autowired(org.springframework.beans.factory.annotation.Autowired) GroupService(it.cnr.cool.security.service.GroupService) PrintDetailBulk(it.cnr.si.cool.jconon.model.PrintDetailBulk) PDType1Font(org.apache.pdfbox.pdmodel.font.PDType1Font) org.apache.poi.ss.usermodel(org.apache.poi.ss.usermodel) BigDecimal(java.math.BigDecimal) JSONException(org.json.JSONException) CriteriaFactory(it.cnr.si.opencmis.criteria.CriteriaFactory) SimpleXlsReportConfiguration(net.sf.jasperreports.export.SimpleXlsReportConfiguration) NumberStyleFormatter(org.springframework.format.number.NumberStyleFormatter) CoolPropertyIds(it.cnr.cool.cmis.model.CoolPropertyIds) BigInteger(java.math.BigInteger) HttpStatus(org.apache.commons.httpclient.HttpStatus) PrintParameterModel(it.cnr.si.cool.jconon.model.PrintParameterModel) ContentStream(org.apache.chemistry.opencmis.commons.data.ContentStream) PropertyDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDefinition) CompetitionFolderService(it.cnr.si.cool.jconon.service.cache.CompetitionFolderService) CMISAuthority(it.cnr.cool.security.service.impl.alfresco.CMISAuthority) PDDocument(org.apache.pdfbox.pdmodel.PDDocument) org.apache.chemistry.opencmis.commons.enums(org.apache.chemistry.opencmis.commons.enums) StandardCharsets(java.nio.charset.StandardCharsets) PropertyDecimalDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDecimalDefinition) CMISUser(it.cnr.cool.security.service.impl.alfresco.CMISUser) MailService(it.cnr.cool.mail.MailService) IOUtils(org.apache.commons.io.IOUtils) Stream(java.util.stream.Stream) OperationContextImpl(org.apache.chemistry.opencmis.client.runtime.OperationContextImpl) PDPage(org.apache.pdfbox.pdmodel.PDPage) BarcodeFormat(com.google.zxing.BarcodeFormat) FieldProperty(it.cnr.bulkinfo.BulkInfoImpl.FieldProperty) JsonDataSource(net.sf.jasperreports.engine.data.JsonDataSource) JRXlsExporter(net.sf.jasperreports.engine.export.JRXlsExporter) JRPdfExporter(net.sf.jasperreports.engine.export.JRPdfExporter) CMISService(it.cnr.cool.cmis.service.CMISService) java.util(java.util) MimeTypes(it.cnr.cool.util.MimeTypes) InputStreamResource(net.sf.jasperreports.repo.InputStreamResource) SimpleDateFormat(java.text.SimpleDateFormat) SimpleExporterInput(net.sf.jasperreports.export.SimpleExporterInput) NumberFormat(java.text.NumberFormat) PDPageContentStream(org.apache.pdfbox.pdmodel.PDPageContentStream) PDFont(org.apache.pdfbox.pdmodel.font.PDFont) Value(org.springframework.beans.factory.annotation.Value) GroupsEnum(it.cnr.cool.security.GroupsEnum) Resource(net.sf.jasperreports.repo.Resource) Service(org.springframework.stereotype.Service) AttachmentBean(it.cnr.cool.mail.model.AttachmentBean) StatoDomanda(it.cnr.si.cool.jconon.service.application.ApplicationService.StatoDomanda) StreamSupport(java.util.stream.StreamSupport) Restrictions(it.cnr.si.opencmis.criteria.restrictions.Restrictions) RepositoryService(net.sf.jasperreports.repo.RepositoryService) PropertyDateTimeDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDateTimeDefinition) UrlBuilder(org.apache.chemistry.opencmis.commons.impl.UrlBuilder) org.apache.chemistry.opencmis.client.api(org.apache.chemistry.opencmis.client.api) org.apache.poi.hssf.usermodel(org.apache.poi.hssf.usermodel) it.cnr.si.cool.jconon.cmis.model(it.cnr.si.cool.jconon.cmis.model) Pair(it.cnr.cool.util.Pair) com.google.gson(com.google.gson) UserService(it.cnr.cool.security.service.UserService) ReportResource(net.sf.jasperreports.repo.ReportResource) LoggerFactory(org.slf4j.LoggerFactory) CmisObjectNotFoundException(org.apache.chemistry.opencmis.commons.exceptions.CmisObjectNotFoundException) SimpleOutputStreamExporterOutput(net.sf.jasperreports.export.SimpleOutputStreamExporterOutput) WriterException(com.google.zxing.WriterException) PDImageXObject(org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject) JcononGroups(it.cnr.si.cool.jconon.util.JcononGroups) JSONObject(org.json.JSONObject) AtomicInteger(java.util.concurrent.atomic.AtomicInteger) JRGzipVirtualizer(net.sf.jasperreports.engine.fill.JRGzipVirtualizer) ParseException(java.text.ParseException) DateFormat(java.text.DateFormat) PDFTextStripper(org.apache.pdfbox.text.PDFTextStripper) JRDocxExporter(net.sf.jasperreports.engine.export.ooxml.JRDocxExporter) Response(org.apache.chemistry.opencmis.client.bindings.spi.http.Response) ACLService(it.cnr.cool.cmis.service.ACLService) CMISApplicationException(it.cnr.cool.web.scripts.exception.CMISApplicationException) QrCodeUtil(it.cnr.si.cool.jconon.util.QrCodeUtil) StringUtil(it.cnr.cool.util.StringUtil) ACLType(it.cnr.cool.cmis.model.ACLType) Collectors(java.util.stream.Collectors) List(java.util.List) PropertyBooleanDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyBooleanDefinition) Type(java.lang.reflect.Type) PropertyIds(org.apache.chemistry.opencmis.commons.PropertyIds) BitMatrix(com.google.zxing.common.BitMatrix) CoolUserFactoryException(it.cnr.cool.exception.CoolUserFactoryException) NotImplementedException(org.apache.commons.lang3.NotImplementedException) CmisStreamNotSupportedException(org.apache.chemistry.opencmis.commons.exceptions.CmisStreamNotSupportedException) MatrixToImageWriter(com.google.zxing.client.j2se.MatrixToImageWriter) CMISPropertyIds(it.cnr.si.cool.jconon.util.CMISPropertyIds) ClassPathResource(org.springframework.core.io.ClassPathResource) ContentStreamImpl(org.apache.chemistry.opencmis.commons.impl.dataobjects.ContentStreamImpl) ApplicationModel(it.cnr.si.cool.jconon.model.ApplicationModel) NodeVersionService(it.cnr.cool.cmis.service.NodeVersionService) Criteria(it.cnr.si.opencmis.criteria.Criteria) JPEGFactory(org.apache.pdfbox.pdmodel.graphics.image.JPEGFactory) AppendMode(org.apache.pdfbox.pdmodel.PDPageContentStream.AppendMode) Util(it.cnr.cool.rest.util.Util) net.sf.jasperreports.engine(net.sf.jasperreports.engine) CacheRepository(it.cnr.si.cool.jconon.repository.CacheRepository) Logger(org.slf4j.Logger) BindingSession(org.apache.chemistry.opencmis.client.bindings.spi.BindingSession) BulkInfo(it.cnr.bulkinfo.BulkInfo) ClientMessageException(it.cnr.cool.web.scripts.exception.ClientMessageException) Output(org.apache.chemistry.opencmis.client.bindings.spi.http.Output) Code39Writer(com.google.zxing.oned.Code39Writer) ApplicationContext(org.springframework.context.ApplicationContext) JRPdfExporterParameter(net.sf.jasperreports.engine.export.JRPdfExporterParameter) PDRectangle(org.apache.pdfbox.pdmodel.common.PDRectangle) EmailMessage(it.cnr.cool.mail.model.EmailMessage) java.io(java.io) FieldPropertySet(it.cnr.bulkinfo.BulkInfoImpl.FieldPropertySet) BulkInfoCoolService(it.cnr.cool.service.BulkInfoCoolService) SimpleDocxReportConfiguration(net.sf.jasperreports.export.SimpleDocxReportConfiguration) Bean(org.springframework.context.annotation.Bean) I18nService(it.cnr.cool.service.I18nService) StringUtils(org.springframework.util.StringUtils) PropertyDecimalDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDecimalDefinition) FieldProperty(it.cnr.bulkinfo.BulkInfoImpl.FieldProperty) PropertyDateTimeDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyDateTimeDefinition) NumberStyleFormatter(org.springframework.format.number.NumberStyleFormatter) BulkInfo(it.cnr.bulkinfo.BulkInfo) PropertyBooleanDefinition(org.apache.chemistry.opencmis.commons.definitions.PropertyBooleanDefinition) PDImageXObject(org.apache.pdfbox.pdmodel.graphics.image.PDImageXObject) JSONObject(org.json.JSONObject) List(java.util.List) SimpleDateFormat(java.text.SimpleDateFormat) Pair(it.cnr.cool.util.Pair)

Aggregations

BulkInfo (it.cnr.bulkinfo.BulkInfo)5 FieldProperty (it.cnr.bulkinfo.BulkInfoImpl.FieldProperty)3 ACLType (it.cnr.cool.cmis.model.ACLType)3 CoolUserFactoryException (it.cnr.cool.exception.CoolUserFactoryException)3 Pair (it.cnr.cool.util.Pair)3 CMISApplicationException (it.cnr.cool.web.scripts.exception.CMISApplicationException)3 ClientMessageException (it.cnr.cool.web.scripts.exception.ClientMessageException)3 JSONObject (org.json.JSONObject)3 JsonObject (com.google.gson.JsonObject)2 WriterException (com.google.zxing.WriterException)2 CoolPropertyIds (it.cnr.cool.cmis.model.CoolPropertyIds)2 MailService (it.cnr.cool.mail.MailService)2 GroupsEnum (it.cnr.cool.security.GroupsEnum)2 GroupService (it.cnr.cool.security.service.GroupService)2 UserService (it.cnr.cool.security.service.UserService)2 CMISUser (it.cnr.cool.security.service.impl.alfresco.CMISUser)2 BulkInfoCoolService (it.cnr.cool.service.BulkInfoCoolService)2 I18nService (it.cnr.cool.service.I18nService)2 it.cnr.si.cool.jconon.cmis.model (it.cnr.si.cool.jconon.cmis.model)2 PrintDetailBulk (it.cnr.si.cool.jconon.model.PrintDetailBulk)2