[LON-CAPA-cvs] cvs: loncom /interface londocs.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Fri, 04 Nov 2005 20:52:35 -0000
albertel Fri Nov 4 15:52:35 2005 EDT
Modified files:
/loncom/interface londocs.pm
Log:
- adding support for get a dump of the symbs in a course (commented out for now.)
Index: loncom/interface/londocs.pm
diff -u loncom/interface/londocs.pm:1.207 loncom/interface/londocs.pm:1.208
--- loncom/interface/londocs.pm:1.207 Mon Oct 31 13:52:22 2005
+++ loncom/interface/londocs.pm Fri Nov 4 15:52:35 2005
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Documents
#
-# $Id: londocs.pm,v 1.207 2005/10/31 18:52:22 albertel Exp $
+# $Id: londocs.pm,v 1.208 2005/11/04 20:52:35 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1721,6 +1721,24 @@
#
+# ----------------------------------------------------------------- List Symbs
+#
+sub list_symbs {
+ my $r=shift;
+ my $html=&Apache::lonxml::xmlbegin();
+ $r->print($html.'<head><title>Symb List</title></head>'.
+ &Apache::loncommon::bodytag('Symb List'));
+ my $navmap = Apache::lonnavmaps::navmap->new();
+ $r->print("<pre>\n");
+ foreach my $res ($navmap->retrieveResources()) {
+ $r->print($res->compTitle()."\t".$res->symb()."\n");
+ }
+ $r->print("\n</pre>\n");
+ $r->print('<a href="/adm/coursedocs">'.&mt('Return to DOCS').'</a>');
+}
+
+
+#
# -------------------------------------------------------------- Verify Content
#
sub verifycontent {
@@ -2087,6 +2105,8 @@
if ($env{'form.verify'}) {
&verifycontent($r);
+ } elsif ($env{'form.listsymbs'}) {
+ &list_symbs($r);
} elsif ($env{'form.versions'}) {
&checkversions($r);
} elsif ($env{'form.dumpcourse'}) {
@@ -2454,6 +2474,7 @@
my %lt=&Apache::lonlocal::texthash(
'vc' => 'Verify Content',
'cv' => 'Check/Set Resource Versions',
+ 'ls' => 'List Symbs',
);
my $folderpath=$env{'form.folderpath'};
@@ -2488,7 +2509,9 @@
<input type="submit" name="versions" value="$lt{'cv'}" />$help{'Check_Resource_Versions'}
$dumpbut
$exportbut
-</td></tr></table>
+</td><!-- <td bgcolor="#DDDDCC">
+ <input type="submit" name="listsymbs" value="$lt{'ls'}" />
+</td>--></tr></table>
</form>
ENDCOURSEVERIFY
$r->print(&Apache::loncommon::help_open_topic('Docs_Adding_Course_Doc',