This is the early access documentation preview for Custom Views. This documentation might not be in sync with our official documentation.

Apply your learning

Use your understanding of Shipping Methods in Composable Commerce to help Electronics Company deliver a new Product Type.

  • After completing this page, you should be able to:

    • Use predicates to define a Shipping Method for a specific Product Type.
  • Promotional campaign

    Electronics Company would like to run a temporary promotion with Silvio's scents, where they bundle perfumes in Carts of a certain value. Due to strict shipping regulations which classify perfumes as dangerous goods, these items must be shipped by road for the entire journey. Currently, the couriers that Electronics Company uses, ship by air for at least part of the journey.

    To solve this problem, you may need to first review the information contained in our Product Types page.

    Your options

    Here are three possible approaches to solve this problem. Only one of them is correct. Use the quiz below to select the option you think would be the best solution and check whether you are right.

    • Option 1
      1. Create a Product Attribute to flag if an item is safe for air shipping. The Attribute type can be Boolean, List (enum), or Text.
      2. Create a Cart Predicate that checks if any items are perfume. If there is a match, the predicate should evaluate to False. This predicate will be saved against Shipping Methods that can use air transport.
    • Option 2
      1. Create a Product Attribute to flag if an item is safe for air shipping. The Attribute type can be Boolean or List (enum).
      2. Create a Cart Predicate that checks if any items are perfume. If there is a match, the predicate should evaluate to False. This predicate will be saved against Shipping Methods that can use air transport.
    • Option 3
      1. Create a Product Attribute to flag if an item is safe for air shipping. The Attribute type can be Boolean or List (enum).
      2. Create a Cart Predicate that checks if any items are perfume. If there is a match, the predicate should evaluate to True. This predicate will be saved against Shipping Methods that can use air transport.

    Review

    You've finished the Shipping Methods module, great job! There were a lot of new concepts presented here and it is a fantastic effort to get to this point!

    What's next? Well, there were a lot of links in the module to Composable Commerce documentation resources, which you may have skipped over. We would recommend reviewing these if you haven't already. We also recommend checking out our tutorial on Multiple Shipping Addresses and Methods.

    Next module

    If you're all up to speed with the above material, then we'd love to see you in the next module! Click the link below and let's continue with learning how to administer Composable Commerce!