Examples of ProductCategory


Examples of org.simplecart.shopcart.catalog.ProductCategory

                    ActionMessages.GLOBAL_MESSAGE,
                    new ActionMessage("error.database"));
            return null;
        }
       
        ProductCategory category = null;

        try {
            // find a category object and attach to request
            category = (ProductCategory) dao.findById(id, false);
            //Hibernate.initialize(category.getProducts());
View Full Code Here

Examples of org.simplecart.shopcart.catalog.ProductCategory

                (HttpServletRequest) pageContext.getRequest();
        StringBuffer url = new StringBuffer(request.getContextPath());
        url.append(config.getPrefix());
        url.append(page);
        url.append(".do");
        ProductCategory category = null;
        try {
            category = (ProductCategory) pageContext.findAttribute(name);
        } catch (ClassCastException e) {
            category = null;
        }
        if (category == null && !this.activity.equals("enter"))
            throw new JspException
                    (messages.getMessage("error.generalMessage", name));
        if (page.indexOf("?") < 0)
            url.append("?");
        else
            url.append("&");
        url.append("activity=");
        url.append(this.activity);
        if (!this.activity.equals("enter")) {
            url.append("&categoryId=");
            url.append(TagUtils.getInstance().filter(category.getId().toString()));
        }
       
        // Generate the hyperlink start element
        HttpServletResponse response =
                (HttpServletResponse) pageContext.getResponse();
View Full Code Here

Examples of org.simplecart.shopcart.catalog.ProductCategory

                    ActionMessages.GLOBAL_MESSAGE,
                    new ActionMessage("error.databaseDAO"));
        }
       
        // find product objects and attach to request
        ProductCategory category = (ProductCategory) cdao.findById(viewForm.getCategoryId(),false);
       
        cat.debug("Category object is: " + category);
        cat.debug("Category object contains " + category.getConsumerVisibleProducts().length + " products ");

        // now add this collection to the request
        request.setAttribute(Constants.COLLECTION_PRODUCT_KEY, category.getConsumerVisibleProducts());
       
        // commit Hibernate transaction and close Session
        HibernateUtility.commitTransaction();
        HibernateUtility.closeSession();
       
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.