From 8097c467df74d9e63eae033108640477e397043f Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 11 Feb 2014 14:09:29 +0100 Subject: [PATCH] Bug 12404: Add some documentation in the help page. --- .../prog/en/modules/help/tools/csv-profiles.tt | 87 +++++++++++++++++++++- .../prog/en/modules/tools/csv-profiles.tt | 1 + 2 files changed, 87 insertions(+), 1 deletion(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/csv-profiles.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/csv-profiles.tt index 89a20bf..327bb04 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/csv-profiles.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/help/tools/csv-profiles.tt @@ -52,6 +52,91 @@

Your CSV Profiles will appear on the export list or cart menu under the 'Download' button in both the staff client and the OPAC

+

Template Toolkit tags

+[% TAGS [- -] %] +

You can use Template Toolkit tags in order to build complex CSV files.

+

To access to the field list of the current record, you have to use the 'fields' variables (which is a hashref).

+

All fields of the record is content into this variable in a "field tag name" key.

+

In order to manage multi-valuated field and subfields, the field and subfields are stored into an arrayref

+

For example, the following MARC record:

+
+008 - FIXED-LENGTH DATA ELEMENTS--GENERAL INFORMATION
+  @ 140211b xxu||||| |||| 00| 0 eng d
+
+100 ## - MAIN ENTRY--PERSONAL NAME
+  a Personal name My author
+
+245 ## - TITLE STATEMENT
+  a Title My first title
+  a Title My second title
+  b Remainder of title My remainder
+
+245 ## - TITLE STATEMENT
+  a Title My third title
+
+

will be stored into the following structure:

+
+{
+    fields => {
+                008 => [
+                        "140211b xxu||||| |||| 00| 0 eng d"
+                ],
+                100 => [
+                            {
+                                a => [
+                                    "My author"
+                                ]
+                            }
+                ]
+                245 => [
+                            {
+                                a => [
+                                    "My first title",
+                                    "My second title"
+                                ],
+                                b => [
+                                    "My remainder"
+                                ]
+                            },
+                            {
+                                a => [
+                                    "My third title"
+                                ]
+                            }
+                ]
+    }
+}
+
+

The indicators can be accessible using the 'indicator' key.

+

Example: [% fields.245.0.indicator.1 %] is the indicator 1 for the first 245 field.

+ +

Some examples:

+ +

Note that the authorized values won't be replaced by their descriptions.

+

See the full documentation for CSV Profiles in the manual (online).

-[% INCLUDE 'help-bottom.inc' %] \ No newline at end of file +[- INCLUDE 'help-bottom.inc' -] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/csv-profiles.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/csv-profiles.tt index 7bbb0e4..785d853 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/csv-profiles.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/csv-profiles.tt @@ -163,6 +163,7 @@ function reloadPage(p) {

You have to define which fields or subfields you want to export, separated by pipes.

You can also use your own headers (instead of the ones from Koha) by prefixing the field number with an header, followed by the equal sign.

Example: Personal name=200|Entry element=210$a|300|009

+

You can use Template Toolkit tags too. See the help page for more information.

  • -- 2.1.0