$main::lxdebug->leave_sub();
}
+sub edit_sepa_strings {
+ $main::lxdebug->enter_sub();
+
+ $main::auth->assert('config');
+
+ my $form = $main::form;
+ my $locale = $main::locale;
+
+ $form->get_lists('languages' => 'LANGUAGES');
+
+ my $translation_list = GenericTranslations->list(translation_type => 'sepa_remittance_info_pfx');
+ my %translations = map { ( ($_->{language_id} || 'default') => $_->{translation} ) } @{ $translation_list };
+
+ unshift @{ $form->{LANGUAGES} }, { 'id' => 'default', };
+
+ foreach my $language (@{ $form->{LANGUAGES} }) {
+ $language->{translation} = $translations{$language->{id}};
+ }
+
+ $form->{title} = $locale->text('Edit SEPA strings');
+ $form->header();
+ print $form->parse_html_template('generictranslations/edit_sepa_strings');
+
+ $main::lxdebug->leave_sub();
+}
+
+sub save_sepa_strings {
+ $main::lxdebug->enter_sub();
+
+ $main::auth->assert('config');
+
+ my $form = $main::form;
+ my $locale = $main::locale;
+
+ $form->get_lists('languages' => 'LANGUAGES');
+
+ unshift @{ $form->{LANGUAGES} }, { };
+
+ foreach my $language (@{ $form->{LANGUAGES} }) {
+ GenericTranslations->save('translation_type' => 'sepa_remittance_info_pfx',
+ 'translation_id' => undef,
+ 'language_id' => $language->{id},
+ 'translation' => $form->{"translation__" . ($language->{id} || 'default')},);
+ }
+
+ $form->{message} = $locale->text('The SEPA strings have been saved.');
+
+ edit_sepa_strings();
+
+ $main::lxdebug->leave_sub();
+}
+
1;
'Edit Purchase Order' => 'Lieferantenaufrag bearbeiten',
'Edit Quotation' => 'Angebot bearbeiten',
'Edit Request for Quotation' => 'Anfrage bearbeiten',
+ 'Edit SEPA strings' => 'Begriffe bei SEPA-Überweisungen bearbeiten',
'Edit Sales Delivery Order' => 'Lieferschein (Verkauf) bearbeiten',
'Edit Sales Invoice' => 'Rechnung bearbeiten',
'Edit Sales Order' => 'Auftrag bearbeiten',
'Reference missing!' => 'Referenz fehlt!',
'Release From Stock' => 'Lagerausgang',
'Remaining' => 'Rest',
+ 'Remittance information prefix' => 'Verwendungszweckvorbelegung (Präfix)',
'Removal' => 'Entnahme',
'Removal from Warehouse' => 'Lagerentnahme',
'Removal from warehouse' => 'Entnahme aus Lager',
'SEPA XML download' => 'SEPA-XML-Download',
'SEPA creditor ID' => 'SEPA-Kreditoren-Identifikation',
'SEPA exports:' => 'SEPA-Exporte:',
+ 'SEPA strings' => 'SEPA-Überweisungen',
'Saldo Credit' => 'Saldo Haben',
'Saldo Debit' => 'Saldo Soll',
'Saldo neu' => 'Saldo neu',
'The GL transaction #1 has been deleted.' => 'Die Dialogbuchung #1 wurde gelöscht.',
'The LDAP server "#1:#2" is unreachable. Please check config/authentication.pl.' => 'Der LDAP-Server "#1:#2" ist nicht erreichbar. Bitte überprüfen Sie die Angaben in config/authentication.pl.',
'The SEPA export has been created.' => 'Der SEPA-Export wurde erstellt',
+ 'The SEPA strings have been saved.' => 'Die bei SEPA-Überweisungen verwendeten Begriffe wurden gespeichert.',
'The access rights have been saved.' => 'Die Zugriffsrechte wurden gespeichert.',
'The account 3804 already exists, the update will be skipped.' => 'Das Konto 3804 existiert schon, das Update wird übersprungen.',
'The account 3804 will not be added automatically.' => 'Das Konto 3804 wird nicht automatisch hinzugefügt.',
module=generictranslations.pl
action=edit_greetings
+[System--Languages--SEPA strings]
+module=generictranslations.pl
+action=edit_sepa_strings
+
[System--Payment Terms]
module=menu.pl
--- /dev/null
+[%- USE T8 %]
+[% USE HTML %]<body>
+
+ <p>
+ <div class="listtop">[% HTML.escape(title) %]</div>
+ </p>
+
+ [%- IF message %]
+ <p>
+ [% HTML.escape(message) %]
+ </p>
+ [%- END %]
+
+ <form method="post" action="generictranslations.pl">
+
+ <table>
+
+ <tr>
+ <th class="listheading"> </th>
+ <th class="listheading">[% 'Remittance information prefix' | $T8 %]</th>
+ </tr>
+
+ [%- FOREACH language = LANGUAGES %]
+ <tr>
+ <td>
+ [%- IF language.id == 'default' %]
+ [% 'Default (no language selected)' | $T8 %]
+ [%- ELSE %]
+ [%- HTML.escape(language.description) %]
+ [%- END %]
+ </td>
+ <td><input name="translation__[% language.id %]" size="40" value="[% HTML.escape(language.translation) %]"></td>
+ </tr>
+ [%- END %]
+
+ </table>
+
+ <p>
+ <input type="hidden" name="action" value="save_sepa_strings">
+ <input type="submit" class="submit" value="[% 'Save' | $T8 %]">
+ </p>
+
+ </form>
+
+</body>
+</html>