minor fixes

This commit is contained in:
Ralph Soika 2024-11-17 10:00:26 +01:00
parent ff8cfb44bd
commit a099bfdfac
4 changed files with 5438 additions and 89 deletions

View file

@ -1,87 +0,0 @@
<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:f="http://xmlns.jcp.org/jsf/core"
xmlns:h="http://xmlns.jcp.org/jsf/html" xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
xmlns:ui="http://xmlns.jcp.org/jsf/facelets" xmlns:a="http://xmlns.jcp.org/jsf/passthrough"
xmlns:marty="http://xmlns.jcp.org/jsf/composite/marty" xmlns:i="http://xmlns.jcp.org/jsf/composite/imixs">
<!-- *** Krieger Custom Search form *** -->
<hr style="border-width:5px" />
<div class="imixs-form-section-3">
<dl>
<dt>#{custom.invoiceamount}:</dt>
<dd>
<h:inputText style="width:12em;" value="#{searchController.searchFilter.item['invoice.total']}">
<f:convertNumber minFractionDigits="2" locale="de" />
</h:inputText>
</dd>
</dl>
<dl>
<dt>#{custom.invoicedate}:</dt>
<dd>
<h:inputText styleClass="imixs-date" value="#{searchController.searchFilter.item['invoice.date']}">
<f:convertDateTime pattern="#{message.datePatternShort}" timeZone="#{message.timeZone}" />
</h:inputText>
</dd>
</dl>
<dl>
<dt>#{custom.invoiceduedate}:</dt>
<dd>
<h:inputText styleClass="imixs-date" value="#{searchController.searchFilter.item['invoice.duedate']}">
<f:convertDateTime pattern="#{message.datePatternShort}" timeZone="#{message.timeZone}" />
</h:inputText>
</dd>
</dl>
<dl>
<dt>#{custom.closingdate}:</dt>
<dd>
<h:inputText styleClass="imixs-date"
value="#{searchController.searchFilter.item['invoice.closingdate']}">
<f:convertDateTime pattern="#{message.datePatternShort}" timeZone="#{message.timeZone}" />
</h:inputText>
</dd>
</dl>
<dl>
<dt>#{custom.creditor_number}:</dt>
<dd>
<h:inputText value="#{searchController.searchFilter.item['cdtr.number']}">
</h:inputText>
</dd>
</dl>
<dl>
<dt>#{custom.invoicenumber}:</dt>
<dd>
<h:inputText value="#{searchController.searchFilter.item['invoice.number']}">
</h:inputText>
</dd>
</dl>
</div>
<div class="imixs-form-section">
<dl>
<dt>Rechnungsart:</dt>
<dd>
<h:selectOneRadio value="#{searchController.searchFilter.item['invoice.type']}">
<f:selectItem itemLabel="Alle" itemValue="0" />
<f:selectItem itemLabel="Cargo Rechnung" itemValue="1" />
<f:selectItem itemLabel="Sachrechnung" itemValue="2" />
<f:selectItem itemLabel="Gutschrift" itemValue="3" />
<f:selectItem itemLabel="Gutschrift Abgleich" itemValue="4" />
</h:selectOneRadio>
</dd>
</dl>
</div>
<hr style="border-width:5px" />
</ui:composition>

View file

@ -0,0 +1,65 @@
package com.alexanderlogistics;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.fail;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.time.temporal.IsoFields;
import java.util.Date;
import java.util.logging.Logger;
import org.junit.Before;
import org.junit.Test;
/**
* Testen der KW Berechnung
*
* @author rsoika
*
*/
public class TestOPListen {
public static DateFormat dateFormat = new SimpleDateFormat("ddMMyyyy");
private final static Logger logger = Logger.getLogger(TestOPListen.class.getName());
@Before
public void setUp() throws Exception {
}
/**
* Teste 31.12.2024
*/
@Test
public void testDatum() {
SimpleDateFormat dateFormatter = new SimpleDateFormat("yyyyMMdd");
String testDate = "20241231";
try {
Date dateResult = dateFormatter.parse(testDate);
System.out.println("Test Date=" + dateResult);
LocalDate date = LocalDate.parse("20241231", DateTimeFormatter.BASIC_ISO_DATE);
int weekNumber = date.get(IsoFields.WEEK_OF_WEEK_BASED_YEAR);
int weekBasedYear = date.get(IsoFields.WEEK_BASED_YEAR);
String weekCategory = weekBasedYear + "/" + String.format("%02d", weekNumber);
if ("2024/01".equals(weekCategory)) {
logger.warning("--> Invoice found with 2024/01: ");
}
assertEquals("2025/01", weekCategory);
} catch (ParseException e) {
e.printStackTrace();
fail();
}
}
}

View file

@ -25,8 +25,8 @@
<!-- Dependency Versions -->
<jakarta.version>10.0.0</jakarta.version>
<org.imixs.office.version>5.0.3-SNAPSHOT</org.imixs.office.version>
<org.imixs.workflow.version>6.0.8</org.imixs.workflow.version>
<org.imixs.office.version>5.0.4-SNAPSHOT</org.imixs.office.version>
<org.imixs.workflow.version>6.0.9-SNAPSHOT</org.imixs.workflow.version>
<org.imixs.marty.version>5.0.0</org.imixs.marty.version>
<org.imixs.archive.version>3.0.2</org.imixs.archive.version>
<org.imixs.adapters.version>3.0.2</org.imixs.adapters.version>

File diff suppressed because it is too large Load diff