diff --git a/lib/Drupal/views/Plugins/views/area/Result.php b/lib/Drupal/views/Plugins/views/area/Result.php index 15027251aabed9a8fdda841233bb3d45ca15ddd2..eda4601a905f09794c7b58210174fcd1df581b3e 100644 --- a/lib/Drupal/views/Plugins/views/area/Result.php +++ b/lib/Drupal/views/Plugins/views/area/Result.php @@ -35,6 +35,7 @@ function options_form(&$form, &$form_state) { '@name -- the human-readable name of the view', '@per_page -- the number of items per page', '@current_page -- the current page number', + '@current_record_count -- the current page record count', '@page_count -- the total page count', ), ); @@ -81,8 +82,9 @@ function render($empty = FALSE) { $start = ($current_page - 1) * $per_page + 1; $end = $total_count; } + $current_record_count = ($end - $start) + 1; // Get the search information. - $items = array('start', 'end', 'total', 'name', 'per_page', 'current_page', 'page_count'); + $items = array('start', 'end', 'total', 'name', 'per_page', 'current_page', 'current_record_count', 'page_count'); $replacements = array(); foreach ($items as $item) { $replacements["@$item"] = ${$item};