From 919999d04e8426363cfc55f9f1dca2d8b99058d1 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 16 Apr 2015 16:57:03 +0200 Subject: [PATCH] Bug 10752: Alert the librarian if the suggestion has not been added Test plan: - Create a new suggestion, chose a short term as your title and copy it. - Leave all other fields of the suggestion form untouched. - Save your first suggestion. - Enter a second suggestion with the same title. Before this patch, the suggestion was not inserted without alert. With this patch, an alert is displayed on the interface. --- .../intranet-tmpl/prog/en/modules/suggestion/suggestion.tt | 12 ++++++++++++ suggestion/suggestion.pl | 5 +++++ 2 files changed, 17 insertions(+) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt index aeb8946..6792b04 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt @@ -457,6 +457,18 @@ h4.local_collapse a { font-size : 80%; text-decoration: none; } fieldset.brief o

Suggestions management

+ +[% FOR m IN messages %] +
+ [% SWITCH m.code %] + [% CASE 'already_exists' %] + The suggestion has not been inserted. The same suggestion already exists (see the suggestion) + [% CASE %] + [% m.code %] + [% END %] +
+[% END %] + [% UNLESS ( notabs ) %]