View | Details | Raw Unified | Return to bug 9508
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/holidays.tt (-204 / +203 lines)
Lines 9-15 Link Here
9
<script language="JavaScript" type="text/javascript">
9
<script language="JavaScript" type="text/javascript">
10
//<![CDATA[
10
//<![CDATA[
11
    [% IF (dateformat == 'metric') %]dt_add_type_uk_date();[% END %]
11
    [% IF (dateformat == 'metric') %]dt_add_type_uk_date();[% END %]
12
	var weekdays = new Array(_("Sundays"),_("Mondays"),_("Tuesdays"),_("Wednesdays"),_("Thursdays"),_("Fridays"),_("Saturdays"));
12
    var weekdays = new Array(_("Sundays"),_("Mondays"),_("Tuesdays"),_("Wednesdays"),_("Thursdays"),_("Fridays"),_("Saturdays"));
13
13
14
    /* Creates all the structures to deal with all diferents kinds of holidays */
14
    /* Creates all the structures to deal with all diferents kinds of holidays */
15
    var week_days = new Array();
15
    var week_days = new Array();
Lines 39-113 Link Here
39
        formObject.submit();
39
        formObject.submit();
40
    }
40
    }
41
41
42
	// This function shows the "Show Holiday" panel //
42
    // This function shows the "Show Holiday" panel //
43
	function showHoliday (exceptionPosibility, dayName, day, month, year, weekDay, title, description, holidayType) {
43
    function showHoliday (exceptionPosibility, dayName, day, month, year, weekDay, title, description, holidayType) {
44
		$("#newHoliday").slideUp("fast");
44
        $("#newHoliday").slideUp("fast");
45
		$("#showHoliday").slideDown("fast");
45
        $("#showHoliday").slideDown("fast");
46
		$('#showDaynameOutput').html(dayName);
46
        $('#showDaynameOutput').html(dayName);
47
		$('#showDayname').val(dayName);
47
        $('#showDayname').val(dayName);
48
		$('#showBranchNameOutput').html($("#branch :selected").text());
48
        $('#showBranchNameOutput').html($("#branch :selected").text());
49
		$('#showBranchName').val($("#branch").val());
49
        $('#showBranchName').val($("#branch").val());
50
		$('#showDayOutput').html(day);
50
        $('#showDayOutput').html(day);
51
		$('#showDay').val(day);
51
        $('#showDay').val(day);
52
		$('#showMonthOutput').html(month);
52
        $('#showMonthOutput').html(month);
53
		$('#showMonth').val(month);
53
        $('#showMonth').val(month);
54
		$('#showYearOutput').html(year);
54
        $('#showYearOutput').html(year);
55
		$('#showYear').val(year);
55
        $('#showYear').val(year);
56
		$('#showDescription').val(description);
56
        $('#showDescription').val(description);
57
		$('#showWeekday:first').val(weekDay);
57
        $('#showWeekday:first').val(weekDay);
58
		$('#showTitle').val(title);
58
        $('#showTitle').val(title);
59
		$('#showHolidayType').val(holidayType);
59
        $('#showHolidayType').val(holidayType);
60
60
61
		if (holidayType == 'exception') {
61
        if (holidayType == 'exception') {
62
			$("#showOperationDelLabel").html(_("Delete this exception."));
62
            $("#showOperationDelLabel").html(_("Delete this exception."));
63
			$("#holtype").attr("class","key exception").html(_("Holiday exception"));
63
            $("#holtype").attr("class","key exception").html(_("Holiday exception"));
64
		} else if(holidayType == 'weekday') {
64
        } else if(holidayType == 'weekday') {
65
			$("#showOperationDelLabel").html(_("Delete this holiday."));
65
            $("#showOperationDelLabel").html(_("Delete this holiday."));
66
			$("#holtype").attr("class","key repeatableweekly").html(_("Holiday repeating weekly"));
66
            $("#holtype").attr("class","key repeatableweekly").html(_("Holiday repeating weekly"));
67
		} else if(holidayType == 'daymonth') {
67
        } else if(holidayType == 'daymonth') {
68
			$("#showOperationDelLabel").html(_("Delete this holiday."));
68
            $("#showOperationDelLabel").html(_("Delete this holiday."));
69
			$("#holtype").attr("class","key repeatableyearly").html(_("Holiday repeating yearly"));
69
            $("#holtype").attr("class","key repeatableyearly").html(_("Holiday repeating yearly"));
70
		} else {
70
        } else {
71
			$("#showOperationDelLabel").html(_("Delete this holiday."));
71
            $("#showOperationDelLabel").html(_("Delete this holiday."));
72
			$("#holtype").attr("class","key holiday").html(_("Unique holiday"));
72
            $("#holtype").attr("class","key holiday").html(_("Unique holiday"));
73
		}
73
        }
74
		
74
        
75
		if (exceptionPosibility == 1) {
75
        if (exceptionPosibility == 1) {
76
			$("#exceptionPosibility").parent().show();
76
            $("#exceptionPosibility").parent().show();
77
		} else {
77
        } else {
78
			$("#exceptionPosibility").parent().hide();
78
            $("#exceptionPosibility").parent().hide();
79
		}
79
        }
80
	}
80
    }
