IDEMPIERE-3532 / fix better defaults - include also order and inout - add a default to IsPaid=N when paymentinfo is called from payment window
This commit is contained in:
parent
6950087449
commit
da15fe4de4
|
@ -7,12 +7,28 @@ UPDATE AD_InfoColumn SET DefaultValue='@C_BPartner_ID@',Updated=TO_DATE('2017-10
|
||||||
;
|
;
|
||||||
|
|
||||||
-- Oct 27, 2017 5:16:25 PM CEST
|
-- Oct 27, 2017 5:16:25 PM CEST
|
||||||
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT ''@IsSOTrx:Y@'' AS DefaultValue FROM DUAL',Updated=TO_DATE('2017-10-27 17:16:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200066
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_DATE('2017-10-27 17:16:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200066
|
||||||
;
|
;
|
||||||
|
|
||||||
-- Oct 27, 2017 5:17:29 PM CEST
|
-- Oct 27, 2017 5:17:29 PM CEST
|
||||||
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT ''@IsSOTrx:Y@'' AS DefaultValue FROM DUAL',Updated=TO_DATE('2017-10-27 17:17:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200085
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_DATE('2017-10-27 17:17:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200085
|
||||||
;
|
;
|
||||||
|
|
||||||
SELECT register_migration_script('201705041136_IDEMPIERE-3338.sql') FROM dual
|
-- Nov 8, 2017 11:04:30 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@C_BPartner_ID@',Updated=TO_DATE('2017-11-08 11:04:30','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200039
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:04:58 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_DATE('2017-11-08 11:04:58','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200051
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:05:07 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_DATE('2017-11-08 11:05:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200078
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:07:22 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT CASE ''@BaseTable_ID:0@'' WHEN ''335'' THEN ''N'' ELSE '''' END AS DefaultValue FROM DUAL',Updated=TO_DATE('2017-11-08 11:07:22','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200065
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201710271720_IDEMPIERE-3532.sql') FROM dual
|
||||||
;
|
;
|
||||||
|
|
|
@ -4,13 +4,28 @@ UPDATE AD_InfoColumn SET DefaultValue='@C_BPartner_ID@',Updated=TO_TIMESTAMP('20
|
||||||
;
|
;
|
||||||
|
|
||||||
-- Oct 27, 2017 5:16:25 PM CEST
|
-- Oct 27, 2017 5:16:25 PM CEST
|
||||||
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT ''@IsSOTrx:Y@'' AS DefaultValue FROM DUAL',Updated=TO_TIMESTAMP('2017-10-27 17:16:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200066
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_TIMESTAMP('2017-10-27 17:16:25','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200066
|
||||||
;
|
;
|
||||||
|
|
||||||
-- Oct 27, 2017 5:17:29 PM CEST
|
-- Oct 27, 2017 5:17:29 PM CEST
|
||||||
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT ''@IsSOTrx:Y@'' AS DefaultValue FROM DUAL',Updated=TO_TIMESTAMP('2017-10-27 17:17:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200085
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_TIMESTAMP('2017-10-27 17:17:29','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=0 WHERE AD_InfoColumn_ID=200085
|
||||||
;
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:04:30 AM CET
|
||||||
SELECT register_migration_script('201705041136_IDEMPIERE-3338.sql') FROM dual
|
UPDATE AD_InfoColumn SET DefaultValue='@C_BPartner_ID@',Updated=TO_TIMESTAMP('2017-11-08 11:04:30','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200039
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:04:58 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_TIMESTAMP('2017-11-08 11:04:58','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200051
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:05:07 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@IsSOTrx:Y@',Updated=TO_TIMESTAMP('2017-11-08 11:05:07','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200078
|
||||||
|
;
|
||||||
|
|
||||||
|
-- Nov 8, 2017 11:07:22 AM CET
|
||||||
|
UPDATE AD_InfoColumn SET DefaultValue='@SQL=SELECT CASE ''@BaseTable_ID:0@'' WHEN ''335'' THEN ''N'' ELSE '''' END AS DefaultValue FROM DUAL',Updated=TO_TIMESTAMP('2017-11-08 11:07:22','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200065
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201710271720_IDEMPIERE-3532.sql') FROM dual
|
||||||
;
|
;
|
||||||
|
|
|
@ -3,10 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.adempiere.webui.info;
|
package org.adempiere.webui.info;
|
||||||
|
|
||||||
import org.adempiere.webui.editor.WEditor;
|
|
||||||
import org.compiere.util.Env;
|
|
||||||
import org.compiere.util.Util;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author hengsin
|
* @author hengsin
|
||||||
*
|
*
|
||||||
|
@ -15,7 +11,7 @@ public class InfoInOutWindow extends InfoWindow {
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 1687215125029008351L;
|
private static final long serialVersionUID = 3027121642718090785L;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param WindowNo
|
* @param WindowNo
|
||||||
|
@ -50,26 +46,4 @@ public class InfoInOutWindow extends InfoWindow {
|
||||||
whereClause, AD_InfoWindow_ID, lookup);
|
whereClause, AD_InfoWindow_ID, lookup);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* {@inheritDoc}
|
|
||||||
* set value of checkbox isSoTrx
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
protected void initParameters() {
|
|
||||||
String isSOTrx = Env.getContext(Env.getCtx(), p_WindowNo, "IsSOTrx");
|
|
||||||
if (!isLookup() && Util.isEmpty(isSOTrx)) {
|
|
||||||
isSOTrx = "Y";
|
|
||||||
}
|
|
||||||
|
|
||||||
// set value of isSoTrx checkbox by env
|
|
||||||
if (!Util.isEmpty(isSOTrx)) {
|
|
||||||
for (WEditor editor : editors) {
|
|
||||||
if (editor.getGridField() != null && editor.getGridField().getColumnName().equals("IsSOTrx")) {
|
|
||||||
editor.setValue(isSOTrx);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,10 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.adempiere.webui.info;
|
package org.adempiere.webui.info;
|
||||||
|
|
||||||
import org.adempiere.webui.editor.WEditor;
|
|
||||||
import org.compiere.util.Env;
|
|
||||||
import org.compiere.util.Util;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author hengsin
|
* @author hengsin
|
||||||
*
|
*
|
||||||
|
@ -15,7 +11,7 @@ public class InfoOrderWindow extends InfoWindow {
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = -558954356627208290L;
|
private static final long serialVersionUID = 1241927188305227636L;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param WindowNo
|
* @param WindowNo
|
||||||
|
@ -50,34 +46,4 @@ public class InfoOrderWindow extends InfoWindow {
|
||||||
whereClause, AD_InfoWindow_ID, lookup);
|
whereClause, AD_InfoWindow_ID, lookup);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* {@inheritDoc}
|
|
||||||
*/
|
|
||||||
@Override
|
|
||||||
protected void initParameters() {
|
|
||||||
String isSOTrx = Env.getContext(Env.getCtx(), p_WindowNo, "IsSOTrx");
|
|
||||||
if (!isLookup() && Util.isEmpty(isSOTrx)) {
|
|
||||||
isSOTrx = "Y";
|
|
||||||
}
|
|
||||||
|
|
||||||
//Set Defaults
|
|
||||||
String bp = Env.getContext(Env.getCtx(), p_WindowNo, "C_BPartner_ID");
|
|
||||||
if (!Util.isEmpty(bp)) {
|
|
||||||
for (WEditor editor : editors) {
|
|
||||||
if (editor.getGridField() != null && editor.getGridField().getColumnName().equals("C_BPartner_ID")) {
|
|
||||||
editor.setValue(new Integer(bp));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!Util.isEmpty(isSOTrx)) {
|
|
||||||
for (WEditor editor : editors) {
|
|
||||||
if (editor.getGridField() != null && editor.getGridField().getColumnName().equals("IsSOTrx")) {
|
|
||||||
editor.setValue(isSOTrx);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue