Revision 90bb521a
Von Moritz Bunkus vor mehr als 11 Jahren hinzugefügt
bin/mozilla/admin.pl | ||
---|---|---|
101 | 101 |
call_sub($locale->findsub($form->{action})); |
102 | 102 |
} |
103 | 103 |
} else { |
104 |
# if there are no drivers bail out |
|
105 |
$form->error($locale->text('No Database Drivers available!')) |
|
106 |
unless (User->dbdrivers); |
|
107 |
|
|
108 | 104 |
adminlogin(); |
109 | 105 |
} |
110 | 106 |
$::lxdebug->leave_sub; |
... | ... | |
143 | 139 |
|
144 | 140 |
sub pg_database_administration { |
145 | 141 |
my $form = $main::form; |
146 |
|
|
147 |
$form->{dbdriver} = 'Pg'; |
|
148 | 142 |
dbselect_source(); |
149 |
|
|
150 | 143 |
} |
151 | 144 |
|
152 | 145 |
sub dbselect_source { |
... | ... | |
171 | 164 |
my $form = $main::form; |
172 | 165 |
my $locale = $main::locale; |
173 | 166 |
|
174 |
$form->{dbdriver} = 'Pg'; |
|
175 | 167 |
User::dbconnect_vars($form, $form->{dbname}); |
176 | 168 |
|
177 | 169 |
my $dbh = DBI->connect($form->{dbconnect}, $form->{dbuser}, $form->{dbpasswd}); |
... | ... | |
225 | 217 |
restore_form($saved_form); |
226 | 218 |
|
227 | 219 |
%::myconfig = (); |
228 |
map { $form->{$_} = $::myconfig{$_} = $form->{"${_}_${i}"} } qw(dbname dbdriver dbhost dbport dbuser dbpasswd);
|
|
220 |
map { $form->{$_} = $::myconfig{$_} = $form->{"${_}_${i}"} } qw(dbname dbhost dbport dbuser dbpasswd); |
|
229 | 221 |
|
230 | 222 |
print $form->parse_html_template("admin/dbupgrade_header"); |
231 | 223 |
|
... | ... | |
233 | 225 |
$form->{$form->{dbname}} = 1; |
234 | 226 |
|
235 | 227 |
User->dbupdate($form); |
236 |
User->dbupdate2($form, SL::DBUpgrade2->new(form => $form, dbdriver => $form->{dbdriver})->parse_dbupdate_controls);
|
|
228 |
User->dbupdate2($form, SL::DBUpgrade2->new(form => $form)->parse_dbupdate_controls); |
|
237 | 229 |
|
238 | 230 |
print $form->parse_html_template("admin/dbupgrade_footer"); |
239 | 231 |
} |
Auch abrufbar als: Unified diff
Alle Vorkommen von dbdriver, sid, Oracle entfernt
...und gegen das hardcodierte Werte für PostgreSQL ersetzt.