You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(28) |
Nov
(58) |
Dec
(85) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(125) |
Feb
(222) |
Mar
(274) |
Apr
(51) |
May
(22) |
Jun
(50) |
Jul
(15) |
Aug
(33) |
Sep
(11) |
Oct
(29) |
Nov
(17) |
Dec
(1) |
2003 |
Jan
(100) |
Feb
(21) |
Mar
(7) |
Apr
(45) |
May
|
Jun
(43) |
Jul
(27) |
Aug
(24) |
Sep
|
Oct
|
Nov
|
Dec
|
2004 |
Jan
(1) |
Feb
|
Mar
(13) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
(7) |
Sep
|
Oct
|
Nov
|
Dec
(4) |
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
From: Rob H. <for...@us...> - 2002-02-24 05:28:04
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv27898/bin Modified Files: sandweb.cgi Log Message: moved edit_file into it's own subroutine Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.208 retrieving revision 1.209 diff -U2 -r1.208 -r1.209 --- sandweb.cgi 24 Feb 2002 05:03:31 -0000 1.208 +++ sandweb.cgi 24 Feb 2002 05:28:02 -0000 1.209 @@ -244,4 +244,25 @@ ); } + elsif ( $action eq 'edit_file' ) { + # called file editor + + if ($submit) { + edit_file_commit( + ck_auth => $ck_auth, + filename => CGI::param('filename'), + module_name => $module_name, + repo_name => $repo_name, + location => CGI::param('location'), + ) + } else { + edit_file_menu( + ck_auth => $ck_auth, + filename => CGI::param('filename'), + module_name => $module_name, + repo_name => $repo_name, + location => CGI::param('location'), + ); + } + } elsif ( $action eq 'repository' ) { if ($submit) { @@ -896,4 +917,67 @@ } +sub edit_file_menu { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_username(); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my $repo_name = $args{'repo_name'}; + my $module_name = $args{'module_name'}; + my $filename = $args{'filename'}; + + $log->debug("viewing file : $filename"); + + $log->debug("creating File object: $filename"); + my $file = SandWeb::File->new( + 'config_obj' => $config, + 'log_obj' => $log, + 'filename' => $filename, + 'location' => "$users_dir/$username/$module_name$location", + ); + if ( $file->get_file_type() ne "Text" ) { + $log->debug("User wants to edit non-text file : $filename"); + set_error("This does not appear to be a text file."); + view_file_menu( + ck_auth => $ck_auth, + file_command => "view", + filename => $filename, + location => $location, + ); + } + $log->debug("reading $users_dir/$username/$module_name$location/$filename"); + + my $content = $file->file_read(); + + $log->debug("closing $users_dir/$username/$module_name$location/$filename"); + $content = $ui->get_menu( + MENU => 'edit_file', + PROGNAME => $progname, + MODULE_NAME => $module_name, + CONTENT => $content, + LOCATION => $location, + FILENAME => $filename, + ); + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : edit file', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'edit file', + FILENAME => $filename, + LOCATION => $location, + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); +} @@ -1026,65 +1110,5 @@ } - if ( $file_command eq 'edit' ) { - $log->debug("editing file : $filename"); - if ($Submit) { - my $file_content = CGI::param('data'), - my $filename = $file->get_filename(); - $log->debug("saving edited file : $filename"); - - $log->debug("editing $users_dir/$username/$module_name$location/$filename"); - $file->file_write( - 'location' => "$location", - 'filename' => "$filename", - 'contents' => $file_content, - ); - - view_file_menu( - ck_auth => $ck_auth, - file_command => "view", - filename => $filename, - module_name => $module_name, - repo_name => $repo_name, - location => CGI::param('location'), - ); - } - if ( $file->get_file_type() ne "Text" ) { - $log->debug("User wants to edit non-text file : $filename"); - set_error("This does not appear to be a text file."); - view_file_menu( - ck_auth => $ck_auth, - file_command => "view", - filename => $filename, - location => $location, - ); - } - $log->debug("reading $users_dir/$username/$module_name$location/$filename"); - - my $content = $file->file_read(); - - $log->debug("closing $users_dir/$username/$module_name$location/$filename"); - $content = $ui->get_menu( - MENU => 'edit_file', - PROGNAME => $progname, - MODULE_NAME => $module_name, - CONTENT => $content, - LOCATION => $location, - FILENAME => $filename, - ); - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : edit file', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'edit file', - FILENAME => $filename, - LOCATION => $location, - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; - } - elsif ( $file_command eq 'create_file' ) { + if ( $file_command eq 'create_file' ) { if ($file) { $file->create_file(); @@ -1200,4 +1224,53 @@ ); } +} + +sub edit_file_commit { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_username(); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my $repo_name = $args{'repo_name'}; + my $module_name = $args{'module_name'}; + my $filename = $args{'filename'}; + + $log->debug("viewing file : $filename"); + + $log->debug("creating File object: $filename"); + my $file = SandWeb::File->new( + 'config_obj' => $config, + 'log_obj' => $log, + 'filename' => $filename, + 'location' => "$users_dir/$username/$module_name$location", + ); + $log->debug("editing file : $filename"); + my $file_content = CGI::param('data'), + $filename = $file->get_filename(); + $log->debug("saving edited file : $filename"); + + $log->debug("editing $users_dir/$username/$module_name$location/$filename"); + $file->file_write( + 'location' => "$location", + 'filename' => "$filename", + 'contents' => $file_content, + ); + + view_file_menu( + ck_auth => $ck_auth, + file_command => "view", + filename => $filename, + module_name => $module_name, + repo_name => $repo_name, + location => CGI::param('location'), + ); } |
From: Rob H. <for...@us...> - 2002-02-24 05:03:36
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv22895/lib/SandWeb Modified Files: Browse.pm Log Message: * moved view_file out of browse_file_commit and into view_file subroutine Index: Browse.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v retrieving revision 1.61 retrieving revision 1.62 diff -U2 -r1.61 -r1.62 --- Browse.pm 23 Feb 2002 21:42:13 -0000 1.61 +++ Browse.pm 24 Feb 2002 05:03:32 -0000 1.62 @@ -95,5 +95,5 @@ } $row_data{FILETYPE} = "dir"; - $row_data{LINK} = "action=browse_module&location=$location/$filename"; + $row_data{LINK} = "action=view_file&location=$location/$filename"; if ($counter eq "0") { $row_data{COLOR} = 0; @@ -104,5 +104,5 @@ elsif ( $file->get_file_type() eq "Text" ) { $row_data{FILETYPE} = "text"; - $row_data{LINK} = "action=browse_file&filename=$filename"; + $row_data{LINK} = "action=view_file&filename=$filename"; if ($counter eq "0") { $row_data{COLOR} = 0; @@ -113,5 +113,5 @@ elsif ( $file->get_file_type() eq "Binary" ) { $row_data{FILETYPE} = "binary"; - $row_data{LINK} = "action=browse_file&filename=$filename"; + $row_data{LINK} = "action=view_file&filename=$filename"; if ($counter eq "0") { $row_data{COLOR} = 0; @@ -122,5 +122,5 @@ else { $row_data{FILETYPE} = "unknown"; - $row_data{LINK} = "action=browse_file&filename=$filename"; + $row_data{LINK} = "action=view_file&filename=$filename"; if ($counter eq "0") { $row_data{COLOR} = 0; |
From: Rob H. <for...@us...> - 2002-02-24 05:03:36
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv22895/bin Modified Files: sandweb.cgi Log Message: * moved view_file out of browse_file_commit and into view_file subroutine Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.207 retrieving revision 1.208 diff -U2 -r1.207 -r1.208 --- sandweb.cgi 23 Feb 2002 21:42:13 -0000 1.207 +++ sandweb.cgi 24 Feb 2002 05:03:31 -0000 1.208 @@ -233,4 +233,15 @@ } } + elsif ( $action eq 'view_file' ) { + # called file viewer + + view_file_menu( + ck_auth => $ck_auth, + filename => CGI::param('filename'), + module_name => $module_name, + repo_name => $repo_name, + location => CGI::param('location'), + ); + } elsif ( $action eq 'repository' ) { if ($submit) { @@ -781,4 +792,108 @@ } +############################################################################### +# view file menu +# +# display the contents of a file to the user, as well as some basic +# info. +# +# A File object is created and used. +# +# args: +# ck_auth - the sessions cookie +# file_command - name of the File object method to be invoked +# filename - name of the file(s) that the File object should +# be invoked with. NOTE: this is an array +# location - system path to the file(s) specified by filename +############################################################################### +sub view_file_menu { + my %args = @_; + + my $ck_auth = $args{'ck_auth'}; + if (! load_config()) { + # no existing user config, forward to prefs menu + preferences_menu( ck_auth => $ck_auth ); + } + + my $location = $args{'location'}; + my $message = CGI::param('message'); + my $username = $auth->get_username(); + my $template_dir = $config->{'paths'}->{'template_dir'}; + my $users_dir = $config->{'paths'}->{'users_dir'}; + my $repo_name = $args{'repo_name'}; + my $module_name = $args{'module_name'}; + my $filename = $args{'filename'}; + + $log->debug("viewing file : $filename"); + + $log->debug("creating File object: $filename"); + my $file = SandWeb::File->new( + 'config_obj' => $config, + 'log_obj' => $log, + 'filename' => $filename, + 'location' => "$users_dir/$username/$module_name$location", + ); + + + my $file_content = $file->file_read(); + + # make output browser-friendly + # Special Characters; RFC 1866 + $file_content =~ s/&/&/g; + $file_content =~ s/\"/"/g; + $file_content =~ s/</</g; + $file_content =~ s/>/>/g; + + my $edit = 0; + + if ( $file->get_file_type() ne "Text" ) { + $log->debug("User wants to view non-text file : $filename"); + set_error("This does not appear to be a text file."); + $file_content = ""; + } else { + $edit = 1; + } + + $log->debug("creating Browse object"); + my $browse = SandWeb::Browse->new( + 'username' => $username, + 'module_name' => $module_name, + 'repo_name' => $repo_name, + 'template_dir' => $template_dir, + 'users_dir' => $users_dir, + 'log_obj' => $log, + ); + + my $current_location = $browse->get_current_location( + 'location' => $location, + 'progname' => $progname, + ); + + my $menu = $ui->get_menu( + MENU => 'view_file', + PROGNAME => "$progname", + MODULE_NAME => $module_name, + FILENAME => "$filename", + LOCATION => "$location", + EDIT => "$edit", + FILE_CONTENT => "$file_content", + FILE_SIZE => $file->get_size(), + FILE_TYPE => $file->get_file_type(), + FILE_AGE => $file->get_age(), + ); + + my $content = "$current_location $menu"; + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : view file', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'view file', + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); +} + @@ -911,78 +1026,5 @@ } - # file viewer - if ( $file_command eq 'view' ) { - $log->debug("viewing file : $filename"); - - my $file_content = $file->file_read(); - - # make output browser-friendly - # Special Characters; RFC 1866 - $file_content =~ s/&/&/g; - $file_content =~ s/\"/"/g; - $file_content =~ s/</</g; - $file_content =~ s/>/>/g; - - my $edit = 0; - - if ( $file->get_file_type() ne "Text" ) { - $log->debug("User wants to view non-text file : $filename"); - set_error("This does not appear to be a text file."); - $file_content = ""; - } else { - $edit = 1; - } - - $log->debug("creating Repository object"); - my $repository = SandWeb::Repository->new( - 'root' => "$vcsroot", - 'repo_type' => $repo_type, - ); - - my @vcs_commands = $repository->get_vcs_commands(); - - $log->debug("creating Browse object"); - my $browse = SandWeb::Browse->new( - 'username' => $username, - 'module_name' => $module_name, - 'repo_name' => $repo_name, - 'template_dir' => $template_dir, - 'vcs_commands' => \@vcs_commands, - 'users_dir' => $users_dir, - 'log_obj' => $log, - ); - - my $current_location = $browse->get_current_location( - 'location' => $location, - 'progname' => $progname, - ); - - my $menu = $ui->get_menu( - MENU => 'view_file', - PROGNAME => "$progname", - MODULE_NAME => $module_name, - FILENAME => "$filename", - LOCATION => "$location", - EDIT => "$edit", - FILE_CONTENT => "$file_content", - FILE_SIZE => $file->get_size(), - FILE_TYPE => $file->get_file_type(), - FILE_AGE => $file->get_age(), - ); - - my $content = "$current_location $menu"; - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : view file', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'view file', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; - } - elsif ( $file_command eq 'edit' ) { + if ( $file_command eq 'edit' ) { $log->debug("editing file : $filename"); if ($Submit) { @@ -998,10 +1040,8 @@ ); - my @filename = $filename; - - browse_file_commit( + view_file_menu( ck_auth => $ck_auth, file_command => "view", - filename => \@filename, + filename => $filename, module_name => $module_name, repo_name => $repo_name, @@ -1012,5 +1052,5 @@ $log->debug("User wants to edit non-text file : $filename"); set_error("This does not appear to be a text file."); - browse_file_commit( + view_file_menu( ck_auth => $ck_auth, file_command => "view", @@ -1180,6 +1220,6 @@ sub browse_vcs_commit { my %args = @_; - my $ck_auth = $args{'ck_auth'}; + my $ck_auth = $args{'ck_auth'}; if (! load_config()) { # no existing user config, forward to prefs menu @@ -1203,5 +1243,4 @@ my %return; - $log->debug("module_name: $module_name"); $log->debug("username: $username"); @@ -1209,8 +1248,8 @@ my $repo_server = $user->get_repo_server(repo => $repo_name); - my $repo_username = $user->get_repo_username(repo => $repo_name); - my $repo_type = $user->get_repo_type(repo => $repo_name); - my $repo_connection = $user->get_repo_connection(repo => $repo_name); - my $repo_root = $user->get_repo_root(repo => $repo_name); + my $repo_username = $user->get_repo_username(repo => $repo_name); + my $repo_type = $user->get_repo_type(repo => $repo_name); + my $repo_connection = $user->get_repo_connection(repo => $repo_name); + my $repo_root = $user->get_repo_root(repo => $repo_name); my $sandbox = $user->{'paths'}->{'users_dir'} || ''; |
From: Rob H. <for...@us...> - 2002-02-24 05:03:36
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv22895/templates Modified Files: browse_module.html Log Message: * moved view_file out of browse_file_commit and into view_file subroutine Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.21 retrieving revision 1.22 diff -U2 -r1.21 -r1.22 --- browse_module.html 22 Feb 2002 21:32:40 -0000 1.21 +++ browse_module.html 24 Feb 2002 05:03:32 -0000 1.22 @@ -49,5 +49,5 @@ <a name="<TMPL_VAR NAME=ENTRY>"> </input> - <a href="<TMPL_VAR NAME=PROGNAME>?<TMPL_VAR NAME=LINK>&file_command=view&location=<TMPL_VAR NAME=LOCATION>&module_name=<TMPL_VAR NAME=MODULE_NAME>&repo_name=<TMPL_VAR NAME=REPO_NAME>"> + <a href="<TMPL_VAR NAME=PROGNAME>?<TMPL_VAR NAME=LINK>&location=<TMPL_VAR NAME=LOCATION>&module_name=<TMPL_VAR NAME=MODULE_NAME>&repo_name=<TMPL_VAR NAME=REPO_NAME>"> <img src="/icons/<TMPL_VAR NAME=FILETYPE>.gif" alt="" border=0 width=20 height=22> |
From: Rob H. <for...@us...> - 2002-02-23 21:42:17
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv29311/lib/SandWeb Modified Files: Browse.pm Log Message: repo_name should be in the constructor, not passed to methods Index: Browse.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v retrieving revision 1.60 retrieving revision 1.61 diff -U2 -r1.60 -r1.61 --- Browse.pm 22 Feb 2002 21:32:40 -0000 1.60 +++ Browse.pm 23 Feb 2002 21:42:13 -0000 1.61 @@ -16,4 +16,5 @@ my $username = $args{'username'}; my $module_name = $args{'module_name'}; + my $repo_name = $args{'repo_name'}; my $users_dir = $args{'users_dir'}; my $template_dir = $args{'template_dir'}; @@ -24,4 +25,5 @@ 'username' => $username, 'module_name' => $module_name, + 'repo_name' => $repo_name, 'users_dir' => $users_dir, 'template_dir' => $template_dir, @@ -159,9 +161,9 @@ my $location = $args{'location'}; my $progname = $args{'progname'}; - my $repo_name = $args{'repo_name'}; my $vcs_commands = $self->_get_vcs_commands(); my $template_dir = $self->_get_template_dir(); my $module_name = $self->_get_module_name(); + my $repo_name = $self->_get_repo_name(); my $content = HTML::Template->new( filename => "$template_dir/tool_bar.html" ); @@ -196,9 +198,9 @@ my $location = $args{'location'}; my $progname = $args{'progname'}; - my $repo_name = $args{'repo_name'}; my $username = $self->_get_username(); my $users_dir = $self->_get_users_dir(); my $module_name = $self->_get_module_name(); + my $repo_name = $self->_get_repo_name(); my $template_dir = $self->_get_template_dir(); my $log = $self->_get_log_obj; @@ -269,4 +271,8 @@ my $self = shift; return $self->{'users_dir'}; +} +sub _get_repo_name { + my $self = shift; + return $self->{'repo_name'}; } sub _get_module_name { |
From: Rob H. <for...@us...> - 2002-02-23 21:42:17
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv29311/bin Modified Files: sandweb.cgi Log Message: repo_name should be in the constructor, not passed to methods Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.206 retrieving revision 1.207 diff -U2 -r1.206 -r1.207 --- sandweb.cgi 23 Feb 2002 04:24:37 -0000 1.206 +++ sandweb.cgi 23 Feb 2002 21:42:13 -0000 1.207 @@ -470,4 +470,5 @@ 'username' => $username, 'module_name' => $module_name, + 'repo_name' => $repo_name, 'template_dir' => $template_dir, 'vcs_commands' => \@vcs_commands, @@ -497,5 +498,4 @@ 'location' => $location, 'progname' => $progname, - 'repo_name' => $repo_name, ); @@ -503,5 +503,4 @@ 'location' => $location, 'progname' => $progname, - 'repo_name' => $repo_name, ); @@ -947,4 +946,5 @@ 'username' => $username, 'module_name' => $module_name, + 'repo_name' => $repo_name, 'template_dir' => $template_dir, 'vcs_commands' => \@vcs_commands, @@ -956,5 +956,4 @@ 'location' => $location, 'progname' => $progname, - 'repo_name' => $repo_name, ); |
From: Nick J. <nje...@us...> - 2002-02-23 04:32:52
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv29715/templates Modified Files: current_location.html Log Message: * fixed up the current_location template a bit Index: current_location.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/current_location.html,v retrieving revision 1.3 retrieving revision 1.4 diff -U2 -r1.3 -r1.4 --- current_location.html 22 Feb 2002 08:22:40 -0000 1.3 +++ current_location.html 23 Feb 2002 04:32:48 -0000 1.4 @@ -1,7 +1,7 @@ <tr> - <td align="left" valign="middle"> + <td align="left" valign="center" bgcolor="#CCDDCC"> <table border="0"> <tr> - Current location: +   Current location: <TMPL_LOOP NAME=LOCATION_LOOP> <a href="<TMPL_VAR NAME=PROGNAME>?action=browse_module&module_name=<TMPL_VAR NAME=MODULE_NAME>&repo_name=<TMPL_VAR NAME=REPO_NAME>&location=<TMPL_VAR NAME=LOCATION_FULL>"><TMPL_VAR NAME=LOCATION_LINK></a> |
From: Nick J. <nje...@us...> - 2002-02-23 04:24:40
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv28012/templates Modified Files: view_file.html Log Message: * now *really* fixed wierd file line space issue. Index: view_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/view_file.html,v retrieving revision 1.35 retrieving revision 1.36 diff -U2 -r1.35 -r1.36 --- view_file.html 22 Feb 2002 22:10:31 -0000 1.35 +++ view_file.html 23 Feb 2002 04:24:37 -0000 1.36 @@ -39,5 +39,7 @@ <tr> <td width="100%" bgcolor="#EEEEEE"> -<pre><TMPL_VAR NAME=FILE_CONTENT></pre> +<pre> +<TMPL_VAR NAME=FILE_CONTENT> +</pre> </td> </tr> |
From: Nick J. <nje...@us...> - 2002-02-23 04:24:40
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv28012/lib/SandWeb Modified Files: File.pm Log Message: * now *really* fixed wierd file line space issue. Index: File.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v retrieving revision 1.44 retrieving revision 1.45 diff -U2 -r1.44 -r1.45 --- File.pm 22 Feb 2002 23:06:27 -0000 1.44 +++ File.pm 23 Feb 2002 04:24:37 -0000 1.45 @@ -128,4 +128,6 @@ my $filename = $self->{'filename'}; my $log = $self->{'log_obj'}; + # passed from CGI->upload - FileHandle of incoming file. + my $filehandle = $args{'filehandle'}; # begin workaround for IE/Windows upload behaviour @@ -135,13 +137,9 @@ # end workaround for IE/Windows upload behaviour - my $filehandle = $args{'filehandle'}; - - open UPLOADFILE, "> $location/$filename"; - - while ( <$filehandle> ) - { - print UPLOADFILE; - } + my @file = <$filehandle>; + chomp @file; + open UPLOADFILE, ">$location/$filename"; + print UPLOADFILE join("\n", @file); close UPLOADFILE; } @@ -304,10 +302,8 @@ my $filename = $self->{'filename'}; - my $contents = _do_file_read( + return _do_file_read( 'location' => "$location", 'filename' => "$filename", ); - - return $contents; } @@ -382,8 +378,6 @@ my $return; - my @data = split(/\n/, $contents); if (open (FILE, ">$location/$filename")) { - $log->debug('dump', @data); - print FILE join('', @data); + print FILE join('', $contents); } else { $log->debug("error opening $location/$filename for writing: $!"); @@ -405,9 +399,9 @@ my $log = $args{'log_obj'}; - open (FILE, "< $location/$filename"); + open (FILE, "<$location/$filename"); my @contents = <FILE>; close FILE; - return "@contents"; + return join('', @contents); } |
From: Nick J. <nje...@us...> - 2002-02-23 04:24:39
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv28012/bin Modified Files: sandweb.cgi Log Message: * now *really* fixed wierd file line space issue. Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.205 retrieving revision 1.206 diff -U2 -r1.205 -r1.206 --- sandweb.cgi 23 Feb 2002 03:47:25 -0000 1.205 +++ sandweb.cgi 23 Feb 2002 04:24:37 -0000 1.206 @@ -1029,5 +1029,5 @@ PROGNAME => $progname, MODULE_NAME => $module_name, - CONTENT => "$content", + CONTENT => $content, LOCATION => $location, FILENAME => $filename, |
From: Nick J. <nje...@us...> - 2002-02-23 03:47:28
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv19982 Modified Files: sandweb.cgi Log Message: * fixed up some code Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.204 retrieving revision 1.205 diff -U2 -r1.204 -r1.205 --- sandweb.cgi 22 Feb 2002 22:10:31 -0000 1.204 +++ sandweb.cgi 23 Feb 2002 03:47:25 -0000 1.205 @@ -436,8 +436,8 @@ my $repo_server = $user->get_repo_server(repo => $repo_name); - my $repo_username = $user->get_repo_username(repo => $repo_name); - my $repo_type = $user->get_repo_type(repo => $repo_name); - my $repo_connection = $user->get_repo_connection(repo => $repo_name); - my $repo_root = $user->get_repo_root(repo => $repo_name); + my $repo_username = $user->get_repo_username(repo => $repo_name); + my $repo_type = $user->get_repo_type(repo => $repo_name); + my $repo_connection = $user->get_repo_connection(repo => $repo_name); + my $repo_root = $user->get_repo_root(repo => $repo_name); my $vcsroot; @@ -587,156 +587,156 @@ ############################################################################### sub repository_menu { - my %args = @_; - my $ck_auth = $args{'ck_auth'}; - my $repository_selected = $args{'repository_selected'}; - my $repo_name = $args{'repo_name'}; - my $repo_server = $args{'repo_server'}; - my $repo_username = $args{'repo_username'}; - my $repo_type = $args{'repo_type'}; - my $repo_connection = $args{'repo_connection'}; - my $repo_root = $args{'repo_root'}; - my $new_repository = $args{'new_repository'} ? 1 : 0; - my $submit = $args{'submit'} ? 1 : 0; - - $log->debug("entering repository_menu\n"); - - $log->debug("<pre>" . Dumper(\%args) . "</pre>"); - - my $new_string = 'Add a new repository'; - my $username = $auth->get_username(); - my $users_dir = $config->{'paths'}->{'users_dir'}; - my @repos = $user->get_repo_list(); # get list of repositories - - $repository_selected = $repository_selected || $repos[0] || $new_string; # default for pulldown - - if (($repository_selected) && ($repository_selected ne $new_string)) { - my $valid = 0; - # verify repository name - foreach my $repo (@repos) { - if ($repository_selected eq $repo) { - $repo_name = $repo; - $valid = 1; - } - } - if (!$valid) { - # bad repository name - set_error("Invalid repository name: $repository_selected\n"); - $repository_selected = $new_string; - $repo_name = ''; - } - } - - if (($repository_selected eq $new_string) && (!$new_repository)) { - # repository selected was 'add new repository' - # new repository display + my %args = @_; + my $ck_auth = $args{'ck_auth'}; + my $repository_selected = $args{'repository_selected'}; + my $repo_name = $args{'repo_name'}; + my $repo_server = $args{'repo_server'}; + my $repo_username = $args{'repo_username'}; + my $repo_type = $args{'repo_type'}; + my $repo_connection = $args{'repo_connection'}; + my $repo_root = $args{'repo_root'}; + my $new_repository = $args{'new_repository'} ? 1 : 0; + my $submit = $args{'submit'} ? 1 : 0; + + $log->debug("entering repository_menu\n"); + + $log->debug("<pre>" . Dumper(\%args) . "</pre>"); + + my $new_string = 'Add a new repository'; + my $username = $auth->get_username(); + my $users_dir = $config->{'paths'}->{'users_dir'}; + my @repos = $user->get_repo_list(); # get list of repositories + + # default for pulldown + $repository_selected = $repository_selected || $repos[0] || $new_string; + + if (($repository_selected) && ($repository_selected ne $new_string)) { + my $valid = 0; + # verify repository name + foreach my $repo (@repos) { + if ($repository_selected eq $repo) { + $repo_name = $repo; + $valid = 1; + } + } + if (!$valid) { + # bad repository name + set_error("Invalid repository name: $repository_selected\n"); + $repository_selected = $new_string; + $repo_name = ''; + } + } + + if (($repository_selected eq $new_string) && (!$new_repository)) { + # repository selected was 'add new repository' + # new repository display $repo_name = ''; - $repo_server = ''; - $repo_username = ''; - $repo_connection = ''; - $repo_type = ''; - $repo_root = ''; + $repo_server = ''; + $repo_username = ''; + $repo_connection = ''; + $repo_type = ''; + $repo_root = ''; - } elsif ($repository_selected) { - # display existing repository + } elsif ($repository_selected) { + # display existing repository $repo_name = $repository_selected; - $repo_server = + $repo_server = $user->get_repo_server(repo => $repo_name); - $repo_username = + $repo_username = $user->get_repo_username(repo => $repo_name); - $repo_connection = + $repo_connection = $user->get_repo_connection(repo => $repo_name); - $repo_type = + $repo_type = $user->get_repo_type(repo => $repo_name); - $repo_root = + $repo_root = $user->get_repo_root(repo => $repo_name); - } + } + + # selected repository data + my $vcsroot; - # selected repository data - my $vcsroot; + my $repository = SandWeb::Repository->new( + root => "", + repo_type => "", + sandbox => "$users_dir/$username", + ); - my $repository = SandWeb::Repository->new( - root => "", - repo_type => "", - sandbox => "$users_dir/$username", - ); - - my @connections = $repository->get_connections(); - my @repo_types = $repository->get_repo_types(); - - # loop data - my @loop_repo_connection = (); - my @loop_repository_select = (); - my @loop_repo_type = (); + my @connections = $repository->get_connections(); + my @repo_types = $repository->get_repo_types(); + + # loop data + my @loop_repo_connection = (); + my @loop_repository_select = (); + my @loop_repo_type = (); $log->debug('@repos: '. join('-', @repos). "\nrepository_selected: '$repository_selected'\n"); - foreach my $repo (@repos) { + foreach my $repo (@repos) { chomp $repo; - my %entries; - if ($repository_selected eq $repo) { - # Doesn't seem to work!?? ($repository_selected != $new_string)) { - $entries{REPOSITORY_ENTRY} = "<option selected>$repo</option>"; - } else { - $entries{REPOSITORY_ENTRY} = "<option>$repo</option>"; - } - push (@loop_repository_select, \%entries); - } - # add new repo - my %tmp; - if ($repository_selected eq $new_string) { - $tmp{REPOSITORY_ENTRY} = "<option selected>$new_string</option>"; - - } else { - $tmp{REPOSITORY_ENTRY} = "<option>$new_string</option>"; - - } - push (@loop_repository_select, \%tmp); - - - foreach my $type (@connections) { - my %row_data; - if ($type eq $repo_connection) { - $row_data{REPO_CONNECTION} = "<option selected>$type</option>"; - } - else { - $row_data{REPO_CONNECTION} = "<option>$type</option>"; - } - push (@loop_repo_connection, \%row_data); - } - - foreach my $type (@repo_types) { - my %row_data; - if ($type eq $repo_type) { - $row_data{REPO_TYPE} = "<option selected>$type</option>"; - } - else { - $row_data{REPO_TYPE} = "<option>$type</option>"; - } - push (@loop_repo_type, \%row_data); - } - - - my $content = $ui->get_menu( - MENU => 'repository', - PROGNAME => $progname, - LOOP_REPO_CONNECTION => \@loop_repo_connection, - LOOP_REPO_TYPE => \@loop_repo_type, - LOOP_REPOSITORY_SELECT => \@loop_repository_select, - REPOSITORY_SELECTED => $repository_selected, - REPO_ROOT => $repo_root, - REPO_NAME => $repo_name, - REPO_SERVER => $repo_server, - REPO_USERNAME => $repo_username, - ); - - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> 'SandWeb : repository', - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => 'repository', - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; + my %entries; + if ($repository_selected eq $repo) { + $entries{REPOSITORY_ENTRY} = "<option selected>$repo</option>"; + } else { + $entries{REPOSITORY_ENTRY} = "<option>$repo</option>"; + } + push (@loop_repository_select, \%entries); + } + # add new repo + my %tmp; + if ($repository_selected eq $new_string) { + $tmp{REPOSITORY_ENTRY} = "<option selected>$new_string</option>"; + + } else { + $tmp{REPOSITORY_ENTRY} = "<option>$new_string</option>"; + + } + push (@loop_repository_select, \%tmp); + + + foreach my $type (@connections) { + my %row_data; + if ($type eq $repo_connection) { + $row_data{REPO_CONNECTION} = "<option selected>$type</option>"; + } + else { + $row_data{REPO_CONNECTION} = "<option>$type</option>"; + } + push (@loop_repo_connection, \%row_data); + } + + foreach my $type (@repo_types) { + my %row_data; + if ($type eq $repo_type) { + $row_data{REPO_TYPE} = "<option selected>$type</option>"; + } + else { + $row_data{REPO_TYPE} = "<option>$type</option>"; + } + push (@loop_repo_type, \%row_data); + } + + + my $content = $ui->get_menu( + MENU => 'repository', + PROGNAME => $progname, + LOOP_REPO_CONNECTION => \@loop_repo_connection, + LOOP_REPO_TYPE => \@loop_repo_type, + LOOP_REPOSITORY_SELECT => \@loop_repository_select, + REPOSITORY_SELECTED => $repository_selected, + REPO_ROOT => $repo_root, + REPO_NAME => $repo_name, + REPO_SERVER => $repo_server, + REPO_USERNAME => $repo_username, + ); + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> 'SandWeb : repository', + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => 'repository', + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; } @@ -834,8 +834,8 @@ my $repo_server = $user->get_repo_server(repo => $repo_name); - my $repo_username = $user->get_repo_username(repo => $repo_name); - my $repo_type = $user->get_repo_type(repo => $repo_name); - my $repo_connection = $user->get_repo_connection(repo => $repo_name); - my $repo_root = $user->get_repo_root(repo => $repo_name); + my $repo_username = $user->get_repo_username(repo => $repo_name); + my $repo_type = $user->get_repo_type(repo => $repo_name); + my $repo_connection = $user->get_repo_connection(repo => $repo_name); + my $repo_root = $user->get_repo_root(repo => $repo_name); my $vcsroot; @@ -1210,8 +1210,8 @@ my $repo_server = $user->get_repo_server(repo => $repo_name); - my $repo_username = $user->get_repo_username(repo => $repo_name); - my $repo_type = $user->get_repo_type(repo => $repo_name); - my $repo_connection = $user->get_repo_connection(repo => $repo_name); - my $repo_root = $user->get_repo_root(repo => $repo_name); + my $repo_username = $user->get_repo_username(repo => $repo_name); + my $repo_type = $user->get_repo_type(repo => $repo_name); + my $repo_connection = $user->get_repo_connection(repo => $repo_name); + my $repo_root = $user->get_repo_root(repo => $repo_name); my $sandbox = $user->{'paths'}->{'users_dir'} || ''; @@ -1405,8 +1405,8 @@ $log->debug('dump', \%return); my $return = write_config(); - if (! $return) { - # uh oh, problem occured - checkout_menu( ck_auth => $ck_auth ); - } + if (! $return) { + # uh oh, problem occured + checkout_menu( ck_auth => $ck_auth ); + } my $content = $ui->get_menu( @@ -1473,28 +1473,28 @@ sub repository_commit { - my %args = @_; - my $ck_auth = $args{'ck_auth'}; - my $repository_selected = $args{'repository_selected'}; - my $repo_name = $args{'repo_name'}; - my $repo_server = $args{'repo_server'}; - my $repo_username = $args{'repo_username'}; - my $repo_type = $args{'repo_type'}; - my $repo_connection = $args{'repo_connection'}; - my $repo_root = $args{'repo_root'}; - my $new_repository = $args{'new_repository'} ? 1 : 0; - my $new_string = 'Add a new repository'; - - load_config(1); # load prefs and do not log error msg - $log->debug("<pre>" . Dumper(\%args) . "</pre>"); - - if (! $repo_name) { - # cannot commit without repository name - $log->error("cannot commit without repository name!\n"); - set_error("cannot commit without repository name!\n"); - repository_menu( ck_auth => $ck_auth ); - exit(0); - } + my %args = @_; + my $ck_auth = $args{'ck_auth'}; + my $repository_selected = $args{'repository_selected'}; + my $repo_name = $args{'repo_name'}; + my $repo_server = $args{'repo_server'}; + my $repo_username = $args{'repo_username'}; + my $repo_type = $args{'repo_type'}; + my $repo_connection = $args{'repo_connection'}; + my $repo_root = $args{'repo_root'}; + my $new_repository = $args{'new_repository'} ? 1 : 0; + my $new_string = 'Add a new repository'; + + load_config(1); # load prefs and do not log error msg + $log->debug("<pre>" . Dumper(\%args) . "</pre>"); + + if (! $repo_name) { + # cannot commit without repository name + $log->error("cannot commit without repository name!\n"); + set_error("cannot commit without repository name!\n"); + repository_menu( ck_auth => $ck_auth ); + exit(0); + } - # commit data to file + # commit data to file if ($user->repository_exists(repo => $repo_name)) { $log->debug("updating: username '$repo_username'\n"); @@ -1519,12 +1519,12 @@ my $return = write_config(); - if (! $return) { - # uh oh, problem occured - repository_menu( ck_auth => $ck_auth ); - } - # when finished go to repository menu. (this should be dynamic probably, - # so it returns to whichever menu they wanted to go to in the first - # place). - repository_menu( ck_auth => $ck_auth, repository_selected => $repo_name ); + if (! $return) { + # uh oh, problem occured + repository_menu( ck_auth => $ck_auth ); + } + # when finished go to repository menu. (this should be dynamic probably, + # so it returns to whichever menu they wanted to go to in the first + # place). + repository_menu( ck_auth => $ck_auth, repository_selected => $repo_name ); } @@ -1587,5 +1587,5 @@ ############################################################################### sub write_config { - $log->debug("write_config()"); + $log->debug("write_config()"); my $username = $auth->get_username(); # write config data into the .$user_cfg file in the users directory @@ -1595,9 +1595,9 @@ ); - if (! $return) { - # uh oh, problem occured - $log->debug("ERROR: $msg"); - $log->error("$msg"); - set_error("$msg"); + if (! $return) { + # uh oh, problem occured + $log->debug("ERROR: $msg"); + $log->error("$msg"); + set_error("$msg"); return 0; } |
From: Nick J. <nje...@us...> - 2002-02-22 23:06:30
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv23494/lib/SandWeb Modified Files: File.pm Log Message: * fixed file save bug Index: File.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/File.pm,v retrieving revision 1.43 retrieving revision 1.44 diff -U2 -r1.43 -r1.44 --- File.pm 10 Feb 2002 21:23:52 -0000 1.43 +++ File.pm 22 Feb 2002 23:06:27 -0000 1.44 @@ -382,6 +382,8 @@ my $return; + my @data = split(/\n/, $contents); if (open (FILE, ">$location/$filename")) { - print FILE $contents; + $log->debug('dump', @data); + print FILE join('', @data); } else { $log->debug("error opening $location/$filename for writing: $!"); |
From: Rob H. <for...@us...> - 2002-02-22 23:00:11
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv21484/lib/SandWeb Modified Files: UI.pm Log Message: "Based" was spelled wrong Index: UI.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/UI.pm,v retrieving revision 1.25 retrieving revision 1.26 diff -U2 -r1.25 -r1.26 --- UI.pm 21 Feb 2002 05:43:14 -0000 1.25 +++ UI.pm 22 Feb 2002 23:00:07 -0000 1.26 @@ -26,5 +26,5 @@ my $menu_bar = $self->get_menu_bar(); my $log = $self->_logobj(); - my $footer = '<font size="2"<a href="http://sandweb.sf.net">SandWeb</a> - Web Basaed Version Control Management System.</font>'; + my $footer = '<font size="2"<a href="http://sandweb.sf.net">SandWeb</a> - Web Based Version Control Management System.</font>'; my @debug_msgs = (); |
From: Rob H. <for...@us...> - 2002-02-22 22:10:35
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv6076/templates Modified Files: view_file.html Log Message: edit_file works again, but for some reason spaces get inserted before all lines after the first one when the file is saved. Odd. I think this existed before the latest change though, going to have to dig around to see where this unwanted space comes from. Index: view_file.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/view_file.html,v retrieving revision 1.34 retrieving revision 1.35 diff -U2 -r1.34 -r1.35 --- view_file.html 21 Feb 2002 05:56:27 -0000 1.34 +++ view_file.html 22 Feb 2002 22:10:31 -0000 1.35 @@ -39,5 +39,5 @@ <tr> <td width="100%" bgcolor="#EEEEEE"> - <pre><TMPL_VAR NAME=FILE_CONTENT></pre> +<pre><TMPL_VAR NAME=FILE_CONTENT></pre> </td> </tr> |
From: Rob H. <for...@us...> - 2002-02-22 22:10:34
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv6076/bin Modified Files: sandweb.cgi Log Message: edit_file works again, but for some reason spaces get inserted before all lines after the first one when the file is saved. Odd. I think this existed before the latest change though, going to have to dig around to see where this unwanted space comes from. Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.203 retrieving revision 1.204 diff -U2 -r1.203 -r1.204 --- sandweb.cgi 22 Feb 2002 09:14:13 -0000 1.203 +++ sandweb.cgi 22 Feb 2002 22:10:31 -0000 1.204 @@ -826,5 +826,5 @@ my $filename = "@filename"; $log->debug("filename(s) : $filename"); - my $save = CGI::param('save'); + my $Submit = CGI::param('Submit'); my $username = $auth->get_username(); my $template_dir = $config->{'paths'}->{'template_dir'} || ''; @@ -987,5 +987,5 @@ elsif ( $file_command eq 'edit' ) { $log->debug("editing file : $filename"); - if ($save) { + if ($Submit) { my $file_content = CGI::param('data'), my $filename = $file->get_filename(); @@ -1001,9 +1001,11 @@ my @filename = $filename; - file( + browse_file_commit( ck_auth => $ck_auth, file_command => "view", filename => \@filename, - location => $location, + module_name => $module_name, + repo_name => $repo_name, + location => CGI::param('location'), ); } |
From: Rob H. <for...@us...> - 2002-02-22 21:32:43
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv17241/lib/SandWeb Modified Files: Browse.pm Log Message: size and age shouldn't be links right now, they don't do anything Index: Browse.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v retrieving revision 1.59 retrieving revision 1.60 diff -U2 -r1.59 -r1.60 --- Browse.pm 22 Feb 2002 09:14:13 -0000 1.59 +++ Browse.pm 22 Feb 2002 21:32:40 -0000 1.60 @@ -57,8 +57,4 @@ my $content = HTML::Template->new( filename => "$template_dir/browse_module.html" ); - $content->param( - PROGNAME => $progname, - ); - my @return = (); my @loop_data = (); |
From: Rob H. <for...@us...> - 2002-02-22 21:32:43
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv17241/templates Modified Files: browse_module.html Log Message: size and age shouldn't be links right now, they don't do anything Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.20 retrieving revision 1.21 diff -U2 -r1.20 -r1.21 --- browse_module.html 22 Feb 2002 08:53:36 -0000 1.20 +++ browse_module.html 22 Feb 2002 21:32:40 -0000 1.21 @@ -30,10 +30,10 @@ <td width="10%" align="left" bgcolor="#CCCCCC"> <font size="2"> - <A href="<TMPL_VAR NAME=PROGNAME>">Size</a> + Size </font> </td> <td width="30%" align="left" bgcolor="#CCCCCC"> <font size="2"> - <A href="<TMPL_VAR NAME=PROGNAME>">Age</a> + Age </font> </td> |
From: Rob H. <for...@us...> - 2002-02-22 09:14:18
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv28554/bin Modified Files: sandweb.cgi Log Message: fixed stupid bug, last checkin for the night :P Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.202 retrieving revision 1.203 diff -U2 -r1.202 -r1.203 --- sandweb.cgi 22 Feb 2002 08:53:36 -0000 1.202 +++ sandweb.cgi 22 Feb 2002 09:14:13 -0000 1.203 @@ -492,7 +492,4 @@ my $browse_module_header = $ui->get_menu( MENU => 'browse_module_header', - MODULE_NAME => $module_name, - REPO_NAME => $repo_name, - LOCATION => $location, ); @@ -962,5 +959,4 @@ ); - my $menu = $ui->get_menu( MENU => 'view_file', @@ -1265,4 +1261,5 @@ VCS_ERROR => "@vcs_error", ); + print CGI::header( -cookie => $ck_auth ); $ui->print_screen( @@ -1308,22 +1305,24 @@ } } + my $content = $ui->get_menu( - MENU => 'vcs_output', - LOCATION => $location, - FILENAME => "@filename", - PROGNAME => $progname, - VCS_OUTPUT => "@vcs_output", - VCS_ERROR => "@vcs_error", - ); - print CGI::header( -cookie => $ck_auth ); - $ui->print_screen( - TITLE=> "SandWeb : VCS $vcs_command", - MENU_TITLE => 'SandWeb', - SUBMENU_TITLE => "VCS $vcs_command", - FOOTER => '', - CONTENT => $content, - ERROR => $error, - ); - exit 0; + MENU => 'vcs_output', + LOCATION => $location, + FILENAME => "@filename", + PROGNAME => $progname, + VCS_OUTPUT => "@vcs_output", + VCS_ERROR => "@vcs_error", + ); + + print CGI::header( -cookie => $ck_auth ); + $ui->print_screen( + TITLE=> "SandWeb : VCS $vcs_command", + MENU_TITLE => 'SandWeb', + SUBMENU_TITLE => "VCS $vcs_command", + FOOTER => '', + CONTENT => $content, + ERROR => $error, + ); + exit 0; } |
From: Rob H. <for...@us...> - 2002-02-22 09:14:18
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv28554/templates Modified Files: browse_module_header.html Log Message: fixed stupid bug, last checkin for the night :P Index: browse_module_header.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module_header.html,v retrieving revision 1.1 retrieving revision 1.2 diff -U2 -r1.1 -r1.2 --- browse_module_header.html 22 Feb 2002 08:54:14 -0000 1.1 +++ browse_module_header.html 22 Feb 2002 09:14:13 -0000 1.2 @@ -1,4 +1 @@ <form method="get" submit="<TMPL_VAR NAME=PROGNAME>" name="browse"> -<input type="hidden" name="module_name" value="<TMPL_VAR NAME=MODULE_NAME>" /> -<input type="hidden" name="repo_name" value="<TMPL_VAR NAME=REPO_NAME>" /> -<input type="hidden" name="location" value="<TMPL_VAR NAME=LOCATION>" /> |
From: Rob H. <for...@us...> - 2002-02-22 09:14:17
|
Update of /cvsroot/sandweb/sandweb/lib/SandWeb In directory usw-pr-cvs1:/tmp/cvs-serv28554/lib/SandWeb Modified Files: Browse.pm Log Message: fixed stupid bug, last checkin for the night :P Index: Browse.pm =================================================================== RCS file: /cvsroot/sandweb/sandweb/lib/SandWeb/Browse.pm,v retrieving revision 1.58 retrieving revision 1.59 diff -U2 -r1.58 -r1.59 --- Browse.pm 22 Feb 2002 08:10:54 -0000 1.58 +++ Browse.pm 22 Feb 2002 09:14:13 -0000 1.59 @@ -185,5 +185,4 @@ $content->param( VCS_CMD_LOOP => \@loop_data, - PROGNAME => $progname, LOCATION => $location, MODULE_NAME => $module_name, |
From: Rob H. <for...@us...> - 2002-02-22 08:54:17
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv22035/templates Added Files: browse_module_footer.html browse_module_header.html Log Message: checking stuff in for the nite. everything seems to work pretty good, lots more cleanup to come. --- NEW FILE --- </form> --- NEW FILE --- <form method="get" submit="<TMPL_VAR NAME=PROGNAME>" name="browse"> <input type="hidden" name="module_name" value="<TMPL_VAR NAME=MODULE_NAME>" /> <input type="hidden" name="repo_name" value="<TMPL_VAR NAME=REPO_NAME>" /> <input type="hidden" name="location" value="<TMPL_VAR NAME=LOCATION>" /> |
From: Rob H. <for...@us...> - 2002-02-22 08:53:39
|
Update of /cvsroot/sandweb/sandweb/templates In directory usw-pr-cvs1:/tmp/cvs-serv21866/templates Modified Files: browse_module.html Log Message: ack, tool_bar is not nearly generic enough for this. took some steps to make it more generic, but realized that header and footer settings should be UI's job. Index: browse_module.html =================================================================== RCS file: /cvsroot/sandweb/sandweb/templates/browse_module.html,v retrieving revision 1.19 retrieving revision 1.20 diff -U2 -r1.19 -r1.20 --- browse_module.html 22 Feb 2002 04:48:23 -0000 1.19 +++ browse_module.html 22 Feb 2002 08:53:36 -0000 1.20 @@ -68,4 +68,3 @@ </td> </tr> -</form> <TMPL_VAR NAME="STATUS"> |
From: Rob H. <for...@us...> - 2002-02-22 08:53:39
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv21866/bin Modified Files: sandweb.cgi Log Message: ack, tool_bar is not nearly generic enough for this. took some steps to make it more generic, but realized that header and footer settings should be UI's job. Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.201 retrieving revision 1.202 diff -U2 -r1.201 -r1.202 --- sandweb.cgi 22 Feb 2002 08:38:58 -0000 1.201 +++ sandweb.cgi 22 Feb 2002 08:53:36 -0000 1.202 @@ -490,4 +490,11 @@ # use the browse object to show user's sandbox + my $browse_module_header = $ui->get_menu( + MENU => 'browse_module_header', + MODULE_NAME => $module_name, + REPO_NAME => $repo_name, + LOCATION => $location, + ); + my $toolbar = $browse->get_tool_bar( 'location' => $location, @@ -509,5 +516,9 @@ ); - my $content = "$toolbar $current_location $browser"; + my $browse_module_footer = $ui->get_menu( + MENU => 'browse_module_footer', + ); + + my $content = "$browse_module_header $toolbar $current_location $browser $browse_module_footer"; print CGI::header( -cookie => $ck_auth ); @@ -945,10 +956,4 @@ ); - my $tool_bar = $browse->get_tool_bar( - 'location' => $location, - 'progname' => $progname, - 'repo_name' => $repo_name, - ); - my $current_location = $browse->get_current_location( 'location' => $location, @@ -971,5 +976,5 @@ ); - my $content = "$tool_bar $current_location $menu"; + my $content = "$current_location $menu"; print CGI::header( -cookie => $ck_auth ); |
From: Rob H. <for...@us...> - 2002-02-22 08:39:01
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv18843/bin Modified Files: sandweb.cgi Log Message: implemented tool_bar and current_location in view_file Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.200 retrieving revision 1.201 diff -U2 -r1.200 -r1.201 --- sandweb.cgi 22 Feb 2002 08:31:13 -0000 1.200 +++ sandweb.cgi 22 Feb 2002 08:38:58 -0000 1.201 @@ -927,5 +927,36 @@ } - my $content = $ui->get_menu( + $log->debug("creating Repository object"); + my $repository = SandWeb::Repository->new( + 'root' => "$vcsroot", + 'repo_type' => $repo_type, + ); + + my @vcs_commands = $repository->get_vcs_commands(); + + $log->debug("creating Browse object"); + my $browse = SandWeb::Browse->new( + 'username' => $username, + 'module_name' => $module_name, + 'template_dir' => $template_dir, + 'vcs_commands' => \@vcs_commands, + 'users_dir' => $users_dir, + 'log_obj' => $log, + ); + + my $tool_bar = $browse->get_tool_bar( + 'location' => $location, + 'progname' => $progname, + 'repo_name' => $repo_name, + ); + + my $current_location = $browse->get_current_location( + 'location' => $location, + 'progname' => $progname, + 'repo_name' => $repo_name, + ); + + + my $menu = $ui->get_menu( MENU => 'view_file', PROGNAME => "$progname", @@ -939,4 +970,6 @@ FILE_AGE => $file->get_age(), ); + + my $content = "$tool_bar $current_location $menu"; print CGI::header( -cookie => $ck_auth ); |
From: Rob H. <for...@us...> - 2002-02-22 08:31:15
|
Update of /cvsroot/sandweb/sandweb/bin In directory usw-pr-cvs1:/tmp/cvs-serv17295/bin Modified Files: sandweb.cgi Log Message: pass $repo_name to upload_file.html Index: sandweb.cgi =================================================================== RCS file: /cvsroot/sandweb/sandweb/bin/sandweb.cgi,v retrieving revision 1.199 retrieving revision 1.200 diff -U2 -r1.199 -r1.200 --- sandweb.cgi 22 Feb 2002 08:10:54 -0000 1.199 +++ sandweb.cgi 22 Feb 2002 08:31:13 -0000 1.200 @@ -1099,4 +1099,5 @@ PROGNAME => $progname, MODULE_NAME => $module_name, + REPO_NAME => $repo_name, FILENAME => $filename, ); |