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

(-)a/koha-tmpl/opac-tmpl/prog/en/css/opac.css (-1 / +13 lines)
Lines 779-784 a.tag_add { Link Here
779
	text-decoration : none;
779
	text-decoration : none;
780
	padding-left : 33px;
780
	padding-left : 33px;
781
}
781
}
782
782
/* Search results place hold link */
783
/* Search results place hold link */
783
#placehold input.submit {
784
#placehold input.submit {
784
    background-image: url("../../images/sprite.png"); /* Place hold */
785
    background-image: url("../../images/sprite.png"); /* Place hold */
Lines 1491-1497 padding-left : .4em; Link Here
1491
.actions a.addtocart,
1492
.actions a.addtocart,
1492
.actions a.addtoshelf,
1493
.actions a.addtoshelf,
1493
.actions a.addtolist,
1494
.actions a.addtolist,
1494
.actions a.tag_add {
1495
.actions a.tag_add,
1496
.actions a.removefromlist {
1495
	margin-left : 1em;
1497
	margin-left : 1em;
1496
	text-decoration : none;
1498
	text-decoration : none;
1497
}
1499
}
Lines 1513-1518 padding-left : .4em; Link Here
1513
	display : none;
1515
	display : none;
1514
}
1516
}
1515
1517
1518
/* List contents remove from list link */
1519
.removefromlist  {
1520
    background-image : url("../../images/sprite.png"); /* Delete */
1521
    background-position : -8px -690px;
1522
    background-repeat: no-repeat;
1523
    text-decoration : none;
1524
    padding-left : 15px;
1525
    display : none;
1526
}
1527
1516
/* Search results rows save to lists */
1528
/* Search results rows save to lists */
1517
.actions a.addtoshelf {
1529
.actions a.addtoshelf {
1518
    background-image : url("../../images/sprite.png"); /* MARC view */
1530
    background-image : url("../../images/sprite.png"); /* MARC view */
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tt (-3 / +22 lines)
Lines 7-12 Link Here
7
<script type="text/javascript">
7
<script type="text/javascript">
8
//<![CDATA[
8
//<![CDATA[
9
var MSG_REMOVE_FROM_LIST = _("Are you sure you want to remove these items from the list?");
9
var MSG_REMOVE_FROM_LIST = _("Are you sure you want to remove these items from the list?");
10
var MSG_REMOVE_ONE_FROM_LIST = _("Are you sure you want to remove this item from the list?");
10
var MSG_CONFIRM_DELETE_LIST = _("Are you sure you want to delete this list?");
11
var MSG_CONFIRM_DELETE_LIST = _("Are you sure you want to delete this list?");
11
12
12
[% IF ( opacuserlogin ) %][% IF ( RequestOnOpac ) %]
13
[% IF ( opacuserlogin ) %][% IF ( RequestOnOpac ) %]
Lines 152-161 $(function() { Link Here
152
        });
153
        });
153
[% END %]
154
[% END %]
154
  [% IF ( loggedinusername && allowremovingitems ) %]
155
  [% IF ( loggedinusername && allowremovingitems ) %]
156
  var removeFromListLinks = $(".removefromlist");
157
  removeFromListLinks.show();
158
  // "remove from list" appearing on each line of the list output
159
  removeFromListLinks.on("click",function(){
160
      $(".checkboxed").unCheckCheckboxes();
161
      var listitem = $("input[name="+this.id+"]");
162
      listitem.prop("checked",true);
163
      $("#myform").submit();
164
  });
155
  $("#myform").submit(function(){
165
  $("#myform").submit(function(){
156
    var checkedBoxes = $(".checkboxed input:checkbox:checked");
166
    var checkedBoxes = $(".checkboxed input:checkbox:checked");
157
    if ($(checkedBoxes).size()) {
167
    var numchecked = $(checkedBoxes).size();
158
      return confirmDelete(MSG_REMOVE_FROM_LIST);
168
    if (numchecked) {
169
        if( numchecked > 1 ){
170
            return confirmDelete(MSG_REMOVE_FROM_LIST);
171
        } else {
172
            return confirmDelete(MSG_REMOVE_ONE_FROM_LIST);
173
        }
159
    } else {
174
    } else {
160
      alert(MSG_NO_RECORD_SELECTED);
175
      alert(MSG_NO_RECORD_SELECTED);
161
      return false;
176
      return false;
Lines 473-478 $(document).ready(function() { Link Here
473
488
474
        [% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( virtualshelves ) %]<a class="addtoshelf" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=[% itemsloo.biblionumber %]" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=[% itemsloo.biblionumber %]'); return false;">Save to another list</a>
489
        [% IF ( opacuserlogin ) %][% IF ( loggedinusername ) %][% IF ( virtualshelves ) %]<a class="addtoshelf" href="/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=[% itemsloo.biblionumber %]" onclick="Dopop('opac-addbybiblionumber.pl?biblionumber=[% itemsloo.biblionumber %]'); return false;">Save to another list</a>
475
          [% END %][% END %][% END %]
490
          [% END %][% END %][% END %]
491
492
        [% IF ( allowremovingitems ) %]
493
            <a class="removefromlist" id="REM-[% itemsloo.biblionumber %]" href="#">Remove from this list</a>
494
        [% END %]
495
476
          [% IF ( opacbookbag ) %]
496
          [% IF ( opacbookbag ) %]
477
              [% IF ( itemsloo.incart ) %]
497
              [% IF ( itemsloo.incart ) %]
478
                  <a class="addtocart cart[% itemsloo.biblionumber %]" href="#" onclick="addRecord('[% itemsloo.biblionumber %]'); return false;">In your cart</a> <a class="cartRemove cartR[% itemsloo.biblionumber %]" href="#" onclick="delSingleRecord('[% itemsloo.biblionumber %]'); return false;">(remove)</a>
498
                  <a class="addtocart cart[% itemsloo.biblionumber %]" href="#" onclick="addRecord('[% itemsloo.biblionumber %]'); return false;">In your cart</a> <a class="cartRemove cartR[% itemsloo.biblionumber %]" href="#" onclick="delSingleRecord('[% itemsloo.biblionumber %]'); return false;">(remove)</a>
479
- 

Return to bug 7257