Skip to main content

Items Page

The Items page provides a comprehensive view of your inventory across all connected e-commerce sites with advanced filtering and search capabilities.

Overview

Navigate to Items in the WordPress admin menu to view and manage product inventory from all your BigCommerce and WooCommerce stores.

Key Features:

  • 📦 Cross-Site Inventory - View products from all stores in one place
  • 🔍 Smart Filtering - Filter by site, active status, and validity
  • 🔎 Quick Search - Search by SKU or product title
  • 📊 Inventory Levels - See current stock quantities
  • 📄 Pagination - 20 items per page for optimal performance
  • Fast Loading - Optimized database queries with caching

Interface Elements

Filter Bar

The top filter bar helps you quickly find specific items:

Search Field

  • Search for products by:
    • SKU (product code)
    • Product title
  • Press Enter or click Search to apply

Site Filter

  • All Sites - View items from all stores
  • Specific Site - Filter by individual store
  • Shows site ID and name (e.g., "1 - Main Store")

Status Filter

  • All Statuses - Show all items regardless of active status
  • Active - Only items currently active/published
  • Inactive - Only disabled/unpublished items

Items Table

The main table displays 20 items per page with comprehensive product information:

ColumnDescription
SKUProduct SKU/code (unique identifier)
TitleProduct name
SiteStore name where product exists
InventoryCurrent stock quantity
Product IDPlatform product ID
TypeProduct type
PriceCurrent selling price
Active✓ or ✗ (published status)
Valid✓ or ✗ (validation status)
Navision StatusSync status with Business Central

Column Details

SKU:

  • Unique product code used across systems
  • Used for inventory sync matching
  • Critical for Business Central integration

Inventory:

  • Current stock quantity from e-commerce platform
  • Updates via:
    • Hourly inventory sync
    • Real-time webhook updates
    • Manual sync operations

Active:

  • ✓ - Product is published and available for sale
  • ✗ - Product is disabled or unpublished

Valid:

  • ✓ - Product passed validation checks
  • ✗ - Product has validation errors (missing data, invalid config)

Navision Status:

  • Current sync status with Business Central
  • Values may include: Synced, Pending, Error

Pagination Controls

Navigation at bottom of table:

  • Previous button - Go to previous page
  • Page X of Y - Current page indicator
  • Next button - Go to next page
  • Showing X of Y items - Total item count

Common Workflows

Finding a Product

By SKU:

  1. Enter SKU in search field
  2. Press Enter or click Search
  3. Product appears in results

By Title:

  1. Enter product name (partial match works)
  2. Press Enter or click Search
  3. All matching products shown

By Site:

  1. Select site from dropdown
  2. View only products from that store
  3. Combine with other filters for refinement

Checking Inventory Levels

View All Items:

  1. Leave all filters at default
  2. Browse through pages
  3. Sort by inventory column to see low stock

Check Specific Site:

  1. Select site from filter
  2. Review inventory levels
  3. Identify products needing restock

Finding Inactive Products

  1. Set Status filter to "Inactive"
  2. View all disabled/unpublished products
  3. Useful for catalog maintenance

Validating Product Data

  1. Check Valid column
  2. Products with ✗ may have issues
  3. Investigate errors in debug log
  4. Verify product configuration in e-commerce platform

Inventory Sync Integration

The Items page displays data synchronized from your e-commerce platforms:

Sync Methods

Hourly Full Sync:

  • Runs automatically every hour
  • Updates inventory for all products
  • Refreshes product details (title, price, status)

Real-Time Webhooks:

  • Product updates pushed immediately
  • Inventory changes reflected within seconds
  • Supported on BigCommerce (requires webhook setup)

Manual Sync:

  • Trigger from Control Panel → Sites
  • Click "Run Inventory Sync" for specific site
  • Useful for immediate updates

Data Flow

E-Commerce Platform → API → Normalize → rm_items table → Items Page Display

Update Frequency:

  • Webhooks: Immediate
  • Scheduled sync: Every hour
  • Manual: On-demand

Performance Considerations

The Items page is optimized for fast loading:

  • Pagination - 20 items per page reduces data transfer
  • Indexed Queries - Database indexes on commonly filtered columns
  • Deferred Sites - Sites dropdown loads 200ms after main content
  • HTTP Caching - Sites endpoint cached for 5 minutes

