From a0078afaf5add85d52b755ac6c58c10a900ab039 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20V=C3=A9ron?= Date: Sun, 4 Jun 2017 19:55:08 +0200 Subject: [PATCH] Bug 11235: Names for reports and dictionary are cut off when quotes are used To reproduce for saved reports: - Go to Home > Reports > Guided reports wizard - Create a report with double quotes in it's name, e.g. 'My "double quoted" report' - Go to "Saved reports", locate in the list the new report (name is correct here, is correct in database as well) - From the selection button at the right choose "Edit" - Result: Content of edit field for the report name is truncated (displays only: 'My') To reproduce for Reports dictionary: - Go to Home > Reports > Guided reports wizard - Create a new definition, give it the name 'The "double quoted" definition' and enter a text with double quotes for "Description" - Save - Verify that in the list of definitions both name and descriptions are truncated (in database as well) To test: - Apply patch - Verify that issues described above can no longer be reproduced --- .../prog/en/modules/reports/dictionary.tt | 54 +++++++++++----------- .../en/modules/reports/guided_reports_start.tt | 4 +- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt index e32d300..eb711ee 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt @@ -89,16 +89,16 @@ [% FOREACH definition IN definitions %] - [% definition.name %] - [% definition.description %] - [% definition.areaname %] - [% definition.saved_sql %] -
- - - -
- + [% definition.name | html %] + [% definition.description | html %] + [% definition.areaname %] + [% definition.saved_sql %] +
+ + + +
+ [% END %] [% ELSE %] @@ -133,8 +133,8 @@
  1. - - + + - - + + - - + + [% FOREACH column IN columns %]
    1. Column: [% column.name %]
    2. [% IF ( column.distinct ) %] -
    3. +
    4. [% END %] [% IF ( column.date ) %]
    5. @@ -235,9 +235,9 @@ [% IF ( step_5 ) %]
      - - - + + +

      Add new definition

      @@ -246,10 +246,10 @@ Step 5 of 5: Confirm details
      1. - Name:[%- definition_name -%] + Name:[%- definition_name | html -%]
      2. - Description:[%- definition_description -%] + Description:[%- definition_description | html -%]
      3. Area:[%- PROCESS area_name area=area -%] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt index 4ef3b0e..499daa3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt @@ -931,7 +931,7 @@ $(document).ready(function() { Create report from SQL
        1. - [% IF ( reportname ) %] + [% IF ( reportname ) %] [% ELSE %][% END %] Required
        2. [% PROCESS group_and_subgroup_selection %] @@ -1023,7 +1023,7 @@ Sub report: Required +
        3. Required
        4. [% PROCESS group_and_subgroup_selection %] [% IF (public) %]
        5. -- 2.1.4