hg merge release-6.2 (merge release6.2 into default)

This commit is contained in:
Carlos Ruiz 2019-01-19 12:59:12 +01:00
commit a600e14237
11 changed files with 154 additions and 73 deletions

View File

@ -433,7 +433,7 @@ public class CalloutPayment extends CalloutEngine
currency.getStdPrecision (), RoundingMode.HALF_UP);
mTab.setValue ("OverUnderAmt", OverUnderAmt);
}
// No Invoice - Set Discount, Witeoff, Under/Over to 0
// No Invoice - Set Discount, Writeoff, Under/Over to 0
else if (C_Invoice_ID == 0)
{
if (Env.ZERO.compareTo (DiscountAmt) != 0)
@ -448,8 +448,12 @@ public class CalloutPayment extends CalloutEngine
&& (!processed)
&& "Y".equals (Env.getContext (ctx, WindowNo, "IsOverUnderPayment")))
{
OverUnderAmt = InvoiceOpenAmt.subtract (PayAmt).subtract (
DiscountAmt).subtract (WriteOffAmt);
OverUnderAmt = InvoiceOpenAmt.subtract (PayAmt).subtract(DiscountAmt).subtract (WriteOffAmt);
if (OverUnderAmt.signum() > 0) { // no discount because is not paid in full
DiscountAmt = Env.ZERO;
mTab.setValue ("DiscountAmt", DiscountAmt);
OverUnderAmt = InvoiceOpenAmt.subtract (PayAmt).subtract(DiscountAmt).subtract (WriteOffAmt);
}
mTab.setValue ("OverUnderAmt", OverUnderAmt);
}
else if (colName.equals ("PayAmt")

View File

@ -50,10 +50,12 @@ public class MToolBarButton extends X_AD_ToolBarButton {
public static MToolBarButton[] getProcessButtonOfTab(int AD_Tab_ID, String trxName) {
MToolBarButton[] buttons = new MToolBarButton[0];
Query query = new Query(Env.getCtx(), MTable.get(Env.getCtx(), Table_ID), "AD_Tab_ID=? AND Action=? AND AD_Process_ID IS NOT NULL", trxName);
Query query = new Query(Env.getCtx(), MTable.get(Env.getCtx(), Table_ID), "AD_ToolBarButton.AD_Tab_ID=? AND AD_ToolBarButton.Action=? AND AD_ToolBarButton.AD_Process_ID IS NOT NULL", trxName)
.addJoinClause("INNER JOIN AD_Process p ON (p.AD_Process_ID = AD_ToolBarButton.AD_Process_ID AND p.IsActive = 'Y')");
List<MToolBarButton> list = query.setParameters(AD_Tab_ID, "W").setOnlyActiveRecords(true)
.setOrderBy("CASE WHEN COALESCE(SeqNo,0)=0 THEN AD_ToolBarButton_ID ELSE SeqNo END").list();
.setOrderBy("CASE WHEN COALESCE(AD_ToolBarButton.SeqNo,0)=0 THEN AD_ToolBarButton.AD_ToolBarButton_ID ELSE AD_ToolBarButton.SeqNo END").list();
if (list != null && !list.isEmpty()) {
buttons = list.toArray(buttons);
}

View File

@ -0,0 +1,15 @@
HISTORY_VIOLATION=Le mot de passe correspond a un des %1%s mots de passe pr\u00E9c\u00E9dent.
ILLEGAL_WORD=Le mot de passe inclus le mot du dictionnaire : '%1%s'.
ILLEGAL_WORD_REVERSED=Le mot de passe inclus le mot invers\u00E9 du dictionnaire : '%1%s'.
ILLEGAL_MATCH=Le mot de passe correspond \u00e0 la s\u00E9quence interdite : '%1%s'.
ILLEGAL_CHAR=Le mot de passe inclus ce(s) caract\u00e8re(s) interdit(s) '%1%s'.
ALLOWED_CHAR=Le mot de passe contient le caract\u00e8re interdit '%1$s'.
ILLEGAL_SEQUENCE=Le mot de passe inclus la s\u00E9quence interdite : '%1$s'.
ILLEGAL_USERNAME=Le mot de passe est compos\u00E9 du nom d'utilisateur '%1$s'.
ILLEGAL_USERNAME_REVERSED=Le mot de passe est compos\u00E9 du nom d'utilisateur '%1$s' invers\u00E9.
ILLEGAL_WHITESPACE=Le mot de passe ne peut contenir d'espaces.
INSUFFICIENT_CHARACTERS=Le mot de passe doit \u00eatre compos\u00E9 d'au minimum '%1$s' caract\u00e8re(s) '%2$s'.
INSUFFICIENT_CHARACTERISTICS=Le mot de passe remplit %1$s des %2$s des pr\u00E9requis, mais '%3$s' sont requis.
SOURCE_VIOLATION=Le mot de passe ne peut \u00eatre identique a votre %1$s mot de passe.
TOO_LONG=Le mot de passe ne peut \u00eatre compos\u00E9 de plus de %2$s caract\u00e8res.
TOO_SHORT=Le mot de passe doit \u00eatre compos\u00E9 d'au moins %1$s caract\u00e8res.

View File

@ -0,0 +1,15 @@
HISTORY_VIOLATION=La password corrisponde a una delle %1%s precedenti
ILLEGAL_WORD=La password ha la parola del dizionario: '%1%s'.
ILLEGAL_WORD_REVERSED=La password ha la parola al contrario del dizionario: '%1%s'.
ILLEGAL_MATCH=La password corrisponde alla sequenza vietata: '%1%s'.
ILLEGAL_CHAR=La password contiene caratteri vietati '%1%s'.
ALLOWED_CHAR=La password contiene il carattere vietato '%1$s'.
ILLEGAL_SEQUENCE=La password contiene la sequenza vietata: '%1$s'.
ILLEGAL_USERNAME=La password \u00e8 composta dal nome utente '%1$s'.
ILLEGAL_USERNAME_REVERSED=La password contiene il nome utente '%1$s' al contrario.
ILLEGAL_WHITESPACE=La pasword non pu\u00F2 contenere spazie.
INSUFFICIENT_CHARACTERS=La password deve contenere un minimo di '%1$s' caratteri '%2$s'.
INSUFFICIENT_CHARACTERISTICS==La password digitata %1$s su %2$s dei pre requisiti ma '%3$s' sono richiesti.
SOURCE_VIOLATION=La password non puo esssere identica a tua %1$s password.
TOO_LONG=La password deve avere pi\u00f9 di %2$s caratteri.
TOO_SHORT=La password deve avere almeno %1$s caratteri.

View File

@ -355,7 +355,7 @@ public final class DisplayType
{
Language myLanguage = language;
if (myLanguage == null)
myLanguage = Language.getLoginLanguage();
myLanguage = Env.getLocaleLanguage(Env.getCtx());
Locale locale = myLanguage.getLocale();
DecimalFormat format = null;
if (locale != null)

View File

@ -37,6 +37,7 @@ import java.util.Date;
import java.util.Enumeration;
import java.util.Iterator;
import java.util.List;
import java.util.Locale;
import java.util.Properties;
import java.util.Set;
import java.util.logging.Level;
@ -1144,6 +1145,45 @@ public final class Env
return Language.getLoginLanguage();
} // getLanguage
/**
* @param ctx
* @return Language
*/
public static Language getLocaleLanguage(Properties ctx) {
Locale locale = getLocale(ctx);
Language language = Env.getLanguage(ctx);
if (!language.getLocale().equals(locale)) {
Language tmp = Language.getLanguage(locale.toString());
String adLanguage = language.getAD_Language();
language = new Language(tmp.getName(), adLanguage, tmp.getLocale(), tmp.isDecimalPoint(),
tmp.getDateFormat().toPattern(), tmp.getMediaSize());
}
return language;
}
public static final String LOCALE = "#Locale";
/**
* @param ctx
* @return Locale
*/
public static Locale getLocale(Properties ctx) {
String value = Env.getContext(ctx, Env.LOCALE);
Locale locale = null;
if (value != null && value.length() > 0)
{
String[] components = value.split("\\_");
String language = components.length > 0 ? components[0] : "";
String country = components.length > 1 ? components[1] : "";
locale = new Locale(language, country);
}
else
{
locale = Env.getLanguage(ctx).getLocale();
}
return locale;
}
public static ArrayList<String> getSupportedLanguages()
{
ArrayList<String> AD_Languages = new ArrayList<String>();

File diff suppressed because one or more lines are too long

View File

@ -90,7 +90,7 @@ import com.itextpdf.text.pdf.PdfWriter;
*/
public final class AEnv
{
public static final String LOCALE = "#Locale";
public static final String LOCALE = Env.LOCALE;
/**
* Show in the center of the screen.
@ -663,15 +663,7 @@ public final class AEnv
* @return Language
*/
public static Language getLanguage(Properties ctx) {
Locale locale = getLocale(ctx);
Language language = Env.getLanguage(ctx);
if (!language.getLocale().equals(locale)) {
Language tmp = Language.getLanguage(locale.toString());
String adLanguage = language.getAD_Language();
language = new Language(tmp.getName(), adLanguage, tmp.getLocale(), tmp.isDecimalPoint(),
tmp.getDateFormat().toPattern(), tmp.getMediaSize());
}
return language;
return Env.getLocaleLanguage(ctx);
}
/**
@ -679,21 +671,7 @@ public final class AEnv
* @return Locale
*/
public static Locale getLocale(Properties ctx) {
String value = Env.getContext(ctx, AEnv.LOCALE);
Locale locale = null;
if (value != null && value.length() > 0)
{
String[] components = value.split("\\_");
String language = components.length > 0 ? components[0] : "";
String country = components.length > 1 ? components[1] : "";
locale = new Locale(language, country);
}
else
{
locale = Env.getLanguage(ctx).getLocale();
}
return locale;
return Env.getLocale(ctx);
}
/**

View File

@ -91,7 +91,7 @@ public class NumberBox extends Div
decimalBox.setSclass("editor-input");
decimalBox.setId(decimalBox.getUuid());
char separatorChar = DisplayType.getNumberFormat(DisplayType.Number, Env.getLanguage(Env.getCtx())).getDecimalFormatSymbols().getDecimalSeparator();
char separatorChar = DisplayType.getNumberFormat(DisplayType.Number, null).getDecimalFormatSymbols().getDecimalSeparator();
String separator = Character.toString(separatorChar);
boolean processDotKeypad = MSysConfig.getBooleanValue(MSysConfig.ZK_DECIMALBOX_PROCESS_DOTKEYPAD, true, Env.getAD_Client_ID(Env.getCtx()));
if (processDotKeypad) {
@ -253,7 +253,7 @@ public class NumberBox extends Div
Vbox vbox = new Vbox();
char separatorChar = DisplayType.getNumberFormat(DisplayType.Number, Env.getLanguage(Env.getCtx())).getDecimalFormatSymbols().getDecimalSeparator();
char separatorChar = DisplayType.getNumberFormat(DisplayType.Number, null).getDecimalFormatSymbols().getDecimalSeparator();
String separator = Character.toString(separatorChar);
txtCalc = new Textbox();

View File

@ -10,7 +10,7 @@
<artifactId>org.idempiere.maven.to.p2</artifactId>
<packaging>pom</packaging>
<properties>
<zk-osgi-zip-file>https://sourceforge.net/projects/zk1/files/ZK/zk-8.6.0.1/zk-bin-osgi-8.6.0.1.zip</zk-osgi-zip-file>
<zk-osgi-zip-file>https://sourceforge.net/project/zk1/ZK/zk-8.6.0.1/zk-bin-osgi-8.6.0.1.zip</zk-osgi-zip-file>
<!-- https://github.com/eclipse/jetty.project/blob/jetty-9.4.9.v20180320/pom.xml up to verison of jetty -->
<jetty.version>9.4.14.v20181114</jetty.version>
<jetty.alpn.api.version>1.1.3.v20160715</jetty.alpn.api.version>
@ -115,12 +115,6 @@
<source>true</source>
<transitive>false</transitive>
</artifact>
<artifact>
<!-- it's maintain and up to date than org.eclipse.jdt.core.compiler.batch -->
<id>org.eclipse.jdt:org.eclipse.jdt.core:jar:${jdtVersion}</id>
<source>true</source>
<transitive>false</transitive>
</artifact>
<artifact>
<id>javax.websocket:javax.websocket-api:jar:1.1</id>
<source>true</source>
@ -1762,6 +1756,39 @@ it also resolve issue confilic between eclipse runtime and tycho build
<retries>5</retries>
</configuration>
</execution>
<!--hot fix for https://tracker.zkoss.org/browse/ZK-4198, https://idempiere.atlassian.net/browse/IDEMPIERE-2003-->
<execution>
<id>download-zk-patch-source-for-IDEMPIERE-2003</id>
<phase>package</phase>
<goals>
<goal>wget</goal>
</goals>
<configuration>
<url>${url.file.srv}/extra.jar/zul.sources_8.6.0.1-patched.jar</url>
<unpack>false</unpack>
<outputFileName>zul.sources_8.6.0.1-patched.jar</outputFileName>
<outputDirectory>${project.build.directory}/repository/plugins</outputDirectory>
<retries>5</retries>
<overwrite>true</overwrite>
<skipCache>true</skipCache>
</configuration>
</execution>
<execution>
<id>download-zk-patch-binary-for-IDEMPIERE-2003</id>
<phase>package</phase>
<goals>
<goal>wget</goal>
</goals>
<configuration>
<url>${url.file.srv}/extra.jar/zul_8.6.0.1-patched.jar</url>
<unpack>false</unpack>
<outputFileName>zul_8.6.0.1-patched.jar</outputFileName>
<outputDirectory>${project.build.directory}/repository/plugins</outputDirectory>
<retries>5</retries>
<overwrite>true</overwrite>
<skipCache>true</skipCache>
</configuration>
</execution>
</executions>
</plugin>
<!-- copy zk osgi bundle to repository folder -->

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><?pde version="3.8"?><target name="idempiere-181229" sequenceNumber="107">
<?xml version="1.0" encoding="UTF-8" standalone="no"?><?pde version="3.8"?><target name="idempiere-190118" sequenceNumber="107">
<locations>
<location includeAllPlatforms="true" includeConfigurePhase="true" includeMode="slicer" includeSource="true" type="InstallableUnit">
<unit id="org.eclipse.e4.core.tools.feature.source.feature.group" version="4.10.0.v20181116-0958"/>
@ -888,30 +888,30 @@
<unit id="bcprov.source" version="1.60.0"/>
<unit id="bctsp" version="1.46.0"/>
<unit id="bctsp.source" version="1.46.0"/>
<unit id="com.fasterxml.jackson.core.jackson-annotations" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-annotations.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-core" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-core.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-databind" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-databind.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.dataformat.jackson-dataformat-xml" version="2.9.7"/>
<unit id="com.fasterxml.jackson.dataformat.jackson-dataformat-xml.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-guava" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-guava.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-joda" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-joda.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-json-org" version="2.9.7"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-json-org.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-base" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-base.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-json-provider" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-json-provider.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-xml-provider" version="2.9.7"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-xml-provider.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jaxb-annotations" version="2.9.7"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jaxb-annotations.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jsonSchema" version="2.9.7"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jsonSchema.source" version="2.9.7"/>
<unit id="com.fasterxml.jackson.core.jackson-annotations" version="2.9.8"/>
<unit id="com.fasterxml.jackson.core.jackson-annotations.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.core.jackson-core" version="2.9.8"/>
<unit id="com.fasterxml.jackson.core.jackson-core.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.core.jackson-databind" version="2.9.8"/>
<unit id="com.fasterxml.jackson.core.jackson-databind.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.dataformat.jackson-dataformat-xml" version="2.9.8"/>
<unit id="com.fasterxml.jackson.dataformat.jackson-dataformat-xml.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-guava" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-guava.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-joda" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-joda.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-json-org" version="2.9.8"/>
<unit id="com.fasterxml.jackson.datatype.jackson-datatype-json-org.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-base" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-base.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-json-provider" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-json-provider.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-xml-provider" version="2.9.8"/>
<unit id="com.fasterxml.jackson.jaxrs.jackson-jaxrs-xml-provider.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jaxb-annotations" version="2.9.8"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jaxb-annotations.source" version="2.9.8"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jsonSchema" version="2.9.8"/>
<unit id="com.fasterxml.jackson.module.jackson-module-jsonSchema.source" version="2.9.8"/>
<unit id="com.fasterxml.woodstox.woodstox-core" version="5.0.3"/>
<unit id="com.fasterxml.woodstox.woodstox-core.source" version="5.0.3"/>
<unit id="com.google.zxing.core" version="3.2.1"/>
@ -1152,8 +1152,6 @@
<unit id="org.atmosphere.runtime.source" version="2.5.0"/>
<unit id="org.cryptacular" version="1.2.2"/>
<unit id="org.cryptacular.source" version="1.2.2"/>
<unit id="org.eclipse.jdt.core" version="3.15.0.v20180905-0317"/>
<unit id="org.eclipse.jdt.core.source" version="3.15.0.v20180905-0317"/>
<unit id="org.eclipse.jetty.alpn.api" version="1.1.3.v20160715"/>
<unit id="org.eclipse.jetty.alpn.api.source" version="1.1.3.v20160715"/>
<unit id="org.eclipse.jetty.alpn.client" version="9.4.14.v20181114"/>
@ -1244,8 +1242,8 @@
<unit id="org.eclipse.jetty.websocket.servlet.source" version="9.4.14.v20181114"/>
<unit id="org.eclipse.jetty.xml" version="9.4.14.v20181114"/>
<unit id="org.eclipse.jetty.xml.source" version="9.4.14.v20181114"/>
<unit id="org.idempiere.org.conscrypt.openjdk-uber" version="1.4.0"/>
<unit id="org.idempiere.org.conscrypt.openjdk-uber.source" version="1.4.0"/>
<unit id="org.idempiere.org.conscrypt.openjdk-uber" version="1.4.2"/>
<unit id="org.idempiere.org.conscrypt.openjdk-uber.source" version="1.4.2"/>
<unit id="org.jfree.chart-osgi" version="1.0.19"/>
<unit id="org.jfree.jcommon-osgi" version="1.0.23"/>
<unit id="org.krysalis.barcode4j" version="2.1.0"/>
@ -1298,10 +1296,12 @@
<unit id="zkwebfragment" version="8.6.0.1"/>
<unit id="zkwebfragment.sources" version="8.6.0.1"/>
<unit id="zul" version="8.6.0.1"/>
<unit id="zul" version="8.6.0.1-patched"/>
<unit id="zul.sources" version="8.6.0.1"/>
<unit id="zul.sources" version="8.6.0.1-patched"/>
<unit id="zweb" version="8.6.0.1"/>
<unit id="zweb.sources" version="8.6.0.1"/>
<repository location="https://raw.githubusercontent.com/idempiere/binary.file/master/p2.maven/maven-p2-R20181229"/>
<repository location="https://raw.githubusercontent.com/idempiere/binary.file/master/p2.maven/maven-p2-R20190118"/>
</location>
</locations>
<targetJRE path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-11"/>