Package org.hoteia.qalingo.core.fetchplan

Examples of org.hoteia.qalingo.core.fetchplan.FetchPlan


                if(arg instanceof Object[]){
                    Object[] objects = (Object[]) arg;
                    for (int j = 0; j < objects.length; j++) {
                        Object object = (Object) objects[j];
                        if(object instanceof FetchPlan){
                            FetchPlan fetchPlan = (FetchPlan) object;
                            if(fetchPlan != null && !fetchPlan.getFetchModes().isEmpty()){
                                askedFetchModes = fetchPlan.getFetchModes();
                            }
                        }
                    }
                }
                if(arg instanceof RequestData){
View Full Code Here


  private final Logger logger = LoggerFactory.getLogger(getClass());

  public Cart getCartById(final Long cartId, Object... params) {
        Criteria criteria = createDefaultCriteria(Cart.class);
       
        FetchPlan fetchPlan = handleSpecificFetchMode(criteria);
       
        criteria.add(Restrictions.eq("id", cartId));
        Cart cart = (Cart) criteria.uniqueResult();
        if(cart != null){
            cart.setFetchPlan(fetchPlan);
View Full Code Here

  }
 
    public Cart getCartByMarketAreaIdAndCustomerId(final Long marketAreaId, final Long customerId, Object... params) {
        Criteria criteria = createDefaultCriteria(Cart.class);
       
        FetchPlan fetchPlan = handleSpecificFetchMode(criteria);
       
        criteria.add(Restrictions.eq("marketAreaId", marketAreaId));
        criteria.add(Restrictions.eq("customerId", customerId));

        Cart cart = (Cart) criteria.uniqueResult();
View Full Code Here

            // CURRENCIES FOR THE CURRENT MARKET AREA
            modelAndView.getModelMap().put(ModelConstants.MARKET_AREA_CURRENCIES_VIEW_BEAN, frontofficeViewBeanFactory.buildListViewBeanCurrenciesByMarketArea(requestData));

            // HEADER
            modelAndView.getModelMap().put(ModelConstants.MENUS_VIEW_BEAN, frontofficeViewBeanFactory.buildListViewBeanMenu(requestData, new FetchPlan(categoryVirtualFetchPlans)));
           
            // FOOTER
            modelAndView.getModelMap().put(ModelConstants.FOOTER_MENUS_VIEW_BEAN, frontofficeViewBeanFactory.buildViewBeanFooterMenu(requestData));

            final List<CatalogCategoryVirtual> virtualRootCategories = catalogCategoryService.findRootVirtualCatalogCategoriesByCatalogCode(currentMarketArea.getCatalog().getCode(), new FetchPlan(categoryVirtualFetchPlans));
            final List<CatalogCategoryViewBean> virtualRootCategoryViewBeans = frontofficeViewBeanFactory.buildListViewBeanRootCatalogCategory(requestUtil.getRequestData(request), virtualRootCategories, new FetchPlan(categoryVirtualFetchPlans), null, null);
            modelAndView.getModelMap().put(ModelConstants.CATALOG_CATEGORIES_VIEW_BEAN, virtualRootCategoryViewBeans);

            // GEOLOC
            if(requestData.getGeolocData() != null){
                modelAndView.getModelMap().put(ModelConstants.GEOLOC_REMOTE_ADDRESS, requestData.getGeolocData().getRemoteAddress());
View Full Code Here

  private final Logger logger = LoggerFactory.getLogger(getClass());

  public Tax getTaxById(final Long taxId, Object... params) {
        Criteria criteria = createDefaultCriteria(Tax.class);
       
        FetchPlan fetchPlan = handleSpecificFetchMode(criteria, params);
       
        criteria.add(Restrictions.eq("id", taxId));
        Tax tax = (Tax) criteria.uniqueResult();
        if(tax != null){
            tax.setFetchPlan(fetchPlan);
View Full Code Here

  }

    public Tax getTaxByCode(final String taxCode, Object... params) {
        Criteria criteria = createDefaultCriteria(Tax.class);

        FetchPlan fetchPlan = handleSpecificFetchMode(criteria, params);

        criteria.add(Restrictions.eq("code", handleCodeValue(taxCode)));
        Tax tax = (Tax) criteria.uniqueResult();
        if(tax != null){
            tax.setFetchPlan(fetchPlan);
View Full Code Here

  // CUSTOMER GROUP
 
  public CustomerGroup getCustomerGroupById(final Long customerGroupId, Object... params) {
        Criteria criteria = createDefaultCriteria(CustomerGroup.class);
       
        FetchPlan fetchPlan = handleSpecificCustomerGroupFetchMode(criteria, params);
       
        criteria.add(Restrictions.eq("id", customerGroupId));
        CustomerGroup customerGroup = (CustomerGroup) criteria.uniqueResult();
        if(customerGroup != null){
            customerGroup.setFetchPlan(fetchPlan);
View Full Code Here

  }
 
  public CustomerGroup getCustomerGroupByCode(final String code, Object... params) {
        Criteria criteria = createDefaultCriteria(CustomerGroup.class);
       
        FetchPlan fetchPlan = handleSpecificCustomerGroupFetchMode(criteria, params);
       
        criteria.add(Restrictions.eq("code", handleCodeValue(code)));
        CustomerGroup customerGroup = (CustomerGroup) criteria.uniqueResult();
        if(customerGroup != null){
            customerGroup.setFetchPlan(fetchPlan);
View Full Code Here

    // USER GROUP
   
    public UserGroup getUserGroupById(final Long userGroupId, Object... params) {
        Criteria criteria = createDefaultCriteria(UserGroup.class);
       
        FetchPlan fetchPlan = handleSpecificUserGroupFetchMode(criteria, params);
       
        criteria.add(Restrictions.eq("id", userGroupId));
        UserGroup userGroup = (UserGroup) criteria.uniqueResult();
        if(userGroup != null){
            userGroup.setFetchPlan(fetchPlan);
View Full Code Here

    }
   
    public UserGroup getUserGroupByCode(final String code, Object... params) {
        Criteria criteria = createDefaultCriteria(UserGroup.class);
       
        FetchPlan fetchPlan = handleSpecificUserGroupFetchMode(criteria, params);
       
        criteria.add(Restrictions.eq("code", handleCodeValue(code)));
        UserGroup userGroup = (UserGroup) criteria.uniqueResult();
        if(userGroup != null){
            userGroup.setFetchPlan(fetchPlan);
View Full Code Here

TOP

Related Classes of org.hoteia.qalingo.core.fetchplan.FetchPlan

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.