Update of /cvsroot/sandweb/sandweb/lib/SandWeb
In directory usw-pr-cvs1:/tmp/cvs-serv26590/lib/SandWeb
Modified Files:
Browse.pm File.pm
Log Message:
implemented file operations.
the functional piece of the UI is there, I don't think the filenames
are being caught correctly however. I'll work on that next.
Index: Browse.pm
===================================================================
RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v
retrieving revision 1.21
retrieving revision 1.22
diff -U2 -r1.21 -r1.22
--- Browse.pm 2001/12/06 23:35:51 1.21
+++ Browse.pm 2001/12/18 02:12:06 1.22
@@ -30,4 +30,5 @@
my $progname = shift;
my $vcs_commands = shift;
+ my $file_commands = shift;
my $repo_type = shift;
@@ -39,4 +40,5 @@
my $sandbox = "$users_dir/$username";
my @vcs_commands = split (/ /, $vcs_commands );
+ my @file_commands = split (/ /, $file_commands );
if (! $sandbox) {
@@ -174,12 +176,19 @@
my @loop_data = ();
- if ($repo_type eq "CVS") {
- foreach my $vcs_command (@vcs_commands) {
- my %row_data;
- $row_data{VCS_CMD} = "$vcs_command";
- push (@loop_data, \%row_data);
- }
- $content->param( VCS_CMD_LOOP => \@loop_data );
+ foreach my $vcs_command (@vcs_commands) {
+ my %row_data;
+ $row_data{VCS_CMD} = "$vcs_command";
+ push (@loop_data, \%row_data);
+ }
+ $content->param( VCS_CMD_LOOP => \@loop_data );
+
+ @loop_data = ();
+
+ foreach my $file_command (@file_commands) {
+ my %row_data;
+ $row_data{FILE_CMD} = "$file_command";
+ push (@loop_data, \%row_data);
}
+ $content->param( FILE_CMD_LOOP => \@loop_data );
return $content->output;
Index: File.pm
===================================================================
RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v
retrieving revision 1.15
retrieving revision 1.16
diff -U2 -r1.15 -r1.16
--- File.pm 2001/11/27 01:29:21 1.15
+++ File.pm 2001/12/18 02:12:06 1.16
@@ -161,3 +161,15 @@
}
+sub get_file_commands {
+ my $self = shift;
+ return (
+ 'create_file',
+ 'create_folder',
+ 'remove',
+ 'rename',
+ 'upload',
+ 'download',
+ );
+}
+
1;
|