Modified viewlog.pl to discern where it was called from and display the appropriate...
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / tools / viewlog.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Tools &rsaquo; Logs</title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 <!-- TMPL_INCLUDE NAME="calendar.inc" -->
5 </head>
6 <body>
7 <!-- TMPL_INCLUDE NAME="header.inc" -->
8 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
9
10 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> &rsaquo; Logs</div>
11
12 <div id="doc3" class="yui-t2">
13    
14    <div id="bd">
15         <div id="yui-main">
16         <div class="yui-b">
17
18 <h1>Browse system logs</h1>
19
20 <form method="post" action="/cgi-bin/koha/tools/viewlog.pl">
21
22 <fieldset>
23     <legend>Additional parameters</legend>
24         <p>
25         <label for="from"> Display from</label> <input type="text" size="10" id="from" name="from" value="<!-- TMPL_VAR NAME="datefrom"-->" />
26                 <img src="<!-- TMPL_VAR Name="themelang" -->/lib/calendar/cal.gif" border="0" alt="Show Calendar" id="openCalendarFrom" style="cursor: pointer;" />
27                 <label for="to">to</label> <input size="10" id="to" name="to" type="text" value="<!-- TMPL_VAR NAME="dateto"-->" />
28                 <img src="<!-- TMPL_VAR Name="themelang" -->/lib/calendar/cal.gif" id="openCalendarTo" alt="Show Calendar" style="cursor: pointer;" border="0" />
29                         <script type="text/javascript">
30                                 // function submit_check (from_id,to_id) {
31                                 //      var dateFrom = Date_from_syspref(document.getElementById(from_id).value);
32                                 //      var dateTo   = Date_from_syspref(document.getElementById(  to_id).value);
33                                 //      var today = new Date();
34                                 //      if (dateFrom < dateTo) { 
35                                 //              alert("The starting date cannot be after the ending date.");
36                                 //              document.getElementById(to_id).select();
37                                 //              return false;
38                                 //      }
39                                 //      if (dateFrom > today) { 
40                                 //              alert("The starting date cannot be in the future.");
41                                 //              document.getElementById(from_id).select();
42                                 //              return false;
43                                 //      }
44                                 // }
45
46                                 // return true if the date is blocked.
47                                 function disable_from(date) {var limit = get_Calendar_limit(date,'to'  ); return (limit && limit < date);}
48                                 function disable_to  (date) {var limit = get_Calendar_limit(date,'from'); return (limit && limit > date);}
49
50                                 Calendar.setup({
51                                         inputField : "from",
52                                         ifFormat : "<!-- TMPL_VAR NAME="DHTMLcalendar_dateformat" -->",
53                                         button : "openCalendarFrom",
54                                         disableFunc : disable_from,
55                                         dateStatusFunc : disable_from
56                                 });
57                                 Calendar.setup({
58                                         inputField : "to",
59                                         ifFormat : "<!-- TMPL_VAR NAME="DHTMLcalendar_dateformat" -->",
60                                         button : "openCalendarTo",
61                                         disableFunc : disable_to,
62                                         dateStatusFunc : disable_to
63                                 });
64                     </script>
65                 </p>
66
67                 <p><b>Export</b></p>
68         <p><input id="screen" type="radio" checked="checked" name="output" value="screen" />
69         <label for="screen" >To screen in the browser</label></p>
70                 <p>
71                 <input id="file" type="radio" name="output" value="file" />
72                  <label for="file">To file</label>
73                 <input type="text" name="basename" value="Export" /> into an application  
74                 <!-- TMPL_VAR NAME="CGIextChoice" -->
75                 <!-- TMPL_VAR NAME="CGIsepChoice" -->
76             <input type="hidden" name="report_name" value="<!--TMPL_VAR NAME="report_name" -->" />
77             <input type="submit" value=" GO " />
78             </p>
79 </fieldset>
80     
81     <!-- TMPL_IF NAME="do_it" -->
82         <p>
83         <!-- TMPL_IF NAME="total" -->
84             <b><!-- TMPL_VAR NAME="total" --> lines found.</b>
85         <!-- TMPL_ELSE -->
86             <b><span class="problem">No log found.</span></b>
87         <!-- /TMPL_IF -->
88         </p>
89     <!-- /TMPL_IF -->
90     <table>
91     <tr>
92         <th>Date</th>
93         <th>Librarian</th>
94         <th>Module</th>
95         <th>Action</th>
96                 <th>Object</th>
97                 <th>Info</th>
98         </tr>
99         <tr>
100             <td>
101             <input type="submit" value="filter" />
102             <input type="hidden" name="do_it" value="1" />
103             </td>
104             <td>
105                 <input type="text" name="user" value="<!-- TMPL_VAR NAME="user"-->" />
106             </td>
107             <td>
108                 <select name="module">
109                             <option value="" selected="selected">All</option>
110                             <option value ="CATALOGUING">Catalogue</option>
111                                 <option value ="MEMBERS">Members</option>
112                                 <option value ="ACQUISITION">Acquisitions</option>
113                                 <option value ="SERIAL">Serial</option>
114                                 <option value="CIRCULATION">Circulation</option>
115                                 <option value="LETTER">Letter</option>
116                                 <option value="FINES">Fines</option>
117                         </select>
118             </td>
119             <td>
120                 <select name="action">
121                         <option value ="">All</option>
122                                 <option value ="add">Add</option>
123                                 <option value ="del">Delete</option>
124                                 <option value ="mod">Modify</option>
125                                 <option value="issue">Issue</option>
126                                 <option value="return">Return</option>
127                         </select>
128             </td>
129             <td>
130                 <input type="text" name="object" value="<!-- TMPL_VAR NAME="object"-->" />
131             </td>
132             <td>
133                 <input type="text" name="info" value="<!-- TMPL_VAR NAME="info"-->" />
134             </td>
135         </tr>
136             <!-- TMPL_LOOP NAME="looprow" -->
137                                         <tr>
138                                                 <td><!-- TMPL_VAR NAME="timestamp" --></td>
139                                                 <td>
140                                                     <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=<!-- TMPL_VAR NAME="user" -->" title="display detail for this librarian.">
141                                                         <!-- TMPL_VAR NAME="user" -->
142                                                     </a>
143                                                 </td>
144                                                 <td><!-- TMPL_VAR NAME="module" --></td>
145                                                 <td><!-- TMPL_VAR NAME="action" --></td>
146                                                 <td>
147                                                     <!-- TMPL_IF NAME="MEMBERS"-->
148                                                         <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=<!-- TMPL_VAR NAME="object" -->" title="display detail for this member." title="Display member details.">
149                                                             member <!-- TMPL_VAR NAME="object" -->
150                                                         </a>
151                                                     <!-- TMPL_ELSE -->
152                                                     <!-- TMPL_IF NAME="CIRCULATION" -->
153                                                         <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=<!-- TMPL_VAR NAME="object" -->" title="display detail for this member." title="Display member details.">
154                                                             <!-- TMPL_IF NAME="object"-->member <!-- TMPL_VAR NAME="object" --><!-- /TMPL_IF -->
155                                                         </a>
156                                                     <!-- TMPL_ELSE -->
157                                                     <!-- TMPL_IF NAME="CATALOGUING" -->
158                                                         <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=<!-- TMPL_VAR NAME="object" -->" title="Display detail for this biblio">biblio <!-- TMPL_VAR NAME="object" --></a>
159                                                     <!-- TMPL_ELSE-->
160                                                     <!-- TMPL_IF NAME="SERIAL"-->
161                                                         <a href="/cgi-bin/koha/serials/subscription-detail.pl?subscriptionid=<!-- TMPL_VAR NAME="object" -->">
162                                                             <!-- TMPL_VAR NAME="object" -->
163                                                         </a>
164                                                     <!-- TMPL_ELSE -->
165                                                     <!-- TMPL_VAR NAME="object" -->
166                                                 <!-- /TMPL_IF -->
167                                                 <!-- /TMPL_IF -->
168                                                 <!-- /TMPL_IF -->
169                                                 <!-- /TMPL_IF -->
170                                                 </td>
171                                                 <td>
172                                                     <!-- TMPL_IF NAME="CIRCULATION" -->
173                                                          <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=<!-- TMPL_VAR NAME="info" -->" title="Display detail for this biblio">biblio <!-- TMPL_VAR NAME="info" --></a>
174                                                 <!-- TMPL_ELSE -->
175                                                     <!-- TMPL_VAR NAME="info" -->
176                                                 <!-- /TMPL_IF -->
177                                                 </td>
178                                         </tr>
179                 <!-- /TMPL_LOOP -->
180     </table>
181         </form>
182 </div>
183 </div>
184 <div class="yui-b">
185 <!-- TMPL_IF NAME="menu" -->
186     <!-- TMPL_INCLUDE NAME="circ-menu.inc" -->
187 <!-- TMPL_ELSE -->
188     <!-- TMPL_INCLUDE NAME="tools-menu.inc" -->
189 <!-- /TMPL_IF -->
190 </div>
191 </div>
192 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->