Project

General

Profile

Revision 9a28ac3f

Added by Assos Assos almost 4 years ago

Weekly update of contrib modules

View differences:

drupal7/sites/all/modules/views_bulk_operations/views_bulk_operations.module
791 791
  // Determine if the operation needs to be executed directly.
792 792
  $aggregate = $operation->aggregate();
793 793
  $skip_batching = $vbo->get_vbo_option('skip_batching');
794
  $save_view = $vbo->get_vbo_option('save_view_object_when_batching');
794 795
  $force_single = $vbo->get_vbo_option('force_single');
795 796
  $execute_directly = ($aggregate || $skip_batching || $force_single);
796 797
  // Try to load all rows without a batch if needed.
......
812 813
      'exposed_input' => $vbo->view->get_exposed_input(),
813 814
    ),
814 815
  );
816
  // If defined, save the whole view object.
817
  if ($save_view) {
818
    $options['view_info']['view'] = $vbo->view;
819
  }
815 820
  // Create an array of rows in the needed format.
816 821
  $rows = array();
817 822
  $current = 1;
......
911 916
  }
912 917

  
913 918
  $view_info = $options['view_info'];
914
  $view = views_get_view($view_info['name']);
915
  $view->set_exposed_input($view_info['exposed_input']);
916
  $view->set_arguments($view_info['arguments']);
917
  $view->set_display($view_info['display']);
919
  if (isset($view_info['view'])) {
920
    $view = $view_info['view'];
921
    // Because of the offset, we want our view to be re-build and re-executed.
922
    $view->built = FALSE;
923
    $view->executed = FALSE;
924
  }
925
  else {
926
    $view = views_get_view($view_info['name']);
927
    $view->set_exposed_input($view_info['exposed_input']);
928
    $view->set_arguments($view_info['arguments']);
929
    $view->set_display($view_info['display']);
930
  }
918 931
  $view->set_offset($context['sandbox']['progress']);
919 932
  $view->build();
920 933
  $view->execute($view_info['display']);

Also available in: Unified diff