Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


These support forums are now closed for new topics and comments.
Please head on over to http://eureka.ucommerce.net/ for support.

  • Morten 3 posts 64 karma points
    Jun 27, 2014 @ 13:11
    Morten
    0

    Basket pipeline error - CalculateOrderLineTaxTask

    I get this error when run the basket pipeline in this code:

    public object Put(BasketUpdate request)
    {
    var basket = SiteContext.Current.OrderContext.GetBasket(true);

    foreach (AddRemoveProduct productUpdate in request.Products.EmptyIfNull())
    {
    if (productUpdate.OrderLineId != null)
    TransactionLibrary.UpdateLineItem(productUpdate.OrderLineId.Value, productUpdate.Quantity);
    else if (productUpdate.Quantity > 0)
    TransactionLibrary.AddToBasket(productUpdate.Quantity, productUpdate.ProductSku, productUpdate.ProductVariantSku, false);
    }

    TransactionLibrary.ExecuteBasketPipeline();

    var basketViewModel = new BasketViewModel(basket);
    return new BasketResponse(basketViewModel);
    }

    Error:

    Exception occoured 
    while processing pipeline 'UCommerce.Pipelines.Basket.BasketPipeline'. See inner 
    exception for details.

    stackTrace:
    [BasketUpdate: 27-06-2014 10:52:35]:\n[REQUEST: {}]\nUCommerce.Pipelines.PipelineException: Exception occoured while processing pipeline 'UCommerce.Pipelines.Basket.BasketPipeline'. See inner exception for details. ---> NHibernate.Hql.Ast.ANTLR.QuerySyntaxException: Exception of type 'Antlr.Runtime.NoViableAltException' was thrown.\r\n at NHibernate.Hql.Ast.ANTLR.ErrorCounter.ThrowQueryException()\r\n at NHibernate.Hql.Ast.ANTLR.HqlParseEngine.Parse()\r\n at NHibernate.Hql.Ast.ANTLR.ASTQueryTranslatorFactory.CreateQueryTranslators(String queryString, String collectionRole, Boolean shallow, IDictionary`2 filters, ISessionFactoryImplementor factory)\r\n at NHibernate.Engine.Query.HQLStringQueryPlan.CreateTranslators(String hql, String collectionRole, Boolean shallow, IDictionary`2 enabledFilters, ISessionFactoryImplementor factory)\r\n at NHibernate.Engine.Query.HQLStringQueryPlan..ctor(String hql, String collectionRole, Boolean shallow, IDictionary`2 enabledFilters, ISessionFactoryImplementor factory)\r\n at NHibernate.Engine.Query.HQLStringQueryPlan..ctor(String hql, Boolean shallow, IDictionary`2 enabledFilters, ISessionFactoryImplementor factory)\r\n at NHibernate.Engine.Query.QueryPlanCache.GetHQLQueryPlan(String queryString, Boolean shallow, IDictionary`2 enabledFilters)\r\n at NHibernate.Impl.AbstractSessionImpl.GetHQLQueryPlan(String query, Boolean shallow)\r\n at NHibernate.Impl.AbstractSessionImpl.CreateQuery(String queryString)\r\n at UCommerce.EntitiesV2.Queries.Orders.ProductsOnOrderQuery.Execute(ISession session)\r\n at UCommerce.Pipelines.Basket.CalculateOrderLineTaxTask.Execute(PurchaseOrder order)\r\n at UCommerce.Pipelines.Pipeline`1.Execute(T subject)\r\n --- End of inner exception stack trace ---\r\n at UCommerce.Pipelines.Pipeline`1.Execute(T subject)\r\n at UCommerce.Transactions.TransactionLibraryInternal.ExecuteOrderPipeline(String pipelineName)\r\n at Portal.WebApplication.Orders.Services.CheckoutService.Put(BasketUpdate request) in c:\\Code\\trunk\\src\\Portal.WebApplication\\Orders\\Services\\CheckoutService.cs:line 72\r\n at ServiceStack.ServiceHost.ServiceRunner`1.Execute(IRequestContext requestContext, Object instance, TRequest request)
  • Morten Skjoldager 440 posts 1499 karma points
    Jun 27, 2014 @ 14:27
    Morten Skjoldager
    100

    Seems to be throwing this error when no products exists on basket.

Please Sign in or register to post replies

Write your reply to:

Draft