IDEMPIERE-1518 2Pack shoud not try to reduce column size (#143)

This commit is contained in:
Carlos Ruiz 2020-07-15 12:42:13 +02:00 committed by GitHub
parent 4afaed6140
commit fd475f0cac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 1 deletions

View File

@ -79,6 +79,14 @@ public class ColumnElementHandler extends AbstractElementHandler {
return; return;
} }
if ( !mColumn.is_new()
&& mColumn.is_ValueChanged(MColumn.COLUMNNAME_FieldLength)
&& mColumn.getFieldLength() < mColumn.get_ValueOldAsInt(MColumn.COLUMNNAME_FieldLength)
) {
// IDEMPIERE-1518 2Pack shoud not try to reduce column size
mColumn.setFieldLength(mColumn.get_ValueOldAsInt(MColumn.COLUMNNAME_FieldLength));
}
if (!mColumn.is_new() && !mColumn.is_Changed()) { if (!mColumn.is_new() && !mColumn.is_Changed()) {
boolean syncDatabase = "Y".equalsIgnoreCase(getStringValue(element, "IsSyncDatabase")); boolean syncDatabase = "Y".equalsIgnoreCase(getStringValue(element, "IsSyncDatabase"));
if (syncDatabase) { if (syncDatabase) {
@ -87,7 +95,7 @@ public class ColumnElementHandler extends AbstractElementHandler {
} }
return; return;
} }
X_AD_Package_Imp_Detail impDetail = createImportDetail(ctx, element.qName, X_AD_Column.Table_Name, X_AD_Column.Table_ID); X_AD_Package_Imp_Detail impDetail = createImportDetail(ctx, element.qName, X_AD_Column.Table_Name, X_AD_Column.Table_ID);
String action = null; String action = null;
if (!mColumn.is_new()) { if (!mColumn.is_new()) {