Package org.hoteia.qalingo.core.domain

Examples of org.hoteia.qalingo.core.domain.Asset


        storeViewBean.setWebsite(store.getWebsite());
       
        storeViewBean.setLongitude(store.getLongitude());
        storeViewBean.setLatitude(store.getLatitude());
       
        final Asset defaultPackshotImage = store.getDefaultPackshotImage(ImageSize.SMALL.name());
        if (defaultPackshotImage != null) {
            final String defaultImage = engineSettingService.getRetailerOrStoreImageWebPath(defaultPackshotImage);
            storeViewBean.setDefaultImage(defaultImage);
        } else {
            storeViewBean.setDefaultImage("");
        }
        final Asset defaultIconImage = store.getDefaultThumbnailImage();
        if (defaultIconImage != null) {
            final String iconImage = engineSettingService.getRetailerOrStoreImageWebPath(defaultIconImage);
            storeViewBean.setIconImage(iconImage);
        } else {
            storeViewBean.setIconImage("");
View Full Code Here


                    catalogCategoryViewBean.getMarketAreaAttributes().put(attribute.getAttributeDefinition().getCode(), buildViewBeanAttributeValue(requestData, attribute));
                }
            }
           
            // ASSETS
            final Asset defaultBackgroundImage = catalogCategory.getDefaultBackgroundImage();
            if (defaultBackgroundImage != null) {
                final String backgroundImage = engineSettingService.getCatalogImageWebPath(defaultBackgroundImage);
                catalogCategoryViewBean.setBackgroundImage(backgroundImage);
            } else {
                catalogCategoryViewBean.setBackgroundImage("");
            }
            final Asset defaultSlideshowImage = catalogCategory.getDefaultSlideshowImage();
            if (defaultSlideshowImage != null) {
                final String slideshowImage = engineSettingService.getCatalogImageWebPath(defaultSlideshowImage);
                catalogCategoryViewBean.setSlideshowImage(slideshowImage);
            } else {
                catalogCategoryViewBean.setBackgroundImage("");
            }

            final Asset defaultPackshotImage = catalogCategory.getDefaultPackshotImage(ImageSize.HD.getPropertyKey());
            if (defaultPackshotImage != null) {
                final String carouselImage = engineSettingService.getCatalogImageWebPath(defaultPackshotImage);
                catalogCategoryViewBean.setCarouselImage(carouselImage);
            } else {
                catalogCategoryViewBean.setCarouselImage("");
            }
            final Asset defaultIconImage = catalogCategory.getDefaultThumbnailImage();
            if (defaultIconImage != null) {
                final String iconImage = engineSettingService.getCatalogImageWebPath(defaultIconImage);
                catalogCategoryViewBean.setIconImage(iconImage);
            } else {
                catalogCategoryViewBean.setIconImage("");
View Full Code Here

        }
       
        // ASSETS
        if (Hibernate.isInitialized(productMarketing.getAssets()) && productMarketing.getAssets() != null) {
            for (Iterator<Asset> iterator = productMarketing.getAssets().iterator(); iterator.hasNext();) {
                Asset asset = (Asset) iterator.next();
                productMarketingViewBean.getAssets().add(buildViewBeanAsset(requestData, asset));
            }
        }

        return productMarketingViewBean;
