webform-results-submissions.tpl.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. /**
  3. * @file
  4. * Result submissions page.
  5. *
  6. * Available variables:
  7. * - $node: The node object for this webform.
  8. * - $submissions: The Webform submissions array.
  9. * - $total_count: The total number of submissions to this webform.
  10. * - $pager_count: The number of results to be shown per page.
  11. * - is_submissions: The user is viewing the node/NID/submissions page.
  12. * - $table: The table[] array consists of three keys:
  13. * - $table['#header']: Table header.
  14. * - $table['#rows']: Table rows.
  15. * - $table['#operation_total']: Maximum number of operations in the operation
  16. * column.
  17. */
  18. ?>
  19. <?php if (count($table['#rows'])): ?>
  20. <?php print theme('webform_results_per_page', array('total_count' => $total_count, 'pager_count' => $pager_count)); ?>
  21. <?php print render($table); ?>
  22. <?php else: ?>
  23. <?php print t('There are no submissions for this form. <a href="!url">View this form</a>.', array('!url' => url('node/' . $node->nid))); ?>
  24. <?php endif; ?>
  25. <?php if ($is_submissions): ?>
  26. <?php print theme('links', array('links' => array('webform' => array('title' => t('Go back to the form'), 'href' => 'node/' . $node->nid)))); ?>
  27. <?php endif; ?>
  28. <?php if ($pager_count): ?>
  29. <?php print theme('pager', array('limit' => $pager_count)); ?>
  30. <?php endif; ?>