From d08543f70544f3e0f6ab5cd080b5165b100f0bfe Mon Sep 17 00:00:00 2001 From: Will Rossiter Date: Sat, 19 May 2012 10:49:34 +1200 Subject: [PATCH] MINOR: translate pages string in submittedformfield. MINOR: updated unit test to reflect updated template --- templates/SubmittedFormReportField.ss | 3 ++- tests/SubmittedFormTest.php | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/templates/SubmittedFormReportField.ss b/templates/SubmittedFormReportField.ss index 28d8857..3ae8bea 100644 --- a/templates/SubmittedFormReportField.ss +++ b/templates/SubmittedFormReportField.ss @@ -23,7 +23,8 @@ <% if Submissions.MoreThanOnePage %>
- Pages: + <% _t('PAGES', 'Pages') %>: + <% loop Submissions.Pages() %> <% if CurrentBool %> $PageNum diff --git a/tests/SubmittedFormTest.php b/tests/SubmittedFormTest.php index 008d370..84012a1 100644 --- a/tests/SubmittedFormTest.php +++ b/tests/SubmittedFormTest.php @@ -31,8 +31,8 @@ class SubmittedFormTest extends FunctionalTest { // check to ensure that the pagination exists $pagination = $parser->getBySelector('.userforms-submissions-pagination'); - $this->assertEquals(str_replace("\n", ' ',(string) $pagination[0]->span), "Viewing rows 0 - 10 of 11 rows"); - $this->assertEquals(str_replace("\n", ' ',(string) $pagination[0]->a), "Next page"); + $this->assertEquals(str_replace("\n", ' ',(string) $pagination[0]->span), "Pages:"); + $this->assertEquals(str_replace("\n", ' ',(string) $pagination[0]->a), "2"); // ensure the actions exist $actions = $parser->getBySelector('.userforms-submission-actions');