1 [% PROCESS "opac/parts/header.tt2";
2 PROCESS "opac/parts/misc_util.tt2";
3 WRAPPER "opac/parts/myopac/base.tt2";
4 myopac_page = "lists" %]
5 <div id='myopac_bookbag_div' style="padding:5px;">
7 <!-- <div class="header_middle">
8 <span id="acct_holds_header" style="float:left;">[% l('My Lists') %]</span>
9 <span style="float:right;"><a class="hide_me" href="#">[% l('Export List') %]</a></span>
11 <div style="float:right;width:85px;">
12 <div style="position:absolute">
13 <div style="position:relative;top:13px;">
14 <a href="#" style="position:relative;top:-3px;left:-5px;"><img alt="[% l('Saving Help') %]"
15 src="[% ctx.media_prefix %]/images/question-mark.png" /></a>
16 <a href="#"><img alt="[% l('Save') %]" src="[% ctx.media_prefix %]/images/save-btn.png"/></a>
20 <div id="temp_wrapper">
23 <!-- new list creation -->
24 <form action="[% ctx.opac_root %]/myopac/list/update" method="POST" id="create_form">
25 <h1>[% l('Create new list') %]</h1><a name="createnewlist"></a>
26 <table cellpadding="0" border="0" id="list_create_table">
29 <label for="list_create_name">[% l('Enter the name of the new list:') %]</label>
32 <input id="list_create_name" type="text" name="name" />
33 <input type="hidden" name="action" value="create" />
36 <label for="list_create_shared">[% l('Share this list?') %]</label>
37 <select name="shared" id="list_create_shared">
38 <option value="0">[% l('No') %]
39 <option value="1">[% l('Yes') %]
41 <a href="javascript:void(0);" onclick="alert(document.getElementById('bb_publish_text').innerHTML);"><img alt="[% l('Sharing Help') %]"
42 src="[% ctx.media_prefix %]/images/question-mark.png" /></a>
44 <td class="list-create-table-buttons">
46 value="[% l('Submit') %]"
47 alt="[% l('Submit') %]"
49
51 value="[% l('Cancel') %]"
52 alt="[% l('Cancel') %]"
53 class="opac-button" />
57 <td class="text-right-top">
58 <label for="list_description">[% l("List description (optional):") %]</label>
61 <textarea cols="40" rows="3" name="description"
62 id="list_description"></textarea>
67 <h1>[% l("Your existing lists") %]</h1>
68 [% INCLUDE "opac/parts/anon_list.tt2" %]
69 [% IF ctx.bookbags.size %]
70 <div id='acct_lists_prime'>
71 [% FOR bbag IN ctx.bookbags %]
72 <div class="bookbag-controls-holder">
73 <div class="bookbag-controls most">
74 [% baseurl = ctx.opac_root _ '/myopac/lists';
75 IF bbag.id != CGI.param("id");
76 url = mkurl(baseurl, {id => bbag.id}, ['edit_notes']);
77 ltitle = l("Show items in list");
79 url = mkurl(baseurl, {}, ['id', 'edit_notes']);
80 ltitle = l("Hide items in list");
82 <h2 class="bookbag-name"><a title="[% ltitle %]" href="[% url %]">[% bbag.name | html %]</a></h2>
83 [% IF bbag.description %]<div class="bookbag-description">[% bbag.description | html %]</div>[% END %]
85 <form action="[% ctx.opac_root %]/myopac/list/update" method="POST">
86 <div class="bookbag-share">
87 <input type="hidden" name="list" value="[% bbag.id %]" />
88 [% IF bbag.pub != 't' %]
89 <input type="hidden" name="action" value="show" />
90 <input class="fixed" type="submit" value="[% l('Share') %]" />
92 <input type="hidden" name="action" value="hide" />
93 <input class="fixed" type="submit" value="[% l('Hide') %]" />
97 <form action="[% ctx.opac_root %]/myopac/list/update" method="POST">
98 <div class="bookbag-controls">
99 <input type="hidden" name="list" value="[% bbag.id %]" />
100 <input type="hidden" name="action" value="delete" />
101 <input type="submit" value="[% l('Delete List') %]" />
104 <form action="[% ctx.opac_root %]/myopac/list/print" method="POST">
105 <div class="bookbag-controls">
106 <input type="hidden" name="list" value="[% bbag.id %]" />
107 <input type="hidden" name="sort" value="[% CGI.param('sort') | html %]" />
108 <input type="submit" value="[% l('Download CSV') %]" />
111 <div class="bookbag-controls">
112 [% IF bbag.pub == 't'; %]
113 <a target='_blank' href='/opac/extras/feed/bookbag/rss2-full/[% bbag.id %]'><img
114 alt="[% l('RSS Feed') %]" border="0"
115 src="[% ctx.media_prefix %]/images/small-rss.png"/></a>
118 <div class="bookbag-controls">
119 [% IF bbag.pub == 't'; %]
121 mkurl( ctx.opac_root _ '/results', {page => '0', query => 'container(bre,bookbag,' _ bbag.id _ ')'} )
122 -%]'>[% l('HTML View') %]</a>
125 <div class="clear-both pad-bottom-five"></div>
127 [% IF CGI.param("id") == bbag.id %]
128 <div class="bookbag-specific">
130 <label for="opac.result.sort">[% l("Sort list items by: ") %]</label>
131 [% INCLUDE "opac/parts/filtersort.tt2"
132 value=CGI.param('sort') mode='bookbag' %]
133 <input type="hidden" name="id"
134 value="[% CGI.param('id') | html %]" />
135 <input type="submit" value="[% l('Sort') %]" />
138 <form action="[% ctx.opac_root %]/myopac/list/update" method="POST">
139 <input type="hidden" name="list" value="[% bbag.id %]" />
140 <input type="hidden" name="sort" value="[% CGI.param('sort') | uri %]" />
141 <table class="bookbag-specific" cellpadding='0' cellspacing='0' border='0'>
142 <thead id="acct_list_header">
144 <td width="1%" style="padding-left: 10px;">
145 <input type="checkbox" onclick="
146 var inputs=document.getElementsByTagName('input');
147 for (i = 0; i < inputs.length; i++) {
148 if (inputs[i].name == 'selected_item' && !inputs[i].disabled && inputs[i].getAttribute('bbag') == [% bbag.id %])
149 inputs[i].checked = this.checked;}"/>
152 <td width="32%" style="padding-left: 5px;">
153 <a href="[% mkurl(ctx.opac_root _ '/myopac/lists', {sort=> (CGI.param('sort') == 'titlesort' ? 'titlesort.descending' : 'titlesort')}) %]">[% l('Title') %]</a>
156 <a href="[% mkurl(ctx.opac_root _ '/myopac/lists', {sort=>(CGI.param('sort') == 'authorsort' ? 'authorsort.descending' : 'authorsort')}) %]">[% l('Author(s)') %]</a>
160 [% IF CGI.param("edit_notes") != bbag.id %]
161 | <a href="[% mkurl(ctx.opac_root _ '/myopac/lists', {edit_notes=> bbag.id}) %]">[% l('Edit') %]</a>
164 <td width="1%" class="nowrap">
165 <select name="action">
166 <option disabled="disabled">[% l('-- Actions for these items --') %]</option>
167 <option value="place_hold">[% l('Place hold') %]</option>
168 <option value="del_item">[% l('Remove from list') %]</option>
170 <input type="submit" value="[% l('Go') %]" />
175 [% UNLESS bbag.items.size %]
176 <tr><td colspan="4" class="opac-auto-171 opac-auto-097">
177 [% l("This list contains no items.") %]
180 [% FOR item IN bbag.items;
181 rec_id = item.target_biblio_record_entry.id;
182 attrs = {marc_xml => ctx.bookbags_marc_xml.$rec_id};
183 PROCESS get_marc_attrs args=attrs %]
184 <tr class="bookbag-item-row">
185 <td class="item_list_padding" style="padding-left: 10px;">
186 <input type="checkbox" name="selected_item" value="[% item.id %]" bbag='[% bbag.id %]'/>
188 <td class="item_list_padding" style="padding-left: 5px;">
189 <a href="[% mkurl(ctx.opac_root _ '/record/' _ rec_id, {}, ['edit_notes', 'id']) %]">[% attrs.title | html %]</a>
191 <td class="item_list_padding">
193 authorquery = attrs.author | replace('[,\.:;]', '');
194 mkurl(ctx.opac_root _ '/results', {qtype => 'author', query => authorquery}, ['page', 'id', 'edit_notes'])
195 -%]">[% attrs.author | html %]</a>
196 [% IF CGI.param("edit_notes") == bbag.id %]
197 <td class="opac-auto-097b">
198 [% FOR note IN item.notes %]
199 <input type="text" name="note-[% note.id %]" value="[% note.note | html %]" />
201 <input type="text" name="item-[% item.id %]" />
204 <td class="opac-auto-097b">
205 [% FOR note IN item.notes %]
206 <div>[% note.note | html %]</div>
212 [% IF CGI.param("edit_notes") == bbag.id %]
214 <td colspan="3"><!-- All space left of notes column --></td>
215 <td class="save-notes">
216 <input type="hidden" name="id" value="[% CGI.param('id') | html %]" />
217 <input type="submit" name="save_notes" value="[% l('Save Notes') %]" />
229 <div id='myopac_delete_bookbag_warn' class='hide_me'>
230 [% l("This will remove the selected bookbag and all items contained within the bookbag. Are you sure you wish to continue?") %]
232 <div style='text-align: center; font-weight: bold;'
233 class='hide_me' id='myopac_bookbags_none'>[% l("You have not created any bookbags") %]</div>
234 <div style='width: 99%; text-align: center'>
235 <b id='myopac_bookbag_items_name'> </b>
237 <span id='bb_publish_text' class='hide_me'>
238 [% |l %]Sharing a Bookbag means that the contents
239 of the Bookbag will be visible to others.
240 To see the public view of a shared Bookbag,
241 click on the Bookbag's name in the Bookbag list.[% END %]
243 <span id='myopac_remove_bb_item_confirm' class='hide_me'>
244 [% l("Are you sure you wish to remove this bookbag item?") %]
246 <span id='myopac_make_published_confirm' class='hide_me'>
247 [% l("Sharing this bookbag will allow the contents of the bookbag to be seen by others. Are you sure you wish to share this bookbag?") %]
249 <span id='myopac_make_unpublished_confirm' class='hide_me'>
250 [% l("Are you sure you wish to hide this bookbag?") %]
252 <span id='myopac_bb_update_success' class='hide_me'>
253 [% l("The Bookbag was successfully updated.") %]
255 <span id='bb_create_warning' class='hide_me'>
256 [% l("Warning: Adding items to a bookbag creates a link between you and the items in the database. The contents of the bookbag are NOT publicly viewable unless the bookbag is shared. However, if you prefer not to have any link between your patron record and a particular item or items, we suggest that you do not place said items in a bookbag or that you avoid using bookbags all together. Thank you.") %]
258 <span id='myopac_bb_what_are' class='hide_me'>
259 [% l("Bookbags are...") %]
261 <span class='hide_me' id='bb_update_success'>
262 [% l("Bookbag successfully updated") %]