81
81
82
	// This function shows the "Add Holiday" panel //
82
    // This function shows the "Add Holiday" panel //
83
	function newHoliday (dayName, day, month, year, weekDay) {
83
    function newHoliday (dayName, day, month, year, weekDay) {
84
		$("#showHoliday").slideUp("fast");
84
        $("#showHoliday").slideUp("fast");
85
		$("#newHoliday").slideDown("fast");
85
        $("#newHoliday").slideDown("fast");
86
		$("#newDaynameOutput").html(dayName);
86
        $("#newDaynameOutput").html(dayName);
87
		$("#newDayname").val(dayName);
87
        $("#newDayname").val(dayName);
88
		$("#newBranchNameOutput").html($('#branch :selected').text());
88
        $("#newBranchNameOutput").html($('#branch :selected').text());
89
		$("#newBranchName").val($('#branch').val());
89
        $("#newBranchName").val($('#branch').val());
90
		$("#newDayOutput").html(day);
90
        $("#newDayOutput").html(day);
91
		$("#newDay").val(day);
91
        $("#newDay").val(day);
92
		$("#newMonthOutput").html(month);
92
        $("#newMonthOutput").html(month);
93
		$("#newMonth").val(month);
93
        $("#newMonth").val(month);
94
		$("#newYearOutput").html(year);
94
        $("#newYearOutput").html(year);
95
		$("#newYear").val(year);
95
        $("#newYear").val(year);
96
		$("#newWeekday:first").val(weekDay);
96
        $("#newWeekday:first").val(weekDay);
97
	}
97
    }
98
98
99
	function hidePanel(aPanelName) {
99
    function hidePanel(aPanelName) {
100
		$("#"+aPanelName).slideUp("fast");
100
        $("#"+aPanelName).slideUp("fast");
101
	}
101
    }
102
102
103
	function changeBranch () {
103
    function changeBranch () {
104
		var branch = $("#branch option:selected").val();
104
        var branch = $("#branch option:selected").val();
105
		location.href='/cgi-bin/koha/tools/holidays.pl?branch=' + branch + '&calendardate=' + "[% calendardate %]";
105
        location.href='/cgi-bin/koha/tools/holidays.pl?branch=' + branch + '&calendardate=' + "[% calendardate %]";
106
	}
106
    }
107
107
108
	function Help() {
108
    function Help() {
109
		newin=window.open("/cgi-bin/koha/help.pl","KohaHelp",'width=600,height=600,toolbar=false,scrollbars=yes');
109
        newin=window.open("/cgi-bin/koha/help.pl","KohaHelp",'width=600,height=600,toolbar=false,scrollbars=yes');
110
	}
110
    }
111
111
112
    /* This function gives css clases to each kind of day */
112
    /* This function gives css clases to each kind of day */
