From 35e255e7af8c03f5bd3fbf3e44881e584beb69dd 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] [SIGNED-OFF] 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 Signed-off-by: Owen Leonard --- .../prog/en/modules/reports/dictionary.tt | 74 +++++++++++----------- .../en/modules/reports/guided_reports_start.tt | 4 +- 2 files changed, 39 insertions(+), 39 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..9bcf24b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/dictionary.tt @@ -80,27 +80,27 @@
- - - - - + + + + + - - [% FOREACH definition IN definitions %] - - - - - - - - [% END %] -
NameDescriptionAreaDefinition
NameDescriptionAreaDefinition Action
[% definition.name %][% definition.description %][% definition.areaname %][% definition.saved_sql %]
- - - -
+ + [% FOREACH definition IN definitions %] + + [% definition.name | html %] + [% definition.description | html %] + [% definition.areaname %] + [% definition.saved_sql %] +
+ + + +
+ + [% END %] + [% ELSE %]
There are no saved definitions. Add a definition to the dictionary.
[% END %] @@ -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