Releases: towfique-elahe/wc-loyalty-card-system
Release list
v1.2.0 — Duplicate Cards, Widget Fixes & UI Overhaul
WooCommerce Loyalty Card System v1.2.0
Released: 2026-02-27
🐛 Bug Fixes
Duplicate card issuance.
A single user could receive the same card type more than once — e.g. Platinum issued twice by admin, or a Privilege Card awarded automatically even if one already existed. Added has_card_type() guards at the top of purchase_card(), issue_special_card(), and award_free_card(). issue_special_card() now returns a descriptive WP_Error displayed in the admin UI instead of a silent generic failure.
Floating widget not toggling.
A CSS hover rule (.wcls-floating-widget:hover .wcls-widget-content { display: block }) was conflicting with the JS click toggle, causing the panel to reappear immediately after being closed. Removed the hover rule — toggle is now purely JS-controlled.
Floating widget positioned on wrong side.
Widget was anchored to the right side of the screen. Corrected to left: 20px.
Tier pill displaying as plain text in floating widget.
A stray wcls-tier-pill text node had been inserted inside the @keyframes wcls-popIn block, invalidating the entire <style> block and stripping all widget styles. Removed the stray text node.
✨ Changes & Improvements
Floating widget redesigned.
Replaced the admin-only Dashicons star (which never loaded on the frontend) with an inline SVG icon. Rebuilt to a minimal, clean design: dark #222 toggle button, neutral gray header with a close × button, stat rows for Points / Tier / Discount, and a plain dark CTA button. Removed all gradients and excessive color.
Admin Special Cards section rebuilt.
Replaced the Select2 AJAX user dropdown (which failed to load reliably) with a fully server-rendered user table showing ID, Name, Email, and an Assign Card control. A client-side search bar filters rows instantly by ID, name, or email with zero JavaScript dependencies. Already-issued card types render as disabled options; users with all cards assigned show an "All cards issued" badge.
Active Cards section redesigned (Loyalty Points page).
Replaced the plain <ul> list with visual card components matching the style of the My Cards page — type-specific gradient backgrounds, SVG icons, large discount percentage display, and a validity footer. Fully responsive at ≤ 480px.
Card colors unified across all templates.
Privilege Card → gold, Investor Card → dark green, Platinum Card → gray. Palette is now consistent across the My Cards public page, the Active Cards section on the Loyalty Points page, and the admin Loyalty Cards badge pills.
📦 Installation / Upgrade
- Deactivate the current version
- Upload and activate
wc-loyalty-card-system-v1.2.0.zip - No database changes — safe drop-in upgrade
Full changelog: See CHANGELOG in the plugin file.
Requires: WordPress 5.0+, WooCommerce 4.0+, PHP 7.2+
v1.1.1 — Fix Tier Distribution Report
WooCommerce Loyalty Card System v1.1.1
Released: 2026-02-26
🐛 Bug Fix
Reports — Points Distribution by Tier was showing "Unassigned" for all rows.
The original query used a LEFT JOIN on loyalty_tiers via a tier_id column that doesn't exist in the loyalty_points table — tiers are calculated dynamically from lifetime_points. This caused every user to fall into the "Unassigned" fallback.
Fix: Replaced the broken SQL JOIN with a PHP loop using Tier_Management::get_user_tier() per user. All configured tiers are now pre-seeded with zero counts, so they always appear in the table even when no users belong to that tier yet.
📦 Installation / Upgrade
- Deactivate the current version
- Upload and activate
wc-loyalty-card-system-v1.1.1.zip - No database changes — safe drop-in upgrade
Full changelog: See CHANGELOG in the plugin file.
Requires: WordPress 5.0+, WooCommerce 4.0+, PHP 7.2+