The case of the missing Coveo facet picker

Quick one this week. Mostly to try and save my own blushes, because the issue here was completely my fault. For the first time on a particular project I was trying to do some Coveo development work. I had created a page based on the default MVC templates they provide for search, but when I tried to add a Facet in Content Editor, I found myself staring at this:

Missing Picker

No picker for the field to facet on – so no way to make the Facet component work…

Over the course of a frustrating couple of hours I tried a load of tests to see if I could spot an issue:

Was Coveo working?

Diagnostics

Diagnostics said yes.

Any obvious config errors?

Config

Nope, nothing looks like an error here. But a subtle hint that I failed to spot.

Were there any Javascript errors in the client?

Script Console

Nope – nothing that seems relevant.

I disappeared off down a few rabbit holes at this point, wondering if the project had done something in its custom configuration that might have been breaking bits of the Sitecore UI. I spent a good hour bouncing between config files and Google, getting nowhere. But that finally lead me to looking at the HTML DOM around the missing control:

UI DOM

And suddenly the clouds lifted: The picker control is there – but it’s expressed as a custom UI control: <coveoui:facetpicker/>. The custom control isn’t being executed. I’d been assuming that because it looks like an ordinary dropdown list, it was just a standard UI control. But custom controls in the Sitecore UI need to be registered so that Sitecore knows what code to run to make them work. And when I fired up the ShowConfig.aspx page and tried searching for this control’s definition I found nothing.

So checking the Coveo configuration include files I found:

Untitled

Cue me banging my head on the desk and feeling embarrassed.

I had forgotten to rename the Coveo UI config file, as specified in their instructions:

Instructions

Low and behold, following the instructions correctly and renaming the UI config file gave me back my picker:

Working

Hopefully leaving this out there for Google will make fixing this easier for anyone else who makes the same mistake…

Advertisements

One thought on “The case of the missing Coveo facet picker

  1. Pingback: Why can’t I bookmark my facets? | Jeremy Davis

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s