X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fadmin.pl;h=e936b2a12430c68d8f04527ea53e822502bbb511;hb=564d8509117493b1b4b28c08d95ba4d1df8d599b;hp=28bc6fad212c40f062886ce30062947c6c61753d;hpb=7804fab3bb495ddedd90159071c51b35a7e603ce;p=kivitendo-erp.git diff --git a/bin/mozilla/admin.pl b/bin/mozilla/admin.pl index 28bc6fad2..e936b2a12 100644 --- a/bin/mozilla/admin.pl +++ b/bin/mozilla/admin.pl @@ -34,20 +34,20 @@ $menufile = "menu.ini"; +use DBI; use SL::Form; use SL::User; +require "bin/mozilla/common.pl"; + $form = new Form; $form->{"root"} = "root login"; $locale = new Locale $language, "admin"; -eval { require DBI; }; -$form->error($locale->text('DBI not installed!')) if ($@); - # customization -if (-f "$form->{path}/custom_$form->{script}") { - eval { require "$form->{path}/custom_$form->{script}"; }; +if (-f "bin/mozilla/custom_$form->{script}") { + eval { require "bin/mozilla/custom_$form->{script}"; }; $form->error($@) if ($@); } @@ -67,7 +67,7 @@ if ($form->{action}) { &check_password; - &$subroutine; + call_sub($subroutine); } else { @@ -125,7 +125,6 @@ sub adminlogin { . $locale->text('Login') . qq|"> -{path}> @@ -197,8 +196,7 @@ sub form_footer { print qq| - -{path}> + {rpw}> {path}&rpw=$form->{rpw}"; + "$script?action=edit&login=$key&rpw=$form->{rpw}"; $href =~ s/ /%20/g; $member{$key}{templates} =~ s/^$templates\///; @@ -330,7 +328,6 @@ sub list_users { -{path}> {rpw}>
text('Login') . qq|"> -{path}> @@ -473,9 +469,13 @@ sub form_header { } } - opendir CSS, "css/."; - @all = sort(grep({ /\.css$/ && ($_ ne "tabcontent.css") } readdir(CSS))); - closedir CSS; +# opendir CSS, "css/."; +# @all = grep /.*\.css$/, readdir CSS; +# closedir CSS; + +# css dir has styles that are not intended as general layouts. +# reverting to hardcoded list + @all = qw(lx-office-erp.css Win2000.css); foreach $item (@all) { if ($item eq $myconfig->{stylesheet}) { @@ -508,16 +508,16 @@ sub form_header { - + - - {password}> + + - + @@ -635,24 +635,25 @@ sub form_header { print qq| - + - + |; if ($item eq 'Pg') { + print qq| - + - + - + - + |; } @@ -668,13 +669,13 @@ sub form_header { - + |; } print qq| - {dbpasswd}> +
| . $locale->text('Login') . qq|
| . $locale->text('Password') . qq|{password}>
| . $locale->text('Name') . qq|
| . $locale->text('E-mail') . qq|| . $locale->text('Driver') . qq| $item $item | . $locale->text('Host') . qq|{"${item}_dbhost"}>
| . $locale->text('Dataset') . qq|{Pg_dbname}> | . $locale->text('Port') . qq|{Pg_dbport}>
| . $locale->text('User') . qq|{"${item}_dbuser"}> | . $locale->text('Password') . qq|{"${item}_dbpasswd"}>
| . $locale->text('Dataset') . qq| {"${item}_dbuser"}> | . $locale->text('Password') . qq|{"${item}_dbpasswd"}>
@@ -1142,7 +1143,6 @@ sub change_admin_password { -{path}> {rpw}>

@@ -1183,7 +1183,7 @@ sub change_password { $root->save_member($memberfile); $form->{callback} = - "$form->{script}?action=list_users&path=$form->{path}&rpw=$root->{password}"; + "$form->{script}?action=list_users&rpw=$root->{password}"; $form->redirect($locale->text('Password changed!')); @@ -1286,9 +1286,9 @@ sub dbselect_source { | . $locale->text('User') . qq| - {dbuser}> + | . $locale->text('Password') . qq| - + @@ -1304,8 +1304,7 @@ sub dbselect_source { - -{path}> + {rpw}>
@@ -1339,9 +1338,7 @@ print qq|

{script}> -{dbdriver}> -{dbhost}> -{dbport}> -{dbuser}> -{dbpasswd}> -{dbdefault}> + + + + + + | . $locale->text('The following Datasets need to be updated') . qq| @@ -1401,9 +1398,8 @@ $upd - + -{path}> {rpw}> @@ -1455,7 +1451,7 @@ sub dbupdate {
| . $locale->text("Continue") . qq||; } @@ -1546,16 +1542,15 @@ sub create_dataset {

-{dbdriver}> -{dbuser}> -{dbhost}> -{dbport}> -{dbpasswd}> -{dbdefault}> + + + + + + - + -{path}> {rpw}> @@ -1606,7 +1601,6 @@ sub dbcreate { . qq| - @@ -1662,16 +1656,15 @@ sub delete_dataset {

-{dbdriver}> -{dbuser}> -{dbhost}> -{dbport}> -{dbpasswd}> -{dbdefault}> + + + + + + - + - @@ -1721,7 +1714,6 @@ $form->{db} | . $locale->text('successfully deleted!') . qq| - @@ -1742,7 +1734,7 @@ sub unlock_system { unlink "$userspath/nologin"; $form->{callback} = - "$form->{script}?action=list_users&path=$form->{path}&rpw=$root->{password}"; + "$form->{script}?action=list_users&rpw=$root->{password}"; $form->redirect($locale->text('Lockfile removed!')); @@ -1755,7 +1747,7 @@ sub lock_system { close(FH); $form->{callback} = - "$form->{script}?action=list_users&path=$form->{path}&rpw=$root->{password}"; + "$form->{script}?action=list_users&rpw=$root->{password}"; $form->redirect($locale->text('Lockfile created!'));