Examples of ProductMarketing


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

        retailer = new Retailer();
        retailer.setId(new Long("1"));
       
        catalogCategories = new ArrayList<CatalogCategoryVirtual>();

        productMarketing = new ProductMarketing();
        productMarketing.setId(new Long("1"));
        productMarketing.setName("Product Marketing");
        productMarketing.setDescription("Product Marketing ...");
        productMarketing.setCode("productMarketing");
       
View Full Code Here

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

        List<ProductSku> skus = productDao.findProductSkusByproductMarketingId(productMarketingId, params);
        return skus;
    }
   
    public List<ProductSku> findProductSkusByProductMarketingCode(final String productMarketingCode, Object... params) {
        ProductMarketing productMarketing = getProductMarketingByCode(productMarketingCode, params);
        List<ProductSku> skus = productDao.findProductSkusByproductMarketingId(productMarketing.getId(), params);
        return skus;
    }
View Full Code Here

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

                    } else if (param instanceof ProductSku) {
                        ProductSku productSku = (ProductSku) param;
                        urlParams.put(RequestConstants.URL_PATTERN_PRODUCT_SKU_CODE, handleParamValue(productSku.getCode()));
                        urlStr = addFullPrefixUrl(requestData, urlStr);
                    } else if (param instanceof ProductMarketing) {
                        ProductMarketing productMarketing = (ProductMarketing) param;
                        urlParams.put(RequestConstants.URL_PATTERN_PRODUCT_MARKETING_CODE, handleParamValue(productMarketing.getCode()));
                        urlStr = addFullPrefixUrl(requestData, urlStr) + handleParamValue(productMarketing.getName()) + "/";
                    } else if (param instanceof CatalogCategoryVirtual) {
                        CatalogCategoryVirtual category = (CatalogCategoryVirtual) param;
                        urlParams.put(RequestConstants.URL_PATTERN_CATEGORY_CODE, handleParamValue(category.getCode()));
                        urlStr = addFullPrefixUrl(requestData, urlStr) + handleParamValue(category.getName()) + "/";
                    } else if (param instanceof CatalogCategoryMaster) {
View Full Code Here

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

        logger.debug("Found {} productMarketings", productMarketings.size());
        return PojoUtil.mapAll(dozerBeanMapper, productMarketings, ProductMarketingPojo.class);
    }
   
    public ProductMarketingPojo getProductMarketing(final String productMarketingCode) {
        final ProductMarketing productMarketing = productService.getProductMarketingByCode(productMarketingCode);
        return buildProductMarketing(productMarketing);
    }
View Full Code Here

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

        final MarketArea marketArea = requestData.getMarketArea();
        final Retailer retailer = requestData.getMarketAreaRetailer();

        List<ProductMarketing> products = productService.findProductMarketings();
        for (Iterator<ProductMarketing> iteratorProductMarketing = products.iterator(); iteratorProductMarketing.hasNext();) {
            ProductMarketing productMarketing = (ProductMarketing) iteratorProductMarketing.next();
            for (Iterator<ProductSku> iteratorProductSku = productMarketing.getProductSkus().iterator(); iteratorProductSku.hasNext();) {
                ProductSku productSku = (ProductSku) iteratorProductSku.next();
                List<CatalogCategoryVirtual> catalogCategories = catalogCategoryService.findVirtualCategoriesByProductSkuId(productSku.getId());
                productMarketingSolrService.addOrUpdateProductMarketing(productMarketing, catalogCategories, marketArea, retailer);
            }
        }