113
    function dateStatusHandler(date) {
113
    function dateStatusHandler(date) {
Lines 142-152 Link Here
142
        var dayMonth = month + '/' + day;
142
        var dayMonth = month + '/' + day;
143
        var dateString = year + '/' + month + '/' + day;
143
        var dateString = year + '/' + month + '/' + day;
144
            if (holidays[dateString] != null) {
144
            if (holidays[dateString] != null) {
145
                showHoliday(0, dayName, day, month, year, weekDay, holidays[dateString].title, 	holidays[dateString].description, 'ymd');
145
                showHoliday(0, dayName, day, month, year, weekDay, holidays[dateString].title,     holidays[dateString].description, 'ymd');
146
            } else if (exception_holidays[dateString] != null) {
146
            } else if (exception_holidays[dateString] != null) {
147
                showHoliday(0, dayName, day, month, year, weekDay, exception_holidays[dateString].title, exception_holidays[dateString].description, 'exception');
147
                showHoliday(0, dayName, day, month, year, weekDay, exception_holidays[dateString].title, exception_holidays[dateString].description, 'exception');
148
            } else if (week_days[weekDay] != null) {
148
            } else if (week_days[weekDay] != null) {
149
                showHoliday(1, dayName, day, month, year, weekDay, week_days[weekDay].title, 	week_days[weekDay].description, 'weekday');
149
                showHoliday(1, dayName, day, month, year, weekDay, week_days[weekDay].title,     week_days[weekDay].description, 'weekday');
150
            } else if (day_month_holidays[dayMonth] != null) {
150
            } else if (day_month_holidays[dayMonth] != null) {
151
                showHoliday(1, dayName, day, month, year, weekDay, day_month_holidays[dayMonth].title, day_month_holidays[dayMonth].description, 'daymonth');
151
                showHoliday(1, dayName, day, month, year, weekDay, day_month_holidays[dayMonth].title, day_month_holidays[dayMonth].description, 'daymonth');
152
            } else {
152
            } else {
Lines 154-165 Link Here
154
            }
154
            }
155
    };
155
    };
156
156
157
	$(document).ready(function() {
157
    $(document).ready(function() {
158
158
159
		$(".hint").hide();
159
        $(".hint").hide();
160
		$("#branch").change(function(){
160
        $("#branch").change(function(){
161
			changeBranch();
161
            changeBranch();
162
		});
162
        });
163
        $("#holidayexceptions,#holidayweeklyrepeatable,#holidaysunique").dataTable($.extend(true, {}, dataTablesDefaults, {
163
        $("#holidayexceptions,#holidayweeklyrepeatable,#holidaysunique").dataTable($.extend(true, {}, dataTablesDefaults, {
164
            "sDom": 't',
164
            "sDom": 't',
165
            "bPaginate": false
165
            "bPaginate": false
Lines 171-182 Link Here
171
            ],
171
            ],
172
            "bPaginate": false
172
            "bPaginate": false
173
        }));
173
        }));
174
		$("a.helptext").click(function(){
174
        $("a.helptext").click(function(){
175
			$(this).parent().find(".hint").toggle(); return false;
175
            $(this).parent().find(".hint").toggle(); return false;
176
		});
176
        });
177
        $("#dateofrange").datepicker();
177
        $("#dateofrange").datepicker();
178
        $("#datecancelrange").datepicker();
178
        $("#datecancelrange").datepicker();
179
		$("#dateofrange").each(function () { this.value = "" });
179
        $("#dateofrange").each(function () { this.value = "" });
180
        $("#datecancelrange").each(function () { this.value = "" });
180
        $("#datecancelrange").each(function () { this.value = "" });
181
        $("#jcalendar-container").datepicker({
181
        $("#jcalendar-container").datepicker({
182
          beforeShowDay: function(thedate) {
182
          beforeShowDay: function(thedate) {
Lines 191-197 Link Here
191
        },
191
        },
192
        defaultDate: new Date("[% keydate %]")
192
        defaultDate: new Date("[% keydate %]")
193
    });
193
    });
194
	});
194
    });
195
//]]>
195
//]]>
196
</script>
196
</script>
197
<style type="text/css"> .key { padding : 3px; white-space:nowrap; line-height:230%; }
197
<style type="text/css"> .key { padding : 3px; white-space:nowrap; line-height:230%; }
Lines 223-233 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
223
<div id="doc3" class="yui-t1">
223
<div id="doc3" class="yui-t1">
224
   
224
   
225
   <div id="bd">
225
   <div id="bd">
226
	<div id="yui-main">
226
    <div id="yui-main">
227
	<div class="yui-b">
227
    <div class="yui-b">
228
	<h2>[% branchname %] Calendar</h2>
228
    <h2>[% branchname %] Calendar</h2>
229
	<div class="yui-g">
229
    <div class="yui-g">
230
	<div class="yui-u first">
230
    <div class="yui-u first">
231
        <label for="branch">Define the holidays for:</label>
231
        <label for="branch">Define the holidays for:</label>
232
            <select id="branch" name="branch">
232
            <select id="branch" name="branch">
233
                [% FOREACH branchloo IN branchloop %]
233
                [% FOREACH branchloo IN branchloop %]
Lines 238-294 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
238
                    [% END %]
238
                    [% END %]
239
                [% END %]
239
                [% END %]
240
            </select>
240
            </select>
241
	
241
    
242
	<!-- ******************************** FLAT PANELS ******************************************* -->
242
    <!-- ******************************** FLAT PANELS ******************************************* -->
