Koha/koha-tmpl/intranet-tmpl/prog/en/modules
Jonathan Druart a236b684fd Bug 17981: Add a preview mode for notice templates
This patch is a first step to provide a preview mode for notice
templates.

CHECKIN, CHECKOUT and HOLD_SLIP are supported so far.
Maybe more, but I have not tested yet and the interface will not allow
you to generate the preview.

The idea is to provide an idea of how will render the messages generated
from a notice template.

A new "Preview" button is added close to each textarea on the editing
notice templates view.
For each notice template code (letter_code), we will need some input
data to produce the preview.

For instance, for CHECKIN we need an barcode. From the barcode we
can guess all the other data.
For CHECKOUT we will need the borrowernumber and the barcode.
Note that the way to enter the data for the preview is not really
user-friendly, for CHECKOUT you will have to fill
'borrowernumber|barcode', but the placeholder will help you to know how
and what to fill.
In the modal window, you will see 4 blocks:
1/ the content of the letter (with the placeholds << >>)
2/ the generated message (with the data filled)
3/ if the letter contained historical syntax markers, the screen will
try to generate a notice template using the TT syntax
4/ the generated message from this TT syntax
=> You will be able to compare the 2 generated messages.

What is the goal of this first patchset:
- Show this first POC and get feedback from other developpers
- Add a way to easily visualise the differences between the 2 syntaxes
- Confort users with the TT syntax and the migration step from the
historical syntax.

I'd like to get opinions before going further.

The possibilities:
- Mock data to get fully working generated messages for any notice
templates. For instance, for CHECKIN and CHECKOUT, the item is not
checked in/out yet. So we cannot access the issue's information.
(I have no idea how to do that)
- Browse the data to get the ones we want to use for the preview (big).

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2018-04-12 10:51:50 -03:00
..
acqui Bug 20426: Fix default fund value when adding orders from iso2709 file 2018-04-12 10:50:38 -03:00
admin Bug 14769: Add preference AuthorityControlledIndicators 2018-04-12 10:50:35 -03:00
authorities Bug 18904: (follow-up) Rebase onto 14769 2018-04-12 10:50:37 -03:00
basket Bug 20033: Switch single-column templates to Bootstrap grid: Catalog 2018-02-15 13:30:23 -03:00
batch Bug 9210: wrap long lines in printed hold notices 2014-01-15 15:51:44 +00:00
catalogue Bug 19953: Record page: acquisition details: add column for invoice 2018-04-04 16:06:57 -03:00
cataloguing Bug 18904: (follow-up) Use Ctrl+Shift+L 2018-04-12 10:50:38 -03:00
circ Bug 18789: (follow-up) Pass a Koha::Patron object from returns.pl 2018-04-09 16:15:17 -03:00
clubs Bug 20035: Switch single-column templates to Bootstrap grid: Patron clubs 2018-02-15 13:30:23 -03:00
common Bug 19641: Move patron templates to the footer 2018-02-15 13:30:23 -03:00
course_reserves Bug 20282: Match course reserve on holdingbranch 2018-04-02 18:07:45 -03:00
errors Bug 16270: Typo authentification/authentication 2016-04-29 14:44:26 +00:00
help Bug 20190: Replace intranet-tmpl with [% interface %] 2018-02-13 12:57:46 -03:00
ill Bug 20295: Allow translating link title in ILL module 2018-02-27 13:48:17 -03:00
installer Bug 20104: Update minimum version of Perl to 5.20 2018-04-11 16:45:09 -03:00
labels Bug 12020: Allow translating label-edit-batch hardcoded strings 2018-03-26 17:31:15 -03:00
members Bug 20518: Don't show "Messages" header and link on patron details if there are no messages 2018-04-11 16:45:09 -03:00
offline_circ Bug 20036: Switch single-column templates to Bootstrap grid: Offline circulation 2018-02-15 13:30:23 -03:00
onboarding Bug 20189: Fix style on installer and onboarding pages 2018-02-13 12:57:21 -03:00
patron_lists Bug 19837: Add error feedback for duplicated or unfound cardnumbers 2018-02-18 16:48:46 -03:00
patroncards Bug 19961: Move template JavaScript to the footer: Patron card creator 2018-03-26 17:31:26 -03:00
plugins Bug 20438: Allow uninstalling plugins not implementing the 'uninstall' method 2018-03-26 17:01:11 -03:00
reports Bug 9634: Allow for combining same paraneters in SQL reports 2018-04-11 16:45:08 -03:00
reserve Bug 18474: Restore multiple holds when patron is searched for 2018-04-02 18:07:34 -03:00
reviews Bug 18789: Send Koha::Patron object to the templates 2018-02-16 13:03:58 -03:00
rotating_collections Bug 12904: Force browser to load new javascript files after upgrade 2018-02-08 14:53:24 -03:00
serials Bug 20045: Switch single-column templates to Bootstrap grid: Various 2018-03-26 17:31:26 -03:00
services Revert bug 13618 - "Prevent XSS in the Staff Client and the OPAC" due to performance issues 2016-02-11 19:39:53 +00:00
suggestion Bug 20045: Switch single-column templates to Bootstrap grid: Various 2018-03-26 17:31:26 -03:00
tags Bug 12904: Force browser to load new javascript files after upgrade 2018-02-08 14:53:24 -03:00
test Bug 14321: Final cleanup, removing obsolete files 2015-09-25 12:02:52 -03:00
tools Bug 17981: Add a preview mode for notice templates 2018-04-12 10:51:50 -03:00
virtualshelves Bug 19960: Update popup window templates to use Bootstrap grid: Add to list 2018-02-15 13:30:23 -03:00
about.tt Bug 19904: (follow-up) Add Nick Clemens as RM assistant 2018-04-11 16:51:03 -03:00
auth.tt Bug 20291: Add a StaffLoginInstructions preference for adding text to staff client login 2018-04-02 18:08:07 -03:00
intranet-main.tt Bug 20268: CSS regression: white gap on the top of the staff pages 2018-03-19 13:55:46 -03:00