View Full Code Here

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

                if(cartItem.getProductSku() == null){
                    final ProductSku productSku = productService.getProductSkuByCode(cartItem.getProductSkuCode());
                    cartItem.setProductSku(productSku);
                }
                if(cartItem.getProductMarketing() == null){
                    final ProductMarketing productMarketing = productService.getProductMarketingByCode(cartItem.getProductMarketingCode());
                    cartItem.setProductMarketing(productMarketing);
                }
                if(cartItem.getCatalogCategory() == null){
                    final CatalogCategoryVirtual catalogCategory = catalogCategoryService.getVirtualCatalogCategoryByCode(cartItem.getCatalogCategoryCode(), catalogVirtualCode, catalogMasterCode);
                    cartItem.setCatalogCategory(catalogCategory);
View Full Code Here

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

                      @ModelAttribute(ModelConstants.PRODUCT_COMMENT_FORM) ProductCommentForm productCommentForm) throws Exception {
    ModelAndViewThemeDevice modelAndView = new ModelAndViewThemeDevice(getCurrentVelocityPath(request), FoUrls.PRODUCT_DETAILS.getVelocityPage());
        final RequestData requestData = requestUtil.getRequestData(request);

    CatalogCategoryVirtual catalogCategory = catalogCategoryService.getVirtualCatalogCategoryByCode(categoryCode, requestData.getVirtualCatalogCode(), requestData.getMasterCatalogCode());
    ProductMarketing productMarketing = productService.getProductMarketingByCode(productMarketingCode, new FetchPlan(productMarketingFetchPlans));
        ProductSku productSku = productService.getProductSkuByCode(productSkuCode, new FetchPlan(productSkuFetchPlans));
   
    final CatalogCategoryViewBean catalogCategoryViewBean = frontofficeViewBeanFactory.buildViewBeanVirtualCatalogCategory(requestUtil.getRequestData(request), catalogCategory,
                                                                                       new FetchPlan(categoryVirtualFetchPlans), new FetchPlan(productMarketingFetchPlans), new FetchPlan(productSkuFetchPlans));
    model.addAttribute(ModelConstants.CATALOG_CATEGORY_VIEW_BEAN, catalogCategoryViewBean);

        final ProductMarketingViewBean productMarketingViewBean = frontofficeViewBeanFactory.buildViewBeanProductMarketing(requestUtil.getRequestData(request), catalogCategory, productMarketing, productSku);
        model.addAttribute(ModelConstants.PRODUCT_MARKETING_VIEW_BEAN, productMarketingViewBean);
       
        final CatalogBreadcrumbViewBean catalogBreadcrumbViewBean = frontofficeViewBeanFactory.buildViewBeanCatalogBreadcrumb(requestUtil.getRequestData(request) , catalogCategory);
    model.addAttribute(ModelConstants.CATALOG_BREADCRUMB_VIEW_BEAN, catalogBreadcrumbViewBean);

        //for now, get the featured products in same category
        //TODO: define related products
        final List<ProductMarketingViewBean> relatedProducts = catalogCategoryViewBean.getFeaturedProductMarketings();
        model.addAttribute(ModelConstants.RELATED_PPRODUCT_MARKETING_VIEW_BEAN, relatedProducts);
       
        final CustomerProductRatesViewBean customerProductRatesViewBean = productService.getProductMarketingCustomerRateDetails(productMarketing.getId());
        model.addAttribute(ModelConstants.CUSTOMER_PRODUCT_RATES_VIEW_BEAN, customerProductRatesViewBean);
       
        //Check if has authorized user
        if(requestData.getCustomer() != null){
          productCommentForm = formFactory.buildProductCommentForm(requestData, productMarketing);
View Full Code Here

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

            final Set<CustomerWishlist> customerWishlists = customerMarketArea.getWishlistProducts();
            if (Hibernate.isInitialized(customerWishlists) && customerWishlists != null) {
                for (Iterator<CustomerWishlist> iterator = customerWishlists.iterator(); iterator.hasNext();) {
                    final CustomerWishlist customerWishlist = (CustomerWishlist) iterator.next();
                    final ProductSku productSku = productService.getProductSkuByCode(customerWishlist.getProductSkuCode());
                    final ProductMarketing productMarketing =  productService.getProductMarketingByCode(productSku.getProductMarketing().getCode());
                    final CatalogCategoryVirtual catalogCategory = catalogCategoryService.getDefaultVirtualCatalogCategoryByProductSkuId(productSku.getId());
                    customerWishlistViewBean.getProductSkus().add(buildViewBeanProductSku(requestData, catalogCategory, productMarketing, productSku));
                }
            }
        }
View Full Code Here

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

            final Set<CustomerProductComment> customerProductComments = customerMarketArea.getProductComments();
            if (Hibernate.isInitialized(customerProductComments) && customerProductComments != null) {
                for (Iterator<CustomerProductComment> iterator = customerProductComments.iterator(); iterator.hasNext();) {
                    final CustomerProductComment customerProductComment = (CustomerProductComment) iterator.next();
                    final ProductSku reloadedProductSku = productService.getProductSkuByCode(customerProductComment.getProductSkuCode());
                    final ProductMarketing productMarketing = reloadedProductSku.getProductMarketing();
                    final CatalogCategoryVirtual catalogCategory = catalogCategoryService.getDefaultVirtualCatalogCategoryByProductSkuId(reloadedProductSku.getId());
                    customerProductCommentsViewBean.getCustomerProductCommentViewBeans().add(
                            buildViewBeanCustomerProductComment(requestData, catalogCategory, productMarketing, reloadedProductSku, customerProductComment));
                }
            }
View Full Code Here

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

     *
     */
    public ProductBrandViewBean buildViewBeanProductBrand(final RequestData requestData, final ProductBrand productBrand, final List<ProductMarketing> productMarketings) throws Exception {
        final ProductBrandViewBean productBrandViewBean = buildViewBeanProductBrand(requestData, productBrand);
        for (Iterator<ProductMarketing> iterator = productMarketings.iterator(); iterator.hasNext();) {
            final ProductMarketing productMarketing = (ProductMarketing) iterator.next();
            final ProductSku productSku = productMarketing.getDefaultProductSku();
            CatalogCategoryVirtual catalogCategory = catalogCategoryService.getDefaultVirtualCatalogCategoryByProductSkuId(productSku.getId());
            productBrandViewBean.getProductMarketings().add(buildViewBeanProductMarketing(requestData, catalogCategory, productMarketing, productSku));
        }
        return productBrandViewBean;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.