243
	<!-- *****           Makes all the flat panel to deal with holidays                     ***** -->
243
    <!-- *****           Makes all the flat panel to deal with holidays                     ***** -->
244
	<!-- **************************************************************************************** -->
244
    <!-- **************************************************************************************** -->
245
245
246
	<!-- ********************** Panel for showing already loaded holidays *********************** -->
246
    <!-- ********************** Panel for showing already loaded holidays *********************** -->
247
	<div class="panel" id="showHoliday">
247
    <div class="panel" id="showHoliday">
248
	 	<form action="/cgi-bin/koha/tools/exceptionHolidays.pl" method="post">
248
         <form action="/cgi-bin/koha/tools/exceptionHolidays.pl" method="post">
249
	 		<input type="hidden" id="showHolidayType" name="showHolidayType" value="" />
249
             <input type="hidden" id="showHolidayType" name="showHolidayType" value="" />
250
			<fieldset class="brief">
250
            <fieldset class="brief">
251
			<h3>Edit this holiday</h3>
251
            <h3>Edit this holiday</h3>
252
			<span id="holtype"></span>
252
            <span id="holtype"></span>
253
			<ol>
253
            <ol>
254
			<li>
254
            <li>
255
				<strong>Library:</strong> <span id="showBranchNameOutput"></span>
255
                <strong>Library:</strong> <span id="showBranchNameOutput"></span>
256
				<input type="hidden" id="showBranchName" name="showBranchName" />
256
                <input type="hidden" id="showBranchName" name="showBranchName" />
257
			</li>
257
            </li>
258
			<li>
258
            <li>
259
				<strong>From Date:</strong>
259
                <strong>From Date:</strong>
260
				<span id="showDaynameOutput"></span>, 
260
                <span id="showDaynameOutput"></span>, 
261
				
261
                
262
                                [% IF ( dateformat == "us" ) %]<span id="showMonthOutput"></span>/<span id="showDayOutput"></span>/<span id="showYearOutput"></span>[% ELSIF ( dateformat == "metric" ) %]<span id="showDayOutput"></span>/<span id="showMonthOutput"></span>/<span id="showYearOutput"></span>[% ELSE %]<span id="showYearOutput"></span>/<span id="showMonthOutput"></span>/<span id="showDayOutput"></span>[% END %]
262
                                [% IF ( dateformat == "us" ) %]<span id="showMonthOutput"></span>/<span id="showDayOutput"></span>/<span id="showYearOutput"></span>[% ELSIF ( dateformat == "metric" ) %]<span id="showDayOutput"></span>/<span id="showMonthOutput"></span>/<span id="showYearOutput"></span>[% ELSE %]<span id="showYearOutput"></span>/<span id="showMonthOutput"></span>/<span id="showDayOutput"></span>[% END %]
263
263
264
				<input type="hidden" id="showDayname" name="showDayname" />
264
                <input type="hidden" id="showDayname" name="showDayname" />
265
				<input type="hidden" id="showWeekday" name="showWeekday" />
265
                <input type="hidden" id="showWeekday" name="showWeekday" />
266
				<input type="hidden" id="showDay" name="showDay" />
266
                <input type="hidden" id="showDay" name="showDay" />
267
				<input type="hidden" id="showMonth" name="showMonth" />
267
                <input type="hidden" id="showMonth" name="showMonth" />
268
				<input type="hidden" id="showYear" name="showYear" />
268
                <input type="hidden" id="showYear" name="showYear" />
269
			</li>
269
            </li>
270
            <li class="dateinsert">
270
            <li class="dateinsert">
271
                <b>To Date : </b>
271
                <b>To Date : </b>
272
                <input type="text" id="datecancelrange" name="datecancelrange" size="20" value="[% datecancelrange %]" class="datepicker"/>
272
                <input type="text" id="datecancelrange" name="datecancelrange" size="20" value="[% datecancelrange %]" class="datepicker"/>
273
            </li>
273
            </li>
274
			<li><label for="showTitle">Title: </label><input type="text" name="showTitle" id="showTitle" size="35" /></li>
274
            <li><label for="showTitle">Title: </label><input type="text" name="showTitle" id="showTitle" size="35" /></li>
275
		    <!-- showTitle is necessary for exception radio button to work properly --> 
275
            <!-- showTitle is necessary for exception radio button to work properly --> 
276
				<label for="showDescription">Description:</label>
276
                <label for="showDescription">Description:</label>
277
				<textarea rows="2" cols="40" id="showDescription" name="showDescription"></textarea>	