View Full Code Here

                productSkuViewBean.getMarketAreaAttributes().put(attribute.getAttributeDefinition().getCode(), buildViewBeanAttributeValue(requestData, attribute));
            }
        }
       
        // ASSETS
        final Asset defaultBackgroundImage = productSku.getDefaultBackgroundImage();
        if (defaultBackgroundImage != null) {
            String backgroundImage = engineSettingService.getProductSkuImageWebPath(defaultBackgroundImage);
            productSkuViewBean.setBackgroundImage(backgroundImage);
        } else {
            productSkuViewBean.setBackgroundImage("");
        }
        final Asset defaultPackshotImage = productMarketing.getDefaultPackshotImage(ImageSize.HD.name());
        if (defaultPackshotImage != null) {
            String carouselImage = engineSettingService.getProductSkuImageWebPath(defaultPackshotImage);
            productSkuViewBean.setCarouselImage(carouselImage);
        } else {
            productSkuViewBean.setCarouselImage("");
        }
        final Asset defaultIconImage = productSku.getDefaultThumbnailImage();
        if (defaultIconImage != null) {
            String iconImage = engineSettingService.getProductSkuImageWebPath(defaultIconImage);
            productSkuViewBean.setIconImage(iconImage);
        } else {
            productSkuViewBean.setIconImage("");
View Full Code Here

        // TODO : WRONG : CROSS IS SKU not marketing

        productAssociationLinkViewBean.setName(productMarketing.getI18nName(localizationCode));
        productAssociationLinkViewBean.setDescription(productMarketing.getDescription());

        final Asset defaultBackgroundImage = productMarketing.getDefaultBackgroundImage();
        if (defaultBackgroundImage != null) {
            String backgroundImage = engineSettingService.getProductMarketingImageWebPath(defaultBackgroundImage);
            productAssociationLinkViewBean.setBackgroundImage(backgroundImage);
        } else {
            productAssociationLinkViewBean.setBackgroundImage("");
        }
        final Asset defaultPackshotImage = productMarketing.getDefaultPackshotImage(ImageSize.HD.name());
        if (defaultPackshotImage != null) {
            String carouselImage = engineSettingService.getProductMarketingImageWebPath(defaultPackshotImage);
            productAssociationLinkViewBean.setCrossLinkImage(carouselImage);
        } else {
            productAssociationLinkViewBean.setCrossLinkImage("");
        }
        final Asset defaultIconImage = productMarketing.getDefaultThumbnailImage();
        if (defaultIconImage != null) {
            String iconImage = engineSettingService.getProductMarketingImageWebPath(defaultIconImage);
            productAssociationLinkViewBean.setIconImage(iconImage);
        } else {
            productAssociationLinkViewBean.setIconImage("");
View Full Code Here

        cartItem.setProductSku(productSku);
       
        cartItemViewBean.setI18nName(productSku.getI18nName(localizationCode));
        cartItemViewBean.setQuantity(cartItem.getQuantity());

        final Asset defaultPackshotImage = productSku.getDefaultPackshotImage(ImageSize.SMALL.name());
        if (defaultPackshotImage != null) {
            String summaryImage = engineSettingService.getProductMarketingImageWebPath(defaultPackshotImage);
            cartItemViewBean.setSummaryImage(summaryImage);
        } else {
            cartItemViewBean.setSummaryImage("");
View Full Code Here

  // PRODUCT MARKETING ASSET
 
  public Asset getProductMarketingAssetById(final Long productMarketingAssetId, Object... params) {
        Criteria criteria = createDefaultCriteria(Asset.class);
        criteria.add(Restrictions.eq("id", productMarketingAssetId));
        Asset productMarketingAsset = (Asset) criteria.uniqueResult();
        return productMarketingAsset;
  }
View Full Code Here

    productMarketingAsset.setDateUpdate(new Date());
        if (productMarketingAsset.getId() != null) {
            if(em.contains(productMarketingAsset)){
                em.refresh(productMarketingAsset);
            }
            Asset mergedAsset = em.merge(productMarketingAsset);
            em.flush();
            return mergedAsset;
        } else {
            em.persist(productMarketingAsset);
            return productMarketingAsset;
View Full Code Here

    // ASSET
   
    public Asset getProductSkuAssetById(final Long productSkuAssetId, Object... params) {
        Criteria criteria = createDefaultCriteria(Asset.class);
        criteria.add(Restrictions.eq("id", productSkuAssetId));
        Asset productSkuAsset = (Asset) criteria.uniqueResult();
        return productSkuAsset;
    }
View Full Code Here

        productSkuAsset.setDateUpdate(new Date());
        if (productSkuAsset.getId() != null) {
            if(em.contains(productSkuAsset)){
                em.refresh(productSkuAsset);
            }
            Asset mergedAsset = em.merge(productSkuAsset);
            em.flush();
            return mergedAsset;
        } else {
            em.persist(productSkuAsset);
            return productSkuAsset;
View Full Code Here

TOP

Related Classes of org.hoteia.qalingo.core.domain.Asset

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.