Portal | Homepage | Blog

How do I display in stock matrix variants first?


#1

When viewing the product page of a matrix item (for example, clothing), by default the first member of a dimension is displayed first. If this variant is not in stock, an out-of-stock message is displayed. Using field mappings, you can set up your product pages to instead display the first size in stock.

To apply a field mapping to cause in-stock items to be displayed before out-of-stock items in matrix drop-down lists, perform the following steps:

In NSc Sync Configuration, under Advanced, select Field Mappings.
Right-click the ItemType table. From the context menu, select Add Field, then Standard RMS Field. The table definition dialog is displayed.

For Microsoft Dynamics RMS users, please use this mapping:
Remote Field Name, enter itemclass_primaryproductid. For Field Source, enter:

ISNULL( (select TOP 1 Item.ID from item inner join itemclasscomponent on itemclasscomponent.itemid =item.id AND itemclassid=itemclass.id where webitem = 1 AND Item.Quantity-QuantityCommitted > 0) ,0)

For PC America CRE set the field mapping for itemclass_primaryproductid to:

(select top 1 inventory_reference.id from Inventory_Reference left join inventory on 
inventory.itemnum=inventory_reference.itemnum left join Departments_Reference on Departments_Reference.Dept_ID=inventory.Dept_ID where dbo.ufn_ReturnInStock(inventory_reference.ItemNum)>0 and Inventory.Inactive = 0 AND Inventory.IsDeleted =0 AND Inventory.ItemType = 0 AND Inventory.IsModifier = 0 AND Inventory.IsRental = 'False' AND Inventory.AvailableOnline = 1 AND (Inventory.ModifierType NOT IN (1,2,3) OR Inventory.ModifierType IS NULL) AND Inventory.ItemNum NOT IN ('GIFT_C','Non_Inventory') AND Inventory.ItemNum NOT IN (SELECT itemNum FROM Inventory_GasPumpInterface) AND Inventory.ItemNum NOT IN (SELECT itemNum FROM Inventory_TagAlongs) And Inventory.store_id in ( select top 1 Store_ID from User_Defined where ud_id ='RONLORD' and Description = 'NITROSELLENABLED' and type = 1) AND Inventory_Reference.Store_ID = Inventory.Store_ID AND Departments_Reference.Store_ID =Inventory.Store_ID)

Click OK twice to remove each dialog box, then re-synchronize your WebStore.


Display on stock product first
#2

Will this work with CRE?


#3

For CRE can you try setting the field mapping for itemclass_primaryproductid to:

(select top 1 inventory_reference.id from Inventory_Reference left join inventory on
inventory.itemnum=inventory_reference.itemnum left join Departments_Reference on Departments_Reference.Dept_ID=inventory.Dept_ID where dbo.ufn_ReturnInStock(inventory_reference.ItemNum)>0 and Inventory.Inactive = 0 AND Inventory.IsDeleted =0 AND Inventory.ItemType = 0 AND Inventory.IsModifier = 0 AND Inventory.IsRental = ‘False’ AND Inventory.AvailableOnline = 1 AND (Inventory.ModifierType NOT IN (1,2,3) OR Inventory.ModifierType IS NULL) AND Inventory.ItemNum NOT IN (‘GIFT_C’,‘Non_Inventory’) AND Inventory.ItemNum NOT IN (SELECT itemNum FROM Inventory_GasPumpInterface) AND Inventory.ItemNum NOT IN (SELECT itemNum FROM Inventory_TagAlongs) And Inventory.store_id in ( select top 1 Store_ID from User_Defined where ud_id =‘RONLORD’ and Description = ‘NITROSELLENABLED’ and type = 1) AND Inventory_Reference.Store_ID = Inventory.Store_ID AND Departments_Reference.Store_ID =Inventory.Store_ID)


#4

Brendan,
Should I only do what you said to the field mapping for itemclass_primaryproductid or should I do both what you said and what Neil described?

Thanks,
Mike


#5

Hi Mike

Use Brendan’s Mapping instead of the one I posted because mind is specific for RMS

Neil


#6

Thank you Neil and Brendan. I will try this and report back in case anyone else using CRE is needing to know.

Thank you,
Mike


#7

I followed your steps for the RMS mapping and I cant get it work on our site, nothing changes even after purging the table cache, refreshing the field and re-syncing.


#8

Do I have the option to show sizing by size (starting with smallest to largest) instead of alphabetically or by stock?


#9

1 year later and no reply or fix in sight.


#10

Please use our ticketing system for store-specific issues. The mapping is working fine for others. You can open a ticket here:

https://portal.nitrosell.com/support/openticket/