=== CoderCreation Multi User Order Activity Log for WooCommerce ===
Contributors:      sharifok
Tags:              woocommerce, orders status log, staff manage, order log history, woo custom status
Requires at least: 6.2
Tested up to:      7.1
Requires PHP:      7.4
Stable tag:        1.0.3
WC requires at least: 7.0
WC tested up to:   9.0
License:           GPLv2 or later
License URI:       https://www.gnu.org/licenses/gpl-2.0.html
Requires Plugins:  woocommerce


Know exactly which staff member last handled any order — with a full activity history and custom order statuses with color coding.

== Description ==

Running an online store with multiple staff members can make it hard to track accountability. When an order status changes, who did it? When did it happen? Which employee is responsible?

**CoderCreation Multi User Order Activity Log for WooCommerce** solves this problem for shop owners. It automatically records which staff member last changed each order's status and displays it directly in the WooCommerce Orders list — no digging through logs, no guessing.

Whether you have 2 employees or 20, this plugin gives your store a clear chain of responsibility for every order.

= Who is this for? =

* **Shop owners** who manage a team of staff with access to the WooCommerce admin.
* **Store managers** who need to know who last touched an order.
* **Multi-staff operations** where orders pass through different team members (e.g. a picker, a packer, a dispatcher).

= Core Features =

**👤 Manage By Column**
A new "Manage By" column appears in your WooCommerce Orders list. Every time a staff member changes an order status, their name is automatically recorded and shown as a badge on that order. At a glance, the shop owner can see exactly who last managed any order — no manual notes required.

**📋 Full Order History Modal**
Click the "See" button on any order to open a timeline modal showing every status change ever made on that order — who made the change, what the status changed from and to, and the exact date and time. Nothing is hidden, nothing is lost.

**🏷️ Custom Order Statuses with Color Coding**
Create your own order statuses to match your store's workflow. Assign a background color and text color to each status so your team can identify order stages at a glance. Custom statuses appear in all WooCommerce dropdowns and bulk actions. You can also set any custom status as the default for new orders.

= How It Works =

1. A customer places an order.
2. A staff member updates the order status (e.g. from "Processing" to "Ready to Ship").
3. The plugin silently records the staff member's name and the timestamp.
4. The shop owner opens the Orders list and sees the "Manage By" column — instantly knowing which staff member last handled each order.
5. For a full history, the shop owner clicks "See" on any order to view the complete timeline.

= How to Use Custom Statuses =

1. Go to **WooCommerce → Order Stuff → Order Statuses**.
2. Enter a status name — the slug is auto-generated.
3. Pick a background color and text color using the color pickers.
4. Optionally toggle **Set as Default Status** to apply it automatically to every new order.
5. Click **Add Status**. Your new status is immediately available in WooCommerce dropdowns and bulk actions.

= Compatibility =

* Fully compatible with WooCommerce **HPOS** (High Performance Order Storage / Custom Order Tables).
* Works with both legacy `shop_order` CPT and the new `wc-orders` screen.

== Installation ==

1. Upload the `order-manage-staff-for-woocommerce` folder to `/wp-content/plugins/`.
2. Activate the plugin through the **Plugins** menu in WordPress.
3. Ensure WooCommerce is installed and active.
4. Go to **WooCommerce → Orders** — you will see the new **Manage By** and **History** columns immediately.
5. To create custom order statuses, go to **WooCommerce → Order Stuff → Order Statuses**.

No configuration is needed to start tracking staff. The plugin begins recording as soon as it is activated.

== Frequently Asked Questions ==

= Does this work with HPOS? =
Yes. The plugin uses WC_Order CRUD methods exclusively, making it fully compatible with WooCommerce HPOS (Custom Order Tables).

= Does it work with multiple staff accounts? =
Yes. Each WordPress user who changes an order status will have their display name recorded independently.

= What if a status is changed by automation or a payment gateway, not a staff member? =
The plugin detects this and records it as "System / Customer" so the history remains complete and accurate.

= Can I see the full history of an order, not just the last staff member? =
Yes. Click the "See" button in the History column on any order to open a timeline modal showing every status change, who made it, and when.

= Can I set a custom status as the default for new orders? =
Yes. On the Order Statuses page, toggle "Set as Default Status" when creating or editing a status. Every new order will automatically start with that status.

= Will my existing WooCommerce statuses still work? =
Yes. Core WooCommerce statuses (Pending, Processing, On Hold, Completed, Cancelled, Refunded, Failed) are completely unaffected. Custom statuses are additive.

= Where is the data stored? =
All data is stored in your own WordPress database as order meta:
* `_ccmuoal_managed_by` — the display name of the last staff member to change the order status.
* `_ccmuoal_status_history` — a complete log of all status transitions.

= What happens to my data if I uninstall the plugin? =
All plugin data (order meta and custom status settings) is permanently removed on uninstall.

== Screenshots ==

1. WooCommerce Orders table showing the "Manage By" column with staff name badges and the "History" column with See buttons.
2. History modal showing a full timeline of status changes — staff name, from/to status, and timestamp.
3. Order Statuses admin page — create and manage custom statuses with color pickers and a live preview badge.

== Changelog ==

= 1.0.3 =
* Updated: Plugin name changed from "CC Multi User Order Activity Log for WooCommerce" to "CoderCreation Multi User Order Activity Log for WooCommerce" to meet WordPress.org directory naming requirements.

= 1.0.2 =

* Updated: update plugin name, slug, prefix and add shortform of codercreation cc at start the plugin name.
* Version: New version 1.0.2 uploaded.

= 1.0.1 =

* Updated: The readme now fully covers the custom order statuses feature with a dedicated feature section
* Version: New version uploaded.

= 1.0.0 =
* Initial release.
* Auto-tracking of staff who change order status ("Manage By" column).
* AJAX history modal with full status change timeline ("History" column).
* Custom order statuses with color coding.
* Default status setting for new orders.
* Full HPOS compatibility.