Expected Load Times:

  • Typical: 0.010-0.050 seconds
  • With filters: 0.015-0.075 seconds
  • Large datasets (100K+ items): Still under 0.100s with proper indexes

Database Queries

The Items page executes these queries:

  1. Sites Query (1 query, deferred)

    SELECT * FROM rm_sites WHERE is_active = 1 ORDER BY name ASC
  2. Items COUNT (1 query)

    SELECT COUNT(*) FROM rm_items WHERE [filters]
  3. Items SELECT (1 query)

    SELECT i.*, s.name as site_name 
    FROM rm_items i
    LEFT JOIN rm_sites s ON i.site = s.id
    WHERE [filters]
    ORDER BY i.id DESC
    LIMIT 20 OFFSET [page]

Total: 3 queries per page load

BazaarVoice Push Reviews

Version Added: 1.18.37

The Items page integrates with the BazaarVoice Metafield Sync to push review JSON-LD to BigCommerce product metafields.

Checkbox Selection

Each row has a checkbox for bulk selection. Use the header checkbox to select/deselect all visible items.

Per-Row Push Button

Each item row with BazaarVoice review data displays a "Push Reviews" button that pushes the combined review JSON-LD to that product's BigCommerce metafield immediately.

Bulk Action Bar

When one or more items are selected, a bulk action bar appears at the top:

  • "Push Reviews to BC" — Pushes review metafields for all selected items
  • Shows count of selected items
  • Processing indicator during push operations

Requirements

  • Site must be BigCommerce platform
  • Site must have bv_metafield_sync enabled
  • Items must have review data in rm_item_schema_markup

Troubleshooting

Items Not Showing

Check:

  • Inventory sync is enabled for site (Settings → Sites)
  • Cron jobs are running (Operations → Cron Jobs)
  • No errors in debug.log
  • Database connection is active

Verify Sync Status:

  1. Go to Control Panel → Sites
  2. Check "Last Inventory Sync" timestamp
  3. Look for errors in sync status

Inventory Out of Date

Solutions:

  1. Trigger manual inventory sync from Control Panel
  2. Check if webhooks are configured (BigCommerce only)
  3. Verify hourly cron job is running
  4. Check API connection status

Search Not Finding Products

Check:

  • Exact SKU match (case-sensitive on some platforms)
  • Product exists in selected site filter
  • Try partial title search
  • Clear browser cache/refresh page

Slow Page Load

Solutions:

  1. Verify database indexes exist
  2. Check for large result sets (use filters)
  3. Enable query logging to identify slow queries
  4. See Query Logging

Technical Details

REST API Endpoint

GET /wp-json/gsm-middleware/v1/items

Query parameters:

  • page - Page number (default: 1)
  • per_page - Items per page (default: 20)
  • search - Search term (SKU or title)
  • site - Site ID filter
  • active - Active status (0 or 1)

React Component

File: assets/js/components/ItemsViewer.jsx

Features:

  • WordPress Components library
  • Hooks-based state management
  • Loading states with spinner overlay
  • Optimized rendering

Database Tables

Primary: rm_items

  • Stores all product/inventory data
  • Fields: id, sku, site, inventory, prod_id, type, active, valid, price, title, navision_status

Related:

  • rm_sites - Site information (LEFT JOIN for site names)
  • rm_lineitems - Links items to orders
  • rm_kits - Kit product structure (parent → component relationships)

Data Schema

interface Item {
id: number; // Auto-increment primary key
sku: string; // Product SKU
site: number; // Site ID (foreign key to rm_sites)
inventory: number; // Stock quantity
prod_id: string; // Platform product ID
type: string; // Product type
active: boolean; // Is published
valid: boolean; // Passes validation
price: number; // Current price
title: string; // Product name
navision_status: string; // BC sync status
site_name?: string; // Joined from rm_sites
}

Integration Points

Inventory Sync System

Items data is populated by:

  • src/Sync/BigCommerce_Inventory_Sync.php - BigCommerce sync
  • src/Sync/WooCommerce_Inventory_Sync.php - WooCommerce sync
  • src/Sync/Product_Webhook_Handler.php - Real-time webhook processing

Queue System

Inventory updates use the queue system for reliability:

  • Webhook events queued in rm_queue
  • Processed by background worker
  • Failed jobs retried automatically
  • See Queue Management

Business Central Export

Items are referenced during order export:

  • SKU matching for line item validation
  • Inventory verification before export
  • Stock level checks