=== Quoteline – Request a Quote for WooCommerce ===
Contributors: afkzonagroup
Tags: request a quote, quote, woocommerce, b2b, vat
Requires at least: 6.7
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Customers request quotes, you price them in the normal order editor, and accepted quotes become orders they pay with any payment method.

== Description ==

Quoteline adds a clean request-a-quote flow to WooCommerce, built on WooCommerce orders instead of a separate system. You price quotes in the order editor you already know, and the customer accepts and pays on the standard WooCommerce payment page – with every payment method your shop supports.

= How it works =

1. Customers add products to a quote list with an **Add to quote** button – on product pages, shop pages and category pages. Guests can request quotes too.
2. They send the request with their details, company, country, optional EU VAT ID and a message.
3. You get an email and find the request under **WooCommerce › Quotes**. Change products, quantities, prices, discounts and shipping in the normal order editor, set a validity date, add a message and press **Save and send quote**.
4. The customer gets an email with a secure link to the quote. **Accept and pay** turns the quote into an order and opens the WooCommerce payment page. They can also decline, with a reason.
5. Quotes that pass their validity date expire automatically.

= Features =

* Add to quote on simple and variable products, product pages and product lists
* Choose which products can be quoted: all, selected categories, products without a price, out-of-stock products – products WooCommerce cannot sell get their own quote form on the product page
* Quote-only mode: hide Add to cart and block quoted products from the cart (classic cart, cart block and Store API)
* Optional: hide prices and show your own text, such as "Price on request"
* Quote page with editable quantities, created automatically (shortcode `[quoteline]` and a block)
* Request form with spam protection and privacy consent
* Quotes are WooCommerce orders with their own statuses: Quote requested, Quote sent, Quote declined, Quote expired. They stay out of WooCommerce Analytics and do not reduce stock
* Edit everything in the standard order editor, then send with one click
* Secure customer link; accept to pay with any payment gateway, or decline with a reason
* Automatic expiry with a daily background job
* My Account › Quotes for logged-in customers
* Six emails in WooCommerce › Settings › Emails: new request, request received, quote, accepted, declined, expired
* Works with High-Performance Order Storage (HPOS) and legacy order storage, block and classic themes
* Translation-ready; Lithuanian included

= EU VAT ID validation =

For business customers in the EU, Quoteline checks the VAT ID with the European Commission’s VIES service. When the VAT ID is valid and the customer is in another EU country than your shop, the quote is VAT-free and carries the legal note for the invoice: "intra-Community supply (Article 138 of Directive 2006/112/EC)" for goods, "reverse charge (Article 196)" for services. If VIES is unavailable, VAT is never removed automatically – you can check again later or decide yourself.

= Quoteline Pro =

[Quoteline Pro](https://afkzonagroup.lt/products/quoteline) adds branded PDF quotes, change requests with revision history, reminders before expiry and follow-ups, your own questions and file uploads on the request form, per-product and customer-group rules with minimum quantities, and quote reports with CSV export.

== External services ==

Quoteline connects to the **VIES VAT number validation service** of the European Commission only when a VAT ID is entered and the "Check with VIES" setting is on (default). It sends the VAT ID (country code and number) and, if you entered one in the settings, your own VAT ID to get a consultation number. Nothing else is sent.

* Service: https://ec.europa.eu/taxation_customs/vies/
* Terms and legal notice: https://ec.europa.eu/info/legal-notice_en
* Privacy: https://ec.europa.eu/info/privacy-policy_en

You can turn the check off under WooCommerce › Settings › Quotes › EU VAT.

== Installation ==

1. Install and activate WooCommerce.
2. Install Quoteline from Plugins › Add New, or upload the zip, and activate it.
3. A "Quote" page is created for you. Adjust the settings in **WooCommerce › Settings › Quotes**.

== Frequently Asked Questions ==

= Where do I find quote requests? =

Under WooCommerce › Quotes, and as orders with the "Quote requested" status.

= How do I change prices before sending? =

Open the quote. It is a normal WooCommerce order: edit items, prices, discounts and shipping, press Recalculate, then press "Save and send quote" in the Quote box.

= Which payment methods can customers use? =

All of them. Accepting a quote opens the standard WooCommerce "Pay for order" page.

= Do quotes show up in my sales reports? =

No. Quote statuses are excluded from WooCommerce Analytics. Once a customer accepts and pays, the order counts like any other order.

= Can themes change how the quote page looks? =

Yes. Copy any file from `quoteline/templates/` to `yourtheme/quoteline/` (emails to `yourtheme/woocommerce/emails/`).

= What happens when I delete the plugin? =

Quotes stay as orders. Settings and the quote page are only removed if you tick "Delete Quoteline settings" in the settings first.

== Screenshots ==

1. Quote list and request form
2. The customer’s quote with Accept and pay
3. WooCommerce › Quotes
4. The Quote box in the order editor with the VIES result

== Changelog ==

= 1.0.0 =
* First release.
