=== Nanflows Bundles for WooCommerce ===
Contributors: spexoid
Tags: product bundles, bundle, woocommerce, frequently bought together, kits
Requires at least: 6.4
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 0.1.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Sell product bundles in WooCommerce: fixed bundles and "frequently bought together" offers, with stock taken from the products inside.

== Description ==

Put products together and sell them at one price.

* **Fixed bundles**: you choose the products and quantities; customers buy them together at one price you set.
* **Frequently bought together**: a main product plus extras the customer can tick or untick, added to the cart together in one click. With every extra unticked, the main product goes to the cart on its own.
* **Customer chooses the option**: put a variable product in a bundle and let the customer pick the size or colour.
* **Stock from the products inside**: a bundle is available while every product inside is in stock, and each sale takes stock from them. Overselling is stopped at add to cart, in the cart and at checkout.
* **Clear cart**: the bundle and its products are shown together; products inside cannot be removed on their own.
* **Cash on delivery or prepaid, per bundle**: accept both, prepaid only, or COD only. The plugin checks that the method is really switched on in WooCommerce before a bundle goes live.
* **Normal WooCommerce checkout**: works with your payment gateways, taxes, shipping and coupons, the classic checkout and the Cart and Checkout blocks.
* **You choose where it shows**: pick product pages, or whole product categories (every product in them, and products added later). Being inside a bundle does not put it on a product's page. A "frequently bought together" offer shows on its main product's page.
* **Only on those pages, or also its own product**: by default a bundle is not listed in the shop, categories or search, and its own page link takes shoppers to the product page that offers it. Or list each bundle as a product of its own (Settings > General).
* **Bundle picture**: made automatically from the product pictures (updated when they change), or choose your own from the Media Library. Shown in the cart, orders and emails.
* **Block and shortcode**: show a bundle anywhere else with the Bundle block or `[nanflows_bundle id="123"]`.
* **One button, the customer's choice**: on a product page, shoppers pick "Just this product" or a bundle with a radio button, and one Add to cart button adds what they chose. A page with one bundle opens it straight away, products and images in view. Separate bundle cards are available in the settings instead.
* **Guided set-up**: "Create Bundle" asks for a name, a type and its products, then takes you through the bundle's products and pages, offer, details and payment, with a live preview that shows the type, the pages the bundle appears on and the card shoppers will see. Required fields are marked, and half-finished bundles can be saved as drafts.
* **Bundles list**: search, filter by type or status, change several bundles at once (publish, move to drafts, move to trash), and drag bundles up or down to set the order product pages show them in. In a bundle, drag products up or down the same way.
* **Several bundles on one product**: a product page offers one bundle by default, up to three if you change it in Settings; the editor tells you when a page already shows a live bundle.
* **Setup wizard and icon styles**: a short first-run wizard, and a choice of line, solid or WordPress Dashicons icons.
* **Analytics**: bundle orders, revenue, units, average bundle value and prepaid vs COD, by day, with date filters. Stored in your own database only.

= Works with =

* Simple products, physical or virtual and downloadable (customers get their downloads as usual).
* Variable products: a set variation, or the customer chooses.
* HPOS (high-performance order storage).
* The classic cart and checkout, the Cart and Checkout blocks, and checkouts built on WooCommerce's checkout or Store API.

Subscription products (WooCommerce Subscriptions) cannot be put in a bundle yet: their renewals would not be billed correctly, so they are refused with a clear message.

= Bundle Pro =

A percentage or amount off fixed bundles, a percentage off "frequently bought together" offers, Quantity Break (buy 3, save 10%; buy 7, save 20%), Mix & Match, Build Your Own, Volume, Buy X Get Y, add-ons, gift boxes, variety packs, a conversion funnel and exports are available in Bundle Pro, a separate plugin. The editor lists them as optional upgrades. Everything described above is free, has no limits, and works fully without Pro.

= Privacy =

The plugin sends nothing outside your site. Analytics are stored in your own database, without personal data: visitors are counted with a salted hash that cannot be turned back into a person or an IP address.

== Installation ==

1. Install and activate WooCommerce.
2. Install and activate Nanflows Bundles for WooCommerce.
3. Open Bundles: a short setup wizard asks how bundles should appear. Then press Create Bundle and follow the steps.

== Frequently Asked Questions ==

= Where do I set a bundle's products and price? =

In Bundles: press Create Bundle (or Edit on an existing one). The WooCommerce product screen still edits the title, images, description and tax class.

= How is stock handled? =

A bundle has no stock of its own. The product with the least stock (for the quantity the bundle needs) decides how many bundles can be sold. Stock is taken from the products inside when an order is paid, and put back on cancellation or a restocking refund, by WooCommerce itself.

= Which product pages show a bundle? =

The product pages and categories you pick when you create it (you can change them later on the Products step), plus the main product's page for "frequently bought together". With a category, every product in it (and in the categories under it) shows the bundle, products added later too. The other products inside a bundle do not show it on their pages.

= Is a bundle also a product of its own in my shop? =

Every bundle is a WooCommerce product underneath, which is how it goes in the cart and takes stock from its products. By default it is not listed in the shop, categories, search or the sitemap, and its own page sends shoppers to the product page that offers it. In Bundles > Settings > General, choose "Also as its own product in the shop" to list bundles like any other product.

= Where does a bundle's picture come from? =

Until you choose one, a bundle gets a picture made from up to four of its products' pictures (saved in the Media Library, and made again when those pictures change). Choose your own on the "Name & text" step; it always wins, and the made one is removed. On servers without the GD image library, the first product's picture is used.

= Several bundles are set to show on one product page. What do shoppers see? =

The page offers up to the number of bundles set in Bundles > Settings (one by default, three at most). With one bundle, it opens by itself; with more, shoppers pick one from the list. They appear in the order of the Bundles list: drag bundles up or down there to change it.

= Can I save a bundle before it is finished? =

Yes. "Save as draft" keeps it, with or without products and a price. Drafts are never shown to shoppers; every check runs when you publish.

= Can a customer pay cash on delivery? =

Yes, unless you set a bundle to "Prepaid only". If a cart holds bundles with different rules, only the methods all of them allow are offered.

= Does it slow my shop down? =

Its CSS and JavaScript load only on pages that show a bundle, the cart and the checkout. Reports read summary tables, never every order.

== Screenshots ==

1. A bundle on a product page: shoppers choose the product alone or the bundle, and see what they save.
2. Frequently bought together: shoppers tick the extras they want with the product.
3. The bundle in the cart, with the products inside listed under it.
4. All your bundles in one list, with bulk actions, status switches and drag to set the order.
5. Creating a bundle: give it a name and pick a type.
6. The bundle editor: add products and see a live preview of the product page.
7. Set the bundle price; the regular price and the saving are worked out for you.
8. Settings: where bundles appear, icon style, cart display and more.

== Changelog ==

= 0.1.0 =
* First release: fixed and "frequently bought together" bundles, guided bundle creation with drafts and a live preview, a setup wizard, icon styles, stock from the products inside, COD or prepaid per bundle, and analytics.
