I have a View with a few displays. I don't see a 'Services' display, so I have to use block. Whatever. Anyway, every display gives me what I want except for one. It has an exposed filter for node title, and the id is title. The node title filter is set to CONTAINS.

I am calling:

  • /kiosk/views/kiosk_nodes?display_id=block_4&args[0]=436&title="example"
  • /kiosk/views/kiosk_nodes?display_id=block_4&args[0]=436&filters[title]="example"
  • /kiosk/views/kiosk_nodes?display_id=block_4&args[0]=436&title[value]="example"

None of those filter anything in the view. I can see that services_views_retrieve() gets the $filters and the value is passed (only when I use filters[title]) but the results never change.

Called with:

Zepto.ajax(
      {
        url: // any of the urls from above //,
        dataType: 'jsonp',
        data: {filters: { title: keywords }, args: [Kiosk.variables.kiosk_id] },
        type: 'GET',
        cache: false,
        success: function (response) {
          var context = { items: [], keywords: keywords }

          $.each(response, function(key, value) {
            context.items.push({ 'title' : value.title, 'nid': value.nid, 'teaser': value.teaser });
          });

          callback(context);
        }
      }
    );

Only args seems to work, filters does not.

Comments

kevinquillen’s picture

Okay, so... does this module just not work for searching for views? I can't seem to get it to recognize filters whatsoever, tried everything according to the documentation.

Coyote’s picture

I've noticed that when you attempt to access the view via:

http://www.yourdomain.com/[endpoint]/[your_view_display_name]

rather than

http://www.yourdomain.com/[endpoint]/views/[your_view_name]

...filters do not work.

Accessing via the clunkier, and less customizable url works normally with filters and arguments and such.

kylebrowning’s picture

Issue summary: View changes
Status: Active » Closed (works as designed)