Bundles
Bundles allow you to combine multiple items into one sales package. They can be defined in the item master data as well as created on-the-fly in most sales documents. A Bundle behaves like a product/item that consists of different components. Bundles unfold their full potential for a clear structuring of sales documents in combination with Formatting which is also part of DYCE Easy Bundle Seller. On Sales Quotes, a whole bundle can also be marked as an alternative choice or an optional add-on using the Alternative and Optional Positions feature from DYCE IT-Business Toolkit.
Bundles cannot be used if items from other software are added to the sales line. This includes Dynamics 365 Sales and the Shopify Connector. The ability to transfer a bundle from another software is currently under review.
Furthermore, nested bundles are not possible.
Product bundle
A bundle is a combination of individual components into a standalone product. It can be used in Sales Quotes and Sales Orders (from here on called sales documents). The price of the bundle is based on the prices of the components. Bundles can be used based on master data or created individually (on-the-fly).
Master data for bundles
To use fixed bundles, they can be created in the master data of the items. This allows easy use e.g. in a sales offer. For this purpose, a new item is created to be used for a product bundle. The description of the bundle is entered in the item's description. The Bundle field (on the Item card in the General fast tab) is set to YES.
The item representing the bundle must be set as inventory managed (Type=Inventory). This is Business Central's requirement for an assembly bill of materials to be created. However, this is not further relevant to the use of the item, as the item will be converted to a text line when used in a sales document.
Subsequently, the components for the bundle are stored via the Assembly BOM (call via Related / Bill of Materials / Assembly). The moment a Bundle item is used in a sales line and a quantity is entered, the related BOM is automatically unfolded. In this process, the line with the Bundle item is converted to a text line (field Grouping=Bundle), and the entries in the BOM become components. The system also takes into account settings from Sales & Receivables Setup.
If the rollout of a Bundle is interrupted by a dialog, request page or other popups, it is possible that the Bundle will not be rolled out completely. The Bundle is then potentially only rolled out up to the point of interruption. During the interruption, some information must be saved in the database (commit). When saving, however, the instruction to create further Sales lines and mark them as components gets lost.
For more details on how assembly BOMs work, please see this part of the Microsoft documentation.
Only items for professional service whose Service Billing Type is Budget can be used as components of a Bundle. The background to this is that Bundles can only be shipped and invoiced as a whole. Neither is possible with the Service Billing Types Time & Material and Fixed Price.
Create Bundles via other Apps or Api
Bundle items that are entered in Sales lines via other apps or an API are not automatically exploded, if setHideValidateDialog(true) or GUIALLOWED(false) applies. This prevents the Sales line from being changed by DYCE Easy Bundle Seller before the other app has finished creating it. For example, if the Shopify Connector were to enter a Bundle item in a Sales line and set the quantity, the Bundle would be immediately explode. The Sales line with the Bundle is now a comment/text line. The Shopify Connector can no longer enter the price and runs into an error.
If the quantity is entered in a Bundle when neither setHideValidateDialog(true) nor GUIALLOWED(false) does apply, the Bundle is exploded immediately. For the user, the Bundle is always going to exploded automatically, while for other apps or an API it will not.
Bundle items are prevented from being posted in order to prevent incorrect data. The user can explode the Bundle via the line action Explode Bundle. The action is available in Sales Quotes, Sales Orders, Blanket Sales Orders, Sales Invoices and Sales Credit Memos.
Additionally, an action has been made public in DYCE Easy Bundle Seller to explode Bundles automatically again. This can be used to create a connector app.
In the Codeunit 70921400 DYCEEBSBundleManagement the procedure "ExplodeBundleLinesInSalesDocument(SalesHeader: Record "Sales Header") " can be called by a connector app. The action explodes all Bundles in the selected document.
For example, to connect the Shopify Connector, the event "Order.Events.OnAfterProcessSalesDocuments(SalesHeader,OrderHeader) " in Codeunit 30166 "Shpfy Process Order" (ShpfyPreocessOrder.Codeunit.al) could be utilized to explode all Bundles in the document.