From 64758056d8a8adf68d95cdd2111f1dcdfc3dc872 Mon Sep 17 00:00:00 2001 From: erickson Date: Fri, 20 Jan 2006 20:26:54 +0000 Subject: [PATCH] now supports creation and showing of public containers git-svn-id: svn://svn.open-ils.org/ILS/trunk@2776 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/web/opac/skin/default/js/myopac.js | 14 ++++++- .../default/xml/myopac/myopac_bookbags.xml | 40 +++++++++++++++---- 2 files changed, 45 insertions(+), 9 deletions(-) diff --git a/Open-ILS/web/opac/skin/default/js/myopac.js b/Open-ILS/web/opac/skin/default/js/myopac.js index e5518e732b..ed5198a61d 100644 --- a/Open-ILS/web/opac/skin/default/js/myopac.js +++ b/Open-ILS/web/opac/skin/default/js/myopac.js @@ -545,6 +545,18 @@ function myOPACShowBookbags(force) { 'javascript:myOPACExpandBookbag("' + cont.id() + '","' + cont.name() + '");'); myOPACFetchBBItems( cont.id(), row ); dlink.setAttribute('href', 'javascript:myOPACDeleteBookbag("'+cont.id()+'");'); + + if( cont.public() ) { + unHideMe($n(row, 'myopac_bb_published_yes')); + var link = $n(row, 'myopac_bb_published_view'); + link.setAttribute('href', buildContribLink( 'bbags.xml?bb='+cont.id(), false)); + link.setAttribute('target', '_blank' ); + unHideMe(link); + + } else { + unHideMe($n(row, 'myopac_bb_published_no')); + } + tbody.appendChild(row); } @@ -641,7 +653,7 @@ function myOPACShowBBItem(r) { function myOPACCreateBookbag() { var name = $('myopac_bookbag_new_name').value; if(!name) return; - var result = containerCreate( name ); + var result = containerCreate( name, $('bb_public_yes').checked ); var code = checkILSEvent(result); if(code) { alertILSEvent(code); return; } myOPACShowBookbags(true); diff --git a/Open-ILS/web/opac/skin/default/xml/myopac/myopac_bookbags.xml b/Open-ILS/web/opac/skin/default/xml/myopac/myopac_bookbags.xml index 2a1c614c9e..cf40f2b282 100644 --- a/Open-ILS/web/opac/skin/default/xml/myopac/myopac_bookbags.xml +++ b/Open-ILS/web/opac/skin/default/xml/myopac/myopac_bookbags.xml @@ -10,13 +10,14 @@
-
You have not created any bookbags
+
You have not created any bookbags
My Bookbags

- + @@ -24,7 +25,14 @@ - + +
Name# ItemsDelete this bookbag?
Name# ItemsPublishedDelete this bookbag?
ItemsDelete + No + Yes + (View) + + Delete +
@@ -36,11 +44,21 @@ Create a new Bookbag - - Enter the name of the new Bookbag: - - - + + + Enter the name of the new Bookbag: + + + + + + Publish this Bookbag + (??) + Yes + No + + @@ -70,5 +88,11 @@ + + + Publishing a Bookbag means that the contents of the Bookbag will be visible to others. + To see the public view of a published Bookbag, click the "View" link in the + "Published" column of the Bookbag list at the top of this page. + -- 2.43.2