Project

General

Profile

Edit Copy Actions

Feature #10778

open

to implement Merchandising & Smart Badges (Storefront Dynamic Attraction) ,checkout page enhancements,

Added by Anonymous 10 days ago. Updated 9 days ago.

Status:
Resolved
Priority:
Normal
Assignee:
Target version:
-
Start date:
09/08/2026
Due date:
09/09/2026 (9 days late)
% Done:

100%

Estimated time:
16:00 h
Spent time:

Add

Subtasks


Add

Related issues

Actions #1

Updated by Anonymous 10 days ago

  • Estimated time changed from 8:00 h to 16:00 h
Actions #2

Updated by Ajit A 10 days ago

  • Status changed from New to In Progress
  • Assignee set to Ajit A

Updated by Ajit A 10 days ago

  • % Done changed from 0 to 70

Automated Bestseller & Trending Qualification:

Tied backend order count and units sold directly to the Admin threshold rule (bestsellerMinOrders).
Added real-time tracking for storefront product views (viewCount) to dynamically award the 🔥 Trending tag when exceeding bestsellerMinViews.
Fixed lifecycle synchronization so that raising thresholds (e.g., to 2000 orders) or changing criteria immediately clears badges from non-qualifying products without server reboot.
Storefront Merchandising Badges & UI Clean-Up:

Hero Image Badge: Displays vibrant floating badges (✨ JUST LAUNCHED, ⭐ BEST SELLER, 🔥 TRENDING NOW) on product image galleries.
De-Duplication on Details Page: Cleaned up the PDP metadata row so Just launched only appears once on the hero image, while metadata shows Best seller, Trending, Seasonal, etc.
Animation Polish: Slowed down the ✨ JUST LAUNCHED shimmer animation from a rapid 1.5s to a relaxed, premium 3.5s gradient sweep.
Recently Viewed Section: Upgraded tracking storage and display cards so recently viewed carousels show all dynamic badges (JUST LAUNCHED, discount , Trending, Best Seller, low-stock FOMO) identically to the rest of the store.
Cart x%x
Card Usability Fixes:

Fixed quantity modifier width (68px) on product cards to prevent clipping on the "Go to Cart" button.
Fixed 500 error in customer OTP dispatch for multitenant domain slugs with local SMTP fallback.
Detailed Code Changes by Module
1. Backend (evergreen_pos_be)

src/cron/productLifecycleCron.js
(New):
Implemented dynamic lifecycle sync for isNewArrival, isBestSeller (aggregating $products and $items), and isTrending (aggregating viewCount).
Fixed empty-set clearing logic when 0 products qualify.

src/controllers/Company-controller.js
:
Trigger syncTenantProductLifecycle on saving merchandisingSettings.

src/models/nursery/nursery.product.js
:
Added isTrending boolean field to schema.

src/services/nursery/product.service.js
:
Added isTrending to STOREFRONT_CARD_SELECT.
Updated recordProductView to dynamically evaluate and update isTrending in real time upon page visits.

src/services/nursery/order.service.js
:
Trigger real-time lifecycle re-evaluation upon order creation.

src/services/nursery/ecom.service.js
&

src/views/emails/sendOtptoClient.ejs
:
Fixed slug matching and OTP dispatch error handling.
2. Storefront Frontend (evergreenpos_E-commerce_new)

src/index.css
:
Slowed .animate-shimmer duration from 1.5s to 3.5s.

src/features/products/components/ProductUnifiedCard.tsx
:
Added resolvers and visual badges for isTrending (Grid and List views).
Optimized quantity modifier button dimensions and "Go to Cart" button width.

src/features/products/pages/productdetailsui.tsx
:
Added Trending tag and hero gallery badge.
Removed duplicate Just launched badge from the metadata row.
Passed full product data to recently viewed tracker.

src/utils/ecomPolishStorage.ts
:
Expanded RecentProduct type and storage to persist all badge and marketing attributes.

src/features/dashboard/componets/RecentlyViewedSection.tsx
:
Mapped all merchandising attributes (isNewArrival, isBestSeller, isTrending, offers) to unified product cards.

src/features/dashboard/componets/FeaturedProducts.tsx
&

TrendingProducts.tsx
:
Reduced query staleTime to 30s with refetchOnWindowFocus: true for live tag responsiveness.
3. Admin Frontend (evergreen_pos_fe)

src/pages/Settings/CompanyProfile/EcommerceSettings.tsx
:
Configured inputs for Bestseller and Trending rules (bestsellerMinOrders and bestsellerMinViews).

Updated by Ajit A 9 days ago

  • % Done changed from 70 to 90

Implemented Auth modal URL state persistence, enhanced Guest & Wishlist UI in Header, added individual "Save for Later" (Wishlist move) functionality on Checkout pages, fixed empty checkout state & shipping fee calculations, and resolved shipping origin fallback on the backend.

Key Deliverables & Changes:
Authentication & Modal UX:

URL State Persistence: Synced active auth modal state (login, signup, otp) with URL search parameters so modals persist on page refresh and clean up on close.
Modal Transitions: Implemented smooth transitions between Login, Registration, and OTP modals.
Branded OTP Loader: Replaced grey button loading state with green brand-themed spinner/button state.
Header & User Profile:

Guest Session Handling: Displays a static "Guest" status for guest users with direct logout support.
Wishlist Integration: Enabled and synchronized the wishlist icon and counter across desktop and mobile header views.
Checkout & Order Summary ("Save for Later"):

Item-Level Save for Later: Added "Save for later" action for each individual product in both Standard Order and Preorder checkout summaries, moving items to the wishlist and removing them from the active cart.
Empty Cart Handling: Added a dedicated empty state view with "View Wishlist" and "Continue Shopping" actions when all items are saved/removed.
Zero-Shipping Guard: Prevented fallback shipping fee calculations and active payment totals when cart subtotal is ₹0.
Route Fix: Corrected the "Continue Shopping" button navigation to /all-products and configured /products route alias.
Backend Shipping Service:

Improved warehouse stock allocation and shipping origin fallback resolution in shippingOrigin.service.js.

Actions #5

Updated by Ajit A 9 days ago

  • Due date set to 09/09/2026
  • % Done changed from 90 to 100
Actions #6

Updated by Ajit A 9 days ago

  • Status changed from In Progress to Resolved
Edit Copy Actions

Also available in: Atom PDF