=== Sortchi – Product Sorter for WooCommerce ===
Contributors: abolfazlsabri
Tags: woocommerce, product sorting, drag and drop, sort products, category order
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 7.4
Requires Plugins: woocommerce
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Drag & drop product sorting for WooCommerce, with separate rules for the shop page and for every product category.

== Description ==

Sortchi lets you decide in which order products appear on your shop page and on each product category page, using simple, stackable rules that you arrange with drag & drop.

**Available rules**

* On-sale products (highest discount percentage first)
* Best-selling products
* Products without a price
* Reviews & ratings
* Out-of-stock products (always moved to the end of the list)
* A specific product (pin any product to a position)
* Products matching a keyword

**Highlights**

* Global rules for the shop page.
* Optional, separate rules for each product category. Categories without their own rules use the global ones.
* Drag & drop interface, rules are saved instantly.
* Results are cached and refreshed automatically when you change the rules or when products change.
* No external services, no tracking, no ads.

The plugin sorts the main product query of the shop page and of product category archives. Custom queries (for example shortcodes or widgets) are not affected.

== Installation ==

1. Make sure WooCommerce is installed and active.
2. Upload the `sortchi` folder to `/wp-content/plugins/`, or install the plugin from the Plugins screen.
3. Activate the plugin.
4. Go to **WooCommerce → Sortchi** and add your rules.
5. To set rules for a single category, edit the category under **Products → Categories**.

== Frequently Asked Questions ==

= Does it need WooCommerce? =

Yes. Sortchi only works while WooCommerce is active.

= What happens to a category that has no rules of its own? =

The global shop rules are used.

= Where is the "Out-of-stock products" rule applied? =

Out-of-stock products always end up at the end of the list.

= What happens when a shopper uses the sorting dropdown? =

Your rules define the default order. As soon as a shopper picks another option (price, popularity, rating, newest…), WooCommerce's own sorting is used instead.

= How fresh is the order after I change a product? =

Changing the rules applies immediately. When stock status, price, publish status or (for keyword rules) the title of a product changes, the saved order is refreshed within a few minutes. Sales counts and ratings are refreshed at most once an hour.

= Does it send data to external servers? =

No. The plugin does not contact any external service.

= What is removed when I delete the plugin? =

All rules (shop and categories) and cached data are removed on uninstall.

== Changelog ==

= 1.0.0 =
* Initial release.

== Upgrade Notice ==

= 1.0.0 =
Initial release.