277
                <textarea rows="2" cols="40" id="showDescription" name="showDescription"></textarea>    
278
		    </li>
278
            </li>
279
			<li class="radio"><div id="exceptionPosibility" style="position:static">
279
            <li class="radio"><div id="exceptionPosibility" style="position:static">
280
				<input type="radio" name="showOperation" id="showOperationExc" value="exception" /> <label for="showOperationExc">Generate an exception for this repeated holiday.</label>
280
                <input type="radio" name="showOperation" id="showOperationExc" value="exception" /> <label for="showOperationExc">Generate an exception for this repeated holiday.</label>
281
				<a href="#" class="helptext">[?]</a>
281
                <a href="#" class="helptext">[?]</a>
282
				<div class="hint">You can make an exception for this holiday rule. This means that you will be able to say that for a repeatable holiday there is one day which is going to be an exception.</div>
282
                <div class="hint">You can make an exception for this holiday rule. This means that you will be able to say that for a repeatable holiday there is one day which is going to be an exception.</div>
283
			</div></li>
283
            </div></li>
284
            <li class="radio"><input type="radio" name="showOperation" id="showOperationExcRange" value="exceptionrange" />
284
            <li class="radio"><input type="radio" name="showOperation" id="showOperationExcRange" value="exceptionrange" />
285
                <label for="newOperationFieldException">Generate exceptions on a range of dates.</label>
285
                <label for="newOperationFieldException">Generate exceptions on a range of dates.</label>
286
                <a href="#" class="helptext">[?]</a>
286
                <a href="#" class="helptext">[?]</a>
287
                <div class="hint">You can make an exception on a range of dates repeated yearly.</div>
287
                <div class="hint">You can make an exception on a range of dates repeated yearly.</div>
288
            </li>
288
            </li>
289
			<li class="radio"><input type="radio" name="showOperation" id="showOperationDel" value="delete" /> <label for="showOperationDel" id="showOperationDelLabel">Delete this holiday</label>
289
            <li class="radio"><input type="radio" name="showOperation" id="showOperationDel" value="delete" /> <label for="showOperationDel" id="showOperationDelLabel">Delete this holiday</label>
290
				<a href="#" class="helptext">[?]</a>
290
                <a href="#" class="helptext">[?]</a>
291
				<div class="hint">This will delete this holiday rule. If it is a repeatable holiday, this option checks for possible exceptions. If an exception exists, this option will remove the exception and set the date to a regular holiday.</div></li>
291
                <div class="hint">This will delete this holiday rule. If it is a repeatable holiday, this option checks for possible exceptions. If an exception exists, this option will remove the exception and set the date to a regular holiday.</div></li>
292
            <li class="radio"><input type="radio" name="showOperation" id="showOperationDelRange" value="deleterange" /> <label for="showOperationDelRange" id="showOperationDelLabelRange">Delete the single holidays on a range</label>.
292
            <li class="radio"><input type="radio" name="showOperation" id="showOperationDelRange" value="deleterange" /> <label for="showOperationDelRange" id="showOperationDelLabelRange">Delete the single holidays on a range</label>.
293
                <a href="#" class="helptext">[?]</a>
293
                <a href="#" class="helptext">[?]</a>
294
                <div class="hint">This will delete the single holidays rules only. The repeatable holidays and exceptions will not be deleted.</div>
294
                <div class="hint">This will delete the single holidays rules only. The repeatable holidays and exceptions will not be deleted.</div>
Lines 301-365 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
301
                <a href="#" class="helptext">[?]</a>
301
                <a href="#" class="helptext">[?]</a>
302
                <div class="hint">This will delete the exceptions inside a given range. Be careful about your scope range if it is oversized you could slow down Koha.</div>
302
                <div class="hint">This will delete the exceptions inside a given range. Be careful about your scope range if it is oversized you could slow down Koha.</div>
303
            </li>
303
            </li>
304
			<li class="radio"><input type="radio" name="showOperation" id="showOperationEdit" value="edit" checked="checked" /> <label for="showOperationEdit">Edit this holiday</label>
304
            <li class="radio"><input type="radio" name="showOperation" id="showOperationEdit" value="edit" checked="checked" /> <label for="showOperationEdit">Edit this holiday</label>
305
                <a href="#" class="helptext">[?]</a>
305
                <a href="#" class="helptext">[?]</a>
306
                <div class="hint">This will save changes to the holiday's title and description. If the information for a repeatable holiday is modified, it affects all of the dates on which the holiday is repeated.</div></li>
