Tags/topics: 
1
Answers
Vote up!
0
Vote down!

List products without displays using views

Hello,

I'm using Drupal commerce with commerce backoffice module to improve backoffice management.

It works pretty well, but there is one feature I need and I didn't find how to do it.

On the All products variation views (so a commerce product view), I need to create a filter that allow to list all products that are not associated with a product display.

How can I do that using views filters ? I tried a lot of different combination, relationship etc... but couldn't find a way to do this.

Thanks

Alex

Asked by: Alex
on July 31, 2015

1 Answer

Vote up!
0
Vote down!

This can be tricky, but it is doable. What you need to do is create a view that lists the product variations.

Then add a relationship to the product page using the relationship called "Commerce Product: Referencing Node"

Then add a filter on something for a node, I chose "Content: Title" and set it to look for "Is Empty (NULL)".

This successfully gave me a list of SKUs that didn't have product pages. If you have more than one relationship field you would need to create a relationship per field, then a filter per field and make it a part of an "OR" statement in the filters.

Josh

Josh Miller
Answer by: Josh Miller
Posted: Aug 4, 2015
骚虎视频_骚虎app