modell update

This commit is contained in:
Ralph Soika 2022-10-18 12:21:34 +02:00
parent 9a83ccc7e1
commit a35633b7aa
3 changed files with 5190 additions and 1 deletions

View file

@ -62,6 +62,8 @@ public class MahnlaufExecuteAdapter implements SignalAdapter {
// get all Invoices of this Mahnlauf // get all Invoices of this Mahnlauf
List<Map<String, List<Object>>> invoiceList = new ArrayList<Map<String, List<Object>>>(); List<Map<String, List<Object>>> invoiceList = new ArrayList<Map<String, List<Object>>>();
List<String> refList = mahnLaufWorkitem.getItemValue("$workitemref"); List<String> refList = mahnLaufWorkitem.getItemValue("$workitemref");
double saldo=0;
String currency="";
for (String uniqueId : refList) { for (String uniqueId : refList) {
ItemCollection invoice = workflowService.getWorkItem(uniqueId); ItemCollection invoice = workflowService.getWorkItem(uniqueId);
if (invoice != null && (invoice.getTaskID() >= MahnlaufService.TASK_MAHNLAUF_START if (invoice != null && (invoice.getTaskID() >= MahnlaufService.TASK_MAHNLAUF_START
@ -100,11 +102,17 @@ public class MahnlaufExecuteAdapter implements SignalAdapter {
invoiceStub.setItemValue("$workflowstatus", invoice.getItemValue("$workflowstatus")); invoiceStub.setItemValue("$workflowstatus", invoice.getItemValue("$workflowstatus"));
invoiceList.add(invoiceStub.getAllItems()); invoiceList.add(invoiceStub.getAllItems());
// store currency in mahnlauf
currency= invoice.getItemValueString("invoice.currency");
saldo=saldo+invoice.getItemValueDouble("invoice.saldo");
} }
} }
mahnLaufWorkitem.setItemValue("dunning.details", invoiceList); mahnLaufWorkitem.setItemValue("dunning.details", invoiceList);
mahnLaufWorkitem.setItemValue("dunning.saldo", saldo);
mahnLaufWorkitem.setItemValue("dunning.currency", currency);
return mahnLaufWorkitem; return mahnLaufWorkitem;
} }

View file

@ -410,6 +410,9 @@ th { font-weight: bold;}
<pre> <pre>
<itemvalue>description</itemvalue> <itemvalue>description</itemvalue>
</pre> </pre>
<p>
Debitor: <itemvalue>dbtr.name</itemvalue> (<itemvalue>dbtr.number</itemvalue>)
</p>
<table> <table>
<theader> <theader>
<tr> <tr>
@ -433,6 +436,9 @@ th { font-weight: bold;}
<td style="text-align:center;"><itemvalue>$workflowstatus</itemvalue></td> <td style="text-align:center;"><itemvalue>$workflowstatus</itemvalue></td>
</tr> </tr>
</for-each> </for-each>
<tr>
<td /><td /><td /><td style="text-align:right;font-weight:bold">Saldo</td><td style="text-align:right;"><itemvalue format="#,###,##0.00" locale="de_DE">dunning.saldo</itemvalue> <itemvalue>dunning.currency</itemvalue></td>
</tr>
</tbody> </tbody>
</table> </table>
@ -463,6 +469,9 @@ th { font-weight: bold;}
<p> <p>
<itemvalue>description</itemvalue> <itemvalue>description</itemvalue>
</p> </p>
<p>
Debitor: <itemvalue>dbtr.name</itemvalue> (<itemvalue>dbtr.number</itemvalue>)
</p>
<table> <table>
<theader> <theader>
<tr> <tr>
@ -486,6 +495,9 @@ th { font-weight: bold;}
<td style="text-align:center;"><itemvalue>$workflowstatus</itemvalue></td> <td style="text-align:center;"><itemvalue>$workflowstatus</itemvalue></td>
</tr> </tr>
</for-each> </for-each>
<tr>
<td /><td /><td /><td style="text-align:right;font-weight:bold">Saldo</td><td style="text-align:right;"><itemvalue format="#,###,##0.00" locale="de_DE">dunning.saldo</itemvalue> <itemvalue>dunning.currency</itemvalue></td>
</tr>
</tbody> </tbody>
</table> </table>
<textblock>E-Mail - Mahnlauf Footer (EN)</textblock> <textblock>E-Mail - Mahnlauf Footer (EN)</textblock>

File diff suppressed because it is too large Load diff