You'll need to fix this by changing lines 35 - 41 of views_service.inc from

  if (!empty($limit)) {
    $view->set_use_pager(TRUE);
  }
  else {
    // Disable the user pager.
    $view->set_use_pager(FALSE);
  }

to

  if (!empty($limit)) {
    $view->set_use_pager = TRUE;
  }
  else {
    // Disable the user pager.
    $view->set_use_pager = FALSE;
  }

Comments

marcingy’s picture

Status: Needs review » Postponed

Postponing in light of http://drupal.org/node/709100

gdd’s picture

Status: Postponed » Closed (won't fix)

I don't see how this can be a problem in 6.3 since 6.3 does not have views service. I also don't want to do any changes to views service for Views 3 since we are deprecating it, it just seems like a waste of time and the code is just going to get more complicated. For instance your change above fixes this problem for Views 3 but breaks it for Views 2.

So basically I'm closing this and any other issues that are not bugs in the current service for Views 2.

gdd’s picture

Project: Services » Services Views
Version: 6.x-3.x-dev »

Moving this to the new Services Views project for consideration there.

vishun’s picture

This approach appears to work for both Views 2 and Views 3

<?php
  if (!empty($limit)) {
    if (method_exists($view,'set_use_pager')) {
      $view->set_use_pager(TRUE);
    } else {
      $view->set_use_pager = TRUE;
    }
  }
  else {
    // Disable the user pager.
    if (method_exists($view,'set_use_pager')) {
      $view->set_use_pager(FALSE);
    } else {
      $view->set_use_pager = FALSE;
    }
  }
?>
Renee S’s picture

Version: » 6.x-1.x-dev

Thanks, @vishun and @RasputinJones, that did it for me - I'm still on Services2 but with Views3, this corrects the error I was getting.

newnewuser’s picture

@vishun code works for me. View3, Service2. Thanks a lot.

vishun’s picture

Just a quick revision

<?php
  if (method_exists($view,'set_use_pager')) {
    if (!empty($limit)) {
      $view->set_use_pager(TRUE);
    } else {
      $view->set_use_pager(FALSE);
    }
  } else {
    if (!empty($limit)) {
      $view->set_use_pager = TRUE;
    } else {
      $view->set_use_pager = FALSE;
    }
  }
?>
sibiru’s picture

Status: Closed (won't fix) » Active

I have problem paging for 7.x version with Views3 any clue how to fix this?

thanks

marcingy’s picture

Status: Active » Closed (won't fix)

Please create a new issue rather re-opening a very old issue,