[LON-CAPA-cvs] cvs: modules /gerd/harvesting lonindexer.pm
www
www at source.lon-capa.org
Mon Jul 9 14:04:50 EDT 2012
www Mon Jul 9 18:04:50 2012 EDT
Modified files:
/modules/gerd/harvesting lonindexer.pm
Log:
Remember londocs basket for later
Index: modules/gerd/harvesting/lonindexer.pm
diff -u modules/gerd/harvesting/lonindexer.pm:1.4 modules/gerd/harvesting/lonindexer.pm:1.5
--- modules/gerd/harvesting/lonindexer.pm:1.4 Mon Jul 9 16:57:30 2012
+++ modules/gerd/harvesting/lonindexer.pm Mon Jul 9 18:04:50 2012
@@ -5,7 +5,7 @@
#
# MODIFY $datapath VARIABLE FOR LOCATION OF DATA FILES
#
-# $Id: lonindexer.pm,v 1.4 2012/07/09 16:57:30 www Exp $
+# $Id: lonindexer.pm,v 1.5 2012/07/09 18:04:50 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -337,13 +337,21 @@
'only','omit','titleelement','basket']);
#-------------------------------------------------------------------
#
-# Get the current basket
+# Get the current basket if being called from londocs
#
my ($cnum,$cdom,$folder)=split(/\,/,$env{'form.basket'});
my %existingres=();
if ($folder) {
%existingres=&urlres(&mapread($cnum,$cdom,$folder));
}
+# Existing and new stuff
+ my $basket='';
+ foreach my $importbasket (values(%existingres)) {
+ if ($importbasket) {
+ $basket.=','.$importbasket;
+ }
+ }
+ $basket=~s/^\,//;
my $closebutton='';
@@ -366,6 +374,10 @@
untie(%dbfile);
}
}
+ if ($basket) {
+ $hash{'basket'}=$basket;
+ }
+
# - Evaluate actions from previous page (both cumulatively and chronologically)
if ($env{'form.catalogmode'} eq 'import' || $hash{'form.catalogmode'} eq 'import') {
&Apache::groupsort::update_actions_hash(\%hash);
More information about the LON-CAPA-cvs
mailing list