MT 1587 : Fixed creation bug
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / tools / csv-profiles.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2
3         <title>Koha &rsaquo; Catalog &rsaquo; Profile for CSV export</title>
4
5         <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
6
7 <script language="Javascript" type="text/javascript">
8 function reloadPage(p) {
9         var id = p.value;
10         if (id != 0) { document.location = "/cgi-bin/koha/tools/csv-profiles.pl?id=" + id; }
11 }
12 </script>
13
14 </head>
15
16 <body>
17         <!-- TMPL_INCLUDE NAME="header.inc" -->
18         <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
19
20         <div id="breadcrumbs">
21                 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
22                 &rsaquo; <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a>
23                 &rsaquo; New profile for CSV export
24         </div>
25
26         <div id="doc3" class="yui-t2">
27                 <div id="bd">
28                         <div id="yui-main">
29                                 <div class="yui-b">
30                                     <!-- TMPL_IF EXPR="success || error" -->
31                                             <!-- TMPL_IF NAME="success" -->
32                 <!-- TMPL_IF EXPR="action eq 'create'" --><p>The new CSV profile "<!-- TMPL_VAR NAME="profile_name" -->" has been successfully created.</p><!-- /TMPL_IF -->
33                 <!-- TMPL_IF EXPR="action eq 'edit'"   --><p>The CSV profile has been successfully modified.</p><!-- /TMPL_IF -->
34                 <!-- TMPL_IF EXPR="action eq 'delete'" --><p>The CSV profile has been successfully deleted.</p><!-- /TMPL_IF -->
35                                             <!-- TMPL_ELSE -->
36                 <!-- TMPL_IF EXPR="action eq 'create'" --><p class="error">The new CSV profile "<!-- TMPL_VAR NAME="profile_name" -->" has not been created.</p><!-- /TMPL_IF -->
37                 <!-- TMPL_IF EXPR="action eq 'edit'"   --><p class="error">The CSV profile has not been modified.</p><!-- /TMPL_IF -->
38                 <!-- TMPL_IF EXPR="action eq 'delete'" --><p class="error">The CSV profile has not been deleted.</p><!-- /TMPL_IF -->
39                                             <!-- /TMPL_IF -->
40                                     <!-- /TMPL_IF -->
41
42                                         <h1>New profile for CSV export</h1>
43
44                                              <form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post">
45                                                 <fieldset class="brief">
46                                                     <label for="profile_name">Profile name :</label>
47                                                     <input type="text" id="profile_name" name="profile_name" /><br /><br />
48
49                                                     <label for="profile_description">Profile description :</label>
50                                                     <textarea cols="50" rows="2" name="profile_description" id="profile_description"></textarea><br /><br />
51
52                                                     <label for="profile_content">Profile marcfields :</label>
53                                                     <textarea cols="50" rows="2" name="profile_content" id="profile_content"></textarea>
54                                                     <p>You have to define which fields or subfields you want to export, separated by pipes.<br />
55                                                         Example&nbsp;: 200|210$a|301
56                                                     </p>
57                                                 </fieldset>
58                                                 <input type="hidden" name="action" value="create" />
59                                                 <input type="submit" />
60                                             </form>
61                                         <!-- /TMPL_IF -->
62
63                                         <!-- TMPL_IF NAME="existing_profiles" -->
64                                         <br /><br />
65                                         <h1>Modify or delete an existing profile</h1>
66                                                 
67                                             <form action="/cgi-bin/koha/tools/csv-profiles.pl" method="post">
68                                                 <fieldset class="brief">
69                                                     <label for="modify_profile_name">Profile name :</label>
70                                                     <select id="modify_profile_name" name="profile_name" onchange="javascript:reloadPage(this)">
71                                                         <option value="0">-- Choose One --</option>
72                                                         <!-- TMPL_LOOP NAME="existing_profiles" -->
73                                                         <option value="<!-- TMPL_VAR NAME="export_format_id" -->"<!-- TMPL_IF EXPR="export_format_id eq selected_profile_id" --> selected="selected"<!-- /TMPL_IF-->><!-- TMPL_VAR NAME="profile" --></option>
74                                                         <!-- /TMPL_LOOP -->
75                                                     </select><br /><br />
76
77                                                     <label for="modify_profile_description">Profile description :</label>
78                                                     <textarea cols="50" rows="2" name="profile_description" id="modify_profile_description"><!-- TMPL_VAR NAME="selected_profile_description" --></textarea><br /><br />
79
80                                                     <label for="modify_profile_content">Profile marcfields :</label>
81                                                     <textarea cols="50" rows="2" name="profile_content" id="modify_profile_content"><!-- TMPL_VAR NAME="selected_profile_marcfields" --></textarea><br /><br />
82                                                     
83                                                     <label for="delete">Delete selected profile ?</label>
84                                                     <input type="checkbox" name="delete" id="delete" />
85
86                                                 </fieldset>
87
88                                                 <input type="hidden" name="modify_profile_id" value="<!-- TMPL_VAR NAME="selected_profile_id" -->" />
89                                                 <input type="hidden" name="action" value="edit" />
90                                                 <input type="submit" />
91                                             </form>
92                                         <!-- /TMPL_IF -->
93
94                                 </div>
95                         </div>
96                         <div class="yui-b">
97
98
99                 </div>
100         </div>
101         <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->