multi currency opliste / zahlungseingang
This commit is contained in:
parent
a6f4b68fba
commit
8b22337548
6 changed files with 66 additions and 29 deletions
|
|
@ -11,6 +11,7 @@ import org.imixs.workflow.ItemCollection;
|
||||||
import org.imixs.workflow.WorkflowKernel;
|
import org.imixs.workflow.WorkflowKernel;
|
||||||
import org.imixs.workflow.engine.DocumentService;
|
import org.imixs.workflow.engine.DocumentService;
|
||||||
import org.imixs.workflow.engine.WorkflowService;
|
import org.imixs.workflow.engine.WorkflowService;
|
||||||
|
import org.imixs.workflow.exceptions.PluginException;
|
||||||
import org.imixs.workflow.exceptions.QueryException;
|
import org.imixs.workflow.exceptions.QueryException;
|
||||||
import org.imixs.workflow.faces.data.WorkflowController;
|
import org.imixs.workflow.faces.data.WorkflowController;
|
||||||
import org.imixs.workflow.faces.data.WorkflowEvent;
|
import org.imixs.workflow.faces.data.WorkflowEvent;
|
||||||
|
|
@ -65,6 +66,9 @@ public class OPListController implements Serializable {
|
||||||
@Inject
|
@Inject
|
||||||
protected DocumentService documentService;
|
protected DocumentService documentService;
|
||||||
|
|
||||||
|
@Inject
|
||||||
|
protected InvoiceService invoiceService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Diese Methode wird für Zahlungseingänge und Mahnläufe verwendet.
|
* Diese Methode wird für Zahlungseingänge und Mahnläufe verwendet.
|
||||||
* <p>
|
* <p>
|
||||||
|
|
@ -444,4 +448,13 @@ public class OPListController implements Serializable {
|
||||||
public void setCurrencyFilter(String currencyFilter) {
|
public void setCurrencyFilter(String currencyFilter) {
|
||||||
this.currencyFilter = currencyFilter;
|
this.currencyFilter = currencyFilter;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public List<String> getCurrenciesOut() {
|
||||||
|
try {
|
||||||
|
return invoiceService.getCurrenciesOut();
|
||||||
|
} catch (PluginException e) {
|
||||||
|
return new ArrayList<String>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,16 @@ form.open_saldo=Offener Saldo
|
||||||
form.dunning=Mahnen
|
form.dunning=Mahnen
|
||||||
form.all=Alle
|
form.all=Alle
|
||||||
|
|
||||||
|
oplist.remaining=Restbetrag
|
||||||
|
oplist.invoicenumber=Rg-Nr.
|
||||||
|
oplist.total=Betrag
|
||||||
|
oplist.rate=Kurs
|
||||||
|
oplist.total.base=Basisumsatz
|
||||||
|
oplist.saldo=Saldo
|
||||||
|
oplist.saldo.base=Saldo
|
||||||
|
oplist.payment=Zahlbetrag
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ERROR_CDTR_INVALID=Die Kreditorennummer ist nicht gültig
|
ERROR_CDTR_INVALID=Die Kreditorennummer ist nicht gültig
|
||||||
ERROR_BOOKING_PERIOD=Eingabefehler - Bitte geben Sie eine gültige Buchungsperiode ein! Prüfen Sie auch die Spalte BP in der Positionstabelle.
|
ERROR_BOOKING_PERIOD=Eingabefehler - Bitte geben Sie eine gültige Buchungsperiode ein! Prüfen Sie auch die Spalte BP in der Positionstabelle.
|
||||||
|
|
|
||||||
|
|
@ -42,6 +42,15 @@ form.open_saldo=Open Balance
|
||||||
form.dunning=Dunning
|
form.dunning=Dunning
|
||||||
form.all=All
|
form.all=All
|
||||||
|
|
||||||
|
oplist.remaining=Remaining Amount
|
||||||
|
oplist.invoicenumber=No.
|
||||||
|
oplist.total=Total
|
||||||
|
oplist.rate=Rate
|
||||||
|
oplist.total.base=Total Base
|
||||||
|
oplist.saldo=Saldo
|
||||||
|
oplist.saldo.base=Saldo
|
||||||
|
oplist.payment=Payment
|
||||||
|
|
||||||
ERROR_CDTR_INVALID=The creditor number is not valid
|
ERROR_CDTR_INVALID=The creditor number is not valid
|
||||||
ERROR_BOOKING_PERIOD=Input error - Please enter a valid booking period! Also check the BP column in the position table.
|
ERROR_BOOKING_PERIOD=Input error - Please enter a valid booking period! Also check the BP column in the position table.
|
||||||
ERROR_MAIN_BOOKING_PERIOD=Input errors - Please check the main booking period with the booking periods of each item.
|
ERROR_MAIN_BOOKING_PERIOD=Input errors - Please check the main booking period with the booking periods of each item.
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@
|
||||||
|
|
||||||
|
|
||||||
<dl>
|
<dl>
|
||||||
<dt>Restbetrag:</dt>
|
<dt>#{custom['oplist.remaining']}:</dt>
|
||||||
<dd style="color:red;" data-item='payment.difference'>
|
<dd style="color:red;" data-item='payment.difference'>
|
||||||
<h:outputText value="#{opListController.calculatePaymentDifference()}">
|
<h:outputText value="#{opListController.calculatePaymentDifference()}">
|
||||||
<f:convertNumber minFractionDigits="2" locale="de" />
|
<f:convertNumber minFractionDigits="2" locale="de" />
|
||||||
|
|
@ -23,23 +23,23 @@
|
||||||
|
|
||||||
<table style="width: 100%; margin: 5px;">
|
<table style="width: 100%; margin: 5px;">
|
||||||
<tr>
|
<tr>
|
||||||
<th style="text-align: left;">Rg-Nr.</th>
|
<th style="text-align: left;">#{custom['oplist.invoicenumber']}</th>
|
||||||
<th style="text-align: left;">#{message['form.date']}</th>
|
<th style="text-align: left;">#{message['form.date']}</th>
|
||||||
|
|
||||||
<th style="text-align: left;">#{message['form.deadline']}</th>
|
<th style="text-align: left;">#{message['form.deadline']}</th>
|
||||||
<th style="text-align: left;">Status</th>
|
<th style="text-align: left;">Status</th>
|
||||||
<th style="text-align: right;">S/H</th>
|
<th style="text-align: right;">#{custom['oplist.total']}</th>
|
||||||
<th style="width: 40px;"></th>
|
<th style="width: 40px;"></th>
|
||||||
|
|
||||||
<th style="width: 70px; text-align: right;">Kurs</th>
|
<th style="width: 70px; text-align: right;">#{custom['oplist.rate']}</th>
|
||||||
<th style="width: 100px; text-align: right;">Basisumsatz</th>
|
<th style="width: 100px; text-align: right;">#{custom['oplist.total.base']}</th>
|
||||||
<th />
|
<th />
|
||||||
|
|
||||||
<th style="width: 100px;">Saldo</th>
|
<th style="width: 100px;">#{custom['oplist.saldo']}</th>
|
||||||
<th />
|
<th />
|
||||||
<th style="width: 100px;">Saldo in EUR</th>
|
<th style="width: 100px;">#{custom['oplist.saldo.base']} #{workitem.item['payment.currency']}</th>
|
||||||
<th style=""></th>
|
<th style=""></th>
|
||||||
<th style="width: 150px;">Zahlbetrag</th>
|
<th style="width: 150px;">#{custom['oplist.payment']}</th>
|
||||||
<th style=""></th>
|
<th style=""></th>
|
||||||
</tr>
|
</tr>
|
||||||
<ui:param name="invoices" value="#{opListController.getInvoices(workitem.item['dbtr.number'])}"></ui:param>
|
<ui:param name="invoices" value="#{opListController.getInvoices(workitem.item['dbtr.number'])}"></ui:param>
|
||||||
|
|
@ -163,20 +163,22 @@
|
||||||
<!-- Invoice total -->
|
<!-- Invoice total -->
|
||||||
<td style="text-align: right;"><strong>
|
<td style="text-align: right;"><strong>
|
||||||
<h:panelGroup id="invoice_total">
|
<h:panelGroup id="invoice_total">
|
||||||
<h:outputText value="#{opListController.calculateInvoiceTotal('EUR')}">
|
<ui:repeat value="#{opListController.getCurrenciesOut()}" var="currency">
|
||||||
<f:convertNumber minFractionDigits="2" locale="de" />
|
<h:outputText value="#{opListController.calculateInvoiceTotal(currency)}">
|
||||||
</h:outputText>
|
<f:convertNumber minFractionDigits="2" locale="de" />
|
||||||
|
</h:outputText>
|
||||||
<br />
|
<br />
|
||||||
|
</ui:repeat>
|
||||||
<h:outputText value="#{opListController.calculateInvoiceTotal('USD')}">
|
|
||||||
<f:convertNumber minFractionDigits="2" locale="de" />
|
|
||||||
</h:outputText>
|
|
||||||
</h:panelGroup>
|
</h:panelGroup>
|
||||||
</strong></td>
|
</strong>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
<td><strong>EUR<br />USD</strong></td>
|
<strong>
|
||||||
|
<ui:repeat value="#{opListController.getCurrenciesOut()}" var="currency">
|
||||||
|
#{currency}<br />
|
||||||
|
</ui:repeat>
|
||||||
|
</strong>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
|
||||||
<td />
|
<td />
|
||||||
|
|
@ -196,7 +198,7 @@
|
||||||
</h:outputText>
|
</h:outputText>
|
||||||
</h:panelGroup>
|
</h:panelGroup>
|
||||||
</strong>
|
</strong>
|
||||||
<!-- Anzeige des Zahlbetrgs in EUR bei Fremdwärungszahlung -->
|
<!-- Anzeige des Zahlbetrags in EUR bei Fremdwärungszahlung -->
|
||||||
<ui:fragment rendered="#{workitem.item['payment.currency'] ne 'EUR'}">
|
<ui:fragment rendered="#{workitem.item['payment.currency'] ne 'EUR'}">
|
||||||
<br />
|
<br />
|
||||||
EUR <h:outputText value="#{opListController.calculatePaymentSaldoEUR()}">
|
EUR <h:outputText value="#{opListController.calculatePaymentSaldoEUR()}">
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
<ui:param name="payments"
|
<ui:param name="payments"
|
||||||
value="#{workitemLinkController.getExternalReferences('$workflowgroup:Zahlungseingang')}"></ui:param>
|
value="#{workitemLinkController.getExternalReferences('$modelversion:zahlungseingang-.*')}"></ui:param>
|
||||||
<ui:repeat var="payment_stub" value="#{payments}">
|
<ui:repeat var="payment_stub" value="#{payments}">
|
||||||
<ui:param name="payment" value="#{opListController.loadInvoice(payment_stub.getUniqueID())}"></ui:param>
|
<ui:param name="payment" value="#{opListController.loadInvoice(payment_stub.getUniqueID())}"></ui:param>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -14,21 +14,24 @@
|
||||||
|
|
||||||
<table style="width: 100%; margin: 5px;">
|
<table style="width: 100%; margin: 5px;">
|
||||||
<tr>
|
<tr>
|
||||||
<th style="text-align: left;">Rg-Nr.</th>
|
<th style="text-align: left;">#{custom['oplist.invoicenumber']}</th>
|
||||||
<th style="text-align: left;">#{message['form.date']}</th>
|
<th style="text-align: left;">#{message['form.date']}</th>
|
||||||
|
|
||||||
<th style="text-align: left;">#{message['form.deadline']}</th>
|
<th style="text-align: left;">#{message['form.deadline']}</th>
|
||||||
<th style="text-align: left;">Status</th>
|
<th style="text-align: left;">Status</th>
|
||||||
<th style="text-align: right;">S/H</th>
|
<th style="text-align: right;">#{custom['oplist.total']}</th>
|
||||||
<th style="width: 40px;"></th>
|
<th style="width: 40px;"></th>
|
||||||
|
|
||||||
<th style="width: 70px; text-align: right;">Kurs</th>
|
<th style="width: 70px; text-align: right;">#{custom['oplist.rate']}</th>
|
||||||
<th style="width: 100px; text-align: right;">Basisumsatz</th>
|
<th style="width: 100px; text-align: right;">#{custom['oplist.total.base']}</th>
|
||||||
<th />
|
<th />
|
||||||
|
|
||||||
<th style="width: 100px;">Saldo</th>
|
<th style="width: 100px;">#{custom['oplist.saldo']}</th>
|
||||||
<th />
|
<th />
|
||||||
|
<th style="width: 100px;">#{custom['oplist.saldo.base']} #{workitem.item['payment.currency']}</th>
|
||||||
|
<th style=""></th>
|
||||||
|
<th style="width: 150px;">#{custom['oplist.payment']}</th>
|
||||||
|
<th style=""></th>
|
||||||
</tr>
|
</tr>
|
||||||
<ui:param name="invoices" value="#{opListController.getInvoices(workitem.item['dbtr.number'])}"></ui:param>
|
<ui:param name="invoices" value="#{opListController.getInvoices(workitem.item['dbtr.number'])}"></ui:param>
|
||||||
<ui:repeat value="#{invoices}" var="invoice">
|
<ui:repeat value="#{invoices}" var="invoice">
|
||||||
Loading…
Reference in a new issue