Copied to clipboard

Flag this post as spam?

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


  • Nathan Sleigh 109 posts 353 karma points
    Feb 23, 2016 @ 09:16
    Nathan Sleigh
    0

    Fulfill Button not working

    Hi Guys,

    Im having an issue with the final steps of my order within merchello, I can create an order fine with line items, shipping address and making and capturing a payment. The problem Im having is when the order is created I get a fulfill button, when I then go to click this button I get an error.

    The following screenshots show the various errors im getting.

    enter image description here

    enter image description here

    And i also get this in the log file:

    ERROR Merchello.Core.Gateways.Shipping.ShippingGatewayProviderBase - ShipMethods could not be determined for Shipment passed to GetAvailableShipMethodsForDestination method. Attempt message: No CatalogKeys found in Shipment Items System.ArgumentException: merchWarehouseCatalogKey.

    Does anyone have an idea of what Im missing?

    Nathan

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 23, 2016 @ 16:54
    Rusty Swayne
    0

    Hey Nathan - can you confirm that all of your products (or variants) in the order have been added to a catalog.

    enter image description here

  • Nathan Sleigh 109 posts 353 karma points
    Feb 23, 2016 @ 16:56
    Nathan Sleigh
    0

    Hi Rusty,

    Yes they are all in a catalog.

    Nathan

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 23, 2016 @ 17:10
    Rusty Swayne
    0

    Are you using a Bazaar build as your base or have you written your own checkout? If the later, would you mind posting the code for when you quote your shipment and add it to the CheckoutManager or SalePreparation?

  • Nathan Sleigh 109 posts 353 karma points
    Feb 23, 2016 @ 17:14
    Nathan Sleigh
    1

    I have done a custom build, The code i have written is mainly based off this post

    https://our.umbraco.org/projects/collaboration/merchello/merchello/57633-Necessary-steps-to-create-and-fullfil-order

    This is the code. In it Im creating the line items and then creating the shipment line item, Im not very familiar with how it works and couldn't get some aspects to work, as you can see with the hard coded contry GUID. So there has to be something wrong with the code.

    enter image description here

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 23, 2016 @ 17:46
    Rusty Swayne
    0

    Ok - the shipment rate quoting process is pretty complex.

    Instead of generating your quote manually can you try:

     var quote = shipment.ShipmentRateQuoteByShipMethod(method.Key, false);
    

    and then add it to your invoice.

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 24, 2016 @ 16:55
    Rusty Swayne
    1

    I think I see it now:

    You need to add the warehouse catalog key to each shipment line item ... this is for inventory and (in the future) being able to ship from multiple warehouses by default.

    Checkout the packaging strategy generally used:

    https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Core/Strategies/Packaging/DefaultWarehousePackagingStrategy.cs#L106

  • Nathan Sleigh 109 posts 353 karma points
    Feb 24, 2016 @ 17:10
    Nathan Sleigh
    0

    I was already doing that in the code I think

    enter image description here

    At the top i was getting the warehouse and getting the catalog key. Then within the line item i add the first extended data is the warehouse catalog key.

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 24, 2016 @ 17:41
    Rusty Swayne
    0

    Sorry bud, yes I see that now. Can you take a quick screen shot of your shipping configurations in the back office. e.g. You have a ship country configured and there is a rate table (assuming your using the default shipping provider) configured with methods for the destination country your testing with ...

  • Nathan Sleigh 109 posts 353 karma points
    Feb 24, 2016 @ 17:48
    Nathan Sleigh
    0

    The following images are of my shipping gateway that is the UK, the warehouse location, catalog, what rate-table providers i have and an example of the shipping address that is being put into one of my orders.

    enter image description here enter image description here enter image description here

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 24, 2016 @ 18:06
    Rusty Swayne
    0

    This is tough without being able to step through it -

    Can you comment out your line

     var quote = rateTableProvider.QuoteShipmentMethodForShipment( ...
    

    and replace with

     var quotes = MerchelloContext.Current.Gateways.Shipping.GetShipRateQuotesForShipment(shipment, false); 
    

    and see if that returns anything?

  • Nathan Sleigh 109 posts 353 karma points
    Feb 24, 2016 @ 18:45
    Nathan Sleigh
    0

    It doesn't seem to do anything? The reason i need the fulfill button to work is to reduce the stock count on the product, is there another way I can reduce the stock of each product in the basket?

    Maybe getting current stock count, reducing it and then saving the product again?

    enter image description here

  • Rusty Swayne 1655 posts 4993 karma points c-trib
    Feb 24, 2016 @ 21:01
    Rusty Swayne
    0

    Are all of your products and variants marked shippable?

    This is the task that decrements the inventory count ... https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Core/Chains/ShipmentCreation/RemoveShipmentOrderItemsFromInventoryAndPersistShipmentTask.cs#L68

  • Nathan Sleigh 109 posts 353 karma points
    Mar 01, 2016 @ 14:04
    Nathan Sleigh
    0

    Yeah they are, after looking at this some more i am still no closer, its an odd one that I cant seem to find any answer anywhere

  • Nathan Sleigh 109 posts 353 karma points
    Feb 24, 2016 @ 12:58
    Nathan Sleigh
    0

    Sadly this doesn't work and it just returns the quote as null so it makes it fail.

Please Sign in or register to post replies

Write your reply to:

Draft