From e5549057abc64f86547384d7c06f99614332c0f4 Mon Sep 17 00:00:00 2001 From: einhverfr Date: Sun, 14 Oct 2007 17:31:23 +0000 Subject: Moving menus to unorderded lists. CSS still need a few changes, but this is waiting on permission to use nice + and - graphics. git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1752 4979c152-3d1c-0410-bac9-87ea11338e46 --- LedgerSMB.pm | 2 +- LedgerSMB/Session/DB.pm | 4 ++-- UI/login.js | 3 ++- UI/menu/expanding.css | 11 +++++---- UI/menu/expanding.html | 60 ++++++++++++++++++++++++++----------------------- scripts/login.pl | 5 +++-- scripts/menu.pl | 1 - 7 files changed, 45 insertions(+), 41 deletions(-) diff --git a/LedgerSMB.pm b/LedgerSMB.pm index b754e8d0..f0e11c11 100755 --- a/LedgerSMB.pm +++ b/LedgerSMB.pm @@ -193,7 +193,7 @@ sub new { $self->_db_init; if ($self->is_run_mode('cgi', 'mod_perl')) { - #check for valid session unless this is an iniital authentication + #check for valid session unless this is an inital authentication #request -- CT if (!Session::session_check( $cookie{"LedgerSMB"}, $self) ) { $self->_get_password("Session Expired"); diff --git a/LedgerSMB/Session/DB.pm b/LedgerSMB/Session/DB.pm index 06385a8f..98694774 100755 --- a/LedgerSMB/Session/DB.pm +++ b/LedgerSMB/Session/DB.pm @@ -34,12 +34,13 @@ use strict; sub session_check { use Time::HiRes qw(gettimeofday); my ( $cookie, $form ) = @_; - + print STFERR "Checking Session\n"; my $path = ($ENV{SCRIPT_NAME}); $path =~ s|[^/]*$||; if ($cookie eq 'Login'){ + print STDERR "creating session\n"; return session_create($form); } my $timeout; @@ -179,7 +180,6 @@ sub session_create { if ( !$lsmb->{timeout} ) { $lsmb->{timeout} = 86400; } - print STDERR "Breakpoint\n"; $deleteExisting->execute( $login) || $lsmb->dberror( __FILE__ . ':' . __LINE__ . ': Delete from session: ' ); diff --git a/UI/login.js b/UI/login.js index cf261624..fd421e26 100644 --- a/UI/login.js +++ b/UI/login.js @@ -13,7 +13,8 @@ function submit_form() { var http = get_http_request_object(); var username = document.login.login.value; var password = document.login.password.value; - http.open("get", 'login.pl?action=authenticate', false, + http.open("get", 'login.pl?action=authenticate&company=' + + document.login.company.value, false, username, password); http.send(""); alert(http.status); diff --git a/UI/menu/expanding.css b/UI/menu/expanding.css index c3b30db9..3a1ba2fe 100644 --- a/UI/menu/expanding.css +++ b/UI/menu/expanding.css @@ -1,11 +1,10 @@ -div.submenu { - display: none; +li.menu_closed { } -A.Menu_Closed:before { - content: '+'; +li.menu_closed > ul { + display: none; } -A.Menu_Open:before { - content: '-'; +li.menu_open > ul { + display: block; } diff --git a/UI/menu/expanding.html b/UI/menu/expanding.html index 76a53b71..bec01754 100644 --- a/UI/menu/expanding.html +++ b/UI/menu/expanding.html @@ -7,8 +7,16 @@ - - + + @@ -17,23 +25,16 @@