1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha › Administration › Contracts ›
3 <!-- TMPL_IF NAME="add_form" -->
4 <!-- TMPL_IF NAME="contractnumber" -->Modify contract '<!-- TMPL_VAR NAME="contractname" -->'
5 <!-- TMPL_ELSE -->New contract<!-- /TMPL_IF -->
7 <!-- TMPL_IF NAME="add_validate" -->Data recorded<!-- /TMPL_IF -->
8 <!-- TMPL_IF NAME="delete_confirm" -->Confirm Deletion of Contract '<!-- TMPL_VAR NAME="contractnumber" -->'<!-- /TMPL_IF -->
9 <!-- TMPL_IF NAME="delete_confirmed" -->Contract Deleted<!-- /TMPL_IF --></title>
10 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
11 <!-- TMPL_INCLUDE NAME="calendar.inc" -->
12 <script type="text/javascript" src="<!-- TMPL_VAR NAME='themelang' -->/js/acq.js"></script>
13 <script type="text/javascript">
15 // to check if the data are correctly entered.
18 var _alertString=_("Form not submitted because of the following problem(s)\n");
19 _alertString +="-------------------------------------------------------------------\n\n";
20 if (!(isNotNull(ff.contractname,0))){
22 _alertString += _("- Name missing\n");
24 if (!(CheckDate(ff.contractstartdate))){
26 _alertString += _("- Start date missing\n");
28 if (!(CheckDate(ff.contractenddate))){
30 _alertString += _("- End date missing\n");
33 if (!CompareDate(ff.contractstartdate.value, ff.contractenddate.value)) {
35 _alertString += _("Wrong date! start date can not be after end date.\n");
37 if (! CheckEndDate(ff.contractenddate.value)) {
39 _alertString += _("End date before today, Invalid end date!\n");
41 if (ok) { // if there is a problem
52 <!-- TMPL_INCLUDE NAME="header.inc" -->
53 <!-- TMPL_INCLUDE NAME="contracts-admin-search.inc" -->
55 <div id="breadcrumbs">
56 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
58 <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
60 <a href="/cgi-bin/koha/acqui/supplier.pl?supplierid=<!--TMPL_VAR name="booksellerid" -->"><!-- TMPL_VAR name="booksellername" --></a>
62 <!-- TMPL_IF NAME="add_form" -->
63 <a href="/cgi-bin/koha/admin/aqcontract.pl?booksellerid=<!-- TMPL_VAR NAME="booksellerid" -->">Contracts</a>
65 <!-- TMPL_IF NAME="contractnumber" -->Modify contract '<!-- TMPL_VAR NAME="contractname" -->'
66 <!-- TMPL_ELSE -->New contract
69 <!-- TMPL_IF NAME="add_validate" -->
70 <a href="/cgi-bin/koha/admin/aqcontract.pl?booksellerid=<!-- TMPL_VAR NAME="booksellerid" -->">Contracts</a>
71 › Data recorded
73 <!-- TMPL_IF NAME="delete_confirm" -->
74 <a href="/cgi-bin/koha/admin/aqcontract.pl?booksellerid=<!-- TMPL_VAR NAME="booksellerid" -->">Contracts</a>
75 › Confirm Deletion of Contract <!-- TMPL_VAR NAME="contractnumber" -->
77 <!-- TMPL_IF NAME="delete_confirmed" -->
78 <a href="/cgi-bin/koha/admin/aqcontract.pl?booksellerid=<!-- TMPL_VAR NAME="booksellerid" -->">Contracts</a> › Contract Deleted
80 <!-- TMPL_IF NAME="else" -->Contracts<!-- /TMPL_IF -->
83 <div id="doc3" class="yui-t2">
87 <!-- TMPL_IF NAME="add_form" -->
88 <form name="Aform" action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
89 <input type="hidden" name="op" value="add_validate" />
90 <input type="hidden" name="booksellerid" value="<!-- TMPL_VAR NAME="booksellerid" -->" />
91 <input type="hidden" name="checked" value="0" />
92 <!-- TMPL_IF NAME="contractnumber" -->
93 <h1>Modify contract <!-- TMPL_VAR NAME="contractname" --> for <!-- TMPL_VAR NAME="booksellername" --></h1>
95 <h1>New contract for <!-- TMPL_VAR NAME="booksellername" --></h1>
97 <fieldset class="rows">
99 <!-- TMPL_IF NAME="contractnumber" -->
100 <li><span class="label">Contract id </span><!-- TMPL_VAR NAME="contractnumber" -->
101 <input type="hidden" name="contractnumber" value="<!-- TMPL_VAR NAME="contractnumber" -->" />
102 <input type="hidden" name="is_a_modif" value="1" />
105 <li><label for="contractname" class="required">Name *</label>
106 <input type="text" name="contractname" id="contractname" size="40" maxlength="80" value="<!-- TMPL_VAR NAME="contractname" -->" />
108 <li><label for="contractdescription">Description</label>
109 <input type="text" name="contractdescription" id="contractdescription" size="40" maxlength="80" value="<!-- TMPL_VAR NAME="contractdescription" -->" />
111 <li><label for="contractstartdate" class="required">Start date *</label>
112 <input type="text" name="contractstartdate" id="contractstartdate" value="<!-- TMPL_VAR NAME="contractstartdate" -->" maxlength="10" size="10"/>
113 <img src="<!-- TMPL_VAR Name="themelang" -->/lib/calendar/cal.gif" id="contractstartdate_button" alt="Show Calendar" />
114 <script language="JavaScript" type="text/javascript">
117 inputField : "contractstartdate",
118 ifFormat : "<!-- TMPL_VAR NAME="DHTMLcalendar_dateformat" -->",
119 button : "contractstartdate_button"
123 <div class="hint"><!-- TMPL_INCLUDE NAME="date-format.inc" --></div>
125 <li><label for="contractenddate" class="required">End date *</label>
126 <input type="text" name="contractenddate" id="contractenddate" value="<!-- TMPL_VAR NAME="contractenddate" -->" maxlength="10" size="10" />
127 <img src="<!-- TMPL_VAR Name="themelang" -->/lib/calendar/cal.gif" id="contractenddate_button" alt="Show Calendar" />
128 <script language="JavaScript" type="text/javascript">
131 inputField : "contractenddate",
132 ifFormat : "<!-- TMPL_VAR NAME="DHTMLcalendar_dateformat" -->",
133 button : "contractenddate_button"
137 <div class="hint"><!-- TMPL_INCLUDE NAME="date-format.inc" --></div>
141 <fieldset class="action">
142 <input type="button" value="Save" onclick="Check(this.form);" />
146 <!-- TMPL_IF NAME="add_validate" -->
147 <h3>Data recorded</h3>
148 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
149 <input type="submit" value="OK" />
152 <!-- TMPL_IF NAME="delete_confirm" -->
153 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
155 <legend>Confirm Deletion of Contract <!-- TMPL_VAR NAME="contractnumber" --></legend>
157 <tr><th scope="row">Contract number:</th><td><!-- TMPL_VAR NAME="contractnumber" --></td></tr>
158 <tr><th scope="row">Contract name:</th><td><!-- TMPL_VAR NAME="contractname" --></td></tr>
159 <tr><th scope="row">Contract description:</th><td><!-- TMPL_VAR NAME="contractdescription" --></td></tr>
160 <tr><th scope="row">Contract start date:</th><td><!-- TMPL_VAR NAME="contractstartdate" --></td></tr>
161 <tr><th scope="row">Contract end date:</th><td><!-- TMPL_VAR NAME="contractenddate" --></td></tr>
162 <tr><th scope="row">Vendor:</th><td><!-- TMPL_VAR NAME="booksellername" --></td></tr>
164 <fieldset class="action">
165 <input type="hidden" name="op" value="delete_confirmed" />
166 <input type="hidden" name="booksellerid" value="<!-- TMPL_VAR name="booksellerid" -->" />
167 <input type="hidden" name="contractnumber" value="<!-- TMPL_VAR NAME="contractnumber" -->" />
168 <input type="submit" value="Delete this Contract" />
169 <a class="cancel" href="/cgi-bin/koha/admin/aqcontract.pl">Cancel</a>
174 <!-- TMPL_IF NAME="delete_confirmed" -->
175 <h3>Contract Deleted</h3>
176 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
177 <input type="hidden" name="booksellerid" value="<!-- TMPL_VAR name="booksellerid" -->/>
178 <input type="submit" value="OK" />
181 <!-- TMPL_IF NAME="else" -->
183 <script type="text/javascript">
185 // prepare DOM for YUI Toolbar
186 $(document).ready(function() {
189 // YUI Toolbar Functions
190 function yuiToolbar() {
191 new YAHOO.widget.Button("newcontract");
196 <li><a id="newcontract" href="/cgi-bin/koha/admin/aqcontract.pl?op=add_form&booksellerid=<!-- TMPL_VAR name="booksellerid" -->">New Contract</a></li>
199 <h2>Contract(s) of <!-- TMPL_VAR name="booksellername" --></h2>
200 <!-- TMPL_IF name="loop" -->
203 <th scope="col">Name</th>
204 <th scope="col">Description</th>
205 <th scope="col">Start date</th>
206 <th scope="col">End date</th>
207 <th scope="col" colspan="2"> </th>
209 <!-- TMPL_LOOP NAME="loop" -->
210 <!-- TMPL_IF NAME="__even__" --><tr class="highlight"><!-- TMPL_ELSE --><tr><!-- /TMPL_IF -->
212 <a href="<!-- TMPL_VAR NAME="script_name" -->?op=add_form&contractnumber=<!-- TMPL_VAR NAME="contractnumber" -->"><!-- TMPL_VAR NAME="contractname" --></a>
214 <td><!-- TMPL_VAR NAME="contractdescription" --></td>
215 <td><!-- TMPL_VAR NAME="contractstartdate" --></td>
216 <td><!-- TMPL_VAR NAME="contractenddate" --></td>
217 <td><a href="<!-- TMPL_VAR NAME="script_name" -->?op=add_form&contractnumber=<!-- TMPL_VAR NAME="contractnumber" -->&booksellerid=<!-- TMPL_VAR name="booksellerid" -->">Edit</a></td>
218 <td><a href="<!-- TMPL_VAR NAME="script_name" -->?op=delete_confirm&contractnumber=<!-- TMPL_VAR NAME="contractnumber" -->&booksellerid=<!-- TMPL_VAR name="booksellerid" -->">Delete</a></td>
227 <!-- TMPL_INCLUDE NAME="admin-menu.inc" -->
230 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->