From 411e92387d44aadbc57f2573ea03178fba0c352b Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Fri, 15 Dec 2006 09:07:19 +0000 Subject: [PATCH] Ein paar Vorlagen in die existierenden Vorlagenverzeichnisse kopieren. --- locale/de/Pg-upgrade-2.2.0.37-2.2.0.38 | 12 ++++ locale/de/all | 14 +++- locale/de/ustva | 16 ++--- .../Pg-upgrade-2.2.0.37-2.2.0.38.pl | 65 +++++++++++++++++++ .../update_templates_warnings_de.html | 11 ++++ .../update_templates_warnings_master.html | 12 ++++ 6 files changed, 117 insertions(+), 13 deletions(-) create mode 100644 locale/de/Pg-upgrade-2.2.0.37-2.2.0.38 create mode 100644 sql/Pg-upgrade/Pg-upgrade-2.2.0.37-2.2.0.38.pl create mode 100644 templates/webpages/dbupgrade/update_templates_warnings_de.html create mode 100644 templates/webpages/dbupgrade/update_templates_warnings_master.html diff --git a/locale/de/Pg-upgrade-2.2.0.37-2.2.0.38 b/locale/de/Pg-upgrade-2.2.0.37-2.2.0.38 new file mode 100644 index 000000000..8601f7fe0 --- /dev/null +++ b/locale/de/Pg-upgrade-2.2.0.37-2.2.0.38 @@ -0,0 +1,12 @@ +$self->{texts} = { + 'Could not copy %s to %s. Reason: %s' => 'Die Datei "%s" konnte nicht nach "%s" kopiert werden. Grund: %s', + 'Could not open the file users/members.' => 'Die Datei "users/members" konnte nicht geöffnet werden.', + 'Could not rename %s to %s. Reason: %s' => 'Die Datei "%s" konnte nicht in "%s" umbenannt werden. Grund: %s', +}; + +$self->{subs} = { + 'do_update' => 'do_update', + 'update_templates' => 'update_templates', +}; + +1; diff --git a/locale/de/all b/locale/de/all index d24af1bea..243b80af6 100644 --- a/locale/de/all +++ b/locale/de/all @@ -94,6 +94,8 @@ $self->{texts} = { 'Amount Due' => 'Betrag fällig', 'Angaben zum Finanzamt' => 'Angaben zum Finanzamt', 'Ansprechpartner' => '', + 'Application Error. No Format given!' => '', + 'Application Error. Wrong Format: ' => '', 'Apr' => 'Apr', 'April' => 'April', 'Are you sure you want to delete Invoice Number' => 'Soll die Rechnung mit folgender Nummer wirklich gelöscht werden:', @@ -242,6 +244,9 @@ aktualisieren wollen?', 'Copies' => 'Kopien', 'Copy to COA' => 'In Kontenplan kopieren', 'Cost Center' => 'Kostenstelle', + 'Could not copy %s to %s. Reason: %s' => 'Die Datei "%s" konnte nicht nach "%s" kopiert werden. Grund: %s', + 'Could not open the file users/members.' => 'Die Datei "users/members" konnte nicht geöffnet werden.', + 'Could not rename %s to %s. Reason: %s' => 'Die Datei "%s" konnte nicht in "%s" umbenannt werden. Grund: %s', 'Could not save!' => 'Konnte nicht speichern!', 'Could not transfer Inventory!' => 'Konnte Waren nicht umlagern!', 'Could not update prices!' => 'Preise konnten nicht aktualisiert werden!', @@ -351,6 +356,7 @@ gestartet', 'E-mail Statement to' => 'Fälligkeitsabrechnung als eMail an', 'E-mail address missing!' => 'eMailadresse fehlt!', 'E-mailed' => 'eMail gesendet.', + 'ELSTER Export nach Taxbird' => '', 'ELSTER Export nach Winston' => 'ELSTER Export nach Winston', 'ELSTER-Steuernummer: ' => 'ELSTER-Steuernummer: ', 'EU with VAT ID' => 'EU mit UstId-Nummer', @@ -481,8 +487,8 @@ gestartet', 'If you see this message, you most likely just setup your LX-Office and haven\'t added any entry types. If this is the case, the option is accessible for administrators in the System menu.' => 'Wenn Sie diese Meldung sehen haben Sie wahrscheinlich ein frisches LX-Office Setup und noch keine Buchungsgruppen eingerichtet. Ein Administrator kann dies im Systemmenü erledigen.', 'Image' => 'Grafik', 'Import CSV' => '', - 'Impossible to create yearly Tax Report as PDF or PS.
Not yet implemented!' => 'Umsatzsteuer Jahreserklärung als PDF wird noch nicht unterstützt.
Bitte benutzen Sie das Ausgabeformat Vorschau.', - 'Impossible to create yearly Tax Report via Winston.
Not yet implemented!' => 'Umsatzsteuer Jahreserklärung via Winston wird noch nicht unterstützt.
Bitte benutzen Sie das Ausgabeformat Vorschau.', + 'Impossible to create yearly Tax Report as PDF or Postscript
Not yet implemented!' => '', + 'Impossible to create yearly Tax Report via Winston or Taxbird.
Not yet implemented!' => '', 'In Lx-Office 2.4.0 the administrator has to enter a list of units in the administrative section.' => 'In Lx-Office 2.4.0 muss der Administrator in den Systemeinstellungen eine Liste von verwendbaren Einheiten angeben.', 'In-line' => 'im Text', 'Include Exchangerate Difference' => 'Wechselkursunterschied einbeziehen', @@ -942,7 +948,6 @@ gestartet', 'The database update/creation did not succeed. The file contained the following error:' => 'Die Datenbankaktualisierung/erstellung schlug fehl. Die Datei enthielt den folgenden Fehler:', 'The database upgrade for the introduction of Buchungsgruppen is now complete.' => 'Das Datenbankupgrade für die Einführung von Buchungsgruppen ist jetzt beendet.', 'The database upgrade for the introduction of units is now complete.' => 'Das Datenbankupgrade zwecks Einführung von Einheiten ist nun beendet.', - 'The dunning process is started' => 'Mahnprozess wird gestartet', 'The dunning process started' => 'Der Mahnprozess ist gestartet.', 'The factor is missing in row %d.' => 'Der Faktor fehlt in Zeile %d.', 'The factor is missing.' => 'Der Faktor fehlt.', @@ -951,6 +956,7 @@ gestartet', 'The following Datasets need to be updated' => 'Folgende Datenbanken müssen aktualisiert werden', 'The following units are unknown.' => 'Die folgenden Einheiten sind unbekannt.', 'The following units exist already:' => 'Die folgenden Einheiten existieren bereits:', + 'The following warnings occured during an upgrade to the document templates:' => 'Die folgenden Warnungen traten während einer Aktualisierung der Dokumentenvorlagen auf:', 'The formula needs the following syntax:
For regular article:
Variablename= Variable Unit;
Variablename2= Variable2 Unit2;
...
###
Variable + ( Variable2 / Variable )
Please be beware of the spaces in the formula
' => 'Die Formeln müssen in der folgenden Syntax eingegeben werden:
Bei normalen Artikeln:
Variablenname= Variable Einheit;
Variablenname2= Variable2 Einheit2;
...
###
Variable + Variable2 * ( Variable - Variable2 )
Bitte achten Sie auf die Leerzeichen in der Formel
Es muss jeweils die Gesamte Zeile eingegeben werden', 'The licensing module has been deactivated in lx-erp.conf.' => 'Das Lizenzverwaltungsmodul wurde in lx-erp.conf deaktiviert.', 'The name in row %d has already been used before.' => 'Der Name in Zeile %d wurde vorher bereits benutzt.', @@ -1085,6 +1091,7 @@ gestartet', 'Warehouse deleted!' => 'Das Lager wurde gelöscht.', 'Warehouse saved!' => 'Das Lager wurde gespeichert.', 'Warehouses' => 'Lager', + 'Warnings during template upgrade' => 'Warnungen bei Aktualisierung der Dokumentenvorlagen', 'Weight' => 'Gewicht', 'Weight Unit' => 'Gewichtseinheit', 'What type of item is this?' => 'Was ist dieser Artikel?', @@ -1092,6 +1099,7 @@ gestartet', 'Workflow request_quotation' => 'Workflow Preisanfrage', 'Workflow sales_order' => 'Workflow Auftrag', 'Workflow sales_quotation' => 'Workflow Angebot', + 'Wrong Period' => '', 'YYYY' => 'JJJJ', 'Year' => 'Jahr', 'Year End' => 'Jahresende', diff --git a/locale/de/ustva b/locale/de/ustva index dff6c30f4..c32088c84 100644 --- a/locale/de/ustva +++ b/locale/de/ustva @@ -5,6 +5,8 @@ $self->{texts} = { '4. Quarter' => '4. Quartal', 'Address' => 'Adresse', 'Angaben zum Finanzamt' => 'Angaben zum Finanzamt', + 'Application Error. No Format given!' => 'Application Error. No Format given!', + 'Application Error. Wrong Format: ' => 'Application Error. Wrong Format: ', 'Apr' => 'Apr', 'April' => 'April', 'Aug' => 'Aug', @@ -31,6 +33,7 @@ $self->{texts} = { 'Dec' => 'Dez', 'December' => 'Dezember', 'Description' => 'Beschreibung', + 'ELSTER Export nach Taxbird' => 'ELSTER Export nach Taxbird', 'ELSTER Export nach Winston' => 'ELSTER Export nach Winston', 'ELSTER-Steuernummer: ' => 'ELSTER-Steuernummer: ', 'Fax' => 'Fax', @@ -45,8 +48,8 @@ $self->{texts} = { 'Help:' => 'Hilfe:', 'Hint-Missing-Preferences' => 'Bitte fehlende USTVA Einstellungen ergänzen (Menüpunkt: Programm)', 'Hinweise' => 'Hinweise', - 'Impossible to create yearly Tax Report as PDF or PS.
Not yet implemented!' => 'Umsatzsteuer Jahreserklärung als PDF wird noch nicht unterstützt.
Bitte benutzen Sie das Ausgabeformat Vorschau.', - 'Impossible to create yearly Tax Report via Winston.
Not yet implemented!' => 'Umsatzsteuer Jahreserklärung via Winston wird noch nicht unterstützt.
Bitte benutzen Sie das Ausgabeformat Vorschau.', + 'Impossible to create yearly Tax Report as PDF or Postscript
Not yet implemented!' => 'Impossible to create yearly Tax Report as PDF or Postscript
Not yet implemented!', + 'Impossible to create yearly Tax Report via Winston or Taxbird.
Not yet implemented!' => 'Impossible to create yearly Tax Report via Winston or Taxbird.
Not yet implemented!', 'Internet' => 'Internet', 'Ist dies eine berichtigte Anmeldung? (Nr. 10/Zeile 15 Steuererklärung)' => 'Ist dies eine berichtigte Anmeldung? (Nr. 10/Zeile 15 Steuererklärung)', 'Jan' => 'Jan', @@ -100,6 +103,7 @@ $self->{texts} = { 'Voranmeldezeitraum' => 'Voranmeldezeitraum', 'Voranmeldungszeitraum' => 'Voranmeldungszeitraum', 'Vorschau' => 'Vorschau', + 'Wrong Period' => 'Wrong Period', 'Year' => 'Jahr', 'Yearly' => 'jährlich', 'accrual' => 'Bilanzierung (Soll-Versteuerung)', @@ -126,16 +130,10 @@ $self->{subs} = { 'config' => 'config', 'continue' => 'continue', 'create_steuernummer' => 'create_steuernummer', - 'create_winston' => 'create_winston', 'debug' => 'debug', 'edit' => 'edit', 'edit_form' => 'edit_form', - 'elster_conf' => 'elster_conf', - 'elster_feedback' => 'elster_feedback', 'elster_hash' => 'elster_hash', - 'elster_readlog' => 'elster_readlog', - 'elster_send' => 'elster_send', - 'elster_xml' => 'elster_xml', 'generate_ustva' => 'generate_ustva', 'get_config' => 'get_config', 'gl_transaction' => 'gl_transaction', @@ -145,13 +143,11 @@ $self->{subs} = { 'report' => 'report', 'sales_invoice' => 'sales_invoice', 'save' => 'save', - 'save_winston' => 'save_winston', 'select_name' => 'select_name', 'select_project' => 'select_project', 'show' => 'show', 'show_fa_daten' => 'show_fa_daten', 'show_options' => 'show_options', - 'test' => 'test', 'ustva_vorauswahl' => 'ustva_vorauswahl', 'vendor_invoice' => 'vendor_invoice', 'weiter' => 'continue', diff --git a/sql/Pg-upgrade/Pg-upgrade-2.2.0.37-2.2.0.38.pl b/sql/Pg-upgrade/Pg-upgrade-2.2.0.37-2.2.0.38.pl new file mode 100644 index 000000000..09a0603f3 --- /dev/null +++ b/sql/Pg-upgrade/Pg-upgrade-2.2.0.37-2.2.0.38.pl @@ -0,0 +1,65 @@ +#!/usr/bin/perl + +# Upgrade von Vorlagen + +die("This script cannot be run from the command line.") unless ($main::form); + +use File::Copy; + +sub update_templates { + local *IN; + + if (!open(IN, "users/members")) { + die($dbup_locale->text("Could not open the file users/members.")); + } + + my %all_template_dirs; + while () { + chomp(); + $all_template_dirs{$1} = 1 if (/^templates=(.*)/); + } + close(IN); + + my @new_templates; + + foreach my $raw (@_) { + $raw =~ /^.*?-(.*)/; + push(@new_templates, { "source" => "templates/$raw", + "destination" => $1 }); + } + + my @warnings; + + foreach my $dir (keys(%all_template_dirs)) { + foreach my $template (@new_templates) { + my $destination = $dir . "/" . $template->{"destination"}; + if (-f $destination) { + if (!rename($destination, $destination . ".bak")) { + push(@warnings, sprintf($dbup_locale->text("Could not rename %s to %s. Reason: %s"), + $destination, $destination . ".bak", $!)); + } + } + if (!copy($template->{"source"}, $destination)) { + push(@warnings, sprintf($dbup_locale->text("Could not copy %s to %s. Reason: %s"), + $template->{"source"}, $destination . ".bak", $!)); + } + } + } + + if (@warnings) { + @warnings = map(+{ "message" => $_ }, @warnings); + print($form->parse_html_template("dbupgrade/update_templates_warnings", + { "WARNINGS" => \@warnings })); + } + + return 1; +} + +sub do_update { + update_templates("German-winston.xml", + "German-taxbird.txb", + "German-credit_note.tex", + "German-zahlungserinnerung.tex"); +} + +return do_update(); diff --git a/templates/webpages/dbupgrade/update_templates_warnings_de.html b/templates/webpages/dbupgrade/update_templates_warnings_de.html new file mode 100644 index 000000000..3580e61dd --- /dev/null +++ b/templates/webpages/dbupgrade/update_templates_warnings_de.html @@ -0,0 +1,11 @@ +
Warnungen bei Aktualisierung der Dokumentenvorlagen
+ +

Die folgenden Warnungen traten während einer Aktualisierung der Dokumentenvorlagen auf:

+ +

+

    + +
  • +
    +
+

diff --git a/templates/webpages/dbupgrade/update_templates_warnings_master.html b/templates/webpages/dbupgrade/update_templates_warnings_master.html new file mode 100644 index 000000000..addda81a4 --- /dev/null +++ b/templates/webpages/dbupgrade/update_templates_warnings_master.html @@ -0,0 +1,12 @@ +
Warnings during template upgrade
+ +

The following warnings occured during an upgrade to the + document templates:

+ +

+

    + +
  • +
    +
+

-- 2.20.1