From: naoki i. <am...@us...> - 2008-05-02 12:50:45
|
Update of /cvsroot/popfile/engine/UI In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10802/UI Modified Files: HTML.pm Log Message: Change Log 1. Add an interface to change the session timeout on the Administration tab UI/HTML.pm skins/default/administration-page.thtml languages/English.pm languages/Nihongo.pm tests/TestHTML.script Current state of the test suite: TestBayesScript PASS TestBayes PASS TestConfiguration PASS TestHistory PASS TestHTML PASS TestHTTP PASS TestIMAP PASS TestInsertScript PASS * TestLogger PASS TestMailParse PASS TestModule PASS TestMQ PASS TestMutex PASS TestPipeScript PASS TestPOP3 PASS TestProxy PASS TestWordMangle PASS TestXMLRPC PASS * : TODO : needs to add tests for multi user support Index: HTML.pm =================================================================== RCS file: /cvsroot/popfile/engine/UI/HTML.pm,v retrieving revision 1.395 retrieving revision 1.396 diff -C2 -d -r1.395 -r1.396 *** HTML.pm 1 May 2008 15:21:43 -0000 1.395 --- HTML.pm 2 May 2008 12:50:50 -0000 1.396 *************** *** 1432,1435 **** --- 1432,1454 ---- } } + + if ( defined($self->{form_}{session_timeout}) ) { + if ( ( $self->{form_}{session_timeout} =~ /^\d+$/ ) && # PROFILE BLOCK START + ( $self->{form_}{session_timeout} >= 300 ) && + ( $self->{form_}{session_timeout} <= 86400 ) ) { # PROFILE BLOCK STOP + if ( $self->global_config_( 'session_timeout' ) ne $self->{form_}{session_timeout} ) { + $self->global_config_( 'session_timeout', $self->{form_}{session_timeout} ); + $self->status_message__( # PROFILE BLOCK START + $templ, + sprintf( $self->language($session)->{Configuration_SessionTimeoutUpdate}, + $self->global_config_( 'session_timeout' ) ) ); # PROFILE BLOCK STOP + + } + } + else { + $self->error_message__( $templ, $self->language($session)->{Configuration_Error9} ); + delete $self->{form_}{session_timeout}; + } + } } *************** *** 1441,1444 **** --- 1460,1464 ---- $templ->param( 'Configuration_UI_HTTPS_Port' => $self->config_( 'https_port' ) ); $templ->param( 'Configuration_TCP_Timeout' => $self->global_config_( 'timeout' ) ); + $templ->param( 'Configuration_Session_Timeout' => $self->global_config_( 'session_timeout' ) ); $templ->param( 'If_Single_User' => $self->global_config_( 'single_user' ) ); |