306
                <div class="hint">This will save changes to the holiday's title and description. If the information for a repeatable holiday is modified, it affects all of the dates on which the holiday is repeated.</div></li>
307
			</ol>
307
            </ol>
308
			<fieldset class="action">
308
            <fieldset class="action">
309
				<input type="submit" name="submit" value="Save" />
309
                <input type="submit" name="submit" value="Save" />
310
				<a href="#" class="cancel" name="cancel2" onclick=" hidePanel('showHoliday');">Cancel</a>
310
                <a href="#" class="cancel" name="cancel2" onclick=" hidePanel('showHoliday');">Cancel</a>
311
			</fieldset>
311
            </fieldset>
312
			</fieldset>
312
            </fieldset>
313
		</form>
313
        </form>
314
	</div>
314
    </div>
315
315
316
	<!-- ***************************** Panel to deal with new holidays **********************  -->
316
    <!-- ***************************** Panel to deal with new holidays **********************  -->
317
	<div class="panel" id="newHoliday">
317
    <div class="panel" id="newHoliday">
318
	 	<form action="/cgi-bin/koha/tools/newHolidays.pl" method="post">
318
         <form action="/cgi-bin/koha/tools/newHolidays.pl" method="post">
319
				<input type="hidden" name="branchCodes" id="branchCodes" value="[% branchcodes %]" /> 
319
                <input type="hidden" name="branchCodes" id="branchCodes" value="[% branchcodes %]" /> 
320
			<fieldset class="brief">
320
            <fieldset class="brief">
321
			<h3>Add new holiday</h3>
321
            <h3>Add new holiday</h3>
322
			<ol>
322
            <ol>
323
			<li>
323
            <li>
324
				<strong>Library:</strong>
324
                <strong>Library:</strong>
325
				<span id="newBranchNameOutput"></span>
325
                <span id="newBranchNameOutput"></span>
326
				<input type="hidden" id="newBranchName" name="newBranchName" />
326
                <input type="hidden" id="newBranchName" name="newBranchName" />
327
			</li>
327
            </li>
328
			<li>
328
            <li>
329
                <strong>From date:</strong>
329
                <strong>From date:</strong>
330
				<span id="newDaynameOutput"></span>, 
330
                <span id="newDaynameOutput"></span>, 
331
331
332
                         [% IF ( dateformat == "us" ) %]<span id="newMonthOutput"></span>/<span id="newDayOutput"></span>/<span id="newYearOutput"></span>[% ELSIF ( dateformat == "metric" ) %]<span id="newDayOutput"></span>/<span id="newMonthOutput"></span>/<span id="newYearOutput"></span>[% ELSE %]<span id="newYearOutput"></span>/<span id="newMonthOutput"></span>/<span id="newDayOutput"></span>[% END %]
332
                         [% IF ( dateformat == "us" ) %]<span id="newMonthOutput"></span>/<span id="newDayOutput"></span>/<span id="newYearOutput"></span>[% ELSIF ( dateformat == "metric" ) %]<span id="newDayOutput"></span>/<span id="newMonthOutput"></span>/<span id="newYearOutput"></span>[% ELSE %]<span id="newYearOutput"></span>/<span id="newMonthOutput"></span>/<span id="newDayOutput"></span>[% END %]
333
333
334
				<input type="hidden" id="newDayname" name="showDayname" />
334
                <input type="hidden" id="newDayname" name="showDayname" />
335
				<input type="hidden" id="newWeekday" name="newWeekday" />
335
                <input type="hidden" id="newWeekday" name="newWeekday" />
336
				<input type="hidden" id="newDay" name="newDay" />
336
                <input type="hidden" id="newDay" name="newDay" />
337
				<input type="hidden" id="newMonth" name="newMonth" />
337
                <input type="hidden" id="newMonth" name="newMonth" />
338
				<input type="hidden" id="newYear" name="newYear" />
338
                <input type="hidden" id="newYear" name="newYear" />
339
			</li>
339
            </li>
340
			<li class="dateinsert">
340
            <li class="dateinsert">
341
                <b>To date : </b>
341
                <b>To date : </b>
342
                <input type="text" id="dateofrange" name="dateofrange" size="20" value="[% dateofrange %]" class="datepicker" />
342
                <input type="text" id="dateofrange" name="dateofrange" size="20" value="[% dateofrange %]" class="datepicker" />
343
			</li>
343
            </li>
344
			<li><label for="title">Title: </label><input type="text" name="newTitle" id="title" size="35" /></li>
