Project

General

Profile

Edit Copy Actions

Support #11573

open

Testing edge cases for the implemented orders in e-commerce and admin panels

Added by Ajit A 3 days ago. Updated 2 days ago.

Status:
Resolved
Priority:
Normal
Assignee:
Start date:
10/19/2026
Due date:
10/19/2026 (2 days late)
% Done:

100%

Estimated time:
8:00 h
Spent time:

Add

Subtasks


Add

Related issues

Actions #1

Updated by Ajit A 3 days ago

  • Status changed from New to In Progress
  • Estimated time set to 8:00 h

Updated by Ajit A 2 days ago

  • Due date set to 10/19/2026
  • Status changed from In Progress to Resolved
  • Target version set to sprint (10/12/2026 - 10/31/2026)
  • % Done changed from 0 to 100

Repository 1: evergreen_pos_be (Backend)
Key Modifications & Features
MongoDB Connection Pool & Timeout Optimization:
Configured connection options in

src/server.js
: maxPoolSize: 50, minPoolSize: 5, serverSelectionTimeoutMS: 10000, connectTimeoutMS: 10000, socketTimeoutMS: 20000, heartbeatFrequencyMS: 10000.
Added graceful 3s forced exit handler on unhandled promise rejections to prevent zombie server processes.
Product Service & Count Performance:
Parallelized productsCount queries using Promise.all with .maxTimeMS(10000) and fallback returns.
Added maxTimeMS(15000) and projection limits to getProductsNearRestockLevel, getOutOfStock, and getUnderRestockLevel in

src/services/nursery/product.service.js
.
Included restock_level and reorder_level in getProductForManage lean projection.
Loyalty Program Service & Engine:
Eliminated N+1 queries in calculateEstimatedPoints by batch-fetching base product details via $in.
Added robust fallback logic for active loyalty programs (isDeleted: { $ne: true }, case-insensitive status matching).
Enhanced client categorization fallback (customerClass: "Retail", client_status: "return customer").
Warehouse Order Filters:
Added stockFilter, cardFilter, shelfReturns, and tab parameter destructuring in getWarehouseOrders to prevent undefined reference crashes in

src/allservices/warehouseServices/locationService.js
.
Business Rule Enforcement:
Disallowed favoriting inactive products in updateFav and added automatic unfavorite logic during product deactivation in updateProduct.
Repository 2: evergreen_pos_fe (Frontend Admin / POS)
Key Modifications & Features
Variant-Wise Restock Level & Current Quantity (Option A):
Created

VariantStockBreakdownModal.tsx
:
Hover Popover Tooltip: Replaced native browser tooltip on the [X variants low] badge in the Qty column with an interactive card showing low-stock variant names, attributes, SKU, current stock vs. restock level, and shortage counts (-X).
Breakdown Modal: Comprehensive modal with 4 KPI summary cards (Total Variants, Near Restock, Out of Stock, In Stock), real-time search, filter tabs, and a detailed table with SKU copying and status pills.
Added click trigger on the Price column {variants.length} variants chip.
Product List Responsiveness & Safe Favorites:
Prevented marking inactive products as favorites with descriptive warning notifications in

src/pages/Nuresy/POS/Products.tsx
and

src/pages/Nuresy/Inventory/Products/Products.tsx
.
Added muted cursor feedback and tooltips for inactive products.
Repository 3: evergreenpos_E-commerce_new (Customer E-Commerce Web App)
Key Modifications & Features
Order Tracking Crash Fix:
Resolved Rendered more hooks than during the previous render in

src/features/orders/pages/trackingorder.tsx
by moving useState(returnOpen) before conditional returns.
Restored functional "Live track" button navigation in

OrderItemCard.tsx
and

DeliveryTrackingStrip.tsx
.
Cancelled Order Actions Hardening:
Updated

cancellationAccess.ts
and

orderReturnEligibility.ts
to verify order-level and line-level cancellation statuses.
Suppressed the "Cancel Order" button on already-cancelled orders in OrderList.tsx, OrderItemCard.tsx, and OrderDetails.tsx.
Checkout & Loyalty UI Enhancements:
Implemented loading skeleton in

LoyaltyCheckoutPanel.tsx
to prevent layout shift during point calculations.
Refined payment button labeling in

Checkout.tsx
for dynamic delivery and payment states.
Tracking Data Cleanliness:
Filtered placeholder shipments without tracking numbers in

OrderDetailsModal.tsx
.

Edit Copy Actions

Also available in: Atom PDF