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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/cat-toolbar.inc (-1 / +1 lines)
Lines 32-38 function confirm_deletion() { Link Here
32
	if (count>0){
32
	if (count>0){
33
		    is_confirmed= alert(_('There are [ '+ count +' ] item(s) attached to this record \n You must delete all items before deleting this record.'));
33
		    is_confirmed= alert(_('There are [ '+ count +' ] item(s) attached to this record \n You must delete all items before deleting this record.'));
34
		    } else{
34
		    } else{
35
		    is_confirmed= confirm(_('Are you sure you want to delete this record? '));
35
		    is_confirmed= confirm(_("Are you sure you want to delete this record? "));
36
	}
36
	}
37
37
38
     if (is_confirmed) {
38
     if (is_confirmed) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/members-toolbar.inc (-2 / +2 lines)
Lines 3-15 Link Here
3
	//<![CDATA[
3
	//<![CDATA[
4
4
5
function confirm_deletion() {
5
function confirm_deletion() {
6
    var is_confirmed = window.confirm(_('Are you sure you want to delete this patron? This cannot be undone.'));
6
    var is_confirmed = window.confirm(_("Are you sure you want to delete this patron? This cannot be undone."));
7
    if (is_confirmed) {
7
    if (is_confirmed) {
8
            window.location='/cgi-bin/koha/members/deletemem.pl?member=[% borrowernumber %]';
8
            window.location='/cgi-bin/koha/members/deletemem.pl?member=[% borrowernumber %]';
9
    }
9
    }
10
}
10
}
11
function confirm_updatechild() {
11
function confirm_updatechild() {
12
    var is_confirmed = window.confirm(_('Are you sure you want to update this child to an Adult category?  This cannot be undone.'));
12
    var is_confirmed = window.confirm(_("Are you sure you want to update this child to an Adult category?  This cannot be undone."));
13
13
14
    if (is_confirmed) {
14
    if (is_confirmed) {
15
            window.location='/cgi-bin/koha/members/update-child.pl?op=update&borrowernumber=[% borrowernumber %]&catcode=[% catcode %]&catcode_multi=[% CATCODE_MULTI %]';
15
            window.location='/cgi-bin/koha/members/update-child.pl?op=update&borrowernumber=[% borrowernumber %]&catcode=[% catcode %]&catcode_multi=[% CATCODE_MULTI %]';
(-)a/koha-tmpl/intranet-tmpl/prog/en/js/acq.js (-1 / +1 lines)
Lines 384-390 function closeandprint(bg){ Link Here
384
	if(document.location = '/cgi-bin/koha/acqui/basketgroup.pl?op=closeandprint&amp;basketgroupid=' + bg ){
384
	if(document.location = '/cgi-bin/koha/acqui/basketgroup.pl?op=closeandprint&amp;basketgroupid=' + bg ){
385
		setTimeout("window.location.reload();",3000);
385
		setTimeout("window.location.reload();",3000);
386
	}else{
386
	}else{
387
		alert(_('Error downloading the file'));
387
		alert(_("Error downloading the file"));
388
	}
388
	}
389
}
389
}
390
390
(-)a/koha-tmpl/intranet-tmpl/prog/en/js/ajax.js (-4 / +4 lines)
Lines 15-38 KOHA.AJAX = { Link Here
15
        KOHA.xhr = xhr;
15
        KOHA.xhr = xhr;
16
        if ( !xhr.getResponseHeader( 'content-type' ).match( 'application/json' ) ) {
16
        if ( !xhr.getResponseHeader( 'content-type' ).match( 'application/json' ) ) {
17
            // Something really failed
17
            // Something really failed
18
            humanMsg.displayAlert( _( 'Internal Server Error, please reload the page' ) );
18
            humanMsg.displayAlert( _( "Internal Server Error, please reload the page" ) );
19
            return;
19
            return;
20
        }
20
        }
21
21
22
        var error = eval( '(' + xhr.responseText + ')' );
22
        var error = eval( '(' + xhr.responseText + ')' );
23
23
24
        if ( error.type == 'auth' ) {
24
        if ( error.type == 'auth' ) {
25
            humanMsg.displayMsg( _( 'You need to log in again, your session has timed out' ) );
25
            humanMsg.displayMsg( _( "You need to log in again, your session has timed out" ) );
26
        }
26
        }
27
27
28
        if ( callback ) {
28
        if ( callback ) {
29
            callback( error );
29
            callback( error );
30
        } else {
30
        } else {
31
            humanMsg.displayAlert( _( 'Error; your data might not have been saved' ) );
31
            humanMsg.displayAlert( _( "Error; your data might not have been saved" ) );
32
        }
32
        }
33
    },
33
    },
34
    MarkRunning: function ( selector, text ) {
34
    MarkRunning: function ( selector, text ) {
35
        text = text || _( 'Loading...' );
35
        text = text || _( "Loading..." );
36
        $( selector )
36
        $( selector )
37
            .attr( 'disabled', 'disabled' )
37
            .attr( 'disabled', 'disabled' )
38
            .each( function () {
38
            .each( function () {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/basket.tt (-5 / +5 lines)
Lines 16-41 Link Here
16
        $("#cancelledorderst").tablesorter();
16
        $("#cancelledorderst").tablesorter();
17
    });
17
    });
18
            function confirm_close() {
18
            function confirm_close() {
19
                var is_confirmed = confirm(_('Are you sure you want to close this basket?'));
19
                var is_confirmed = confirm(_("Are you sure you want to close this basket?"));
20
                if (is_confirmed) {
20
                if (is_confirmed) {
21
                    window.location = "[% script_name %]?op=close&basketno=[% basketno %]";
21
                    window.location = "[% script_name %]?op=close&basketno=[% basketno %]";
22
                }
22
                }
23
            }
23
            }
24
            function confirm_deletion() {
24
            function confirm_deletion() {
25
                var is_confirmed = confirm(_('Are you sure you want to delete this basket?'));
25
                var is_confirmed = confirm(_("Are you sure you want to delete this basket?"));
26
                if (is_confirmed) {
26
                if (is_confirmed) {
27
                    window.location = "[% script_name %]?op=delete_confirm&basketno=[% basketno %]&booksellerid=[% booksellerid %]";
27
                    window.location = "[% script_name %]?op=delete_confirm&basketno=[% basketno %]&booksellerid=[% booksellerid %]";
28
                }
28
                }
29
            }
29
            }
30
            function confirm_delete_item(ordernumber, biblionumber) {
30
            function confirm_delete_item(ordernumber, biblionumber) {
31
                var is_confirmed = confirm(_('Are you sure you want to delete this order ?'));
31
                var is_confirmed = confirm(_("Are you sure you want to delete this order ?"));
32
                if (is_confirmed) {
32
                if (is_confirmed) {
33
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber;
33
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber;
34
                }
34
                }
35
            }
35
            }
36
            
36
            
37
            function confirm_delete_biblio(ordernumber, biblionumber) {
37
            function confirm_delete_biblio(ordernumber, biblionumber) {
38
                var is_confirmed = confirm(_('Are you sure you want to delete this catalog record and order ?'));
38
                var is_confirmed = confirm(_("Are you sure you want to delete this catalog record and order ?"));
39
                if (is_confirmed) {
39
                if (is_confirmed) {
40
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber+"&delbiblio=1";
40
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno=[% basketno %]&quantity=0&biblionumber="+biblionumber+"&delbiblio=1";
41
                    }
41
                    }
Lines 59-65 Link Here
59
<script type="text/javascript">
59
<script type="text/javascript">
60
//<![CDATA[
60
//<![CDATA[
61
            function confirm_reopen(skip) {
61
            function confirm_reopen(skip) {
62
                var is_confirmed = skip || confirm(_('Are you sure you want to reopen this basket?'));
62
                var is_confirmed = skip || confirm(_("Are you sure you want to reopen this basket?"));
63
                if (is_confirmed) {
63
                if (is_confirmed) {
64
                    window.location = "[% script_name %]?op=reopen&basketno=[% basketno %]";
64
                    window.location = "[% script_name %]?op=reopen&basketno=[% basketno %]";
65
                }
65
                }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt (-1 / +1 lines)
Lines 108-114 function Check(ff) { Link Here
108
108
109
    [% IF (AcqCreateItemOrdering) %]
109
    [% IF (AcqCreateItemOrdering) %]
110
        if(check_additem('[% UniqueItemFields %]') == false) {
110
        if(check_additem('[% UniqueItemFields %]') == false) {
111
            alert(_('Duplicate values detected. Please correct the errors and resubmit.') );
111
            alert(_("Duplicate values detected. Please correct the errors and resubmit.") );
112
            if(tobedeleted) {
112
            if(tobedeleted) {
113
                $(lastitemblock).appendTo('#outeritemblock');
113
                $(lastitemblock).appendTo('#outeritemblock');
114
            }
114
            }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt (-1 / +1 lines)
Lines 27-33 Link Here
27
            }
27
            }
28
28
29
            if(check_additem('[% UniqueItemFields %]') == false){
29
            if(check_additem('[% UniqueItemFields %]') == false){
30
                alert(_('Duplicate values detected. Please correct the errors and resubmit.') );
30
                alert(_("Duplicate values detected. Please correct the errors and resubmit.") );
31
                return false;
31
                return false;
32
            };
32
            };
33
33
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt (-2 / +2 lines)
Lines 75-88 Link Here
75
<script type="text/javascript">
75
<script type="text/javascript">
76
//<![CDATA[
76
//<![CDATA[
77
            function confirm_delete_item(ordernumber, basketno, biblionumber) {
77
            function confirm_delete_item(ordernumber, basketno, biblionumber) {
78
                var is_confirmed = confirm(_('Are you sure you want to delete this order ?'));
78
                var is_confirmed = confirm(_("Are you sure you want to delete this order ?"));
79
                if (is_confirmed) {
79
                if (is_confirmed) {
80
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno="+basketno+"&quantity=0&biblionumber="+biblionumber;
80
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno="+basketno+"&quantity=0&biblionumber="+biblionumber;
81
                }
81
                }
82
            }
82
            }
83
            
83
            
84
            function confirm_delete_biblio(ordernumber, basketno, biblionumber) {
84
            function confirm_delete_biblio(ordernumber, basketno, biblionumber) {
85
                var is_confirmed = confirm(_('Are you sure you want to delete this catalog record and order ?'));
85
                var is_confirmed = confirm(_("Are you sure you want to delete this catalog record and order ?"));
86
                if (is_confirmed) {
86
                if (is_confirmed) {
87
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno="+basketno+"&quantity=0&biblionumber="+biblionumber+"&delbiblio=1";
87
                    window.location = "addorder.pl?ordernumber="+ordernumber+"&basketno="+basketno+"&quantity=0&biblionumber="+biblionumber+"&delbiblio=1";
88
                    }
88
                    }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/biblio_framework.tt (-2 / +2 lines)
Lines 81-87 $(document).ready(function() { Link Here
81
            var filename = $(this).val();
81
            var filename = $(this).val();
82
            if ( ! /(?:\.csv|\.sql|\.ods|\.xml)$/.test(filename)) {
82
            if ( ! /(?:\.csv|\.sql|\.ods|\.xml)$/.test(filename)) {
83
                $(this).css("background-color","yellow");
83
                $(this).css("background-color","yellow");
84
                alert(_('Please select an ods or xml file'));
84
                alert(_("Please select an ods or xml file"));
85
                $(this).val("");
85
                $(this).val("");
86
                $(this).css("background-color","white");
86
                $(this).css("background-color","white");
87
            }
87
            }
Lines 109-115 $(document).ready(function() { Link Here
109
                    return false;
109
                    return false;
110
            }
110
            }
111
            obj.css("background-color","yellow");
111
            obj.css("background-color","yellow");
112
            alert(_('Please select an spreadsheet (csv, ods, xml) or sql file'));
112
            alert(_("Please select an spreadsheet (csv, ods, xml) or sql file"));
113
            obj.val("");
113
            obj.val("");
114
            obj.css("background-color","white");
114
            obj.css("background-color","white");
115
            return false;
115
            return false;
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/item_circulation_alerts.tt (-4 / +4 lines)
Lines 42-51 var $branch = "[% branch %]"; Link Here
42
$(function(){
42
$(function(){
43
    $('#alerttabs > ul').tabs();
43
    $('#alerttabs > ul').tabs();
44
44
45
    var blocked            = _('Blocked!');
45
    var blocked            = _("Blocked!");
46
    var saving             = _('Saving...');
46
    var saving             = _("Saving...");
47
    var disabledForAll     = _('Disabled for all');
47
    var disabledForAll     = _("Disabled for all");
48
    var disabledForCurrent = _('Disabled for') + ' ' + $branch;
48
    var disabledForCurrent = _("Disabled for") + ' ' + $branch;
49
49
50
    $('#branch_selector input:submit').hide();
50
    $('#branch_selector input:submit').hide();
51
    $('#branch').change(function(){
51
    $('#branch').change(function(){
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/merge.tt (-1 / +1 lines)
Lines 73-79 $(document).ready(function(){ Link Here
73
	    }
73
	    }
74
	    // If the field is not repeatable, we check if it already exists in the result table
74
	    // If the field is not repeatable, we check if it already exists in the result table
75
	    if (canbeadded == false) {
75
	    if (canbeadded == false) {
76
		alert(_('The field is non-repeatable and already exists in the destination record. Therefore, you cannot add it.'));
76
		alert(_("The field is non-repeatable and already exists in the destination record. Therefore, you cannot add it."));
77
		pField.checked = 0;
77
		pField.checked = 0;
78
	    } else {
78
	    } else {
79
79
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/label-manage.tt (-2 / +2 lines)
Lines 64-70 Link Here
64
                        return(document.layouts.action[selected[0]].value);
64
                        return(document.layouts.action[selected[0]].value);
65
                    }
65
                    }
66
                    else {
66
                    else {
67
                        alert(_('Please select only one ')+'[% label_element %]'+_(' to')+op+'.');
67
                        alert(_("Please select only one ")+"[% label_element %]"+_(" to")+op+".");
68
                        return (-1);
68
                        return (-1);
69
                    }
69
                    }
70
                }
70
                }
Lines 73-79 Link Here
73
                        return(document.layouts.action.value);
73
                        return(document.layouts.action.value);
74
                    }
74
                    }
75
                };
75
                };
76
                alert(_('Please select a ')+'[% label_element %].');
76
                alert(_("Please select a ")+"[% label_element %].");
77
                return (-1);
77
                return (-1);
78
            };
78
            };
79
        //]]>
79
        //]]>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt (-2 / +2 lines)
Lines 38-51 $(document).ready(function() { Link Here
38
    [% IF ( picture ) %]
38
    [% IF ( picture ) %]
39
    // new YAHOO.widget.Button("delpicture");   // FIXME: formatting mismatch between YUI and normal button
39
    // new YAHOO.widget.Button("delpicture");   // FIXME: formatting mismatch between YUI and normal button
40
	$('#delpicture').click(function(){
40
	$('#delpicture').click(function(){
41
		 return confirm(_('Are you sure you want to delete this patron image? This cannot be undone.'));
41
		 return confirm(_("Are you sure you want to delete this patron image? This cannot be undone."));
42
	});
42
	});
43
	$('#manage-patron-image').find("input[value*=Upload]").click(function(){
43
	$('#manage-patron-image').find("input[value*=Upload]").click(function(){
44
        if($("#uploadfile").val() == ""){
44
        if($("#uploadfile").val() == ""){
45
            alert(_("Please choose a file to upload"));
45
            alert(_("Please choose a file to upload"));
46
            return false;
46
            return false;
47
        }
47
        }
48
        return confirm(_('Are you sure you want to replace the current patron image? This cannot be undone.'));
48
        return confirm(_("Are you sure you want to replace the current patron image? This cannot be undone."));
49
	});[% END %]
49
	});[% END %]
50
	$("#renew_all"      ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); });
50
	$("#renew_all"      ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); });
51
	$("#CheckAllitems"  ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
51
	$("#CheckAllitems"  ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/list.tt (-2 / +2 lines)
Lines 7-14 Link Here
7
    //<![CDATA[
7
    //<![CDATA[
8
        $(document).ready(function() {
8
        $(document).ready(function() {
9
9
10
        $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/offline_circ/list.pl\">"+_('Uncheck all')+"<\/a>");
10
        $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/offline_circ/list.pl\">"+_("Uncheck all")+"<\/a>");
11
        $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/offline_circ/list.pl\">"+_('Check all')+"<\/a>");
11
        $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/offline_circ/list.pl\">"+_("Check all")+"<\/a>");
12
            $('#CheckNone').click(function() {
12
            $('#CheckNone').click(function() {
13
                $("#operations").unCheckCheckboxes();
13
                $("#operations").unCheckCheckboxes();
14
                return false;
14
                return false;
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/offline_circ/process_koc.tt (-1 / +1 lines)
Lines 18-24 function CheckUpload(f){ Link Here
18
}
18
}
19
function CheckForm(f) {
19
function CheckForm(f) {
20
    if (f.uploadedfileid.value == '') {
20
    if (f.uploadedfileid.value == '') {
21
        alert(_('Please upload a file first.'));
21
        alert(_("Please upload a file first."));
22
    } else {
22
    } else {
23
		$("#fileuploadstatus").hide();
23
		$("#fileuploadstatus").hide();
24
		$("#fileuploadform").slideUp();
24
		$("#fileuploadform").slideUp();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/patroncards/manage.tt (-4 / +4 lines)
Lines 38-44 Link Here
38
                        }
38
                        }
39
                    }
39
                    }
40
                    if (batches.length < 1) {
40
                    if (batches.length < 1) {
41
                        alert(_('Please select at least one batch to export.'));
41
                        alert(_("Please select at least one batch to export."));
42
                        return;     // no batch selected
42
                        return;     // no batch selected
43
                    }
43
                    }
44
                    getstr = batches.join("&");
44
                    getstr = batches.join("&");
Lines 47-53 Link Here
47
                    getstr = "batch_id="+document.layouts.action.value;
47
                    getstr = "batch_id="+document.layouts.action.value;
48
                }
48
                }
49
                else {
49
                else {
50
                    alert(_('Please select at least one batch to export.'));
50
                    alert(_("Please select at least one batch to export."));
51
                    return;     // no batch selected
51
                    return;     // no batch selected
52
                }
52
                }
53
                return GB_showCenter('Export Patron Cards', "/cgi-bin/koha/patroncards/print.pl?" + getstr, 700, 800);
53
                return GB_showCenter('Export Patron Cards', "/cgi-bin/koha/patroncards/print.pl?" + getstr, 700, 800);
Lines 64-70 Link Here
64
                        return(document.layouts.action[selected[0]].value);
64
                        return(document.layouts.action[selected[0]].value);
65
                    }
65
                    }
66
                    else {
66
                    else {
67
                        alert(_('Please select only one ')+'[% card_element %]'+_(' to ') + op + '.');
67
                        alert(_("Please select only one ")+"[% card_element %]"+_(" to ") + op + ".");
68
                        return (-1);
68
                        return (-1);
69
                    }
69
                    }
70
                }
70
                }
Lines 73-79 Link Here
73
                        return(document.layouts.action.value);
73
                        return(document.layouts.action.value);
74
                    }
74
                    }
75
                };
75
                };
76
                alert(_('Please select a ')+'[% card_element %].');
76
                alert(_("Please select a ")+"[% card_element %].");
77
                return (-1);
77
                return (-1);
78
            };
78
            };
79
        //]]>
79
        //]]>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt (-4 / +4 lines)
Lines 97-112 function checkMultiHold() { Link Here
97
        var msg = '';
97
        var msg = '';
98
98
99
        switch (override_items[itemnumber].holdallowed) {
99
        switch (override_items[itemnumber].holdallowed) {
100
            case 0: msg = _( 'This item normally cannot be put on hold.' ); break;
100
            case 0: msg = _("This item normally cannot be put on hold."); break;
101
            case 1: msg = _( 'This item normally cannot be put on hold except for patrons from ' ) + override_items[itemnumber].homebranch + '.'; break;
101
            case 1: msg = _("This item normally cannot be put on hold except for patrons from ") + override_items[itemnumber].homebranch + "."; break;
102
        }
102
        }
103
103
104
        msg += "\n\n" + _( 'Place hold on this item?' );
104
        msg += "\n\n" + _("Place hold on this item?");
105
105
106
        return confirm(msg);
106
        return confirm(msg);
107
    });
107
    });
108
    $("input.warning").click(function() {
108
    $("input.warning").click(function() {
109
        return confirm( _( 'None of these items can normally be put on hold for this patron.' ) + "\n\n" + _( 'Place hold?' ) );
109
        return confirm( _("None of these items can normally be put on hold for this patron.") + "\n\n" + _("Place hold?") );
110
    });
110
    });
111
 	$("#requestany").click(function() {
111
 	$("#requestany").click(function() {
112
		if(this.checked){
112
		if(this.checked){
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/claims.tt (-4 / +4 lines)
Lines 37-43 Link Here
37
		var selected = $("input:checked");
37
		var selected = $("input:checked");
38
38
39
		if (selected.length == 0) {
39
		if (selected.length == 0) {
40
			alert(_('Please select at least one item to export.'));
40
			alert(_("Please select at least one item to export."));
41
			return false;
41
			return false;
42
		}
42
		}
43
		
43
		
Lines 63-69 Link Here
63
	// Checks if the form can be sent (at least one checkbox must be checked)
63
	// Checks if the form can be sent (at least one checkbox must be checked)
64
	function checkForm() {
64
	function checkForm() {
65
	    if ($("input:checked").length == 0) {
65
	    if ($("input:checked").length == 0) {
66
		alert(_('Please select at least one item.'));
66
		alert(_("Please select at least one item."));
67
		return false;
67
		return false;
68
	    }
68
	    }
69
	}
69
	}
Lines 96-108 Link Here
96
	    
96
	    
97
	    // Checks if the beginning date is valid
97
	    // Checks if the beginning date is valid
98
	    if (!parseInt(beginDate)) {
98
	    if (!parseInt(beginDate)) {
99
		alert(_('The beginning date is missing or invalid.'));
99
		alert(_("The beginning date is missing or invalid."));
100
		return false;
100
		return false;
101
	    }
101
	    }
102
102
103
	    // Checks if the ending date is valid
103
	    // Checks if the ending date is valid
104
	    if (!parseInt(endDate)) {
104
	    if (!parseInt(endDate)) {
105
		alert(_('The ending date is missing or invalid.'));
105
		alert(_("The ending date is missing or invalid."));
106
		return false;
106
		return false;
107
	    }
107
	    }
108
108
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tags/review.tt (-2 / +2 lines)
Lines 48-60 td input,td input[type="submit"] { font-size: 85%; padding: 1px; } Link Here
48
		}
48
		}
49
	}
49
	}
50
	var success_approve = function(tag){
50
	var success_approve = function(tag){
51
		// window.alert(_('AJAX approved tag: ') + tag);
51
		// window.alert(_("AJAX approved tag: ") + tag);
52
	};
52
	};
53
	var failure_approve = function(tag){
53
	var failure_approve = function(tag){
54
		window.alert(_("AJAX failed to approve tag: ") + tag);
54
		window.alert(_("AJAX failed to approve tag: ") + tag);
55
	};
55
	};
56
	var success_reject  = function(tag){
56
	var success_reject  = function(tag){
57
		// window.alert(_('AJAX rejected tag: ') + tag);
57
		// window.alert(_("AJAX rejected tag: ") + tag);
58
	};
58
	};
59
	var failure_reject  = function(tag){
59
	var failure_reject  = function(tag){
60
		window.alert(_("AJAX failed to reject tag: ") + tag);
60
		window.alert(_("AJAX failed to reject tag: ") + tag);
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/holidays.tt (-4 / +4 lines)
Lines 34-49 Link Here
34
		$('#showHolidayType').val(holidayType);
34
		$('#showHolidayType').val(holidayType);
35
35
36
		if (holidayType == 'exception') {
36
		if (holidayType == 'exception') {
37
			$("#showOperationDelLabel").html(_('Delete this exception.'));
37
			$("#showOperationDelLabel").html(_("Delete this exception."));
38
			$("#holtype").attr("class","key exception").html(_("Holiday exception"));
38
			$("#holtype").attr("class","key exception").html(_("Holiday exception"));
39
		} else if(holidayType == 'weekday') {
39
		} else if(holidayType == 'weekday') {
40
			$("#showOperationDelLabel").html(_('Delete this holiday.'));
40
			$("#showOperationDelLabel").html(_("Delete this holiday."));
41
			$("#holtype").attr("class","key repeatableweekly").html(_("Holiday repeating weekly"));
41
			$("#holtype").attr("class","key repeatableweekly").html(_("Holiday repeating weekly"));
42
		} else if(holidayType == 'daymonth') {
42
		} else if(holidayType == 'daymonth') {
43
			$("#showOperationDelLabel").html(_('Delete this holiday.'));
43
			$("#showOperationDelLabel").html(_("Delete this holiday."));
44
			$("#holtype").attr("class","key repeatableyearly").html(_("Holiday repeating yearly"));
44
			$("#holtype").attr("class","key repeatableyearly").html(_("Holiday repeating yearly"));
45
		} else {
45
		} else {
46
			$("#showOperationDelLabel").html(_('Delete this holiday.'));
46
			$("#showOperationDelLabel").html(_("Delete this holiday."));
47
			$("#holtype").attr("class","key holiday").html(_("Unique holiday"));
47
			$("#holtype").attr("class","key holiday").html(_("Unique holiday"));
48
		}
48
		}
49
		
49
		
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/stage-marc-import.tt (-1 / +1 lines)
Lines 14-20 $(document).ready(function(){ Link Here
14
});
14
});
15
function CheckForm(f) {
15
function CheckForm(f) {
16
    if ($("#fileToUpload").value == '') {
16
    if ($("#fileToUpload").value == '') {
17
        alert(_('Please upload a file first.'));
17
        alert(_("Please upload a file first."));
18
    } else {
18
    } else {
19
        return submitBackgroundJob(f);
19
        return submitBackgroundJob(f);
20
    }
20
    }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/upload-images.tt (-1 / +1 lines)
Lines 20-26 $(document).ready(function(){ Link Here
20
});
20
});
21
function CheckForm(f) {
21
function CheckForm(f) {
22
    if ($("#fileToUpload").value == '') {
22
    if ($("#fileToUpload").value == '') {
23
        alert(_('Please upload a file first.'));
23
        alert(_("Please upload a file first."));
24
    } else {
24
    } else {
25
        return submitBackgroundJob(f);
25
        return submitBackgroundJob(f);
26
    }
26
    }
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt (-3 / +3 lines)
Lines 9-16 var MSG_NO_ITEM_SELECTED = _("Nothing is selected."); Link Here
9
9
10
$(document).ready(function(){
10
$(document).ready(function(){
11
	$("#addbarcode").focus();
11
	$("#addbarcode").focus();
12
    $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/shelves.pl\">"+_('Clear all')+"<\/a>");
12
    $("span.clearall").html("<a id=\"CheckNone\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Clear all")+"<\/a>");
13
    $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/shelves.pl\">"+_('Select all')+"<\/a>");
13
    $("span.checkall").html("<a id=\"CheckAll\" href=\"/cgi-bin/koha/shelves.pl\">"+_("Select all")+"<\/a>");
14
    $("#CheckAll").click(function(){
14
    $("#CheckAll").click(function(){
15
        $(".checkboxed").checkCheckboxes();
15
        $(".checkboxed").checkCheckboxes();
16
        return false;
16
        return false;
Lines 37-43 $(document).ready(function(){ Link Here
37
	var checkboxes = $("input:checkbox:checked");
37
	var checkboxes = $("input:checkbox:checked");
38
        var nbCheckbox = checkboxes.length;
38
        var nbCheckbox = checkboxes.length;
39
	if (nbCheckbox != 2) {
39
	if (nbCheckbox != 2) {
40
	    alert(_('Two records must be selected for merging.'));
40
	    alert(_("Two records must be selected for merging."));
41
	} else {
41
	} else {
42
	    location.href='/cgi-bin/koha/cataloguing/merge.pl?biblionumber=' + checkboxes[0].value + '&amp;biblionumber=' + checkboxes[1].value;
42
	    location.href='/cgi-bin/koha/cataloguing/merge.pl?biblionumber=' + checkboxes[0].value + '&amp;biblionumber=' + checkboxes[1].value;
43
	}
43
	}
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results-grouped.tt (-2 / +2 lines)
Lines 34-45 $(document).ready(function(){ Link Here
34
			var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
34
			var shelfnumber = $("#addto").find("option:selected").attr("id").replace("s","");
35
			[% IF ( loggedinusername ) %]if (vShelfAdd()) {
35
			[% IF ( loggedinusername ) %]if (vShelfAdd()) {
36
			Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?selectedshelf='+shelfnumber+'&' + vShelfAdd());
36
			Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?selectedshelf='+shelfnumber+'&' + vShelfAdd());
37
			}[% ELSE %] alert(_('You must be logged in to create or add to Lists')); [% END %]
37
			}[% ELSE %] alert(_("You must be logged in to create or add to Lists")); [% END %]
38
			return false;
38
			return false;
39
		} else if($("#addto").find("option:selected").attr("value") == "newlist"){
39
		} else if($("#addto").find("option:selected").attr("value") == "newlist"){
40
			[% IF ( loggedinusername ) %]if (vShelfAdd()) {
40
			[% IF ( loggedinusername ) %]if (vShelfAdd()) {
41
			Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
41
			Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
42
			}[% ELSE %] alert(_('You must be logged in to create or add to Lists')); [% END %]
42
			}[% ELSE %] alert(_("You must be logged in to create or add to Lists")); [% END %]
43
			return false;
43
			return false;
44
		}
44
		}
45
		if($("#addto").find("option:selected").attr("value") == "addtocart"){
45
		if($("#addto").find("option:selected").attr("value") == "addtocart"){
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt (-2 / +2 lines)
Lines 167-178 $(document).ready(function(){ Link Here
167
        } else if($("#addto").find("option:selected").attr("value") == "newlist"){
167
        } else if($("#addto").find("option:selected").attr("value") == "newlist"){
168
            [% IF ( loggedinusername ) %]if (vShelfAdd()) {
168
            [% IF ( loggedinusername ) %]if (vShelfAdd()) {
169
            Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
169
            Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());
170
            }[% ELSE %] alert(_('You must be logged in to create or add to lists')); [% END %]
170
            }[% ELSE %] alert(_("You must be logged in to create or add to lists")); [% END %]
171
            return false;
171
            return false;
172
        } else if($("#addto").find("option:selected").attr("value") == "morelists"){
172
        } else if($("#addto").find("option:selected").attr("value") == "morelists"){
173
            [% IF ( loggedinusername ) %]if (vShelfAdd()) {
173
            [% IF ( loggedinusername ) %]if (vShelfAdd()) {
174
            Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?' + vShelfAdd());
174
            Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?' + vShelfAdd());
175
            }[% ELSE %] alert(_('You must be logged in to create or add to lists')); [% END %]
175
            }[% ELSE %] alert(_("You must be logged in to create or add to lists")); [% END %]
176
            return false;
176
            return false;
177
        }
177
        }
178
        if($("#addto").find("option:selected").attr("value") == "addtocart" || $("#addto").attr("class") == "addtocart"){
178
        if($("#addto").find("option:selected").attr("value") == "addtocart" || $("#addto").attr("class") == "addtocart"){
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-review.tt (-1 / +1 lines)
Lines 8-14 Link Here
8
	 $(document).ready(function() {
8
	 $(document).ready(function() {
9
	 	var inject_old = function(comment) {
9
	 	var inject_old = function(comment) {
10
			[% IF ( reviewid ) %]
10
			[% IF ( reviewid ) %]
11
			[% IF ( cgi_debug ) %]alert(_('injecting OLD comment: ')+comment);[% END %]
11
			[% IF ( cgi_debug ) %]alert(_("injecting OLD comment: ")+comment);[% END %]
12
            parent.opener.$('#c[% reviewid %] p').prev("small").prev("h5").html(_("Your edited comment (preview, pending approval)"));
12
            parent.opener.$('#c[% reviewid %] p').prev("small").prev("h5").html(_("Your edited comment (preview, pending approval)"));
13
			parent.opener.$('#c[% reviewid %] p').html(comment);
13
			parent.opener.$('#c[% reviewid %] p').html(comment);
14
            parent.opener.$('#c[% reviewid %] p').append(" <a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber | uri %]&amp;reviewid=[% reviewid | uri%]\');\">"+_("Edit")+"<\/a>");
14
            parent.opener.$('#c[% reviewid %] p').append(" <a href=\"#comment\" onclick=\"Dopop(\'/cgi-bin/koha/opac-review.pl?biblionumber=[% biblionumber | uri %]&amp;reviewid=[% reviewid | uri%]\');\">"+_("Edit")+"<\/a>");
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt (-4 / +3 lines)
Lines 78-88 function enableCheckboxActions(){ Link Here
78
78
79
$(function() {
79
$(function() {
80
    [% IF ( opacbookbag ) %]$(".addtocart").show();[% END %]
80
    [% IF ( opacbookbag ) %]$(".addtocart").show();[% END %]
81
    $("span.clearall").html("<a id=\"CheckNone\" href=\"#\">"+_('Clear all')+"<\/a>");
81
    $("span.clearall").html("<a id=\"CheckNone\" href=\"#\">"+_("Clear all")+"<\/a>");
82
    $("span.checkall").html("<a id=\"CheckAll\" href=\"#\">"+_('Select all')+"<\/a>");
82
    $("span.checkall").html("<a id=\"CheckAll\" href=\"#\">"+_("Select all")+"<\/a>");
83
  $("a.print").show();
83
  $("a.print").show();
84
84
85
    [% IF ( opacuserlogin ) %][% IF ( RequestOnOpac ) %]$("#placehold").html("<a href=\"#\" class=\"hold tag_hides disabled\">"+_('Place hold')+"<\/a>");
85
    [% IF ( opacuserlogin ) %][% IF ( RequestOnOpac ) %]$("#placehold").html("<a href=\"#\" class=\"hold tag_hides disabled\">"+_("Place hold")+"<\/a>");
86
      $("#selections-toolbar a.hold").click(function(){
86
      $("#selections-toolbar a.hold").click(function(){
87
         holdSelections();
87
         holdSelections();
88
         return false;
88
         return false;
89
- 

Return to bug 8942