344
            <li><label for="title">Title: </label><input type="text" name="newTitle" id="title" size="35" /></li>
345
			<li><label for="newDescription">Description:</label>
345
            <li><label for="newDescription">Description:</label>
346
				<textarea rows="2" cols="40" id="newDescription" name="newDescription"></textarea>
346
                <textarea rows="2" cols="40" id="newDescription" name="newDescription"></textarea>
347
			</li>
347
            </li>
348
			<li class="radio"><input type="radio" name="newOperation" id="newOperationOnce" value="holiday" checked="checked" />
348
            <li class="radio"><input type="radio" name="newOperation" id="newOperationOnce" value="holiday" checked="checked" />
349
			<label for="newOperationOnce">Holiday only on this day</label>.
349
            <label for="newOperationOnce">Holiday only on this day</label>.
350
			<a href="#" class="helptext">[?]</a>
350
            <a href="#" class="helptext">[?]</a>
351
			<div class="hint">Make a single holiday. For example, selecting August 1st, 2012 will make it a holiday, but will not affect August 1st in other years.</div>
351
            <div class="hint">Make a single holiday. For example, selecting August 1st, 2012 will make it a holiday, but will not affect August 1st in other years.</div>
352
			</li>
352
            </li>
353
			<li class="radio"><input type="radio" name="newOperation" id="newOperationDay" value="weekday" />
353
            <li class="radio"><input type="radio" name="newOperation" id="newOperationDay" value="weekday" />
354
							<label for="newOperationDay">Holiday repeated every same day of the week</label>.
354
                            <label for="newOperationDay">Holiday repeated every same day of the week</label>.
355
							<a href="#" class="helptext">[?]</a>
355
                            <a href="#" class="helptext">[?]</a>
356
							<div class="hint">Make this weekday a holiday, every week. For example, if your library is closed on Saturdays, use this option to make every Saturday a holiday.</div>
356
                            <div class="hint">Make this weekday a holiday, every week. For example, if your library is closed on Saturdays, use this option to make every Saturday a holiday.</div>
357
							</li>
357
                            </li>
358
			<li class="radio"><input type="radio" name="newOperation" id="newOperationYear" value="repeatable" />
358
            <li class="radio"><input type="radio" name="newOperation" id="newOperationYear" value="repeatable" />
359
							<label for="newOperationYear">Holiday repeated yearly on the same date</label>.
359
                            <label for="newOperationYear">Holiday repeated yearly on the same date</label>.
360
							<a href="#" class="helptext">[?]</a>
360
                            <a href="#" class="helptext">[?]</a>
361
							<div class="hint">This will take this day and month as a reference to make it a holiday. Through this option, you can repeat this rule for every year. For example, selecting August 1st will make August 1st a holiday every year.</div>
361
                            <div class="hint">This will take this day and month as a reference to make it a holiday. Through this option, you can repeat this rule for every year. For example, selecting August 1st will make August 1st a holiday every year.</div>
362
							</li>
362
                            </li>
363
            <li class="radio"><input type="radio" name="newOperation" id="newOperationField" value="holidayrange" />
363
            <li class="radio"><input type="radio" name="newOperation" id="newOperationField" value="holidayrange" />
364
                            <label for="newOperationField">Holidays on a range</label>.
364
                            <label for="newOperationField">Holidays on a range</label>.
365
                            <a href="#" class="helptext">[?]</a>
365
                            <a href="#" class="helptext">[?]</a>
Lines 370-392 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
370
                            <a href="#" class="helptext">[?]</a>
370
                            <a href="#" class="helptext">[?]</a>
371
                            <div class="hint">Make a single holiday on a range repeated yearly. For example, selecting August 1st, 2012  and August 10st, 2012 will make all days between 1st and 10st holiday, and will affect August 1-10 in other years.</div>
371
                            <div class="hint">Make a single holiday on a range repeated yearly. For example, selecting August 1st, 2012  and August 10st, 2012 will make all days between 1st and 10st holiday, and will affect August 1-10 in other years.</div>
372
                            </li>
372
                            </li>
373
				<li class="radio">
373
                <li class="radio">
374
				<input type="checkbox" name="allBranches" id="allBranches" />
374
                <input type="checkbox" name="allBranches" id="allBranches" />
375
				<label for="allBranches">Copy to all libraries</label>.
375
                <label for="allBranches">Copy to all libraries</label>.
376
				<a href="#" class="helptext">[?]</a>
376
                <a href="#" class="helptext">[?]</a>
