hg merge release-5.1 (merge release5.1 into default)

This commit is contained in:
Carlos Ruiz 2018-06-06 11:16:36 +02:00
commit a32055713e
12 changed files with 219 additions and 37 deletions

View File

@ -0,0 +1,11 @@
SET SQLBLANKLINES ON
SET DEFINE OFF
-- IDEMPIERE-3651 Report Column Set=>Report Column=>User Element List1 not displaying User1_ID values
-- Jun 4, 2018 12:51:33 PM CEST
UPDATE AD_Column SET AD_Val_Rule_ID=258,Updated=TO_DATE('2018-06-04 12:51:33','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=6026
;
SELECT register_migration_script('201806041252_IDEMPIERE-3651.sql') FROM dual
;

View File

@ -0,0 +1,68 @@
-- Mar 5, 2013 9:52:39 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:52:39','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=327
;
-- Mar 5, 2013 9:52:55 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:52:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=323
;
-- Mar 5, 2013 9:53:10 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:53:10','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=337
;
-- Mar 5, 2013 9:53:36 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:53:36','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=331
;
-- Mar 5, 2013 9:53:52 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:53:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=419
;
-- Mar 5, 2013 9:54:09 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:54:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=53112
;
-- Mar 5, 2013 9:54:40 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:54:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=210
;
-- Mar 5, 2013 9:54:50 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:54:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=324
;
-- Mar 5, 2013 9:56:01 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:56:01','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=422
;
-- Mar 5, 2013 9:56:14 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:56:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=333
;
-- Mar 5, 2013 9:56:27 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:56:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=53077
;
-- Mar 5, 2013 9:56:44 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:56:44','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=209
;
-- Mar 5, 2013 9:57:04 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_DATE('2013-03-05 09:57:04','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=334
;
SELECT register_migration_script('201806061111_IDEMPIERE-585.sql') FROM dual
;

View File

@ -0,0 +1,8 @@
-- IDEMPIERE-3651 Report Column Set=>Report Column=>User Element List1 not displaying User1_ID values
-- Jun 4, 2018 12:51:33 PM CEST
UPDATE AD_Column SET AD_Val_Rule_ID=258,Updated=TO_TIMESTAMP('2018-06-04 12:51:33','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Column_ID=6026
;
SELECT register_migration_script('201806041252_IDEMPIERE-3651.sql') FROM dual
;

View File

@ -0,0 +1,68 @@
-- Mar 5, 2013 9:52:39 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:52:39','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=327
;
-- Mar 5, 2013 9:52:55 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:52:55','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=323
;
-- Mar 5, 2013 9:53:10 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:53:10','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=337
;
-- Mar 5, 2013 9:53:36 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:53:36','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=331
;
-- Mar 5, 2013 9:53:52 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:53:52','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=419
;
-- Mar 5, 2013 9:54:09 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:54:09','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=53112
;
-- Mar 5, 2013 9:54:40 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:54:40','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=210
;
-- Mar 5, 2013 9:54:50 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:54:50','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=324
;
-- Mar 5, 2013 9:56:01 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:56:01','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=422
;
-- Mar 5, 2013 9:56:14 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:56:14','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=333
;
-- Mar 5, 2013 9:56:27 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:56:27','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=53077
;
-- Mar 5, 2013 9:56:44 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:56:44','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=209
;
-- Mar 5, 2013 9:57:04 AM CET
-- IDEMPIERE 585
UPDATE AD_Tab SET IsInsertRecord='N',Updated=TO_TIMESTAMP('2013-03-05 09:57:04','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Tab_ID=334
;
SELECT register_migration_script('201806061111_IDEMPIERE-585.sql') FROM dual
;

View File

@ -93,30 +93,36 @@ public class MStatusLine extends X_AD_StatusLine
}
String sql = ""
+ "SELECT AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn "
+ "WHERE IsActive = 'Y' "
+ " AND IsStatusLine = 'Y' "
+ " AND AD_Window_ID = ? "
+ " AND AD_Tab_ID = ?";
+ "SELECT slu.AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn slu "
+ "JOIN AD_StatusLine sl ON (sl.AD_StatusLine_ID = slu.AD_StatusLine_ID) "
+ "WHERE slu.IsActive = 'Y' "
+ " AND sl.IsActive = 'Y' "
+ " AND slu.IsStatusLine = 'Y' "
+ " AND slu.AD_Window_ID = ? "
+ " AND slu.AD_Tab_ID = ?";
int slid = DB.getSQLValueEx(null, sql, window_ID, tab_ID);
if (slid <= 0) {
sql = ""
+ "SELECT AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn "
+ "WHERE IsActive = 'Y' "
+ " AND IsStatusLine = 'Y' "
+ " AND AD_Window_ID = ? "
+ " AND AD_Tab_ID IS NULL";
+ "SELECT slu.AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn slu "
+ "JOIN AD_StatusLine sl ON (sl.AD_StatusLine_ID = slu.AD_StatusLine_ID) "
+ "WHERE slu.IsActive = 'Y' "
+ " AND sl.IsActive = 'Y' "
+ " AND slu.IsStatusLine = 'Y' "
+ " AND slu.AD_Window_ID = ? "
+ " AND slu.AD_Tab_ID IS NULL";
slid = DB.getSQLValueEx(null, sql, window_ID);
}
if (slid <= 0) {
sql = ""
+ "SELECT AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn "
+ "WHERE IsActive = 'Y' "
+ " AND IsStatusLine = 'Y' "
+ " AND AD_Table_ID = ?";
+ "SELECT slu.AD_StatusLine_ID "
+ "FROM AD_StatusLineUsedIn slu "
+ "JOIN AD_StatusLine sl ON (sl.AD_StatusLine_ID = slu.AD_StatusLine_ID) "
+ "WHERE slu.IsActive = 'Y' "
+ " AND sl.IsActive = 'Y' "
+ " AND slu.IsStatusLine = 'Y' "
+ " AND slu.AD_Table_ID = ?";
slid = DB.getSQLValueEx(null, sql, table_ID);
}
if (slid > 0) {
@ -145,12 +151,14 @@ public class MStatusLine extends X_AD_StatusLine
}
final String sql = ""
+ "SELECT DISTINCT AD_StatusLine_ID, SeqNo "
+ "FROM AD_StatusLineUsedIn "
+ "WHERE IsActive = 'Y' "
+ " AND IsStatusLine = 'N' "
+ " AND (AD_Table_ID = ? OR (AD_Window_ID=? AND AD_Tab_ID=?) OR (AD_Window_ID=? AND AD_Tab_ID IS NULL)) "
+ "ORDER BY SeqNo";
+ "SELECT DISTINCT slu.AD_StatusLine_ID, slu.SeqNo "
+ "FROM AD_StatusLineUsedIn slu "
+ "JOIN AD_StatusLine sl ON (sl.AD_StatusLine_ID = slu.AD_StatusLine_ID) "
+ "WHERE slu.IsActive = 'Y' "
+ " AND sl.IsActive = 'Y' "
+ " AND slu.IsStatusLine = 'N' "
+ " AND (slu.AD_Table_ID = ? OR (slu.AD_Window_ID=? AND slu.AD_Tab_ID=?) OR (slu.AD_Window_ID=? AND slu.AD_Tab_ID IS NULL)) "
+ "ORDER BY slu.SeqNo";
int[] wlids = DB.getIDsEx(null, sql, table_ID, window_ID, tab_ID, window_ID);
if (wlids.length > 0) {
ArrayList<MStatusLine> list = new ArrayList<MStatusLine>();

View File

@ -186,7 +186,8 @@ public class MWFNode extends X_AD_WF_Node
*/
private void loadNext()
{
m_next = new Query(getCtx(), MWFNodeNext.Table_Name, "AD_WF_Node_ID=?", get_TrxName())
m_next = new Query(getCtx(), MWFNodeNext.Table_Name, "AD_WF_NodeNext.AD_WF_Node_ID=?", get_TrxName())
.addJoinClause(" JOIN AD_WF_Node ON (AD_WF_Node.AD_WF_Node_ID=AD_WF_NodeNext.AD_WF_Next_ID AND AD_WF_Node.IsActive='Y')")
.setParameters(new Object[]{get_ID()})
.setOnlyActiveRecords(true)
.setOrderBy(MWFNodeNext.COLUMNNAME_SeqNo)

View File

@ -435,7 +435,7 @@ public class MWorkflow extends X_AD_Workflow
for (int i = 0; i < nexts.length; i++)
{
MWFNode child = getNode (nexts[i].getAD_WF_Next_ID());
if (!child.isActive())
if (child == null || !child.isActive())
continue;
if (child.getAD_Client_ID() == 0
|| child.getAD_Client_ID() == AD_Client_ID)

View File

@ -699,8 +699,9 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
.append(mTab.getTableName());
if (where.length() > 0)
sql.append(" WHERE ").append(where);
// Does not consider security
int no = DB.getSQLValue(null, sql.toString());
String finalSQL = MRole.getDefault().addAccessSQL(sql.toString(),
mTab.getTableName(), MRole.SQL_NOTQUALIFIED, MRole.SQL_RO);
int no = DB.getSQLValue(null, finalSQL.toString());
//
require = MRole.getDefault().isQueryRequire(no);
}

View File

@ -40,7 +40,8 @@ public class Listbox extends org.zkoss.zul.Listbox implements EventListener<Even
/**
*
*/
private static final long serialVersionUID = 2102597724705225997L;
private static final long serialVersionUID = -3713350125429939476L;
private List<EventListener<Event>> doubleClickListeners = new ArrayList<EventListener<Event>>();
private List<EventListener<Event>> onDropListeners = new ArrayList<EventListener<Event>>();
private boolean draggable;
@ -333,5 +334,17 @@ public class Listbox extends org.zkoss.zul.Listbox implements EventListener<Even
items.append("]");
return items.toString();
}
/**
* Get selected item for the list box based on the value of list item
* @return Value of selected ListItem
*/
public Object getValue()
{
ListItem item = getSelectedItem();
return item.getValue();
}
}

View File

@ -561,7 +561,7 @@ public class WSearchEditor extends WEditor implements ContextMenuListener, Value
}
protected void showInfoPanel(final InfoPanel ip) {
public void showInfoPanel(final InfoPanel ip) {
ip.setVisible(true);
ip.setStyle("border: 2px");
ip.setClosable(true);

View File

@ -2,10 +2,14 @@
@Echo on
cd %~dp0
set DESTINATION=%cd%
@echo %DESTINATION%
@echo %1%
@set DESTINATION=%cd%
@echo DESTINATION = %DESTINATION%
@set REPO=%1%
@echo REPOSITORY = %REPO%
@set PACK=%2%
@echo PACKAGES = %PACK%
FOR %%c in (plugins\org.eclipse.equinox.launcher_1.*.jar) DO set JARFILE=%%c
java -Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient4 -Djava.net.preferIPv4Stack=true -jar %JARFILE% -install director -configuration director/configuration -application org.eclipse.equinox.p2.director -consoleLog -profileProperties org.eclipse.update.install.features=true -destination %DESTINATION% -repository %1% -u %2%
java -Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient4 -Djava.net.preferIPv4Stack=true -jar %JARFILE% -install director -configuration director/configuration -application org.eclipse.equinox.p2.director -consoleLog -profileProperties org.eclipse.update.install.features=true -destination %DESTINATION% -repository %1% -i %2%
@FOR %%c in (plugins\org.eclipse.equinox.launcher_1.*.jar) DO set JARFILE=%%c
@echo JARFILE = %JARFILE%
java -Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient4 -Djava.net.preferIPv4Stack=true -jar %JARFILE% -install director -configuration director/configuration -application org.eclipse.equinox.p2.director -consoleLog -profileProperties org.eclipse.update.install.features=true -destination %DESTINATION% -repository %REPO% -u %PACK%
java -Dorg.eclipse.ecf.provider.filetransfer.excludeContributors=org.eclipse.ecf.provider.filetransfer.httpclient4 -Djava.net.preferIPv4Stack=true -jar %JARFILE% -install director -configuration director/configuration -application org.eclipse.equinox.p2.director -consoleLog -profileProperties org.eclipse.update.install.features=true -destination %DESTINATION% -repository %REPO% -i %PACK%

View File

@ -23,7 +23,7 @@ if exist jettyhome\etc\jetty-selector.xml (
copy jettyhome\etc\jetty-selector.xml jetty-selector.xml.sav
)
@call %DESTINATION%\update-prd %1% org.adempiere.server.product,org.idempiere.fitnesse.feature.feature.group
@call %DESTINATION%\update-prd %1% "org.adempiere.server.product,org.idempiere.fitnesse.feature.group"
copy idempiere.ini.sav idempiere.ini