|
Lines 47-60
Link Here
|
| 47 |
}); |
47 |
}); |
| 48 |
|
48 |
|
| 49 |
/* check cookie to hide/show marcdocs*/ |
49 |
/* check cookie to hide/show marcdocs*/ |
| 50 |
if($.cookie("marcdocs_[% borrowernumber | html %]") == 'hide'){ |
50 |
if( Cookies.get("marcdocs_[% borrowernumber | html %]") == 'hide'){ |
| 51 |
toggleMARCdocLinks(false); |
51 |
toggleMARCdocLinks(false); |
| 52 |
} else { |
52 |
} else { |
| 53 |
toggleMARCdocLinks(true); |
53 |
toggleMARCdocLinks(true); |
| 54 |
} |
54 |
} |
| 55 |
|
55 |
|
| 56 |
$("#marcDocsSelect").click(function(){ |
56 |
$("#marcDocsSelect").click(function(){ |
| 57 |
if($.cookie("marcdocs_[% borrowernumber | html %]") == 'hide'){ |
57 |
if( Cookies.get("marcdocs_[% borrowernumber | html %]") == 'hide'){ |
| 58 |
toggleMARCdocLinks(true); |
58 |
toggleMARCdocLinks(true); |
| 59 |
} else { |
59 |
} else { |
| 60 |
toggleMARCdocLinks(false); |
60 |
toggleMARCdocLinks(false); |
|
Lines 62-68
Link Here
|
| 62 |
}); |
62 |
}); |
| 63 |
|
63 |
|
| 64 |
/* check cookie to hide/show marc tags*/ |
64 |
/* check cookie to hide/show marc tags*/ |
| 65 |
var marctags_cookie = $.cookie("marctags_[% borrowernumber | html %]"); |
65 |
var marctags_cookie = Cookies.get("marctags_[% borrowernumber | html %]"); |
| 66 |
if( marctags_cookie == 'hide'){ |
66 |
if( marctags_cookie == 'hide'){ |
| 67 |
toggleMARCTagLinks(false); |
67 |
toggleMARCTagLinks(false); |
| 68 |
} else if( marctags_cookie == 'show'){ |
68 |
} else if( marctags_cookie == 'show'){ |
|
Lines 76-82
Link Here
|
| 76 |
} |
76 |
} |
| 77 |
|
77 |
|
| 78 |
$("#marcTagsSelect").click(function(){ |
78 |
$("#marcTagsSelect").click(function(){ |
| 79 |
if( $.cookie("marctags_[% borrowernumber | html %]") == 'hide'){ |
79 |
if( Cookies.get("marctags_[% borrowernumber | html %]") == 'hide'){ |
| 80 |
toggleMARCTagLinks(true) |
80 |
toggleMARCTagLinks(true) |
| 81 |
} else { |
81 |
} else { |
| 82 |
toggleMARCTagLinks(false); |
82 |
toggleMARCTagLinks(false); |
|
Lines 125-131
Link Here
|
| 125 |
|
125 |
|
| 126 |
if ( !confirm( breedingid ? _("This record cannot be transferred to the advanced editor. Continue?") : _("Any changes will not be saved. Continue?") ) ) return false; |
126 |
if ( !confirm( breedingid ? _("This record cannot be transferred to the advanced editor. Continue?") : _("Any changes will not be saved. Continue?") ) ) return false; |
| 127 |
|
127 |
|
| 128 |
$.cookie( 'catalogue_editor_[% logged_in_user.borrowernumber | html %]', 'advanced', { expires: 365, path: '/' } ); |
128 |
Cookies.set( 'catalogue_editor_[% logged_in_user.borrowernumber | html %]', 'advanced', { expires: 365, path: '/' } ); |
| 129 |
|
129 |
|
| 130 |
var biblionumber = [% biblionumber || "null" | html %]; |
130 |
var biblionumber = [% biblionumber || "null" | html %]; |
| 131 |
|
131 |
|
|
Lines 260-270
Link Here
|
| 260 |
function toggleMARCdocLinks(flag){ |
260 |
function toggleMARCdocLinks(flag){ |
| 261 |
if( flag === true ){ |
261 |
if( flag === true ){ |
| 262 |
$(".marcdocs").show(); |
262 |
$(".marcdocs").show(); |
| 263 |
$.cookie("marcdocs_[% borrowernumber | html %]",'show', { path: "/", expires: 365 }); |
263 |
Cookies.set("marcdocs_[% borrowernumber | html %]",'show', { path: "/", expires: 365 }); |
| 264 |
$("#marcDocsSelect i").addClass('fa-check-square-o').removeClass('fa-square-o'); |
264 |
$("#marcDocsSelect i").addClass('fa-check-square-o').removeClass('fa-square-o'); |
| 265 |
} else { |
265 |
} else { |
| 266 |
$(".marcdocs").hide(); |
266 |
$(".marcdocs").hide(); |
| 267 |
$.cookie("marcdocs_[% borrowernumber | html %]",'hide', { path: "/", expires: 365 }); |
267 |
Cookies.set("marcdocs_[% borrowernumber | html %]",'hide', { path: "/", expires: 365 }); |
| 268 |
$("#marcDocsSelect i").removeClass('fa-check-square-o').addClass('fa-square-o'); |
268 |
$("#marcDocsSelect i").removeClass('fa-check-square-o').addClass('fa-square-o'); |
| 269 |
} |
269 |
} |
| 270 |
} |
270 |
} |
|
Lines 273-284
Link Here
|
| 273 |
if( flag === true ){ |
273 |
if( flag === true ){ |
| 274 |
$(".tagnum").show(); |
274 |
$(".tagnum").show(); |
| 275 |
$(".subfieldcode").show(); |
275 |
$(".subfieldcode").show(); |
| 276 |
$.cookie("marctags_[% borrowernumber | html %]",'show', { path: "/", expires: 365 }); |
276 |
Cookies.set("marctags_[% borrowernumber | html %]",'show', { path: "/", expires: 365 }); |
| 277 |
$("#marcTagsSelect i").addClass('fa-check-square-o').removeClass('fa-square-o'); |
277 |
$("#marcTagsSelect i").addClass('fa-check-square-o').removeClass('fa-square-o'); |
| 278 |
} else { |
278 |
} else { |
| 279 |
$(".tagnum").hide(); |
279 |
$(".tagnum").hide(); |
| 280 |
$(".subfieldcode").hide(); |
280 |
$(".subfieldcode").hide(); |
| 281 |
$.cookie("marctags_[% borrowernumber | html %]",'hide', { path: "/", expires: 365 }); |
281 |
Cookies.set("marctags_[% borrowernumber | html %]",'hide', { path: "/", expires: 365 }); |
| 282 |
$("#marcTagsSelect i").removeClass('fa-check-square-o').addClass('fa-square-o'); |
282 |
$("#marcTagsSelect i").removeClass('fa-check-square-o').addClass('fa-square-o'); |
| 283 |
} |
283 |
} |
| 284 |
} |
284 |
} |
| 285 |
- |
|
|