377
				<div class="hint">If checked, this holiday will be copied to all libraries. If the holiday already exists for a library, no change is made.</div>
377
                <div class="hint">If checked, this holiday will be copied to all libraries. If the holiday already exists for a library, no change is made.</div>
378
				</li></ol>
378
                </li></ol>
379
				<fieldset class="action">
379
                <fieldset class="action">
380
					<input type="submit" name="submit" value="Save" />
380
                    <input type="submit" name="submit" value="Save" />
381
					<a href="#" class="cancel" name="cancel2" onclick=" hidePanel('newHoliday');">Cancel</a>
381
                    <a href="#" class="cancel" name="cancel2" onclick=" hidePanel('newHoliday');">Cancel</a>
382
				</fieldset>
382
                </fieldset>
383
				</fieldset>
383
                </fieldset>
384
	 	</form>
384
         </form>
385
	</div>
385
    </div>
386
386
387
	<!-- *************************************************************************************** -->
387
    <!-- *************************************************************************************** -->
388
	<!-- ******                          END OF FLAT PANELS                               ****** -->
388
    <!-- ******                          END OF FLAT PANELS                               ****** -->
389
	<!-- *************************************************************************************** -->
389
    <!-- *************************************************************************************** -->
390
390
391
<!-- ************************************************************************************** -->
391
<!-- ************************************************************************************** -->
392
<!-- ******                              MAIN SCREEN CODE                            ****** -->
392
<!-- ******                              MAIN SCREEN CODE                            ****** -->
Lines 396-402 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
396
396
397
<div style="margin-top: 2em;">
397
<div style="margin-top: 2em;">
398
<form action="copy-holidays.pl" method="post">
398
<form action="copy-holidays.pl" method="post">
399
	<input type="hidden" name="from_branchcode" value="[% branch %]" />
399
    <input type="hidden" name="from_branchcode" value="[% branch %]" />
400
  <label for="branchcode">Copy holidays to:</label>
400
  <label for="branchcode">Copy holidays to:</label>
401
  <select id="branchcode" name="branchcode">
401
  <select id="branchcode" name="branchcode">
402
    <option value=""></option>
402
    <option value=""></option>
Lines 404-410 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
404
    <option value="[% branchloo.value %]">[% branchloo.branchname %]</option>
404
    <option value="[% branchloo.value %]">[% branchloo.branchname %]</option>
405
    [% END %]
405
    [% END %]
406
  </select>
406
  </select>
407
	<input type="submit" value="Copy" />
407
    <input type="submit" value="Copy" />
408
</form>
408
</form>
409
</div>
409
</div>
410
410
Lines 412-432 td.repeatableyearly a.ui-state-default { background: #FFFF99 none; color : Bl Link Here
412
<div class="yui-u">
412
<div class="yui-u">
413
<div class="help">
413
<div class="help">
414
<h4>Hints</h4>
414
<h4>Hints</h4>
415
	<ul>
415
    <ul>
416
		<li>Search in the calendar the day you want to set as holiday.</li>
416
        <li>Search in the calendar the day you want to set as holiday.</li>
417
		<li>Click the date to add or edit a holiday.</li>
417
        <li>Click the date to add or edit a holiday.</li>
418
		<li>Enter a title and description for the holdiay.</li>
418
        <li>Enter a title and description for the holdiay.</li>
419
		<li>Specify how the holiday should repeat.</li>
419
        <li>Specify how the holiday should repeat.</li>
420
		<li>Click Save to finish.</li>
420
        <li>Click Save to finish.</li>
421
	</ul>
421
    </ul>
422
<h4>Key</h4>
422
<h4>Key</h4>
423
	<p>
423
    <p>
424
		<span class="key normalday">Working day</span>
424
        <span class="key normalday">Working day</span>
425
		<span class="key holiday">Unique holiday</span>
425
        <span class="key holiday">Unique holiday</span>
426
		<span class="key repeatableweekly">Holiday repeating weekly</span>
426
        <span class="key repeatableweekly">Holiday repeating weekly</span>
427
		<span class="key repeatableyearly">Holiday repeating yearly</span>
427
        <span class="key repeatableyearly">Holiday repeating yearly</span>
428
		<span class="key exception">Holiday exception</span>
428
        <span class="key exception">Holiday exception</span>
429
	</p>
429
    </p>
430
</div>
430
</div>
431
<div id="holiday-list">
431
<div id="holiday-list">
432
<!-- Exceptions First -->
432
<!-- Exceptions First -->
433
- 

Return to bug 9508