[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb:[4813] trunk
- Subject: SF.net SVN: ledger-smb:[4813] trunk
- From: ..hidden..
- Date: Thu, 31 May 2012 10:26:28 +0000
Revision: 4813
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=4813&view=rev
Author: einhverfr
Date: 2012-05-31 10:26:27 +0000 (Thu, 31 May 2012)
Log Message:
-----------
Fixing permalink missing company name, thus requiring separate login into correct db wbefore it can be run
Modified Paths:
--------------
trunk/LedgerSMB/App_State.pm
trunk/LedgerSMB/Form.pm
trunk/LedgerSMB/Template.pm
trunk/LedgerSMB.pm
trunk/UI/Reports/aging_report.html
trunk/UI/Reports/display_report.html
Modified: trunk/LedgerSMB/App_State.pm
===================================================================
--- trunk/LedgerSMB/App_State.pm 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/LedgerSMB/App_State.pm 2012-05-31 10:26:27 UTC (rev 4813)
@@ -80,6 +80,14 @@
our $Role_Prefix;
+=item DBName
+
+name of the database connecting to
+
+=cut
+
+our $DBName;
+
=back
=head1 METHODS
@@ -111,6 +119,7 @@
$Locale = undef;
$DBH = undef;
@Roles = ();
+ $DBName = undef;
$Role_Prefix = undef;
}
@@ -133,6 +142,7 @@
$SODA = {};
$Company_Settings = {};
$DBH = undef;
+ $DBName = undef;
@Roles = ();
$Role_Prefix = undef;
}
Modified: trunk/LedgerSMB/Form.pm
===================================================================
--- trunk/LedgerSMB/Form.pm 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/LedgerSMB/Form.pm 2012-05-31 10:26:27 UTC (rev 4813)
@@ -1283,6 +1283,7 @@
($self->{_role_prefix}) = $sth->fetchrow_array;
$LedgerSMB::App_State::Roles = @{$self->{_roles}};
$LedgerSMB::App_State::Role_Prefix = $self->{_role_prefix};
+ $LedgerSMB::App_State::DBName = $dbname;
# Expect @{$self->{_roles}} to go away sometime during 1.4/1.5 development
# -CT
Modified: trunk/LedgerSMB/Template.pm
===================================================================
--- trunk/LedgerSMB/Template.pm 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/LedgerSMB/Template.pm 2012-05-31 10:26:27 UTC (rev 4813)
@@ -282,6 +282,7 @@
$vars->{ENVARS} = \%ENV;
$vars->{USER} = $LedgerSMB::App_State::User;
$vars->{CSSDIR} = $LedgerSMB::Sysconfig::cssdir;
+ $vars->{DBNAME} = $LedgerSMB::App_State::DBName;
my @stdformats = ();
for (qw(HTML PDF PS)){
Modified: trunk/LedgerSMB.pm
===================================================================
--- trunk/LedgerSMB.pm 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/LedgerSMB.pm 2012-05-31 10:26:27 UTC (rev 4813)
@@ -887,6 +887,7 @@
$self->{dbh}->{pg_server_prepare} = 0;
$self->{dbh}->{pg_enable_utf8} = 1;
$LedgerSMB::App_State::DBH = $self->{dbh};
+ $LedgerSMB::App_State::DBName = $dbname;
# This is the general version check
my $sth = $self->{dbh}->prepare("
Modified: trunk/UI/Reports/aging_report.html
===================================================================
--- trunk/UI/Reports/aging_report.html 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/UI/Reports/aging_report.html 2012-05-31 10:26:27 UTC (rev 4813)
@@ -8,7 +8,7 @@
PROCESS "dynatable.html";
LINK = 'http://' _ ENVARS.SERVER_NAME _ ENVARS.SCRIPT_NAME
- _ '?' _ ENVARS.QUERY_STRING _ '&company=' _ form.company;
+ _ '?' _ ENVARS.QUERY_STRING _ '&company=' _ DBNAME;
?>
<body>
Modified: trunk/UI/Reports/display_report.html
===================================================================
--- trunk/UI/Reports/display_report.html 2012-05-31 10:06:11 UTC (rev 4812)
+++ trunk/UI/Reports/display_report.html 2012-05-31 10:26:27 UTC (rev 4813)
@@ -8,7 +8,7 @@
PROCESS "dynatable.html";
LINK = 'http://' _ ENVARS.SERVER_NAME _ ENVARS.SCRIPT_NAME
- _ '?' _ ENVARS.QUERY_STRING _ '&company=' _ form.company;
+ _ '?' _ ENVARS.QUERY_STRING _ '&company=' _ DBNAME;
?>
<body>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.