Update to 3.0PR17Q2 3.0PR17Q2
authorRM packaging bot <staff.rm@openbravo.com>
Thu, 25 May 2017 06:12:59 +0000
changeset 734 2bda32ef2d4a
parent 731 de8379bb0033
child 735 56a556ff885f
Update to 3.0PR17Q2
java/reference/java.japi.gz
js/utils.js.details
model/modules/org.openbravo.advpaymentmngt/src-db/database/model/functions/APRM_GEN_PAYMENTSCHEDULE_INV.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_COLUMN.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_FIELD.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MESSAGE.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_PREFERENCE.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_REFERENCE.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml
model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUISEL_SELECTOR.xml
model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER.xml
model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER_VALUE.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_COLUMN.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_DATASET_TABLE.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_ELEMENT.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_FIELD.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MESSAGE.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/OBSERDS_DATASOURCE.xml
model/modules/org.openbravo.client.application/src-db/database/sourcedata/OBSERDS_DATASOURCE_FIELD.xml
model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.myob/src-db/database/model/modifiedTables/OBUIAPP_PARAMETER.xml
model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.querylist/src-db/database/model/tables/OBCQL_WIDGET_QUERY.xml
model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBCQL_WIDGET_QUERY.xml
model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml
model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_PREFERENCE.xml
model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_PREFERENCE.xml
model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.userinterface.selector/src-db/database/model/tables/OBUISEL_SELECTOR_TRL.xml
model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE.xml
model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml
model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_MERGE.xml
model/src-db/database/model/excludeFilter.xml
model/src-db/database/model/functions/C_COMMISSION_PROCESS.xml
model/src-db/database/model/functions/C_CONVERT_DOC_CURRENCY.xml
model/src-db/database/model/functions/C_GET_NET_AMOUNT_FROM_GROSS.xml
model/src-db/database/model/functions/C_GET_NET_PRICE_FROM_GROSS.xml
model/src-db/database/model/functions/C_INVOICELINETAX_INSERT.xml
model/src-db/database/model/functions/C_INVOICETAX_ADJUSTMENT.xml
model/src-db/database/model/functions/C_INVOICE_POST.xml
model/src-db/database/model/functions/C_ORDERLINETAX_INSERT.xml
model/src-db/database/model/functions/C_ORDERTAX_ADJUSTMENT.xml
model/src-db/database/model/functions/C_ORDER_POST1.xml
model/src-db/database/model/functions/FIN_AGING_GETDOCNO.xml
model/src-db/database/model/functions/FIN_AGING_INVOICECURRENCY_RATE.xml
model/src-db/database/model/functions/FIN_AGING_ISDOUBTFULTDEBT.xml
model/src-db/database/model/functions/FIN_AGING_PAYMENTCURRENCY_RATE.xml
model/src-db/database/model/functions/MA_STANDARD_COST.xml
model/src-db/database/model/functions/MRP_PURCHASEORDER.xml
model/src-db/database/model/functions/M_EXPLODEBOMNOTSTOCK.xml
model/src-db/database/model/functions/M_GET_PARETO_ABC.xml
model/src-db/database/model/functions/M_INOUT_CREATEINVOICE.xml
model/src-db/database/model/functions/M_INOUT_POST.xml
model/src-db/database/model/functions/M_PROMOTION_ADJUSTMENT.xml
model/src-db/database/model/functions/M_REQUISITION_CREATEPO.xml
model/src-db/database/model/functions/M_UPDATE_INVENTORY.xml
model/src-db/database/model/postscript-Oracle.sql
model/src-db/database/model/postscript-PostgreSql.sql
model/src-db/database/model/prescript-Oracle.sql
model/src-db/database/model/prescript-PostgreSql.sql
model/src-db/database/model/tables/AD_COLUMN.xml
model/src-db/database/model/tables/AD_MODEL_OBJECT.xml
model/src-db/database/model/tables/AD_ORGMODULE.xml
model/src-db/database/model/tables/AD_PROCESS_RUN.xml
model/src-db/database/model/tables/AD_TAB.xml
model/src-db/database/model/tables/AD_USER.xml
model/src-db/database/model/tables/A_AMORTIZATIONLINE.xml
model/src-db/database/model/tables/A_ASSET.xml
model/src-db/database/model/tables/C_ACCTSCHEMA_PROCESS.xml
model/src-db/database/model/tables/C_BPARTNER.xml
model/src-db/database/model/tables/C_CITY.xml
model/src-db/database/model/tables/C_CONVERSION_RATE_DOCUMENT.xml
model/src-db/database/model/tables/C_INVOICE.xml
model/src-db/database/model/tables/C_INVOICELINE.xml
model/src-db/database/model/tables/C_ORDER.xml
model/src-db/database/model/tables/C_ORDERLINE.xml
model/src-db/database/model/tables/C_ORDERLINETAX.xml
model/src-db/database/model/tables/C_ORDERTAX.xml
model/src-db/database/model/tables/C_POC_DOCTYPE_TEMPLATE.xml
model/src-db/database/model/tables/C_POC_EMAILDEFINITION.xml
model/src-db/database/model/tables/C_TAXREGISTER.xml
model/src-db/database/model/tables/C_TAXREGISTERLINE.xml
model/src-db/database/model/tables/C_TAXREGISTER_TYPE_LINES.xml
model/src-db/database/model/tables/FACT_ACCT.xml
model/src-db/database/model/tables/FIN_DOUBTFUL_DEBT.xml
model/src-db/database/model/tables/FIN_ORIG_PAYMENT_SCHEDULE.xml
model/src-db/database/model/tables/FIN_ORIG_PAYM_SCHEDDETAIL.xml
model/src-db/database/model/tables/FIN_PAYMENT.xml
model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULE.xml
model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULEDETAIL.xml
model/src-db/database/model/tables/GL_JOURNAL.xml
model/src-db/database/model/tables/MA_MAINTENANCE.xml
model/src-db/database/model/tables/MA_MEASURE_GROUP.xml
model/src-db/database/model/tables/MA_PROCESS.xml
model/src-db/database/model/tables/MA_WEINCIDENCE.xml
model/src-db/database/model/tables/MRP_RUN_PRODUCTIONLINE.xml
model/src-db/database/model/tables/M_COSTADJUSTMENTLINE.xml
model/src-db/database/model/tables/M_COSTING.xml
model/src-db/database/model/tables/M_INOUT.xml
model/src-db/database/model/tables/M_LANDEDCOST.xml
model/src-db/database/model/tables/M_LC_COST.xml
model/src-db/database/model/tables/M_LC_MATCHED.xml
model/src-db/database/model/tables/M_LC_RECEIPT.xml
model/src-db/database/model/tables/M_LC_RECEIPTLINE_AMT.xml
model/src-db/database/model/tables/M_LOCATOR.xml
model/src-db/database/model/tables/M_MATCHPO.xml
model/src-db/database/model/tables/M_PRODUCT.xml
model/src-db/database/model/tables/M_RAPPEL_BPARTNER.xml
model/src-db/database/model/tables/M_RAPPEL_INVOICE.xml
model/src-db/database/model/tables/M_RAPPEL_PRODUCT.xml
model/src-db/database/model/tables/M_RAPPEL_PRODUCTCATEGORY.xml
model/src-db/database/model/tables/M_RAPPEL_SCALE.xml
model/src-db/database/model/tables/M_RESERVATION.xml
model/src-db/database/model/tables/M_RESERVATION_STOCK.xml
model/src-db/database/model/tables/M_STOCK_AUX.xml
model/src-db/database/model/tables/M_STOCK_VALUATION.xml
model/src-db/database/model/tables/M_TRANSACTION.xml
model/src-db/database/model/tables/M_TRANSACTION_COST.xml
model/src-db/database/model/tables/M_VALUED_STOCK_AGG.xml
model/src-db/database/model/tables/M_WAREHOUSE_SHIPPER.xml
model/src-db/database/model/tables/S_TIMEEXPENSELINE.xml
model/src-db/database/model/triggers/C_INVLINE_CHK_RESTRICTIONS_TRG.xml
model/src-db/database/model/triggers/C_INVOICELINETAX_TRG.xml
model/src-db/database/model/triggers/C_INVOICELINE_BEFORE_TRG.xml
model/src-db/database/model/triggers/C_INVOICELINE_TRG2.xml
model/src-db/database/model/triggers/C_ORDERLINETAX_TRG.xml
model/src-db/database/model/triggers/C_ORDERLINE_TRG.xml
model/src-db/database/model/triggers/C_ORDERLINE_TRG2.xml
model/src-db/database/model/triggers/M_PRODUCT_CATEGORY_TRG.xml
model/src-db/database/model/views/C_INVOICETAX_CASHVAT_V.xml
model/src-db/database/model/views/C_INVOICE_CANDIDATE_V.xml
model/src-db/database/sourcedata/AD_CALLOUT.xml
model/src-db/database/sourcedata/AD_COLUMN.xml
model/src-db/database/sourcedata/AD_ELEMENT.xml
model/src-db/database/sourcedata/AD_FIELD.xml
model/src-db/database/sourcedata/AD_MENU.xml
model/src-db/database/sourcedata/AD_MESSAGE.xml
model/src-db/database/sourcedata/AD_MODEL_OBJECT.xml
model/src-db/database/sourcedata/AD_MODEL_OBJECT_MAPPING.xml
model/src-db/database/sourcedata/AD_MODEL_OBJECT_PARA.xml
model/src-db/database/sourcedata/AD_MODULE.xml
model/src-db/database/sourcedata/AD_PREFERENCE.xml
model/src-db/database/sourcedata/AD_REFERENCE.xml
model/src-db/database/sourcedata/AD_REF_LIST.xml
model/src-db/database/sourcedata/AD_TEXTINTERFACES.xml
model/src-db/database/sourcedata/AD_TREENODE.xml
model/src-db/database/sourcedata/AD_VAL_RULE.xml
model/src-db/database/sourcedata/AD_WINDOW.xml
model/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml
model/src-db/database/sourcedata/OBUIAPP_PROCESS.xml
model/src-db/database/sourcedata/OBUIAPP_REPORT.xml
model/src-db/database/sourcedata/OBUISEL_SELECTOR.xml
model/src-db/database/sourcedata/OBUISEL_SELECTOR_FIELD.xml
Binary file java/reference/java.japi.gz has changed
--- a/js/utils.js.details	Mon May 15 08:34:27 2017 +0200
+++ b/js/utils.js.details	Thu May 25 06:12:59 2017 +0000
@@ -137,6 +137,13 @@
 FUNCTION: menuShowHide
 FUNCTION: menuShow
 FUNCTION: menuHide
+FUNCTION: menuExpand
+FUNCTION: menuCollapse
+FUNCTION: menuExpandCollapse
+FUNCTION: getMenuExpandCollapse_status
+FUNCTION: menuUserOptions
+FUNCTION: menuQuit
+FUNCTION: menuAlerts
 FUNCTION: isVisibleElement
 FUNCTION: executeWindowButton
 FUNCTION: executeMenuButton
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/model/functions/APRM_GEN_PAYMENTSCHEDULE_INV.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/model/functions/APRM_GEN_PAYMENTSCHEDULE_INV.xml	Thu May 25 06:12:59 2017 +0000
@@ -16,7 +16,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2010-2016 Openbravo SLU
+* All portions are Copyright (C) 2010-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -1155,6 +1155,7 @@
   ELSIF (p_docaction = 'RC') THEN
     DECLARE
       v_count NUMBER;
+      v_prepaymentamt NUMBER;
     BEGIN
       v_delete_paymentplan := TRUE;
       SELECT c_invoice_id INTO v_reversalinvoice_id
@@ -1180,6 +1181,12 @@
       IF (v_count <> 0) THEN
         v_delete_paymentplan := FALSE;
       END IF;
+      SELECT prepaymentamt INTO v_prepaymentamt
+      FROM c_invoice
+      WHERE c_invoice_id = p_record_id;
+      IF (v_prepaymentamt <> 0) THEN
+        v_delete_paymentplan := FALSE;
+      END IF;
     END;
   END IF;
 
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_COLUMN.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_COLUMN.xml	Thu May 25 06:12:59 2017 +0000
@@ -11335,8 +11335,7 @@
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISKEY><![CDATA[N]]></ISKEY>
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISPARENT><![CDATA[N]]></ISPARENT>
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISMANDATORY><![CDATA[N]]></ISMANDATORY>
-<!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
-<!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <READONLYLOGIC><![CDATA['Y']]></READONLYLOGIC>
+<!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISUPDATEABLE><![CDATA[N]]></ISUPDATEABLE>
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <SEQNO><![CDATA[410]]></SEQNO>
 <!--D5B4BD05344C4B44AB7ED2F6CF9C86F6-->  <ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_FIELD.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_FIELD.xml	Thu May 25 06:12:59 2017 +0000
@@ -22505,7 +22505,7 @@
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <DISPLAYLOGIC><![CDATA[@EM_Aprm_Finacc_Trans_Origin@!'']]></DISPLAYLOGIC>
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <DISPLAYLENGTH><![CDATA[32]]></DISPLAYLENGTH>
-<!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
+<!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <ISREADONLY><![CDATA[Y]]></ISREADONLY>
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <SEQNO><![CDATA[80]]></SEQNO>
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--FBEA6835AE0543FE8821B907BD5D0F0B-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MESSAGE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MESSAGE.xml	Thu May 25 06:12:59 2017 +0000
@@ -679,7 +679,7 @@
 <!--712C841E501642B881A998CCAC13E420-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--712C841E501642B881A998CCAC13E420-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--712C841E501642B881A998CCAC13E420-->  <VALUE><![CDATA[APRM_CreditWithNegativeAmt]]></VALUE>
-<!--712C841E501642B881A998CCAC13E420-->  <MSGTEXT><![CDATA[It is not necessary to use credit for this payment: Actual Payment is greater than Expected Payment.]]></MSGTEXT>
+<!--712C841E501642B881A998CCAC13E420-->  <MSGTEXT><![CDATA[It is not possible to use credit in negative payments. Please, unselect credit records.]]></MSGTEXT>
 <!--712C841E501642B881A998CCAC13E420-->  <MSGTYPE><![CDATA[E]]></MSGTYPE>
 <!--712C841E501642B881A998CCAC13E420-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
 <!--712C841E501642B881A998CCAC13E420-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <NAME><![CDATA[Advanced Payables and Receivables Mngmt]]></NAME>
-<!--A918E3331C404B889D69AA9BFAFB23AC-->  <VERSION><![CDATA[3.0.31087]]></VERSION>
+<!--A918E3331C404B889D69AA9BFAFB23AC-->  <VERSION><![CDATA[3.0.31787]]></VERSION>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <DESCRIPTION><![CDATA[Managing your finances with an ERP does not have to be difficult. Enjoy a radically improved user experience that combines the power of an enterprise grade financial application with the simplicity and ease of a web 2.0 personal accounting service.]]></DESCRIPTION>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <HELP><![CDATA[Advanced Payables and Receivables Management simplifies and automates the business processes around the management of financial accounts, from the receipt and issue of payment, to the reconciliation of those events with bank statements.
 If you would like to help shape this module you are welcome to take part in the forum discussions or register feature requests or issues in the corresponding (Forum and Bug Tracking) sections in the Advanced Payables and Receivable project in the OB Forge.]]></HELP>
@@ -25,7 +25,7 @@
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <UPDATEINFO><![CDATA[Fixed issue with document sequence numbers reset in case of applying dataset second time.
 Fixed issue 15305.]]></UPDATEINFO>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <REFERENCEDATAINFO><![CDATA[Document types and default algorithm for bank statement auto matching]]></REFERENCEDATAINFO>
-<!--A918E3331C404B889D69AA9BFAFB23AC-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--A918E3331C404B889D69AA9BFAFB23AC-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--A918E3331C404B889D69AA9BFAFB23AC-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--A918E3331C404B889D69AA9BFAFB23AC--></AD_MODULE>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <AD_DEPENDENT_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_DEPENDENT_MODULE_ID>
-<!--89326AE95DAD449D85DFAB2C5B1C6683-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--89326AE95DAD449D85DFAB2C5B1C6683-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Selector]]></DEPENDANT_MODULE_NAME>
 <!--89326AE95DAD449D85DFAB2C5B1C6683-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--B97FC854C6DD41E692161585645A900F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--B97FC854C6DD41E692161585645A900F-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
 <!--B97FC854C6DD41E692161585645A900F-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--B97FC854C6DD41E692161585645A900F-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--B97FC854C6DD41E692161585645A900F-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--B97FC854C6DD41E692161585645A900F-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--B97FC854C6DD41E692161585645A900F-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--B97FC854C6DD41E692161585645A900F-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_PREFERENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_PREFERENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -55,6 +55,61 @@
 <!--9B4A5EB695FEA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
 <!--9B4A5EB695FEA841E040A8C0E1077381--></AD_PREFERENCE>
 
+<!--9B4A5EB69751A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB69751A841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcess3C4A5FB206B74C3CA9FE20116FCA0464]]></ATTRIBUTE>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB69751A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--9B4A5EB69751A841E040A8C0E1077381--></AD_PREFERENCE>
+
+<!--9B4A5EB69752A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB69752A841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcess4A059E4F79294640AD37B1B718C56E5D]]></ATTRIBUTE>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB69752A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--9B4A5EB69752A841E040A8C0E1077381--></AD_PREFERENCE>
+
+<!--9B4A5EB69756A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB69756A841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcessBBA11D1A061346459AF6148920FE6629]]></ATTRIBUTE>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB69756A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--9B4A5EB69756A841E040A8C0E1077381--></AD_PREFERENCE>
+
+<!--9B4A5EB69758A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB69758A841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcessD5B90B539C254B959045EDCA1DC99BDF]]></ATTRIBUTE>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB69758A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--9B4A5EB69758A841E040A8C0E1077381--></AD_PREFERENCE>
+
+<!--9B4A5EB6975CA841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB6975CA841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcessE54287EE357C493EB127DC3BA1758751]]></ATTRIBUTE>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB6975CA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--9B4A5EB6975CA841E040A8C0E1077381--></AD_PREFERENCE>
+
 <!--C2250516BAB0443AA56D758F10186E09--><AD_PREFERENCE>
 <!--C2250516BAB0443AA56D758F10186E09-->  <AD_PREFERENCE_ID><![CDATA[C2250516BAB0443AA56D758F10186E09]]></AD_PREFERENCE_ID>
 <!--C2250516BAB0443AA56D758F10186E09-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_REFERENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/AD_REFERENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -349,6 +349,18 @@
 <!--C20E5E22588E40E5B8CC6D80ED3015C5-->  <ISVALUEDISPLAYED><![CDATA[N]]></ISVALUEDISPLAYED>
 <!--C20E5E22588E40E5B8CC6D80ED3015C5--></AD_REFERENCE>
 
+<!--C4A74AE591F04D9A9CB859CC67F61340--><AD_REFERENCE>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <AD_REFERENCE_ID><![CDATA[C4A74AE591F04D9A9CB859CC67F61340]]></AD_REFERENCE_ID>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <NAME><![CDATA[Financial Transaction Selector]]></NAME>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <ISBASEREFERENCE><![CDATA[N]]></ISBASEREFERENCE>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <PARENTREFERENCE_ID><![CDATA[95E2A8B50A254B2AAE6774B8C2F28120]]></PARENTREFERENCE_ID>
+<!--C4A74AE591F04D9A9CB859CC67F61340-->  <ISVALUEDISPLAYED><![CDATA[N]]></ISVALUEDISPLAYED>
+<!--C4A74AE591F04D9A9CB859CC67F61340--></AD_REFERENCE>
+
 <!--D9B6068A6D3E4B7487470E7D2F033A54--><AD_REFERENCE>
 <!--D9B6068A6D3E4B7487470E7D2F033A54-->  <AD_REFERENCE_ID><![CDATA[D9B6068A6D3E4B7487470E7D2F033A54]]></AD_REFERENCE_ID>
 <!--D9B6068A6D3E4B7487470E7D2F033A54-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml	Thu May 25 06:12:59 2017 +0000
@@ -1036,6 +1036,7 @@
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <STARTINNEWLINE><![CDATA[N]]></STARTINNEWLINE>
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <AD_FIELDGROUP_ID><![CDATA[612BAE7A8D3E4170936F79A760FCF94C]]></AD_FIELDGROUP_ID>
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <READONLYLOGIC><![CDATA[@trxtype@='BPW']]></READONLYLOGIC>
+<!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <ONCHANGEFUNCTION><![CDATA[OB.APRM.AddTransaction.amtOnChangeFunction]]></ONCHANGEFUNCTION>
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <DISPLAYEDROWS><![CDATA[5]]></DISPLAYEDROWS>
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <DISPLAYTITLE><![CDATA[Y]]></DISPLAYTITLE>
 <!--7B2AE9099ECB4CE9B80C665D7662FA03-->  <ATT_SHOWINDESCRIPTION><![CDATA[N]]></ATT_SHOWINDESCRIPTION>
@@ -1625,6 +1626,7 @@
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <STARTINNEWLINE><![CDATA[N]]></STARTINNEWLINE>
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <AD_FIELDGROUP_ID><![CDATA[612BAE7A8D3E4170936F79A760FCF94C]]></AD_FIELDGROUP_ID>
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <READONLYLOGIC><![CDATA[@trxtype@='BPD']]></READONLYLOGIC>
+<!--AC203DDD5CF1459AA36DC7769ED15567-->  <ONCHANGEFUNCTION><![CDATA[OB.APRM.AddTransaction.amtOnChangeFunction]]></ONCHANGEFUNCTION>
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <DISPLAYEDROWS><![CDATA[5]]></DISPLAYEDROWS>
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <DISPLAYTITLE><![CDATA[Y]]></DISPLAYTITLE>
 <!--AC203DDD5CF1459AA36DC7769ED15567-->  <ATT_SHOWINDESCRIPTION><![CDATA[N]]></ATT_SHOWINDESCRIPTION>
--- a/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUISEL_SELECTOR.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.advpaymentmngt/src-db/database/sourcedata/OBUISEL_SELECTOR.xml	Thu May 25 06:12:59 2017 +0000
@@ -99,6 +99,21 @@
 <!--7811D4DBBB734D5ABB5DCC0CFDA21B88-->  <CUSTOM_QUERY><![CDATA[N]]></CUSTOM_QUERY>
 <!--7811D4DBBB734D5ABB5DCC0CFDA21B88--></OBUISEL_SELECTOR>
 
+<!--80D03C83D251489F984B488FA5B0B75F--><OBUISEL_SELECTOR>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <OBUISEL_SELECTOR_ID><![CDATA[80D03C83D251489F984B488FA5B0B75F]]></OBUISEL_SELECTOR_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <AD_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_MODULE_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <NAME><![CDATA[Financial Transaction Selector]]></NAME>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <AD_REFERENCE_ID><![CDATA[C4A74AE591F04D9A9CB859CC67F61340]]></AD_REFERENCE_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <AD_TABLE_ID><![CDATA[4D8C3B3C31D1410DA046140C9F024D17]]></AD_TABLE_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <OBCLKER_TEMPLATE_ID><![CDATA[9314DE8599AD44E7BFC4CC50699042AB]]></OBCLKER_TEMPLATE_ID>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <SUGGESTIONTEXTMATCHSTYLE><![CDATA[startsWith]]></SUGGESTIONTEXTMATCHSTYLE>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <POPUPTEXTMATCHSTYLE><![CDATA[startsWith]]></POPUPTEXTMATCHSTYLE>
+<!--80D03C83D251489F984B488FA5B0B75F-->  <CUSTOM_QUERY><![CDATA[N]]></CUSTOM_QUERY>
+<!--80D03C83D251489F984B488FA5B0B75F--></OBUISEL_SELECTOR>
+
 <!--8E06629A43A84B099387466818B1C54F--><OBUISEL_SELECTOR>
 <!--8E06629A43A84B099387466818B1C54F-->  <OBUISEL_SELECTOR_ID><![CDATA[8E06629A43A84B099387466818B1C54F]]></OBUISEL_SELECTOR_ID>
 <!--8E06629A43A84B099387466818B1C54F-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--8A098711BB324335A19833286BDB093D-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--8A098711BB324335A19833286BDB093D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--8A098711BB324335A19833286BDB093D-->  <NAME><![CDATA[Apache External Connection Pool]]></NAME>
-<!--8A098711BB324335A19833286BDB093D-->  <VERSION><![CDATA[1.0.31087]]></VERSION>
+<!--8A098711BB324335A19833286BDB093D-->  <VERSION><![CDATA[1.0.31787]]></VERSION>
 <!--8A098711BB324335A19833286BDB093D-->  <DESCRIPTION><![CDATA[Apache External Connection Pool]]></DESCRIPTION>
 <!--8A098711BB324335A19833286BDB093D-->  <HELP><![CDATA[This module implements the Apache JDBC Connection Pool (http://wiki.openbravo.com/wiki/Modules:Apache_JDBC_Connection_Pool).]]></HELP>
 <!--8A098711BB324335A19833286BDB093D-->  <TYPE><![CDATA[M]]></TYPE>
@@ -20,7 +20,7 @@
 <!--8A098711BB324335A19833286BDB093D-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--8A098711BB324335A19833286BDB093D-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--8A098711BB324335A19833286BDB093D-->  <UPDATEINFO><![CDATA[fixed issue #26663: configuration is read from servlet context]]></UPDATEINFO>
-<!--8A098711BB324335A19833286BDB093D-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--8A098711BB324335A19833286BDB093D-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--8A098711BB324335A19833286BDB093D-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--8A098711BB324335A19833286BDB093D-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--8A098711BB324335A19833286BDB093D--></AD_MODULE>
--- a/model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.apachejdbcconnectionpool/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <AD_MODULE_ID><![CDATA[8A098711BB324335A19833286BDB093D]]></AD_MODULE_ID>
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <AD_DEPENDENT_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_DEPENDENT_MODULE_ID>
-<!--1467C397BC5F4999A5606F39CD6FF8A4-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--1467C397BC5F4999A5606F39CD6FF8A4-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <DEPENDANT_MODULE_NAME><![CDATA[Openbravo 3.0 Framework]]></DEPENDANT_MODULE_NAME>
 <!--1467C397BC5F4999A5606F39CD6FF8A4-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <NAME><![CDATA[JBoss Weld]]></NAME>
-<!--C70732EA90A14EC0916078B85CC33D2D-->  <VERSION><![CDATA[1.1.31087]]></VERSION>
+<!--C70732EA90A14EC0916078B85CC33D2D-->  <VERSION><![CDATA[1.1.31787]]></VERSION>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <DESCRIPTION><![CDATA[JBoss Weld]]></DESCRIPTION>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <HELP><![CDATA[Provides the JBoss Weld framework: Java Contexts and Dependency Injection for the Java EE platform (CDI). For more information see http://seamframework.org/Weld]]></HELP>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <URL><![CDATA[http://forge.openbravo.com/projects/weld]]></URL>
@@ -22,7 +22,7 @@
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <UPDATEINFO><![CDATA[Bug fixing.]]></UPDATEINFO>
-<!--C70732EA90A14EC0916078B85CC33D2D-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--C70732EA90A14EC0916078B85CC33D2D-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--C70732EA90A14EC0916078B85CC33D2D-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--C70732EA90A14EC0916078B85CC33D2D--></AD_MODULE>
--- a/model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.base.weld/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <AD_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_MODULE_ID>
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <DEPENDANT_MODULE_NAME><![CDATA[Core]]></DEPENDANT_MODULE_NAME>
 <!--8BDE81545C1A43EAAC4BA3C5ED754DC8-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER.xml	Thu May 25 06:12:59 2017 +0000
@@ -192,12 +192,15 @@
       </foreign-key>
       <index name="OBUIAPP_PARAMETER_ATTMET_IDX" unique="false">
         <index-column name="C_ATTACHMENT_METHOD_ID"/>
+        <whereClause><![CDATA[C_ATTACHMENT_METHOD_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="OBUIAPP_PARAMETER_PROCESS" unique="false">
         <index-column name="OBUIAPP_PROCESS_ID"/>
+        <whereClause><![CDATA[OBUIAPP_PROCESS_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="OBUIAPP_PARAMETER_TAB_IDX" unique="false">
         <index-column name="AD_TAB_ID"/>
+        <whereClause><![CDATA[AD_TAB_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="OBUIAPP_PARAM_SHOWTITLE_CHK"><![CDATA[DISPLAYTITLE IN ('Y', 'N')]]></check>
       <check name="OBUIAPP_PARAMETER_CENTR_CHK"><![CDATA[ISCENTRALLYMAINTAINED IN ('Y', 'N')]]></check>
--- a/model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER_VALUE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/model/tables/OBUIAPP_PARAMETER_VALUE.xml	Thu May 25 06:12:59 2017 +0000
@@ -71,6 +71,7 @@
       </foreign-key>
       <index name="OBUIAPP_PARAMVAL_FILE_IDX" unique="false">
         <index-column name="C_FILE_ID"/>
+        <whereClause><![CDATA[C_FILE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="OBUIAPP_PARAMVAL_PARAM_IDX" unique="false">
         <index-column name="OBUIAPP_PARAMETER_ID"/>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_COLUMN.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_COLUMN.xml	Thu May 25 06:12:59 2017 +0000
@@ -774,7 +774,7 @@
 <!--08AF323AC6C066ADE050007F0100548B-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--08AF323AC6C066ADE050007F0100548B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--08AF323AC6C066ADE050007F0100548B-->  <NAME><![CDATA[Use PDF as XLS Template]]></NAME>
-<!--08AF323AC6C066ADE050007F0100548B-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the XLS instead of defining a specific template for it.]]></HELP>
+<!--08AF323AC6C066ADE050007F0100548B-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the Excel report instead of defining a specific template for it.]]></HELP>
 <!--08AF323AC6C066ADE050007F0100548B-->  <COLUMNNAME><![CDATA[USE_Pdf_As_Xls_Template]]></COLUMNNAME>
 <!--08AF323AC6C066ADE050007F0100548B-->  <AD_TABLE_ID><![CDATA[C7CAB786F3EF4DF0B5E7B9AC6EC7DED8]]></AD_TABLE_ID>
 <!--08AF323AC6C066ADE050007F0100548B-->  <AD_REFERENCE_ID><![CDATA[20]]></AD_REFERENCE_ID>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_DATASET_TABLE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_DATASET_TABLE.xml	Thu May 25 06:12:59 2017 +0000
@@ -65,7 +65,7 @@
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <AD_TABLE_ID><![CDATA[C7CAB786F3EF4DF0B5E7B9AC6EC7DED8]]></AD_TABLE_ID>
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <INCLUDEALLCOLUMNS><![CDATA[Y]]></INCLUDEALLCOLUMNS>
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <WHERECLAUSE><![CDATA[obuiapp_process_id in (select obuiapp_process_id from obuiapp_process where ad_module_id in (:moduleid))]]></WHERECLAUSE>
-<!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <EXCLUDEAUDITINFO><![CDATA[N]]></EXCLUDEAUDITINFO>
+<!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <EXCLUDEAUDITINFO><![CDATA[Y]]></EXCLUDEAUDITINFO>
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <ISBUSINESSOBJECT><![CDATA[N]]></ISBUSINESSOBJECT>
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--7AA152F1C7D340CD9C29F2D4926EBFE0--></AD_DATASET_TABLE>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_ELEMENT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_ELEMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -46,8 +46,8 @@
 <!--08AF323AC6C766ADE050007F0100548B-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--08AF323AC6C766ADE050007F0100548B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--08AF323AC6C766ADE050007F0100548B-->  <COLUMNNAME><![CDATA[XLS_Template]]></COLUMNNAME>
-<!--08AF323AC6C766ADE050007F0100548B-->  <NAME><![CDATA[XLS Template]]></NAME>
-<!--08AF323AC6C766ADE050007F0100548B-->  <PRINTNAME><![CDATA[XLS Template]]></PRINTNAME>
+<!--08AF323AC6C766ADE050007F0100548B-->  <NAME><![CDATA[Excel Template]]></NAME>
+<!--08AF323AC6C766ADE050007F0100548B-->  <PRINTNAME><![CDATA[Excel Template]]></PRINTNAME>
 <!--08AF323AC6C766ADE050007F0100548B-->  <HELP><![CDATA[JRXML template to export to Excel the report when a specific template is required for excel]]></HELP>
 <!--08AF323AC6C766ADE050007F0100548B-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--08AF323AC6C766ADE050007F0100548B-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
@@ -59,9 +59,9 @@
 <!--08AF323AC6C866ADE050007F0100548B-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--08AF323AC6C866ADE050007F0100548B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--08AF323AC6C866ADE050007F0100548B-->  <COLUMNNAME><![CDATA[USE_Pdf_As_Xls_Template]]></COLUMNNAME>
-<!--08AF323AC6C866ADE050007F0100548B-->  <NAME><![CDATA[Use PDF as XLS Template]]></NAME>
-<!--08AF323AC6C866ADE050007F0100548B-->  <PRINTNAME><![CDATA[Use PDF as XLS Template]]></PRINTNAME>
-<!--08AF323AC6C866ADE050007F0100548B-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the XLS instead of defining a specific template for it.]]></HELP>
+<!--08AF323AC6C866ADE050007F0100548B-->  <NAME><![CDATA[Use PDF as Excel Template]]></NAME>
+<!--08AF323AC6C866ADE050007F0100548B-->  <PRINTNAME><![CDATA[Use PDF as Excel Template]]></PRINTNAME>
+<!--08AF323AC6C866ADE050007F0100548B-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the Excel report instead of defining a specific template for it.]]></HELP>
 <!--08AF323AC6C866ADE050007F0100548B-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--08AF323AC6C866ADE050007F0100548B-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--08AF323AC6C866ADE050007F0100548B--></AD_ELEMENT>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_FIELD.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_FIELD.xml	Thu May 25 06:12:59 2017 +0000
@@ -605,7 +605,7 @@
 <!--08AEFECA5A607AECE050007F0100529C-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--08AEFECA5A607AECE050007F0100529C-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--08AEFECA5A607AECE050007F0100529C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--08AEFECA5A607AECE050007F0100529C-->  <NAME><![CDATA[XLS Template]]></NAME>
+<!--08AEFECA5A607AECE050007F0100529C-->  <NAME><![CDATA[Excel Template]]></NAME>
 <!--08AEFECA5A607AECE050007F0100529C-->  <HELP><![CDATA[JRXML template to export to Excel the report when a specific template is required for excel]]></HELP>
 <!--08AEFECA5A607AECE050007F0100529C-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
 <!--08AEFECA5A607AECE050007F0100529C-->  <AD_TAB_ID><![CDATA[2B7B3CCDC940436F93437445AA7752F3]]></AD_TAB_ID>
@@ -633,8 +633,8 @@
 <!--08AEFECA5A617AECE050007F0100529C-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--08AEFECA5A617AECE050007F0100529C-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--08AEFECA5A617AECE050007F0100529C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--08AEFECA5A617AECE050007F0100529C-->  <NAME><![CDATA[Use PDF as XLS Template]]></NAME>
-<!--08AEFECA5A617AECE050007F0100529C-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the XLS instead of defining a specific template for it.]]></HELP>
+<!--08AEFECA5A617AECE050007F0100529C-->  <NAME><![CDATA[Use PDF as Excel Template]]></NAME>
+<!--08AEFECA5A617AECE050007F0100529C-->  <HELP><![CDATA[Determines whether the PDF Template needs to be used to generate the Excel report instead of defining a specific template for it.]]></HELP>
 <!--08AEFECA5A617AECE050007F0100529C-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
 <!--08AEFECA5A617AECE050007F0100529C-->  <AD_TAB_ID><![CDATA[2B7B3CCDC940436F93437445AA7752F3]]></AD_TAB_ID>
 <!--08AEFECA5A617AECE050007F0100529C-->  <AD_COLUMN_ID><![CDATA[08AF323AC6C066ADE050007F0100548B]]></AD_COLUMN_ID>
@@ -8516,7 +8516,7 @@
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <AD_COLUMN_ID><![CDATA[0E78BBBD0F814831A4E5837C677666FD]]></AD_COLUMN_ID>
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
-<!--FCD55C499D894E95B322C17919EAB3E4-->  <DISPLAYLOGIC><![CDATA[@Uipattern@='M']]></DISPLAYLOGIC>
+<!--FCD55C499D894E95B322C17919EAB3E4-->  <DISPLAYLOGIC><![CDATA[@Uipattern@='M' | @Uipattern@='OBUIAPP_PickAndExecute']]></DISPLAYLOGIC>
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <DISPLAYLENGTH><![CDATA[1]]></DISPLAYLENGTH>
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
 <!--FCD55C499D894E95B322C17919EAB3E4-->  <SEQNO><![CDATA[110]]></SEQNO>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MESSAGE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MESSAGE.xml	Thu May 25 06:12:59 2017 +0000
@@ -1755,7 +1755,7 @@
 <!--CDBC4895920A424CB8715EC232729ABD-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--CDBC4895920A424CB8715EC232729ABD-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--CDBC4895920A424CB8715EC232729ABD-->  <VALUE><![CDATA[OBUIAPP_XLSExport]]></VALUE>
-<!--CDBC4895920A424CB8715EC232729ABD-->  <MSGTEXT><![CDATA[Export to XLS]]></MSGTEXT>
+<!--CDBC4895920A424CB8715EC232729ABD-->  <MSGTEXT><![CDATA[Export to Excel]]></MSGTEXT>
 <!--CDBC4895920A424CB8715EC232729ABD-->  <MSGTYPE><![CDATA[I]]></MSGTYPE>
 <!--CDBC4895920A424CB8715EC232729ABD-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--CDBC4895920A424CB8715EC232729ABD-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <NAME><![CDATA[User Interface Application]]></NAME>
-<!--9BA0836A3CD74EE4AB48753A47211BCC-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--9BA0836A3CD74EE4AB48753A47211BCC-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <DESCRIPTION><![CDATA[Provides the main application components for the openbravo user interface]]></DESCRIPTION>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <HELP><![CDATA[Provides the main application components for the openbravo user interface. The main layout incorporates a navigation bar and a main view area.]]></HELP>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <URL><![CDATA[http://forge.openbravo.com/projects/clientapplication]]></URL>
@@ -22,7 +22,7 @@
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <UPDATEINFO><![CDATA[Styling bugfixing]]></UPDATEINFO>
-<!--9BA0836A3CD74EE4AB48753A47211BCC-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--9BA0836A3CD74EE4AB48753A47211BCC-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--9BA0836A3CD74EE4AB48753A47211BCC-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--9BA0836A3CD74EE4AB48753A47211BCC--></AD_MODULE>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_DEPENDENT_MODULE_ID>
-<!--15D7CE8D95D043189162DBABA54A1F61-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--15D7CE8D95D043189162DBABA54A1F61-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON Datasource]]></DEPENDANT_MODULE_NAME>
 <!--15D7CE8D95D043189162DBABA54A1F61-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--60A170212F36499D83B8AD38D01F46B3-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--60A170212F36499D83B8AD38D01F46B3-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--60A170212F36499D83B8AD38D01F46B3-->  <AD_DEPENDENT_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_DEPENDENT_MODULE_ID>
-<!--60A170212F36499D83B8AD38D01F46B3-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--60A170212F36499D83B8AD38D01F46B3-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--60A170212F36499D83B8AD38D01F46B3-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--60A170212F36499D83B8AD38D01F46B3-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Client Kernel]]></DEPENDANT_MODULE_NAME>
 <!--60A170212F36499D83B8AD38D01F46B3-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--824D60CB352E4099B1D8C903CA139DAE-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--824D60CB352E4099B1D8C903CA139DAE-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--824D60CB352E4099B1D8C903CA139DAE-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -49,7 +49,7 @@
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <AD_DEPENDENT_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_DEPENDENT_MODULE_ID>
-<!--E8FD820AFE3D4FE08C02FC47769026AD-->  <STARTVERSION><![CDATA[8.1.31087]]></STARTVERSION>
+<!--E8FD820AFE3D4FE08C02FC47769026AD-->  <STARTVERSION><![CDATA[8.1.31787]]></STARTVERSION>
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <DEPENDANT_MODULE_NAME><![CDATA[Smartclient]]></DEPENDANT_MODULE_NAME>
 <!--E8FD820AFE3D4FE08C02FC47769026AD-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.application/src-db/database/sourcedata/OBSERDS_DATASOURCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/OBSERDS_DATASOURCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -28,6 +28,34 @@
 <!--3C1148C0AB604DE1B51B7EA4112C325F-->  <IDFKFILTERING><![CDATA[Y]]></IDFKFILTERING>
 <!--3C1148C0AB604DE1B51B7EA4112C325F--></OBSERDS_DATASOURCE>
 
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E--><OBSERDS_DATASOURCE>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <OBSERDS_DATASOURCE_ID><![CDATA[99B9CC42FDEA4CA7A4EE35BC49D61E0E]]></OBSERDS_DATASOURCE_ID>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <NAME><![CDATA[QuickLaunchDataSource]]></NAME>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <DESCRIPTION><![CDATA[Provides the data for the open view navigation bar widget]]></DESCRIPTION>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <CLASSNAME><![CDATA[org.openbravo.client.application.navigationbarcomponents.QuickLaunchDataSource]]></CLASSNAME>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <OBCLKER_TEMPLATE_ID><![CDATA[2BAD445C2A0343C58E455F9BD379C690]]></OBCLKER_TEMPLATE_ID>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <USEASTABLEDATAORIGIN><![CDATA[N]]></USEASTABLEDATAORIGIN>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E-->  <IDFKFILTERING><![CDATA[Y]]></IDFKFILTERING>
+<!--99B9CC42FDEA4CA7A4EE35BC49D61E0E--></OBSERDS_DATASOURCE>
+
+<!--C17951F970E942FD9F3771B7BE91D049--><OBSERDS_DATASOURCE>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <OBSERDS_DATASOURCE_ID><![CDATA[C17951F970E942FD9F3771B7BE91D049]]></OBSERDS_DATASOURCE_ID>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <AD_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_MODULE_ID>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <NAME><![CDATA[QuickCreateDataSource]]></NAME>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <DESCRIPTION><![CDATA[Datasource for the quick create navigation bar widget]]></DESCRIPTION>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <CLASSNAME><![CDATA[org.openbravo.client.application.navigationbarcomponents.QuickCreateDataSource]]></CLASSNAME>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <OBCLKER_TEMPLATE_ID><![CDATA[2BAD445C2A0343C58E455F9BD379C690]]></OBCLKER_TEMPLATE_ID>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <USEASTABLEDATAORIGIN><![CDATA[N]]></USEASTABLEDATAORIGIN>
+<!--C17951F970E942FD9F3771B7BE91D049-->  <IDFKFILTERING><![CDATA[Y]]></IDFKFILTERING>
+<!--C17951F970E942FD9F3771B7BE91D049--></OBSERDS_DATASOURCE>
+
 <!--DB9F062472294F12A0291A7BD203F922--><OBSERDS_DATASOURCE>
 <!--DB9F062472294F12A0291A7BD203F922-->  <OBSERDS_DATASOURCE_ID><![CDATA[DB9F062472294F12A0291A7BD203F922]]></OBSERDS_DATASOURCE_ID>
 <!--DB9F062472294F12A0291A7BD203F922-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/modules/org.openbravo.client.application/src-db/database/sourcedata/OBSERDS_DATASOURCE_FIELD.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,69 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<data>
+<!--124A746198DD46F5958C0A299351CBB6--><OBSERDS_DATASOURCE_FIELD>
+<!--124A746198DD46F5958C0A299351CBB6-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[124A746198DD46F5958C0A299351CBB6]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--124A746198DD46F5958C0A299351CBB6-->  <OBSERDS_DATASOURCE_ID><![CDATA[99B9CC42FDEA4CA7A4EE35BC49D61E0E]]></OBSERDS_DATASOURCE_ID>
+<!--124A746198DD46F5958C0A299351CBB6-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--124A746198DD46F5958C0A299351CBB6-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--124A746198DD46F5958C0A299351CBB6-->  <NAME><![CDATA[icon]]></NAME>
+<!--124A746198DD46F5958C0A299351CBB6-->  <DESCRIPTION><![CDATA[icon]]></DESCRIPTION>
+<!--124A746198DD46F5958C0A299351CBB6-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--124A746198DD46F5958C0A299351CBB6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--124A746198DD46F5958C0A299351CBB6--></OBSERDS_DATASOURCE_FIELD>
+
+<!--4EBEE8A96E064B4E95F51FDD6B34154F--><OBSERDS_DATASOURCE_FIELD>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[4EBEE8A96E064B4E95F51FDD6B34154F]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <OBSERDS_DATASOURCE_ID><![CDATA[99B9CC42FDEA4CA7A4EE35BC49D61E0E]]></OBSERDS_DATASOURCE_ID>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <NAME><![CDATA[_identifier]]></NAME>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <DESCRIPTION><![CDATA[identifier]]></DESCRIPTION>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--4EBEE8A96E064B4E95F51FDD6B34154F--></OBSERDS_DATASOURCE_FIELD>
+
+<!--622AC1D0D0364D4E965F2BD28E572E93--><OBSERDS_DATASOURCE_FIELD>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[622AC1D0D0364D4E965F2BD28E572E93]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <OBSERDS_DATASOURCE_ID><![CDATA[99B9CC42FDEA4CA7A4EE35BC49D61E0E]]></OBSERDS_DATASOURCE_ID>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <NAME><![CDATA[id]]></NAME>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <DESCRIPTION><![CDATA[id]]></DESCRIPTION>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--622AC1D0D0364D4E965F2BD28E572E93-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--622AC1D0D0364D4E965F2BD28E572E93--></OBSERDS_DATASOURCE_FIELD>
+
+<!--CB0B4C3E832241758A652D115AE521FE--><OBSERDS_DATASOURCE_FIELD>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[CB0B4C3E832241758A652D115AE521FE]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <OBSERDS_DATASOURCE_ID><![CDATA[C17951F970E942FD9F3771B7BE91D049]]></OBSERDS_DATASOURCE_ID>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <NAME><![CDATA[_identifier]]></NAME>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <DESCRIPTION><![CDATA[_identifier]]></DESCRIPTION>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--CB0B4C3E832241758A652D115AE521FE-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--CB0B4C3E832241758A652D115AE521FE--></OBSERDS_DATASOURCE_FIELD>
+
+<!--D74248F87B7B460C8D5F770A099DAF1C--><OBSERDS_DATASOURCE_FIELD>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[D74248F87B7B460C8D5F770A099DAF1C]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <OBSERDS_DATASOURCE_ID><![CDATA[C17951F970E942FD9F3771B7BE91D049]]></OBSERDS_DATASOURCE_ID>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <NAME><![CDATA[icon]]></NAME>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <DESCRIPTION><![CDATA[icon]]></DESCRIPTION>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--D74248F87B7B460C8D5F770A099DAF1C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--D74248F87B7B460C8D5F770A099DAF1C--></OBSERDS_DATASOURCE_FIELD>
+
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7--><OBSERDS_DATASOURCE_FIELD>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <OBSERDS_DATASOURCE_FIELD_ID><![CDATA[E872E11DC1BA4A42BCFFA8CF02BF91B7]]></OBSERDS_DATASOURCE_FIELD_ID>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <OBSERDS_DATASOURCE_ID><![CDATA[C17951F970E942FD9F3771B7BE91D049]]></OBSERDS_DATASOURCE_ID>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <NAME><![CDATA[id]]></NAME>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <DESCRIPTION><![CDATA[id]]></DESCRIPTION>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--E872E11DC1BA4A42BCFFA8CF02BF91B7--></OBSERDS_DATASOURCE_FIELD>
+
+</data>
--- a/model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <NAME><![CDATA[HTML Widget]]></NAME>
-<!--D393BE6F22BB44B7B728259B34FC795A-->  <VERSION><![CDATA[1.0.31087]]></VERSION>
+<!--D393BE6F22BB44B7B728259B34FC795A-->  <VERSION><![CDATA[1.0.31787]]></VERSION>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <DESCRIPTION><![CDATA[Provides the HTML Widget superclass that allows to create widget classes that embed the html code.]]></DESCRIPTION>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <HELP><![CDATA[With this module you can define your own widget classes just setting up your own html code or the html code provided by third parties.]]></HELP>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <URL><![CDATA[http://forge.openbravo.com/projects/htmlwidget]]></URL>
@@ -21,7 +21,7 @@
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--D393BE6F22BB44B7B728259B34FC795A-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--D393BE6F22BB44B7B728259B34FC795A-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--D393BE6F22BB44B7B728259B34FC795A-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--D393BE6F22BB44B7B728259B34FC795A--></AD_MODULE>
--- a/model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.htmlwidget/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <AD_MODULE_ID><![CDATA[D393BE6F22BB44B7B728259B34FC795A]]></AD_MODULE_ID>
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <AD_DEPENDENT_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_DEPENDENT_MODULE_ID>
-<!--DCE798FBC5B648F7A3C81A6941720A57-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--DCE798FBC5B648F7A3C81A6941720A57-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <DEPENDANT_MODULE_NAME><![CDATA[My Openbravo Tab]]></DEPENDANT_MODULE_NAME>
 <!--DCE798FBC5B648F7A3C81A6941720A57-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--4B828F4D03264080AA1D2057B13F613C-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <NAME><![CDATA[User Interface Client Kernel]]></NAME>
-<!--4B828F4D03264080AA1D2057B13F613C-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--4B828F4D03264080AA1D2057B13F613C-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <DESCRIPTION><![CDATA[Provides framework functionality for the Openbravo User Interface]]></DESCRIPTION>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <HELP><![CDATA[The user interface client kernel is a generation framework for generating client (browser) components used in Openbravo. Its components are mainly used by other modules to provide customizable and extendable user interfaces.]]></HELP>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <URL><![CDATA[http://forge.openbravo.com/projects/openbravoclientkernel]]></URL>
@@ -22,7 +22,7 @@
 <!--4B828F4D03264080AA1D2057B13F613C-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <UPDATEINFO><![CDATA[Bug fix for issue 15289]]></UPDATEINFO>
-<!--4B828F4D03264080AA1D2057B13F613C-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--4B828F4D03264080AA1D2057B13F613C-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--4B828F4D03264080AA1D2057B13F613C-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--4B828F4D03264080AA1D2057B13F613C--></AD_MODULE>
--- a/model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.kernel/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <AD_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_MODULE_ID>
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--26B041893E844A53AFA58BC326C4F0D7-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--26B041893E844A53AFA58BC326C4F0D7-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--26B041893E844A53AFA58BC326C4F0D7-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <AD_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_MODULE_ID>
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <AD_DEPENDENT_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_DEPENDENT_MODULE_ID>
-<!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <DEPENDANT_MODULE_NAME><![CDATA[JBoss Weld]]></DEPENDANT_MODULE_NAME>
 <!--3AB045DA35ED4CA58EF7EB5BF04CDE3F-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <AD_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_MODULE_ID>
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <AD_DEPENDENT_MODULE_ID><![CDATA[F8D1B3ECB3474E8DA5C216473C840DF1]]></AD_DEPENDENT_MODULE_ID>
-<!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <STARTVERSION><![CDATA[2.0.31087]]></STARTVERSION>
+<!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <STARTVERSION><![CDATA[2.0.31787]]></STARTVERSION>
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON REST Webservice]]></DEPENDANT_MODULE_NAME>
 <!--D7BA4BB0844942C58DC46B9E23CF8E67-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.myob/src-db/database/model/modifiedTables/OBUIAPP_PARAMETER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.myob/src-db/database/model/modifiedTables/OBUIAPP_PARAMETER.xml	Thu May 25 06:12:59 2017 +0000
@@ -10,6 +10,7 @@
       </foreign-key>
       <index name="EM_OBKMO_PARAM_WIDGET" unique="false">
         <index-column name="EM_OBKMO_WIDGET_CLASS_ID"/>
+        <whereClause><![CDATA[EM_OBKMO_WIDGET_CLASS_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <NAME><![CDATA[Workspace & Widgets]]></NAME>
-<!--2758CD25B2704AF6BBAD10365FC82C06-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--2758CD25B2704AF6BBAD10365FC82C06-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <DESCRIPTION><![CDATA[Workspace & Widgets]]></DESCRIPTION>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <HELP><![CDATA[Provides the infrastructure of workspace tab (formerly My Openbravo)]]></HELP>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <URL><![CDATA[http://forge.openbravo.com/projects/myopenbravo]]></URL>
@@ -23,7 +23,7 @@
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <HASREFERENCEDATA><![CDATA[Y]]></HASREFERENCEDATA>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <UPDATEINFO><![CDATA[Styling bugfixing]]></UPDATEINFO>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <REFERENCEDATAINFO><![CDATA[Provides the infrastructure of workspace tab]]></REFERENCEDATAINFO>
-<!--2758CD25B2704AF6BBAD10365FC82C06-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--2758CD25B2704AF6BBAD10365FC82C06-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--2758CD25B2704AF6BBAD10365FC82C06-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--2758CD25B2704AF6BBAD10365FC82C06--></AD_MODULE>
--- a/model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.myob/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--15F51F03882F444CAB6593B4566DC929-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--15F51F03882F444CAB6593B4566DC929-->  <AD_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_MODULE_ID>
 <!--15F51F03882F444CAB6593B4566DC929-->  <AD_DEPENDENT_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_DEPENDENT_MODULE_ID>
-<!--15F51F03882F444CAB6593B4566DC929-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--15F51F03882F444CAB6593B4566DC929-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--15F51F03882F444CAB6593B4566DC929-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--15F51F03882F444CAB6593B4566DC929-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Application]]></DEPENDANT_MODULE_NAME>
 <!--15F51F03882F444CAB6593B4566DC929-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <AD_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_MODULE_ID>
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--E71B28FC949D481D9F59C17D01E46EF9-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--E71B28FC949D481D9F59C17D01E46EF9-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <DEPENDANT_MODULE_NAME><![CDATA[Core]]></DEPENDANT_MODULE_NAME>
 <!--E71B28FC949D481D9F59C17D01E46EF9-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.querylist/src-db/database/model/tables/OBCQL_WIDGET_QUERY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.querylist/src-db/database/model/tables/OBCQL_WIDGET_QUERY.xml	Thu May 25 06:12:59 2017 +0000
@@ -66,6 +66,7 @@
       </index>
       <index name="OBCQL_WIDGET_QUERY_DS" unique="false">
         <index-column name="OBSERDS_DATASOURCE_ID"/>
+        <whereClause><![CDATA[OBSERDS_DATASOURCE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="OBCQL_WIDGET_QUERY_ACTIVECHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <NAME><![CDATA[Query/List Widget]]></NAME>
-<!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <VERSION><![CDATA[1.0.31087]]></VERSION>
+<!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <VERSION><![CDATA[1.0.31787]]></VERSION>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <DESCRIPTION><![CDATA[Provides the Query/List superclass widget that allows to create widget classes that prints a grid of data based on a query.]]></DESCRIPTION>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <HELP><![CDATA[With this module you can define your own widget classes that just with simple Application Dictionary shows a grid of data based on a HQL Query.]]></HELP>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <URL><![CDATA[http://forge.openbravo.com/projects/querylistwidget]]></URL>
@@ -21,7 +21,7 @@
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--0A060B2AF1974E8EAA8DB61388E9AECC--></AD_MODULE>
--- a/model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.querylist/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--26558497C31140BFAB067BA4BC47D799-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--26558497C31140BFAB067BA4BC47D799-->  <AD_MODULE_ID><![CDATA[0A060B2AF1974E8EAA8DB61388E9AECC]]></AD_MODULE_ID>
 <!--26558497C31140BFAB067BA4BC47D799-->  <AD_DEPENDENT_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_DEPENDENT_MODULE_ID>
-<!--26558497C31140BFAB067BA4BC47D799-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--26558497C31140BFAB067BA4BC47D799-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--26558497C31140BFAB067BA4BC47D799-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--26558497C31140BFAB067BA4BC47D799-->  <DEPENDANT_MODULE_NAME><![CDATA[My Openbravo Tab]]></DEPENDANT_MODULE_NAME>
 <!--26558497C31140BFAB067BA4BC47D799-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--FF8080812D842086012D844F3CC0003E-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--FF8080812D842086012D844F3CC0003E-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080812D842086012D844F3CC0003E-->  <NAME><![CDATA[Widgets Collection]]></NAME>
-<!--FF8080812D842086012D844F3CC0003E-->  <VERSION><![CDATA[0.0.31087]]></VERSION>
+<!--FF8080812D842086012D844F3CC0003E-->  <VERSION><![CDATA[0.0.31787]]></VERSION>
 <!--FF8080812D842086012D844F3CC0003E-->  <DESCRIPTION><![CDATA[Collection of Workspace Widgets]]></DESCRIPTION>
 <!--FF8080812D842086012D844F3CC0003E-->  <HELP><![CDATA[Collection of Workspace Widgets]]></HELP>
 <!--FF8080812D842086012D844F3CC0003E-->  <URL><![CDATA[http://forge.openbravo.com/projects/widgetscollection]]></URL>
@@ -22,7 +22,7 @@
 <!--FF8080812D842086012D844F3CC0003E-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--FF8080812D842086012D844F3CC0003E-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--FF8080812D842086012D844F3CC0003E-->  <UPDATEINFO><![CDATA[Added Currency Converter. Added Google Docs]]></UPDATEINFO>
-<!--FF8080812D842086012D844F3CC0003E-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--FF8080812D842086012D844F3CC0003E-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--FF8080812D842086012D844F3CC0003E-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--FF8080812D842086012D844F3CC0003E-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--FF8080812D842086012D844F3CC0003E--></AD_MODULE>
--- a/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--FF8080812D842086012D845002070046-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080812D842086012D845002070046-->  <AD_MODULE_ID><![CDATA[FF8080812D842086012D844F3CC0003E]]></AD_MODULE_ID>
 <!--FF8080812D842086012D845002070046-->  <AD_DEPENDENT_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080812D842086012D845002070046-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--FF8080812D842086012D845002070046-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--FF8080812D842086012D845002070046-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--FF8080812D842086012D845002070046-->  <DEPENDANT_MODULE_NAME><![CDATA[Workspace & Widgets]]></DEPENDANT_MODULE_NAME>
 <!--FF8080812D842086012D845002070046-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBCQL_WIDGET_QUERY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBCQL_WIDGET_QUERY.xml	Thu May 25 06:12:59 2017 +0000
@@ -51,6 +51,7 @@
 and @optional_filters@
 and ol.client.id = :client
 and ol.product.name like :pname
+and ol.organization.id in (:organizationList)
 group by product.name, product.uOM.name, product.id, product.uOM.id 
 order by sum(orderedQuantity) desc]]></HQL>
 <!--CFDF8EE593F04CFE9709F5AD19A3A573-->  <TYPE><![CDATA[HQL]]></TYPE>
--- a/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.client.widgets/src-db/database/sourcedata/OBUIAPP_PARAMETER.xml	Thu May 25 06:12:59 2017 +0000
@@ -559,6 +559,32 @@
 <!--D1BE41F04FD14C3A9E6980369BC97E87-->  <EM_OBKMO_WIDGET_CLASS_ID><![CDATA[5291D3D3B07B4CFC87928071377740E8]]></EM_OBKMO_WIDGET_CLASS_ID>
 <!--D1BE41F04FD14C3A9E6980369BC97E87--></OBUIAPP_PARAMETER>
 
+<!--D4B555A658964D3C87B4D06F828832FA--><OBUIAPP_PARAMETER>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <OBUIAPP_PARAMETER_ID><![CDATA[D4B555A658964D3C87B4D06F828832FA]]></OBUIAPP_PARAMETER_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <AD_MODULE_ID><![CDATA[FF8080812D842086012D844F3CC0003E]]></AD_MODULE_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <NAME><![CDATA[Organization List]]></NAME>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <DESCRIPTION><![CDATA[List of Organizations this Role can access]]></DESCRIPTION>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <HELP><![CDATA[The Organization List indicates the Organizations (by organization id) that this Role can access.  Multiple Organizations are delimited by a comma ','.]]></HELP>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <SEQNO><![CDATA[30]]></SEQNO>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <AD_REFERENCE_ID><![CDATA[10]]></AD_REFERENCE_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <COLUMNNAME><![CDATA[organizationList]]></COLUMNNAME>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <FIELDLENGTH><![CDATA[0]]></FIELDLENGTH>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <ISMANDATORY><![CDATA[N]]></ISMANDATORY>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <AD_ELEMENT_ID><![CDATA[478]]></AD_ELEMENT_ID>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <ISFIXED><![CDATA[Y]]></ISFIXED>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <FIXEDVALUE><![CDATA[OB.getContext().getReadableOrganizations()]]></FIXEDVALUE>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <EVALUATEFIXEDVALUE><![CDATA[Y]]></EVALUATEFIXEDVALUE>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <STARTINNEWLINE><![CDATA[N]]></STARTINNEWLINE>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <DISPLAYEDROWS><![CDATA[5]]></DISPLAYEDROWS>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <DISPLAYTITLE><![CDATA[Y]]></DISPLAYTITLE>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <ATT_SHOWINDESCRIPTION><![CDATA[N]]></ATT_SHOWINDESCRIPTION>
+<!--D4B555A658964D3C87B4D06F828832FA-->  <EM_OBKMO_WIDGET_CLASS_ID><![CDATA[CD1B06C4ED974B5F905A5A01B097DF4E]]></EM_OBKMO_WIDGET_CLASS_ID>
+<!--D4B555A658964D3C87B4D06F828832FA--></OBUIAPP_PARAMETER>
+
 <!--D57E85EA046B475C94EEE74A9CF67C78--><OBUIAPP_PARAMETER>
 <!--D57E85EA046B475C94EEE74A9CF67C78-->  <OBUIAPP_PARAMETER_ID><![CDATA[D57E85EA046B475C94EEE74A9CF67C78]]></OBUIAPP_PARAMETER_ID>
 <!--D57E85EA046B475C94EEE74A9CF67C78-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <NAME><![CDATA[Payment Report]]></NAME>
-<!--2A5EE903D7974AC298C0504FBC4501A7-->  <VERSION><![CDATA[3.0.31087]]></VERSION>
+<!--2A5EE903D7974AC298C0504FBC4501A7-->  <VERSION><![CDATA[3.0.31787]]></VERSION>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <DESCRIPTION><![CDATA[Payment Report]]></DESCRIPTION>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <URL><![CDATA[http://forge.openbravo.com/projects/paymentreport]]></URL>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <TYPE><![CDATA[M]]></TYPE>
@@ -22,7 +22,7 @@
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--2A5EE903D7974AC298C0504FBC4501A7-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--2A5EE903D7974AC298C0504FBC4501A7-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--2A5EE903D7974AC298C0504FBC4501A7-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--2A5EE903D7974AC298C0504FBC4501A7--></AD_MODULE>
--- a/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <AD_MODULE_ID><![CDATA[2A5EE903D7974AC298C0504FBC4501A7]]></AD_MODULE_ID>
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_DEPENDENT_MODULE_ID>
-<!--A3B449C4D5FE4D688CC58236FE33B802-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--A3B449C4D5FE4D688CC58236FE33B802-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <DEPENDANT_MODULE_NAME><![CDATA[Advanced Payables and Receivables Mngmt]]></DEPENDANT_MODULE_NAME>
 <!--A3B449C4D5FE4D688CC58236FE33B802-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_PREFERENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.financial.paymentreport/src-db/database/sourcedata/AD_PREFERENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -11,4 +11,15 @@
 <!--9B4A5EB695FFA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[2A5EE903D7974AC298C0504FBC4501A7]]></AD_MODULE_ID>
 <!--9B4A5EB695FFA841E040A8C0E1077381--></AD_PREFERENCE>
 
+<!--9B4A5EB6975EA841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB6975EA841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcess6AD04479EC134BD4826077F36B709876]]></ATTRIBUTE>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB6975EA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[2A5EE903D7974AC298C0504FBC4501A7]]></AD_MODULE_ID>
+<!--9B4A5EB6975EA841E040A8C0E1077381--></AD_PREFERENCE>
+
 </data>
--- a/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--3A3A943684D64DEF9EC39F588A656848-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <NAME><![CDATA[Orders Awaiting Delivery]]></NAME>
-<!--3A3A943684D64DEF9EC39F588A656848-->  <VERSION><![CDATA[1.1.31087]]></VERSION>
+<!--3A3A943684D64DEF9EC39F588A656848-->  <VERSION><![CDATA[1.1.31787]]></VERSION>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <DESCRIPTION><![CDATA[Report displaying sales orders not shipped.]]></DESCRIPTION>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <URL><![CDATA[http://forge.openbravo.com/projects/ordersawaitingdlivery]]></URL>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <TYPE><![CDATA[M]]></TYPE>
@@ -19,7 +19,7 @@
 <!--3A3A943684D64DEF9EC39F588A656848-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--3A3A943684D64DEF9EC39F588A656848-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--3A3A943684D64DEF9EC39F588A656848-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--3A3A943684D64DEF9EC39F588A656848-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--3A3A943684D64DEF9EC39F588A656848--></AD_MODULE>
--- a/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <AD_MODULE_ID><![CDATA[3A3A943684D64DEF9EC39F588A656848]]></AD_MODULE_ID>
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--64060E9EE9EC408BBFFD0CC2DE25C86F-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_PREFERENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.reports.ordersawaitingdelivery/src-db/database/sourcedata/AD_PREFERENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -11,4 +11,15 @@
 <!--9B4A5EB69600A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[3A3A943684D64DEF9EC39F588A656848]]></AD_MODULE_ID>
 <!--9B4A5EB69600A841E040A8C0E1077381--></AD_PREFERENCE>
 
+<!--9B4A5EB6975FA841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB6975FA841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcess3DAA5E63A30D45A8ABF87701F8BD91EF]]></ATTRIBUTE>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB6975FA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[3A3A943684D64DEF9EC39F588A656848]]></AD_MODULE_ID>
+<!--9B4A5EB6975FA841E040A8C0E1077381--></AD_PREFERENCE>
+
 </data>
--- a/model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <NAME><![CDATA[JSON Datasource]]></NAME>
-<!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <DESCRIPTION><![CDATA[Provides data source CRUD functionality using JSON as the data format]]></DESCRIPTION>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <HELP><![CDATA[This module implements the datasource concept. Datasources play a central role in Smartclient applications. The datasource module automatically creates a datasource for each Openbravo entity. In addition custom data source implementations can be defined.]]></HELP>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <URL><![CDATA[http://forge.openbravo.com/projects/datasourceservice]]></URL>
@@ -22,7 +22,7 @@
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <UPDATEINFO><![CDATA[Bug fixing & new development for 3.0]]></UPDATEINFO>
-<!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--A44B9BA75C354D8FB2E3F7D6EB6BFDC4--></AD_MODULE>
--- a/model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.datasource/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <AD_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_MODULE_ID>
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <AD_DEPENDENT_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_DEPENDENT_MODULE_ID>
-<!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <DEPENDANT_MODULE_NAME><![CDATA[JBoss Weld]]></DEPENDANT_MODULE_NAME>
 <!--0BA071C783CC4984AC9C03BB7CAA87C7-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <AD_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_MODULE_ID>
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <AD_DEPENDENT_MODULE_ID><![CDATA[F8D1B3ECB3474E8DA5C216473C840DF1]]></AD_DEPENDENT_MODULE_ID>
-<!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <STARTVERSION><![CDATA[2.0.31087]]></STARTVERSION>
+<!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <STARTVERSION><![CDATA[2.0.31787]]></STARTVERSION>
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON REST Webservice]]></DEPENDANT_MODULE_NAME>
 <!--3E531F0CD0A54130996F5AF3B6A2D01B-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <AD_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_MODULE_ID>
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--4FCE95802A854F7E8623AFF7C33D13EE-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--4FCE95802A854F7E8623AFF7C33D13EE-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--4FCE95802A854F7E8623AFF7C33D13EE-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -49,7 +49,7 @@
 <!--54AF8B39C55E4E7496902893ECD82786-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--54AF8B39C55E4E7496902893ECD82786-->  <AD_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_MODULE_ID>
 <!--54AF8B39C55E4E7496902893ECD82786-->  <AD_DEPENDENT_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_DEPENDENT_MODULE_ID>
-<!--54AF8B39C55E4E7496902893ECD82786-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--54AF8B39C55E4E7496902893ECD82786-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--54AF8B39C55E4E7496902893ECD82786-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--54AF8B39C55E4E7496902893ECD82786-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Client Kernel]]></DEPENDANT_MODULE_NAME>
 <!--54AF8B39C55E4E7496902893ECD82786-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -63,7 +63,7 @@
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <AD_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_MODULE_ID>
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <AD_DEPENDENT_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_DEPENDENT_MODULE_ID>
-<!--D03C56D8A4E14F45A5466350E05C631F-->  <STARTVERSION><![CDATA[8.1.31087]]></STARTVERSION>
+<!--D03C56D8A4E14F45A5466350E05C631F-->  <STARTVERSION><![CDATA[8.1.31787]]></STARTVERSION>
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <DEPENDANT_MODULE_NAME><![CDATA[Smartclient]]></DEPENDANT_MODULE_NAME>
 <!--D03C56D8A4E14F45A5466350E05C631F-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--FF8080813129ADA401312CA1222A0005-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--FF8080813129ADA401312CA1222A0005-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813129ADA401312CA1222A0005-->  <NAME><![CDATA[Integration with Google APIs]]></NAME>
-<!--FF8080813129ADA401312CA1222A0005-->  <VERSION><![CDATA[0.1.31087]]></VERSION>
+<!--FF8080813129ADA401312CA1222A0005-->  <VERSION><![CDATA[0.1.31787]]></VERSION>
 <!--FF8080813129ADA401312CA1222A0005-->  <DESCRIPTION><![CDATA[Integration with Google APIs]]></DESCRIPTION>
 <!--FF8080813129ADA401312CA1222A0005-->  <TYPE><![CDATA[M]]></TYPE>
 <!--FF8080813129ADA401312CA1222A0005-->  <LICENSE><![CDATA[Licensed under the Openbravo Public License Version 1.1.
@@ -19,7 +19,7 @@
 <!--FF8080813129ADA401312CA1222A0005-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--FF8080813129ADA401312CA1222A0005-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--FF8080813129ADA401312CA1222A0005-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--FF8080813129ADA401312CA1222A0005-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--FF8080813129ADA401312CA1222A0005-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--FF8080813129ADA401312CA1222A0005-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--FF8080813129ADA401312CA1222A0005-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--FF8080813129ADA401312CA1222A0005--></AD_MODULE>
--- a/model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.integration.google/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--FF8080813141B198013141BA0F7D0012-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813141B198013141BA0F7D0012-->  <AD_MODULE_ID><![CDATA[FF8080813129ADA401312CA1222A0005]]></AD_MODULE_ID>
 <!--FF8080813141B198013141BA0F7D0012-->  <AD_DEPENDENT_MODULE_ID><![CDATA[FF8080813141B198013141B86DD70003]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080813141B198013141BA0F7D0012-->  <STARTVERSION><![CDATA[0.1.31087]]></STARTVERSION>
+<!--FF8080813141B198013141BA0F7D0012-->  <STARTVERSION><![CDATA[0.1.31787]]></STARTVERSION>
 <!--FF8080813141B198013141BA0F7D0012-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--FF8080813141B198013141BA0F7D0012-->  <DEPENDANT_MODULE_NAME><![CDATA[OpenID Service Integration]]></DEPENDANT_MODULE_NAME>
 <!--FF8080813141B198013141BA0F7D0012-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--FF8080813151AEE1013151C4ACE6001B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813151AEE1013151C4ACE6001B-->  <AD_MODULE_ID><![CDATA[FF8080813129ADA401312CA1222A0005]]></AD_MODULE_ID>
 <!--FF8080813151AEE1013151C4ACE6001B-->  <AD_DEPENDENT_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080813151AEE1013151C4ACE6001B-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--FF8080813151AEE1013151C4ACE6001B-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--FF8080813151AEE1013151C4ACE6001B-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--FF8080813151AEE1013151C4ACE6001B-->  <DEPENDANT_MODULE_NAME><![CDATA[Openbravo 3.0 Framework]]></DEPENDANT_MODULE_NAME>
 <!--FF8080813151AEE1013151C4ACE6001B-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--FF8080813141B198013141B86DD70003-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--FF8080813141B198013141B86DD70003-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813141B198013141B86DD70003-->  <NAME><![CDATA[OpenID Service Integration]]></NAME>
-<!--FF8080813141B198013141B86DD70003-->  <VERSION><![CDATA[0.1.31087]]></VERSION>
+<!--FF8080813141B198013141B86DD70003-->  <VERSION><![CDATA[0.1.31787]]></VERSION>
 <!--FF8080813141B198013141B86DD70003-->  <DESCRIPTION><![CDATA[OpenID Service Integration]]></DESCRIPTION>
 <!--FF8080813141B198013141B86DD70003-->  <TYPE><![CDATA[M]]></TYPE>
 <!--FF8080813141B198013141B86DD70003-->  <LICENSE><![CDATA[Licensed under the Openbravo Public License Version 1.1.
@@ -19,7 +19,7 @@
 <!--FF8080813141B198013141B86DD70003-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--FF8080813141B198013141B86DD70003-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--FF8080813141B198013141B86DD70003-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--FF8080813141B198013141B86DD70003-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--FF8080813141B198013141B86DD70003-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--FF8080813141B198013141B86DD70003-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--FF8080813141B198013141B86DD70003-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--FF8080813141B198013141B86DD70003--></AD_MODULE>
--- a/model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.integration.openid/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--FF8080813141B198013141B8B21B0006-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813141B198013141B8B21B0006-->  <AD_MODULE_ID><![CDATA[FF8080813141B198013141B86DD70003]]></AD_MODULE_ID>
 <!--FF8080813141B198013141B8B21B0006-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080813141B198013141B8B21B0006-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--FF8080813141B198013141B8B21B0006-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--FF8080813141B198013141B8B21B0006-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--FF8080813141B198013141B8B21B0006-->  <DEPENDANT_MODULE_NAME><![CDATA[Core]]></DEPENDANT_MODULE_NAME>
 <!--FF8080813141B198013141B8B21B0006-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <NAME><![CDATA[JSON REST Webservice]]></NAME>
-<!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <VERSION><![CDATA[2.0.31087]]></VERSION>
+<!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <VERSION><![CDATA[2.0.31787]]></VERSION>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <DESCRIPTION><![CDATA[Provides a JSON REST webservice for CRUD service requests]]></DESCRIPTION>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <HELP><![CDATA[Provides a JSON REST webservice for CRUD service requests. Both the servlet implementation (receiving HTTP REST requests in JSON) as the backend processing are provided.]]></HELP>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <URL><![CDATA[http://forge.openbravo.com/projects/openbravojsonrest]]></URL>
@@ -22,7 +22,7 @@
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <UPDATEINFO><![CDATA[Bug fixing & new development for 3.0]]></UPDATEINFO>
-<!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--F8D1B3ECB3474E8DA5C216473C840DF1--></AD_MODULE>
--- a/model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.service.json/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--9E3E7B42DB16405FB794496D309D7044-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--9E3E7B42DB16405FB794496D309D7044-->  <AD_MODULE_ID><![CDATA[F8D1B3ECB3474E8DA5C216473C840DF1]]></AD_MODULE_ID>
 <!--9E3E7B42DB16405FB794496D309D7044-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--9E3E7B42DB16405FB794496D309D7044-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--9E3E7B42DB16405FB794496D309D7044-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--9E3E7B42DB16405FB794496D309D7044-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--9E3E7B42DB16405FB794496D309D7044-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--9E3E7B42DB16405FB794496D309D7044-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.userinterface.selector/src-db/database/model/tables/OBUISEL_SELECTOR_TRL.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.selector/src-db/database/model/tables/OBUISEL_SELECTOR_TRL.xml	Thu May 25 06:12:59 2017 +0000
@@ -78,6 +78,7 @@
       </foreign-key>
       <index name="OBUISEL_SELECTOR_TRL_LANGUAGE" unique="false">
         <index-column name="AD_LANGUAGE"/>
+        <whereClause><![CDATA[AD_LANGUAGE IS NOT NULL]]></whereClause>
       </index>
       <unique name="OBUISEL_SEL_TRL_ADLANG_UN">
         <unique-column name="OBUISEL_SELECTOR_ID"/>
--- a/model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <NAME><![CDATA[User Interface Selector]]></NAME>
-<!--5EB4F15C80684ACA904756BDC12ADBE5-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--5EB4F15C80684ACA904756BDC12ADBE5-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <DESCRIPTION><![CDATA[Provides a selector with a suggestion box and popup grid window]]></DESCRIPTION>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <HELP><![CDATA[The Openbravo selector provides new selector functionality which is used inside of existing Openbravo forms. The selector is mainly used for supporting foreign key references in the user interface. The selector combines both suggestion box behavior with a popup grid.]]></HELP>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <URL><![CDATA[http://forge.openbravo.com/projects/selector]]></URL>
@@ -22,7 +22,7 @@
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <UPDATEINFO><![CDATA[Bug fixing & new development for 3.0]]></UPDATEINFO>
-<!--5EB4F15C80684ACA904756BDC12ADBE5-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--5EB4F15C80684ACA904756BDC12ADBE5-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--5EB4F15C80684ACA904756BDC12ADBE5-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--5EB4F15C80684ACA904756BDC12ADBE5--></AD_MODULE>
--- a/model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.selector/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <AD_DEPENDENT_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_DEPENDENT_MODULE_ID>
-<!--38825CAED43941D38CA0C78DB04FCFA0-->  <STARTVERSION><![CDATA[8.1.31087]]></STARTVERSION>
+<!--38825CAED43941D38CA0C78DB04FCFA0-->  <STARTVERSION><![CDATA[8.1.31787]]></STARTVERSION>
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <DEPENDANT_MODULE_NAME><![CDATA[Smartclient]]></DEPENDANT_MODULE_NAME>
 <!--38825CAED43941D38CA0C78DB04FCFA0-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <AD_DEPENDENT_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_DEPENDENT_MODULE_ID>
-<!--6DDE7B1A70174242AF82B5022FB89279-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--6DDE7B1A70174242AF82B5022FB89279-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Application]]></DEPENDANT_MODULE_NAME>
 <!--6DDE7B1A70174242AF82B5022FB89279-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <AD_DEPENDENT_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_DEPENDENT_MODULE_ID>
-<!--94F9CD2CB5EF4467A67475C786C984A7-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--94F9CD2CB5EF4467A67475C786C984A7-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Client Kernel]]></DEPENDANT_MODULE_NAME>
 <!--94F9CD2CB5EF4467A67475C786C984A7-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -49,7 +49,7 @@
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <AD_DEPENDENT_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_DEPENDENT_MODULE_ID>
-<!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <DEPENDANT_MODULE_NAME><![CDATA[JBoss Weld]]></DEPENDANT_MODULE_NAME>
 <!--BCCB5A08EC0446DE8BCE191C6BC607A4-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -63,7 +63,7 @@
 <!--C8DAC574B88649D08C9468521B343F12-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--C8DAC574B88649D08C9468521B343F12-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--C8DAC574B88649D08C9468521B343F12-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--C8DAC574B88649D08C9468521B343F12-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--C8DAC574B88649D08C9468521B343F12-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--C8DAC574B88649D08C9468521B343F12-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--C8DAC574B88649D08C9468521B343F12-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--C8DAC574B88649D08C9468521B343F12-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -77,7 +77,7 @@
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <AD_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_MODULE_ID>
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_DEPENDENT_MODULE_ID>
-<!--F14EB17946BE4724A46F80CB1A47EC70-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--F14EB17946BE4724A46F80CB1A47EC70-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON Datasource]]></DEPENDANT_MODULE_NAME>
 <!--F14EB17946BE4724A46F80CB1A47EC70-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <NAME><![CDATA[2.50 to 3.00 Compatibility Skin]]></NAME>
-<!--96998CBC42744B3DBEE28AC8095C9335-->  <VERSION><![CDATA[2.0.31087]]></VERSION>
+<!--96998CBC42744B3DBEE28AC8095C9335-->  <VERSION><![CDATA[2.0.31787]]></VERSION>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <DESCRIPTION><![CDATA[Skin module to proper visualization of classic windows inside the MDI interface]]></DESCRIPTION>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <HELP><![CDATA[With this skin module the classic windows styles will display in a way more coherent with the new 3.00 styles]]></HELP>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <URL><![CDATA[www.openbravo.com]]></URL>
@@ -23,7 +23,7 @@
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--96998CBC42744B3DBEE28AC8095C9335-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--96998CBC42744B3DBEE28AC8095C9335-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--96998CBC42744B3DBEE28AC8095C9335-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--96998CBC42744B3DBEE28AC8095C9335--></AD_MODULE>
--- a/model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.skin.250to300Comp/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <AD_MODULE_ID><![CDATA[96998CBC42744B3DBEE28AC8095C9335]]></AD_MODULE_ID>
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--39BF75AD9AB3453698BF5DE29E727AA9-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--39BF75AD9AB3453698BF5DE29E727AA9-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--39BF75AD9AB3453698BF5DE29E727AA9-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <NAME><![CDATA[Smartclient]]></NAME>
-<!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <VERSION><![CDATA[8.1.31087]]></VERSION>
+<!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <VERSION><![CDATA[8.1.31787]]></VERSION>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <DESCRIPTION><![CDATA[SmartClient libraries for use within Openbravo]]></DESCRIPTION>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <HELP><![CDATA[This module contains the SmartClient libraries for usage by other modules. It also contains some simple test pages to validate that SmartClient is working correctly. Also contains generic Openbravo SmartClient components]]></HELP>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <URL><![CDATA[http://forge.openbravo.com/projects/obsmartclient]]></URL>
@@ -23,7 +23,7 @@
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <UPDATEINFO><![CDATA[Bug fixing & new development for 3.0
 Updated to new SmartClient 8.3d 26-May-2012]]></UPDATEINFO>
-<!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--EC356CEE3D46416CA1EBEEB9AB82EDB9--></AD_MODULE>
--- a/model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.userinterface.smartclient/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--086331E18477496B8AC74D2CFEBD1307-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--086331E18477496B8AC74D2CFEBD1307-->  <AD_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_MODULE_ID>
 <!--086331E18477496B8AC74D2CFEBD1307-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--086331E18477496B8AC74D2CFEBD1307-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--086331E18477496B8AC74D2CFEBD1307-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--086331E18477496B8AC74D2CFEBD1307-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--086331E18477496B8AC74D2CFEBD1307-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--086331E18477496B8AC74D2CFEBD1307-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--DC5D4EF450244482BD2B458DAA496333-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--DC5D4EF450244482BD2B458DAA496333-->  <AD_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_MODULE_ID>
 <!--DC5D4EF450244482BD2B458DAA496333-->  <AD_DEPENDENT_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_DEPENDENT_MODULE_ID>
-<!--DC5D4EF450244482BD2B458DAA496333-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--DC5D4EF450244482BD2B458DAA496333-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--DC5D4EF450244482BD2B458DAA496333-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--DC5D4EF450244482BD2B458DAA496333-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Client Kernel]]></DEPENDANT_MODULE_NAME>
 <!--DC5D4EF450244482BD2B458DAA496333-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <AD_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_MODULE_ID>
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <AD_DEPENDENT_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_DEPENDENT_MODULE_ID>
-<!--F2AF15C0AF5540E393D96BE506E20648-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--F2AF15C0AF5540E393D96BE506E20648-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <DEPENDANT_MODULE_NAME><![CDATA[JBoss Weld]]></DEPENDANT_MODULE_NAME>
 <!--F2AF15C0AF5540E393D96BE506E20648-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <NAME><![CDATA[Log Clean Up Utility]]></NAME>
-<!--8A34B301DC524EA3A07513DF9F42CC90-->  <VERSION><![CDATA[1.0.31087]]></VERSION>
+<!--8A34B301DC524EA3A07513DF9F42CC90-->  <VERSION><![CDATA[1.0.31787]]></VERSION>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <DESCRIPTION><![CDATA[Log Clean Up Utility]]></DESCRIPTION>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <HELP><![CDATA[Utility to periodically cleanup log tables]]></HELP>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <URL><![CDATA[http://centralrepository.openbravo.com/heartbeat-server/org.openbravo.forge.ui/ForgeProjectDetail?projectId=7DC25E3B7ADE426CAD71E7804B95C1BF]]></URL>
@@ -21,7 +21,7 @@
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <HASREFERENCEDATA><![CDATA[Y]]></HASREFERENCEDATA>
-<!--8A34B301DC524EA3A07513DF9F42CC90-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--8A34B301DC524EA3A07513DF9F42CC90-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--8A34B301DC524EA3A07513DF9F42CC90-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--8A34B301DC524EA3A07513DF9F42CC90--></AD_MODULE>
--- a/model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.utility.cleanup.log/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--86EBD30DEB8045508185B457896C9F6D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--86EBD30DEB8045508185B457896C9F6D-->  <AD_MODULE_ID><![CDATA[8A34B301DC524EA3A07513DF9F42CC90]]></AD_MODULE_ID>
 <!--86EBD30DEB8045508185B457896C9F6D-->  <AD_DEPENDENT_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_DEPENDENT_MODULE_ID>
-<!--86EBD30DEB8045508185B457896C9F6D-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--86EBD30DEB8045508185B457896C9F6D-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--86EBD30DEB8045508185B457896C9F6D-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--86EBD30DEB8045508185B457896C9F6D-->  <DEPENDANT_MODULE_NAME><![CDATA[Openbravo 3.0 Framework]]></DEPENDANT_MODULE_NAME>
 <!--86EBD30DEB8045508185B457896C9F6D-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <NAME><![CDATA[Standard Roles]]></NAME>
-<!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <VERSION><![CDATA[3.0.31087]]></VERSION>
+<!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <VERSION><![CDATA[3.0.31787]]></VERSION>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <DESCRIPTION><![CDATA[Pre-configured collection of standard ERP roles]]></DESCRIPTION>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <HELP><![CDATA[This dataset contains the following roles with their access to corresponding Openbravo entities - windows, reports, actions.
 * Employee - Any person of the enterprise
@@ -28,7 +28,7 @@
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <HASREFERENCEDATA><![CDATA[Y]]></HASREFERENCEDATA>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <REFERENCEDATAINFO><![CDATA[Pre-configured collection of standard ERP roles]]></REFERENCEDATAINFO>
-<!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--883B5872CA0548F9AF2BBBE7D2DDFA61--></AD_MODULE>
--- a/model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3.datasets/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <AD_MODULE_ID><![CDATA[883B5872CA0548F9AF2BBBE7D2DDFA61]]></AD_MODULE_ID>
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--148A000EE9A04A3CA653B1296A00B8E6-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--148A000EE9A04A3CA653B1296A00B8E6-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--148A000EE9A04A3CA653B1296A00B8E6-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--30F966407A6F4E15965821BAEE34D25B-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--30F966407A6F4E15965821BAEE34D25B-->  <AD_MODULE_ID><![CDATA[883B5872CA0548F9AF2BBBE7D2DDFA61]]></AD_MODULE_ID>
 <!--30F966407A6F4E15965821BAEE34D25B-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_DEPENDENT_MODULE_ID>
-<!--30F966407A6F4E15965821BAEE34D25B-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--30F966407A6F4E15965821BAEE34D25B-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--30F966407A6F4E15965821BAEE34D25B-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--30F966407A6F4E15965821BAEE34D25B-->  <DEPENDANT_MODULE_NAME><![CDATA[Advanced Payables and Receivables Mngmt]]></DEPENDANT_MODULE_NAME>
 <!--30F966407A6F4E15965821BAEE34D25B-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--F93CE30003B24F8F8886510B0065EECC-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--F93CE30003B24F8F8886510B0065EECC-->  <AD_MODULE_ID><![CDATA[883B5872CA0548F9AF2BBBE7D2DDFA61]]></AD_MODULE_ID>
 <!--F93CE30003B24F8F8886510B0065EECC-->  <AD_DEPENDENT_MODULE_ID><![CDATA[3A3A943684D64DEF9EC39F588A656848]]></AD_DEPENDENT_MODULE_ID>
-<!--F93CE30003B24F8F8886510B0065EECC-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--F93CE30003B24F8F8886510B0065EECC-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--F93CE30003B24F8F8886510B0065EECC-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--F93CE30003B24F8F8886510B0065EECC-->  <DEPENDANT_MODULE_NAME><![CDATA[Orders Awaiting Delivery]]></DEPENDANT_MODULE_NAME>
 <!--F93CE30003B24F8F8886510B0065EECC-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <NAME><![CDATA[Openbravo 3.0 Framework]]></NAME>
-<!--7E48CDD73B7E493A8BED4F7253E7C989-->  <VERSION><![CDATA[2.1.31087]]></VERSION>
+<!--7E48CDD73B7E493A8BED4F7253E7C989-->  <VERSION><![CDATA[2.1.31787]]></VERSION>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <DESCRIPTION><![CDATA[Openbravo 3.0 Framework]]></DESCRIPTION>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <HELP><![CDATA[Contains all the components required to run the Openbravo 3.0 framework]]></HELP>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <URL><![CDATA[http://forge.openbravo.com/projects/openbravov30framework]]></URL>
@@ -24,7 +24,7 @@
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <UPDATEINFO><![CDATA[minor bugfix release to include latest client.application 2.0.1, client.myob 2.0.2 and client.kernel 2.0.1]]></UPDATEINFO>
-<!--7E48CDD73B7E493A8BED4F7253E7C989-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--7E48CDD73B7E493A8BED4F7253E7C989-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--7E48CDD73B7E493A8BED4F7253E7C989-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--7E48CDD73B7E493A8BED4F7253E7C989--></AD_MODULE>
--- a/model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3.framework/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <AD_DEPENDENT_MODULE_ID><![CDATA[2758CD25B2704AF6BBAD10365FC82C06]]></AD_DEPENDENT_MODULE_ID>
-<!--01E1BCCEC9114DE0960538DF34E30E6F-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--01E1BCCEC9114DE0960538DF34E30E6F-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <DEPENDANT_MODULE_NAME><![CDATA[My Openbravo Tab]]></DEPENDANT_MODULE_NAME>
 <!--01E1BCCEC9114DE0960538DF34E30E6F-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--025B181F63CA47B48A920F6983242390-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--025B181F63CA47B48A920F6983242390-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--025B181F63CA47B48A920F6983242390-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--025B181F63CA47B48A920F6983242390-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--025B181F63CA47B48A920F6983242390-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--025B181F63CA47B48A920F6983242390-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--025B181F63CA47B48A920F6983242390-->  <DEPENDANT_MODULE_NAME><![CDATA[core]]></DEPENDANT_MODULE_NAME>
 <!--025B181F63CA47B48A920F6983242390-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <AD_DEPENDENT_MODULE_ID><![CDATA[9BA0836A3CD74EE4AB48753A47211BCC]]></AD_DEPENDENT_MODULE_ID>
-<!--054B4FEAF919478AA3FF27098A46D1D6-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--054B4FEAF919478AA3FF27098A46D1D6-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Application]]></DEPENDANT_MODULE_NAME>
 <!--054B4FEAF919478AA3FF27098A46D1D6-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -49,7 +49,7 @@
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0A060B2AF1974E8EAA8DB61388E9AECC]]></AD_DEPENDENT_MODULE_ID>
-<!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <STARTVERSION><![CDATA[1.0.31087]]></STARTVERSION>
+<!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <STARTVERSION><![CDATA[1.0.31787]]></STARTVERSION>
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <DEPENDANT_MODULE_NAME><![CDATA[Query/List Widget]]></DEPENDANT_MODULE_NAME>
 <!--1FA6BAA6DC3A4434A6E62A0D1319A9D7-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -63,7 +63,7 @@
 <!--224754C3EF674C93B0D468F47BAAB824-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--224754C3EF674C93B0D468F47BAAB824-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--224754C3EF674C93B0D468F47BAAB824-->  <AD_DEPENDENT_MODULE_ID><![CDATA[5EB4F15C80684ACA904756BDC12ADBE5]]></AD_DEPENDENT_MODULE_ID>
-<!--224754C3EF674C93B0D468F47BAAB824-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--224754C3EF674C93B0D468F47BAAB824-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--224754C3EF674C93B0D468F47BAAB824-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--224754C3EF674C93B0D468F47BAAB824-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Selector]]></DEPENDANT_MODULE_NAME>
 <!--224754C3EF674C93B0D468F47BAAB824-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -77,7 +77,7 @@
 <!--5B72D24032DD4879A950194139D961B6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--5B72D24032DD4879A950194139D961B6-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--5B72D24032DD4879A950194139D961B6-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A44B9BA75C354D8FB2E3F7D6EB6BFDC4]]></AD_DEPENDENT_MODULE_ID>
-<!--5B72D24032DD4879A950194139D961B6-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--5B72D24032DD4879A950194139D961B6-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--5B72D24032DD4879A950194139D961B6-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--5B72D24032DD4879A950194139D961B6-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON Datasource]]></DEPENDANT_MODULE_NAME>
 <!--5B72D24032DD4879A950194139D961B6-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -91,7 +91,7 @@
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <AD_DEPENDENT_MODULE_ID><![CDATA[D393BE6F22BB44B7B728259B34FC795A]]></AD_DEPENDENT_MODULE_ID>
-<!--8730CA6A4224439D82E0DD31B3806E36-->  <STARTVERSION><![CDATA[1.0.31087]]></STARTVERSION>
+<!--8730CA6A4224439D82E0DD31B3806E36-->  <STARTVERSION><![CDATA[1.0.31787]]></STARTVERSION>
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <DEPENDANT_MODULE_NAME><![CDATA[HTML Widget]]></DEPENDANT_MODULE_NAME>
 <!--8730CA6A4224439D82E0DD31B3806E36-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -105,7 +105,7 @@
 <!--98C47FF058F8413B8A2B26036061446E-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--98C47FF058F8413B8A2B26036061446E-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--98C47FF058F8413B8A2B26036061446E-->  <AD_DEPENDENT_MODULE_ID><![CDATA[EC356CEE3D46416CA1EBEEB9AB82EDB9]]></AD_DEPENDENT_MODULE_ID>
-<!--98C47FF058F8413B8A2B26036061446E-->  <STARTVERSION><![CDATA[8.1.31087]]></STARTVERSION>
+<!--98C47FF058F8413B8A2B26036061446E-->  <STARTVERSION><![CDATA[8.1.31787]]></STARTVERSION>
 <!--98C47FF058F8413B8A2B26036061446E-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--98C47FF058F8413B8A2B26036061446E-->  <DEPENDANT_MODULE_NAME><![CDATA[Smartclient]]></DEPENDANT_MODULE_NAME>
 <!--98C47FF058F8413B8A2B26036061446E-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -119,7 +119,7 @@
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <AD_DEPENDENT_MODULE_ID><![CDATA[96998CBC42744B3DBEE28AC8095C9335]]></AD_DEPENDENT_MODULE_ID>
-<!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <STARTVERSION><![CDATA[2.0.31087]]></STARTVERSION>
+<!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <STARTVERSION><![CDATA[2.0.31787]]></STARTVERSION>
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <DEPENDANT_MODULE_NAME><![CDATA[2.50 to 3.00 Compatibility Skin]]></DEPENDANT_MODULE_NAME>
 <!--A6D7BA917B3B4DEABD7CA1BA00B01E8A-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -133,7 +133,7 @@
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <AD_DEPENDENT_MODULE_ID><![CDATA[4B828F4D03264080AA1D2057B13F613C]]></AD_DEPENDENT_MODULE_ID>
-<!--A9CB99330AF34944877F889DD8A0AB3C-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--A9CB99330AF34944877F889DD8A0AB3C-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <DEPENDANT_MODULE_NAME><![CDATA[User Interface Client Kernel]]></DEPENDANT_MODULE_NAME>
 <!--A9CB99330AF34944877F889DD8A0AB3C-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -147,7 +147,7 @@
 <!--E72A053A403C4A98A189C105B850ADB0-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--E72A053A403C4A98A189C105B850ADB0-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--E72A053A403C4A98A189C105B850ADB0-->  <AD_DEPENDENT_MODULE_ID><![CDATA[C70732EA90A14EC0916078B85CC33D2D]]></AD_DEPENDENT_MODULE_ID>
-<!--E72A053A403C4A98A189C105B850ADB0-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--E72A053A403C4A98A189C105B850ADB0-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--E72A053A403C4A98A189C105B850ADB0-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--E72A053A403C4A98A189C105B850ADB0-->  <DEPENDANT_MODULE_NAME><![CDATA[JBoss Weld]]></DEPENDANT_MODULE_NAME>
 <!--E72A053A403C4A98A189C105B850ADB0-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -161,7 +161,7 @@
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <AD_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_MODULE_ID>
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <AD_DEPENDENT_MODULE_ID><![CDATA[F8D1B3ECB3474E8DA5C216473C840DF1]]></AD_DEPENDENT_MODULE_ID>
-<!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <STARTVERSION><![CDATA[2.0.31087]]></STARTVERSION>
+<!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <STARTVERSION><![CDATA[2.0.31787]]></STARTVERSION>
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <DEPENDANT_MODULE_NAME><![CDATA[JSON REST Webservice]]></DEPENDANT_MODULE_NAME>
 <!--F62443FC17DA4C0E84FBCA9F2E5B68C0-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <NAME><![CDATA[Openbravo 3.0]]></NAME>
-<!--0138E7A89B5E4DC3932462252801FFBC-->  <VERSION><![CDATA[3.0.31087]]></VERSION>
+<!--0138E7A89B5E4DC3932462252801FFBC-->  <VERSION><![CDATA[3.0.31787]]></VERSION>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <DESCRIPTION><![CDATA[Openbravo 3.0 distribution template]]></DESCRIPTION>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <HELP><![CDATA[Openbravo 3.0 is a collection (distribution) of modules. This template is a container of all the modules and configuration changes that compose Openbravo 3.0.]]></HELP>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <URL><![CDATA[http://forge.openbravo.com/projects/vthree]]></URL>
@@ -20,7 +20,7 @@
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <HASCHARTOFACCOUNTS><![CDATA[N]]></HASCHARTOFACCOUNTS>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <HASREFERENCEDATA><![CDATA[N]]></HASREFERENCEDATA>
-<!--0138E7A89B5E4DC3932462252801FFBC-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--0138E7A89B5E4DC3932462252801FFBC-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--0138E7A89B5E4DC3932462252801FFBC-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--0138E7A89B5E4DC3932462252801FFBC--></AD_MODULE>
--- a/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_DEPENDENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -7,7 +7,7 @@
 <!--48D556894CE54CF998DC97882E904CBD-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--48D556894CE54CF998DC97882E904CBD-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--48D556894CE54CF998DC97882E904CBD-->  <AD_DEPENDENT_MODULE_ID><![CDATA[8A098711BB324335A19833286BDB093D]]></AD_DEPENDENT_MODULE_ID>
-<!--48D556894CE54CF998DC97882E904CBD-->  <STARTVERSION><![CDATA[1.0.31087]]></STARTVERSION>
+<!--48D556894CE54CF998DC97882E904CBD-->  <STARTVERSION><![CDATA[1.0.31787]]></STARTVERSION>
 <!--48D556894CE54CF998DC97882E904CBD-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--48D556894CE54CF998DC97882E904CBD-->  <DEPENDANT_MODULE_NAME><![CDATA[Apache External Connection Pool]]></DEPENDANT_MODULE_NAME>
 <!--48D556894CE54CF998DC97882E904CBD-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -21,7 +21,7 @@
 <!--4D11E3A70650475381139522373CD191-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--4D11E3A70650475381139522373CD191-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--4D11E3A70650475381139522373CD191-->  <AD_DEPENDENT_MODULE_ID><![CDATA[7E48CDD73B7E493A8BED4F7253E7C989]]></AD_DEPENDENT_MODULE_ID>
-<!--4D11E3A70650475381139522373CD191-->  <STARTVERSION><![CDATA[2.1.31087]]></STARTVERSION>
+<!--4D11E3A70650475381139522373CD191-->  <STARTVERSION><![CDATA[2.1.31787]]></STARTVERSION>
 <!--4D11E3A70650475381139522373CD191-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--4D11E3A70650475381139522373CD191-->  <DEPENDANT_MODULE_NAME><![CDATA[Openbravo 3.0 Framework]]></DEPENDANT_MODULE_NAME>
 <!--4D11E3A70650475381139522373CD191-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -35,7 +35,7 @@
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <AD_DEPENDENT_MODULE_ID><![CDATA[2A5EE903D7974AC298C0504FBC4501A7]]></AD_DEPENDENT_MODULE_ID>
-<!--52CE523C40634C47A99C6EBBD9C3125C-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--52CE523C40634C47A99C6EBBD9C3125C-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <DEPENDANT_MODULE_NAME><![CDATA[Payment Report]]></DEPENDANT_MODULE_NAME>
 <!--52CE523C40634C47A99C6EBBD9C3125C-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -49,7 +49,7 @@
 <!--60834727BB114764ACEF019F40A34562-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--60834727BB114764ACEF019F40A34562-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--60834727BB114764ACEF019F40A34562-->  <AD_DEPENDENT_MODULE_ID><![CDATA[3A3A943684D64DEF9EC39F588A656848]]></AD_DEPENDENT_MODULE_ID>
-<!--60834727BB114764ACEF019F40A34562-->  <STARTVERSION><![CDATA[1.1.31087]]></STARTVERSION>
+<!--60834727BB114764ACEF019F40A34562-->  <STARTVERSION><![CDATA[1.1.31787]]></STARTVERSION>
 <!--60834727BB114764ACEF019F40A34562-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--60834727BB114764ACEF019F40A34562-->  <DEPENDANT_MODULE_NAME><![CDATA[Orders Awaiting Delivery]]></DEPENDANT_MODULE_NAME>
 <!--60834727BB114764ACEF019F40A34562-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -63,7 +63,7 @@
 <!--8418885E97D643138B6D907671351E3D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--8418885E97D643138B6D907671351E3D-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--8418885E97D643138B6D907671351E3D-->  <AD_DEPENDENT_MODULE_ID><![CDATA[883B5872CA0548F9AF2BBBE7D2DDFA61]]></AD_DEPENDENT_MODULE_ID>
-<!--8418885E97D643138B6D907671351E3D-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--8418885E97D643138B6D907671351E3D-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--8418885E97D643138B6D907671351E3D-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--8418885E97D643138B6D907671351E3D-->  <DEPENDANT_MODULE_NAME><![CDATA[Standard Roles]]></DEPENDANT_MODULE_NAME>
 <!--8418885E97D643138B6D907671351E3D-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -77,7 +77,7 @@
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <AD_DEPENDENT_MODULE_ID><![CDATA[0]]></AD_DEPENDENT_MODULE_ID>
-<!--A32F3279B3374FC0A6CFEA2368BB7053-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--A32F3279B3374FC0A6CFEA2368BB7053-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <ISINCLUDED><![CDATA[N]]></ISINCLUDED>
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <DEPENDANT_MODULE_NAME><![CDATA[Core]]></DEPENDANT_MODULE_NAME>
 <!--A32F3279B3374FC0A6CFEA2368BB7053-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MINOR]]></DEPENDENCY_ENFORCEMENT>
@@ -91,7 +91,7 @@
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <AD_DEPENDENT_MODULE_ID><![CDATA[A918E3331C404B889D69AA9BFAFB23AC]]></AD_DEPENDENT_MODULE_ID>
-<!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <STARTVERSION><![CDATA[3.0.31087]]></STARTVERSION>
+<!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <STARTVERSION><![CDATA[3.0.31787]]></STARTVERSION>
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <DEPENDANT_MODULE_NAME><![CDATA[Advanced Payables and Receivables Mngmt]]></DEPENDANT_MODULE_NAME>
 <!--ED06CE9F2AFD4092871D9E9494AF42DD-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -105,7 +105,7 @@
 <!--FEF6E40F244A4061B7C62CB755663712-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FEF6E40F244A4061B7C62CB755663712-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--FEF6E40F244A4061B7C62CB755663712-->  <AD_DEPENDENT_MODULE_ID><![CDATA[8A34B301DC524EA3A07513DF9F42CC90]]></AD_DEPENDENT_MODULE_ID>
-<!--FEF6E40F244A4061B7C62CB755663712-->  <STARTVERSION><![CDATA[1.0.31087]]></STARTVERSION>
+<!--FEF6E40F244A4061B7C62CB755663712-->  <STARTVERSION><![CDATA[1.0.31787]]></STARTVERSION>
 <!--FEF6E40F244A4061B7C62CB755663712-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--FEF6E40F244A4061B7C62CB755663712-->  <DEPENDANT_MODULE_NAME><![CDATA[Log Clean Up Utility]]></DEPENDANT_MODULE_NAME>
 <!--FEF6E40F244A4061B7C62CB755663712-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -119,7 +119,7 @@
 <!--FF8080813189932B013189B45B59003A-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813189932B013189B45B59003A-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--FF8080813189932B013189B45B59003A-->  <AD_DEPENDENT_MODULE_ID><![CDATA[FF8080813141B198013141B86DD70003]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080813189932B013189B45B59003A-->  <STARTVERSION><![CDATA[0.1.31087]]></STARTVERSION>
+<!--FF8080813189932B013189B45B59003A-->  <STARTVERSION><![CDATA[0.1.31787]]></STARTVERSION>
 <!--FF8080813189932B013189B45B59003A-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--FF8080813189932B013189B45B59003A-->  <DEPENDANT_MODULE_NAME><![CDATA[OpenID Service Integration]]></DEPENDANT_MODULE_NAME>
 <!--FF8080813189932B013189B45B59003A-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -133,7 +133,7 @@
 <!--FF8080813189932B013189B4C00F003D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8080813189932B013189B4C00F003D-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--FF8080813189932B013189B4C00F003D-->  <AD_DEPENDENT_MODULE_ID><![CDATA[FF8080813129ADA401312CA1222A0005]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8080813189932B013189B4C00F003D-->  <STARTVERSION><![CDATA[0.1.31087]]></STARTVERSION>
+<!--FF8080813189932B013189B4C00F003D-->  <STARTVERSION><![CDATA[0.1.31787]]></STARTVERSION>
 <!--FF8080813189932B013189B4C00F003D-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--FF8080813189932B013189B4C00F003D-->  <DEPENDANT_MODULE_NAME><![CDATA[Integration with Google APIs]]></DEPENDANT_MODULE_NAME>
 <!--FF8080813189932B013189B4C00F003D-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
@@ -147,7 +147,7 @@
 <!--FF8081812E2F6F3C012E2F750109001C-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--FF8081812E2F6F3C012E2F750109001C-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
 <!--FF8081812E2F6F3C012E2F750109001C-->  <AD_DEPENDENT_MODULE_ID><![CDATA[FF8080812D842086012D844F3CC0003E]]></AD_DEPENDENT_MODULE_ID>
-<!--FF8081812E2F6F3C012E2F750109001C-->  <STARTVERSION><![CDATA[0.0.31087]]></STARTVERSION>
+<!--FF8081812E2F6F3C012E2F750109001C-->  <STARTVERSION><![CDATA[0.0.31787]]></STARTVERSION>
 <!--FF8081812E2F6F3C012E2F750109001C-->  <ISINCLUDED><![CDATA[Y]]></ISINCLUDED>
 <!--FF8081812E2F6F3C012E2F750109001C-->  <DEPENDANT_MODULE_NAME><![CDATA[Widgets Collection]]></DEPENDANT_MODULE_NAME>
 <!--FF8081812E2F6F3C012E2F750109001C-->  <DEPENDENCY_ENFORCEMENT><![CDATA[MAJOR]]></DEPENDENCY_ENFORCEMENT>
--- a/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_MERGE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/modules/org.openbravo.v3/src-db/database/sourcedata/AD_MODULE_MERGE.xml	Thu May 25 06:12:59 2017 +0000
@@ -10,6 +10,26 @@
 <!--10FBB7E64CFC495EB32B3C6F17D10197-->  <MERGED_MODULE_NAME><![CDATA[Inventory Average Cost transactions]]></MERGED_MODULE_NAME>
 <!--10FBB7E64CFC495EB32B3C6F17D10197--></AD_MODULE_MERGE>
 
+<!--12D2973485914E9AB38702464C531896--><AD_MODULE_MERGE>
+<!--12D2973485914E9AB38702464C531896-->  <AD_MODULE_MERGE_ID><![CDATA[12D2973485914E9AB38702464C531896]]></AD_MODULE_MERGE_ID>
+<!--12D2973485914E9AB38702464C531896-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--12D2973485914E9AB38702464C531896-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--12D2973485914E9AB38702464C531896-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--12D2973485914E9AB38702464C531896-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
+<!--12D2973485914E9AB38702464C531896-->  <MERGED_MODULE_UUID><![CDATA[391979C3E1A44A9D814B3F9756FC57F4]]></MERGED_MODULE_UUID>
+<!--12D2973485914E9AB38702464C531896-->  <MERGED_MODULE_NAME><![CDATA[Aging Balance Report]]></MERGED_MODULE_NAME>
+<!--12D2973485914E9AB38702464C531896--></AD_MODULE_MERGE>
+
+<!--766B82ABD28C42E999EF034F80F73992--><AD_MODULE_MERGE>
+<!--766B82ABD28C42E999EF034F80F73992-->  <AD_MODULE_MERGE_ID><![CDATA[766B82ABD28C42E999EF034F80F73992]]></AD_MODULE_MERGE_ID>
+<!--766B82ABD28C42E999EF034F80F73992-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--766B82ABD28C42E999EF034F80F73992-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--766B82ABD28C42E999EF034F80F73992-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--766B82ABD28C42E999EF034F80F73992-->  <AD_MODULE_ID><![CDATA[0138E7A89B5E4DC3932462252801FFBC]]></AD_MODULE_ID>
+<!--766B82ABD28C42E999EF034F80F73992-->  <MERGED_MODULE_UUID><![CDATA[FF80808131D1689F0131D170F19A0006]]></MERGED_MODULE_UUID>
+<!--766B82ABD28C42E999EF034F80F73992-->  <MERGED_MODULE_NAME><![CDATA[Report: Cash Flow Forecast]]></MERGED_MODULE_NAME>
+<!--766B82ABD28C42E999EF034F80F73992--></AD_MODULE_MERGE>
+
 <!--9AF40DD3765F4F048F3C9764C3A82796--><AD_MODULE_MERGE>
 <!--9AF40DD3765F4F048F3C9764C3A82796-->  <AD_MODULE_MERGE_ID><![CDATA[9AF40DD3765F4F048F3C9764C3A82796]]></AD_MODULE_MERGE_ID>
 <!--9AF40DD3765F4F048F3C9764C3A82796-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/model/excludeFilter.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/excludeFilter.xml	Thu May 25 06:12:59 2017 +0000
@@ -67,4 +67,24 @@
     <excludedFunction name="ADD_HMS"/>
     <excludedFunction name="PG\_%"/> <!-- PostgreSQL extension functions -->
     <excludedTrigger name="AU\_%"/> <!-- Audit trail triggers -->
+    <excludedFunction name="GIN_EXTRACT_QUERY_TRGM"/>
+    <excludedFunction name="GIN_EXTRACT_VALUE_TRGM"/>
+    <excludedFunction name="GIN_TRGM_CONSISTENT"/>
+    <excludedFunction name="GTRGM_COMPRESS"/>
+    <excludedFunction name="GTRGM_CONSISTENT"/>
+    <excludedFunction name="GTRGM_DECOMPRESS"/>
+    <excludedFunction name="GTRGM_DISTANCE"/>
+    <excludedFunction name="GTRGM_IN"/>
+    <excludedFunction name="GTRGM_OUT"/>
+    <excludedFunction name="GTRGM_PENALTY"/>
+    <excludedFunction name="GTRGM_PICKSPLIT"/>
+    <excludedFunction name="GTRGM_SAME"/>
+    <excludedFunction name="GTRGM_UNION"/>
+    <excludedFunction name="SET_LIMIT"/>
+    <excludedFunction name="SHOW_LIMIT"/>
+    <excludedFunction name="SHOW_TRGM"/>
+    <excludedFunction name="SIMILARITY"/>
+    <excludedFunction name="SIMILARITY_DIST"/>
+    <excludedFunction name="SIMILARITY_OP"/>
+    <excludedFunction name="OBEQUALS"/>
   </vector>
--- a/model/src-db/database/model/functions/C_COMMISSION_PROCESS.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_COMMISSION_PROCESS.xml	Thu May 25 06:12:59 2017 +0000
@@ -16,7 +16,7 @@
   * Portions created by Jorg Janke are Copyright (C) 1999-2001 Jorg Janke, parts
   * created by ComPiere are Copyright (C) ComPiere, Inc.;   All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2001-2015 Openbravo S.L.U.
+  * Contributions are Copyright (C) 2001-2017 Openbravo S.L.U.
   ******************************************************************************/
   -- Logistice
   v_ResultStr VARCHAR2(2000):='';
@@ -249,7 +249,7 @@
           IF(v_ListDetails='Y' OR v_IsCascade='Y') THEN
             IF(v_BasisAmt='N') THEN
               IF(v_BasisStatus='F') THEN
-                v_Cmd:='SELECT h.C_Currency_ID, CASE WHEN dt.docbasetype IN (''ARC'',''APC'') THEN -1 ELSE 1 END * l.LineNetAmt * (psv.expected / h.grandtotal),'
+                v_Cmd:='SELECT h.C_Currency_ID, l.LineNetAmt * (psv.expected / h.grandtotal),'
                 || 'CASE WHEN dt.docbasetype IN (''ARC'',''APC'') THEN -1 ELSE 1 END * l.QtyInvoiced, '
                 || 'NULL, l.C_InvoiceLine_ID, h.DocumentNo, substr(COALESCE(prd.Name,l.Description),1,60), ''Y'' '
                 || 'FROM C_Invoice h JOIN C_InvoiceLine l ON h.C_Invoice_ID = l.C_Invoice_ID'
@@ -286,7 +286,7 @@
           ELSE
             --v_BasisAmt = 'N'
             IF(v_BasisStatus='F') THEN
-              v_Cmd:='SELECT h.C_Currency_ID, SUM(CASE WHEN dt.docbasetype IN (''ARC'',''APC'') THEN -1 ELSE 1 END * l.LineNetAmt * (psv.expected / h.grandtotal)) AS Amt,'
+              v_Cmd:='SELECT h.C_Currency_ID, SUM(l.LineNetAmt * (psv.expected / h.grandtotal)) AS Amt,'
               || ' SUM(CASE WHEN dt.docbasetype IN (''ARC'',''APC'') THEN -1 ELSE 1 END * l.QtyInvoiced) AS Qty, '
               || 'NULL, NULL, NULL, NULL, ''Y'' '
               || 'FROM C_Invoice h JOIN C_InvoiceLine l ON h.C_Invoice_ID = l.C_Invoice_ID'
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/C_CONVERT_DOC_CURRENCY.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,82 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION C_CONVERT_DOC_CURRENCY">
+    <function name="C_CONVERT_DOC_CURRENCY" type="NUMERIC">
+      <parameter name="p_amount" type="NUMERIC" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curfrom_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curto_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_convdate" type="TIMESTAMP" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_c_invoice_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_fin_payment_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_fin_finacc_transaction_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_client_id" type="VARCHAR" mode="in">
+        <default><![CDATA[0]]></default>
+      </parameter>
+      <parameter name="p_org_id" type="VARCHAR" mode="in">
+        <default><![CDATA[0]]></default>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2011 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+  v_Rate NUMBER;
+  v_ConvDate DATE;
+BEGIN
+
+  IF(p_Amount=0 OR p_CurFrom_ID=p_CurTo_ID) THEN
+    RETURN p_Amount;
+  END IF;
+
+  if (p_convdate > now()) then
+    v_ConvDate:=now();
+  else
+    v_ConvDate:=p_convdate;
+  end if;
+
+  if (p_fin_finacc_transaction_id is not null) then
+    select foreign_convert_rate into v_rate from fin_finacc_transaction fat where fin_finacc_transaction_id=p_fin_finacc_transaction_id;
+  elsif (p_fin_payment_id is not null) then
+    select finacc_txn_convert_rate into v_rate from fin_payment where fin_payment_id=p_fin_payment_id;
+  elsif (p_c_invoice_id is not null) then
+    select rate into v_Rate from c_conversion_rate_document where c_invoice_id=p_c_invoice_id and c_currency_id=p_curfrom_id and c_currency_id_to=p_curto_id;
+  end if;
+
+  if (v_Rate is not null) then
+    return ROUND(p_Amount * v_Rate, C_GET_CURRENCY_PRECISION(p_CurTo_ID, 'A'));
+  else
+    RETURN C_CURRENCY_CONVERT(p_amount, p_curfrom_id, p_curto_id, p_convdate, null, p_client_id, p_org_id);
+  end if;
+
+EXCEPTION
+WHEN OTHERS THEN
+  DBMS_OUTPUT.PUT_LINE(SQLERRM);
+  RAISE;
+END C_CONVERT_DOC_CURRENCY
+]]></body>
+    </function>
+  </database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/C_GET_NET_AMOUNT_FROM_GROSS.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,66 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION C_GET_NET_AMOUNT_FROM_GROSS">
+    <function name="C_GET_NET_AMOUNT_FROM_GROSS" type="NUMERIC">
+      <parameter name="p_tax_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_grossamt" type="NUMERIC" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_alternatetaxbaseamt" type="NUMERIC" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_stdprecision" type="NUMERIC" mode="in">
+        <default><![CDATA[NULL]]></default>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2017 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+/*
+* It returns the Net Amount calculated from the Gross Amount after applying the Tax.
+* Net Amount will be rounded to p_stdprecision if not NULL,
+* otherwise it will be rounded to a big precision (50) to avoid rounding issues.
+*/
+
+v_ResultStr VARCHAR(2000) := '';
+v_calcPrecision NUMBER:= 50;
+v_TaxAmount NUMBER;
+v_NetAmount NUMBER;
+
+BEGIN --BODY
+
+  IF (p_grossamt = 0) THEN
+    RETURN 0;
+  END IF;
+
+  v_TaxAmount := C_GET_TAX_AMT_FROM_NET(p_tax_id, p_grossamt, p_alternatetaxbaseamt, v_calcPrecision, 0);
+  -- Do multiplication before division to avoid wrong calculation in PostgreSQL. See Issue 35486.
+  v_NetAmount := ROUND((p_grossamt * p_grossamt) / (p_grossamt + v_TaxAmount), v_calcPrecision);
+  IF (p_stdprecision IS NOT NULL) THEN
+    v_NetAmount := ROUND(v_NetAmount, p_stdprecision);
+  END IF;
+  RETURN v_NetAmount;
+
+EXCEPTION
+WHEN OTHERS THEN
+  v_ResultStr:= '@ERROR=' || SQLERRM;
+  DBMS_OUTPUT.PUT_LINE(v_ResultStr) ;
+  RAISE;
+END C_GET_NET_AMOUNT_FROM_GROSS
+]]></body>
+    </function>
+  </database>
--- a/model/src-db/database/model/functions/C_GET_NET_PRICE_FROM_GROSS.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_GET_NET_PRICE_FROM_GROSS.xml	Thu May 25 06:12:59 2017 +0000
@@ -28,7 +28,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2012-2016 Openbravo SLU
+* All portions are Copyright (C) 2012-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -46,7 +46,8 @@
   END IF;
   v_TaxAmount := C_GET_TAX_AMT_FROM_NET(p_tax_id, p_grossamt, p_alternatetaxbaseamt, v_calcPrecision, 0);
   DBMS_OUTPUT.PUT_LINE('Unit tax ' || v_TaxAmount);
-  v_NetPrice:= ROUND(p_grossamt * (p_grossamt  / (p_grossamt + v_TaxAmount)) / p_qty, p_priceprecision);
+  -- Do multiplication before division to avoid wrong calculation in PostgreSQL. See Issue 35486.
+  v_NetPrice:= ROUND(((p_grossamt * p_grossamt) / (p_grossamt + v_TaxAmount)) / p_qty, p_priceprecision);
 
   --TODO:Call function to recalculate alternate taxbase amount.
 
--- a/model/src-db/database/model/functions/C_INVOICELINETAX_INSERT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_INVOICELINETAX_INSERT.xml	Thu May 25 06:12:59 2017 +0000
@@ -40,7 +40,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2010-2016 Openbravo SLU
+* All portions are Copyright (C) 2010-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -78,7 +78,7 @@
       v_TaxBaseAmount:=0;
     END IF;
     IF (v_BaseAmount='TAX' OR v_BaseAmount='LNATAX' OR v_BaseAmount='TBATAX') THEN
-      SELECT COALESCE(SUM(TAXAMT),0) + v_TaxBaseAmount
+      SELECT COALESCE(SUM(TAXAMT), 0) + v_TaxBaseAmount
       INTO v_TaxBaseAmount
       FROM C_INVOICELINETAX, C_TAX
       WHERE C_INVOICELINETAX.C_TAX_ID = C_TAX.C_TAX_ID
@@ -103,12 +103,12 @@
       INSERT
       INTO C_INVOICELINETAX (
       C_InvoiceLineTax_ID, C_InvoiceLine_ID, C_Invoice_ID, C_Tax_ID, AD_Client_ID, AD_Org_ID,
-      IsActive, Created, CreatedBy, Updated,
-      UpdatedBy, TaxBaseAmt, TaxAmt, Line)
+      IsActive, Created, CreatedBy, Updated, UpdatedBy,
+      TaxBaseAmt, TaxAmt, Line)
       VALUES (
       GET_UUID(), p_invoiceline_id, p_invoice_id, p_tax_id, v_Client_ID, p_org_id,
-      'Y', now(), p_user_id, now(),
-      p_user_id, v_TaxBaseAmount, ROUND(v_TaxBaseAmount*v_Rate / 100, p_StdPrecision), v_LineNo);
+      'Y', now(), p_user_id, now(), p_user_id,
+      v_TaxBaseAmount, ROUND(ROUND(v_TaxBaseAmount, p_StdPrecision) * v_Rate/100, p_StdPrecision), v_LineNo);
     ELSE
       FOR Cur_Taxes IN
         (SELECT C_Tax_ID, RATE
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/C_INVOICETAX_ADJUSTMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,195 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION C_INVOICETAX_ADJUSTMENT">
+    <function name="C_INVOICETAX_ADJUSTMENT" type="NULL">
+      <parameter name="p_invoice_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_precision" type="NUMERIC" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_action" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2017 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+/*
+* It rounds C_InvoiceLineTax and C_InvoiceTax TaxBaseAmt and adjusts C_InvoiceTax TaxAmt and C_InvoiceLine LineNetAmt
+* when completing the p_invoice_id invoice.
+* It removes C_InvoiceLineTax and C_InvoiceTax taxes and C_InvoiceLine and C_Invoice amounts and recalculates them again
+* when reactivating the p_invoice_id invoice.
+*/
+
+-- Variables
+v_taxAmt C_INVOICETAX.TaxAmt%TYPE;
+v_amount C_INVOICELINE.Line_Gross_Amount%TYPE;
+TYPE RECORD IS REF CURSOR;
+CUR_Tax RECORD;
+CUR_Line RECORD;
+
+BEGIN --BODY
+
+  -- Round and Adjust taxes
+  IF (p_action = 'CO') THEN
+
+    -- Disable triggers
+    INSERT INTO AD_Session_Status (ad_session_status_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, isimporting)
+    VALUES (get_uuid(), '0', '0', 'Y', now(), '0', now(), '0', 'Y');
+
+    -- Round
+    UPDATE C_INVOICELINETAX
+    SET TaxBaseAmt = round(TaxBaseAmt, p_precision)
+    WHERE C_Invoice_ID = p_invoice_id;
+
+    UPDATE C_INVOICETAX
+    SET TaxBaseAmt = round(TaxBaseAmt, p_precision)
+    WHERE C_Invoice_ID = p_invoice_id
+    AND Recalculate = 'Y';
+
+    -- Adjust
+    FOR CUR_Tax IN (
+      SELECT it.C_Tax_ID, COALESCE((MIN(it.DocTaxBaseAmt) + MIN(it.DocTaxAmt)) - (SUM(ilt.LineTaxBaseAmt) + SUM(ilt.LineTaxAmt)), 0) as TaxAdjustment, COALESCE(MIN(it.DocTaxBaseAmt) - SUM(ilt.LineTaxBaseAmt), 0) as LineAdjustment
+      FROM (
+        SELECT c_tax_get_root(it.c_tax_id) as C_Tax_ID, CASE WHEN MIN(it.TaxBaseAmt) > 0 THEN MIN(it.TaxBaseAmt) ELSE MAX(it.TaxBaseAmt) END as DocTaxBaseAmt, SUM(it.TaxAmt) as DocTaxAmt, MIN(it.Line) as Line
+        FROM C_InvoiceTax it
+        JOIN C_Tax t
+        ON it.C_Tax_ID = t.C_Tax_ID
+        WHERE it.C_Invoice_ID = p_invoice_id
+        AND it.Recalculate = 'Y'
+        AND t.DocTaxAmount = 'D'
+        GROUP BY c_tax_get_root(it.c_tax_id)
+      ) it
+      JOIN (
+        SELECT c_tax_get_root(ilt.c_tax_id) as C_Tax_ID, CASE WHEN MIN(ilt.TaxBaseAmt) > 0 THEN MIN(ilt.TaxBaseAmt) ELSE MAX(ilt.TaxBaseAmt) END as LineTaxBaseAmt, SUM(ilt.TaxAmt) as LineTaxAmt
+        FROM C_InvoiceLineTax ilt
+        JOIN C_Tax t
+        ON ilt.C_Tax_ID = t.C_Tax_ID
+        WHERE ilt.C_Invoice_ID = p_invoice_id
+        AND t.DocTaxAmount = 'D'
+        GROUP BY ilt.C_InvoiceLine_ID, c_tax_get_root(ilt.c_tax_id)
+      ) ilt
+      ON ilt.C_Tax_ID = it.C_Tax_ID
+      GROUP BY it.C_Tax_ID, it.Line
+      HAVING COALESCE(MIN(it.DocTaxBaseAmt), 0) <> COALESCE(SUM(ilt.LineTaxBaseAmt), 0)
+      OR COALESCE(MIN(it.DocTaxBaseAmt) + MIN(it.DocTaxAmt), 0) <> COALESCE(SUM(ilt.LineTaxBaseAmt) + SUM(ilt.LineTaxAmt), 0)
+      ORDER BY it.Line
+    )
+    LOOP
+      -- Adjust TaxAmt
+      IF (CUR_Tax.TaxAdjustment <> 0) THEN
+        FOR CUR_Line IN (
+          SELECT it.C_InvoiceTax_ID, it.C_Tax_ID, t.Line
+          FROM C_InvoiceTax it
+          JOIN C_Tax t
+          ON it.C_Tax_ID = t.C_Tax_ID
+          WHERE it.C_Invoice_ID = p_invoice_id
+          AND it.Recalculate = 'Y'
+          AND c_tax_get_root(it.C_Tax_ID) = CUR_Tax.C_Tax_ID
+          ORDER BY ABS(it.TaxAmt) DESC, t.Line DESC
+        )
+        LOOP
+          UPDATE C_INVOICETAX
+          SET TaxAmt = TaxAmt - CUR_Tax.TaxAdjustment
+          WHERE C_InvoiceTax_ID = CUR_Line.C_InvoiceTax_ID;
+
+          UPDATE C_INVOICETAX it
+          SET TaxBaseAmt = TaxBaseAmt - CUR_Tax.TaxAdjustment
+          WHERE it.C_Invoice_ID = p_invoice_id
+          AND it.Recalculate = 'Y'
+          AND c_tax_get_root(it.C_Tax_ID) = CUR_Tax.C_Tax_ID
+          AND EXISTS (
+            SELECT 1
+            FROM C_Tax t
+            WHERE t.C_Tax_ID = it.C_Tax_ID
+            AND ((t.Cascade = 'Y'
+            AND t.Line > CUR_Line.Line)
+            OR (t.BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+            AND C_TAX_ISMEMBER(t.C_TaxBase_ID, CUR_Line.C_Tax_ID) = 1
+            AND t.IsSummary = 'N'))
+          );
+
+          EXIT;
+        END LOOP;
+      END IF;
+
+      -- Adjust LineNetAmt
+      IF (CUR_Tax.LineAdjustment <> 0) THEN
+        FOR CUR_Line IN (
+          SELECT il.C_InvoiceLine_ID
+          FROM C_InvoiceLine il
+          WHERE il.C_Invoice_ID = p_invoice_id
+          AND EXISTS (
+            SELECT 1
+            FROM C_InvoiceLineTax ilt
+            WHERE il.C_InvoiceLine_ID = ilt.C_InvoiceLine_ID
+            AND c_tax_get_root(ilt.C_Tax_ID) = CUR_Tax.c_Tax_ID
+          )
+          ORDER BY ABS(il.LineNetAmt) DESC, il.Line DESC
+        )
+        LOOP
+          UPDATE C_INVOICELINE
+          SET LineNetAmt = LineNetAmt + CUR_Tax.LineAdjustment
+          WHERE C_InvoiceLine_ID = CUR_Line.C_InvoiceLine_ID;
+
+          -- TODO: Adjust C_InvoiceLineTax accordingly
+
+          EXIT;
+        END LOOP;
+      END IF;
+    END LOOP;
+
+    -- Enable triggers
+    DELETE FROM AD_Session_Status
+    WHERE isimporting = 'Y';
+
+  -- Recalculate amounts and taxes
+  ELSIF (p_action = 'RE') THEN
+
+    -- Remove header amounts and taxes
+    DELETE FROM C_INVOICETAX WHERE C_Invoice_ID = p_invoice_id AND Recalculate = 'Y';
+    SELECT COALESCE(SUM(TaxAmt), 0) INTO v_taxAmt FROM C_INVOICETAX WHERE C_Invoice_ID = p_invoice_id AND Recalculate = 'N';
+    UPDATE C_INVOICE SET TotalLines = 0, GrandTotal = v_taxAmt WHERE C_Invoice_ID = p_invoice_id;
+
+    FOR Cur_line IN (
+      SELECT C_InvoiceLine_ID
+      FROM C_INVOICELINE
+      WHERE C_Invoice_ID = p_invoice_id
+    ) LOOP
+
+      -- Disable triggers
+      INSERT INTO AD_Session_Status (ad_session_status_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, isimporting)
+      VALUES (get_uuid(), '0', '0', 'Y', now(), '0', now(), '0', 'Y');
+
+      -- Remove line amounts and taxes
+      DELETE FROM C_INVOICELINETAX WHERE C_InvoiceLine_ID = Cur_line.C_InvoiceLine_ID;
+      SELECT Line_Gross_Amount INTO v_amount FROM C_INVOICELINE WHERE C_InvoiceLine_ID = Cur_line.C_InvoiceLine_ID;
+      UPDATE C_INVOICELINE SET Line_Gross_Amount = 0 WHERE C_InvoiceLine_ID = Cur_line.C_InvoiceLine_ID;
+
+      -- Enable triggers
+      DELETE FROM AD_Session_Status
+      WHERE isimporting = 'Y';
+
+      -- Recalculate amounts and taxes
+      UPDATE C_INVOICELINE SET Line_Gross_Amount = v_amount WHERE C_InvoiceLine_ID = Cur_line.C_InvoiceLine_ID;
+
+    END LOOP;
+
+  END IF;
+END C_INVOICETAX_ADJUSTMENT
+]]></body>
+    </function>
+  </database>
--- a/model/src-db/database/model/functions/C_INVOICE_POST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_INVOICE_POST.xml	Thu May 25 06:12:59 2017 +0000
@@ -22,7 +22,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2001-2016 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2001-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -152,7 +152,8 @@
   Cur_InvoiceNetLine RECORD;
 
   v_LineMax NUMBER:=0;
-  v_precision NUMBER;
+  v_pricePrecision C_Currency.PricePrecision%TYPE;
+  v_stdPrecision C_Currency.StdPrecision%TYPE;
   v_gross_unit_price NUMBER;
   v_line_gross_amount NUMBER;
   v_Isquantityvariable CHAR(1);
@@ -172,8 +173,8 @@
 
   v_iscashvat C_Invoice.IsCashVat%TYPE;
   v_invoiceline_qtysum NUMBER;
-  v_PriceList_ID varchar2(32);
   v_prepaymentamt NUMBER;
+  v_prepayment_inorders NUMBER;
   v_hasTaxes NUMBER;
    
 BEGIN
@@ -213,23 +214,25 @@
   END IF;
 BEGIN --BODY
 
-  /*Invoiceline acct dimension*/
-  SELECT C_INVOICE.ISSOTRX , C_INVOICE.c_bpartner_id
-  INTO v_IsSOTrx, v_BPartner_ID
-  FROM C_INVOICE
-  WHERE C_INVOICE_ID = v_Record_ID;
+  SELECT i.ISSOTRX , i.c_bpartner_id, i.DocAction, c.PricePrecision, c.StdPrecision, p.IsTaxIncluded
+  INTO v_IsSOTrx, v_BPartner_ID, v_DocAction, v_pricePrecision, v_stdPrecision, v_isTaxIncluded
+  FROM C_INVOICE i
+  JOIN C_CURRENCY c
+  ON i.C_CURRENCY_ID = c.C_CURRENCY_ID
+  JOIN M_PRICELIST p
+  ON i.M_PRICELIST_ID = p.M_PRICELIST_ID
+  WHERE i.C_INVOICE_ID = v_Record_ID;
 
-  SELECT CASE WHEN (m.ISSOTRX='Y') THEN customer_blocking  ELSE vendor_blocking END ,  
-  CASE WHEN (m.ISSOTRX='Y') THEN so_invoice_blocking ELSE po_invoice_blocking  END, name, DocAction
-  INTO v_bpartner_blocked, v_invoiceBlocking, v_bpartner_name, v_DocAction
-  FROM C_INVOICE m, C_BPartner bp
-  WHERE m.c_bpartner_id=bp.c_bpartner_id
-  AND m.C_INVOICE_ID=v_Record_ID
-  AND m.C_BPARTNER_ID=v_BPartner_ID;
+  SELECT CASE WHEN (v_IsSOTrx = 'Y') THEN customer_blocking ELSE vendor_blocking END,
+  CASE WHEN (v_IsSOTrx = 'Y') THEN so_invoice_blocking ELSE po_invoice_blocking END, name
+  INTO v_bpartner_blocked, v_invoiceBlocking, v_bpartner_name
+  FROM C_BPartner bp
+  WHERE bp.c_bpartner_id = v_BPartner_ID;
   IF (v_DocAction = 'CO' AND v_bpartner_blocked = 'Y' AND v_invoiceBlocking = 'Y') THEN
     RAISE_APPLICATION_ERROR(-20000,'@ThebusinessPartner@'||' '|| v_bpartner_name ||' '||'@BusinessPartnerBlocked@');
   END IF;
 
+  /*Invoiceline acct dimension*/
   IF (v_IsSOTrx = 'N') THEN
     FOR Cur_line IN
       (SELECT C_INVOICELINE.C_InvoiceLine_ID,
@@ -257,14 +260,14 @@
       i.AD_Client_ID, i.AD_Org_ID, i.UpdatedBy, i.DocumentNo,
       i.C_Order_ID, i.IsSOTrx, i.C_BPartner_ID, i.AD_User_ID,
       i.C_Currency_ID, i.POReference, i.Posted,
-      i.c_Project_Id, i.C_WithHolding_ID, i.IsCashVat, i.M_PriceList_ID, i.prepaymentamt
+      i.c_Project_Id, i.C_WithHolding_ID, i.IsCashVat, i.prepaymentamt
   INTO v_Processing, v_Processed, v_DocAction, v_DocStatus,
       v_DocType_ID, v_DocTypeTarget_ID,
       v_PaymentRule, v_PaymentTerm, v_DateAcct, v_DateInvoiced,
       v_Client_ID, v_Org_ID, v_UpdatedBy, v_DocumentNo,
       v_Order_ID, v_IsSOTrx, v_BPartner_ID, v_BPartner_User_ID,
       v_Currency_ID, v_POReference, v_Posted,
-      v_C_Project_Id, cWithHoldID, v_iscashvat, v_PriceList_ID, v_prepaymentamt
+      v_C_Project_Id, cWithHoldID, v_iscashvat, v_prepaymentamt
   FROM C_INVOICE i
   WHERE i.C_Invoice_ID=v_Record_ID FOR UPDATE;
 
@@ -272,11 +275,6 @@
   INTO  v_isreturndoctype    
   FROM  c_doctype dt  
   WHERE dt.c_doctype_id= v_DocTypeTarget_ID;
-
-  SELECT pl.istaxincluded
-  INTO   v_istaxincluded
-  FROM   m_pricelist pl 
-  WHERE pl.m_pricelist_id= v_PriceList_ID;
   
   DBMS_OUTPUT.PUT_LINE('Invoice_ID=' || v_Record_ID ||', DocAction=' || v_DocAction || ', DocStatus=' || v_DocStatus || ', DocType_ID=' || v_DocType_ID || ', DocTypeTarget_ID=' || v_DocTypeTarget_ID) ;
   /**
@@ -1068,9 +1066,16 @@
       IF (v_IsSOTrx='Y') THEN
         C_BP_SOCREDITUSED_REFRESH(v_BPartner_ID) ;
       END IF;
+      DELETE
+      FROM C_INVOICELINETAX
+      WHERE EXISTS (SELECT 1 FROM C_INVOICELINE
+                    WHERE C_INVOICE_DISCOUNT_ID IS NOT NULL
+                    AND C_INVOICE_ID = v_Record_ID
+                    AND C_INVOICELINETAX.C_INVOICELINE_ID = C_INVOICELINE.C_INVOICELINE_ID);
       DELETE FROM C_INVOICELINE
       WHERE C_INVOICE_DISCOUNT_ID IS NOT NULL
         AND C_INVOICE_ID=v_Record_ID;
+
       END_PROCESSING:=TRUE;
     END IF;
   END IF;--END_PROCESSING
@@ -1199,9 +1204,6 @@
     SELECT MAX(LINE) INTO v_InvoiceLineSeqNo
     FROM C_INVOICELINE
     WHERE C_INVOICE_ID=v_Record_ID;
-    SELECT PricePrecision INTO v_precision
-    FROM C_INVOICE i, C_CURRENCY c
-    WHERE i.C_INVOICE_ID = v_Record_ID AND i.C_CURRENCY_ID = c.C_CURRENCY_ID;
     FOR Cur_CInvoiceDiscount IN
       (SELECT C_INVOICE_DISCOUNT.C_INVOICE_DISCOUNT_ID, C_DISCOUNT.DISCOUNT, C_DISCOUNT.M_PRODUCT_ID, C_DISCOUNT.NAME,
            C_INVOICE_DISCOUNT.CASCADE, C_DISCOUNT.C_DISCOUNT_ID, M_PRODUCT.C_UOM_ID,
@@ -1233,7 +1235,7 @@
           ELSE
             v_line_gross_amount:=(-1) * Cur_TaxDiscount.LINEGROSSAMT * Cur_CInvoiceDiscount.Discount/100;
           END IF;
-          v_Discount:= C_GET_NET_PRICE_FROM_GROSS(Cur_TaxDiscount.C_TAX_ID, v_line_gross_amount, 0, v_precision, 1);
+          v_Discount:= C_GET_NET_AMOUNT_FROM_GROSS(Cur_TaxDiscount.C_TAX_ID, v_line_gross_amount, 0, v_stdPrecision);
           v_gross_unit_price:= v_line_gross_amount;
         ELSE
           IF (Cur_CInvoiceDiscount.CASCADE='Y') THEN
@@ -1297,7 +1299,7 @@
            0, Cur_CInvoiceDiscount.C_UOM_ID, Cur_TaxDiscount.C_TAX_ID, NULL,
            NULL, NULL, 'N' ,
            NULL, NULL, v_Discount,
-           ROUND(v_gross_unit_price, v_precision), v_Discount  ,ROUND(v_line_gross_amount, v_precision),
+           ROUND(v_gross_unit_price, v_pricePrecision), v_Discount  ,ROUND(v_line_gross_amount, v_pricePrecision),
            v_isdeferred_inv, v_defplantype_inv, v_periodnumber_inv, v_period_inv,
            NULL, NULL
           );
@@ -1796,11 +1798,21 @@
     END IF;
   END IF;--FINISH_PROCESS
   IF (NOT FINISH_PROCESS AND NOT END_PROCESSING) THEN
+    --Update the prepayment amount from orders related to the invoice lines.
+    SELECT COALESCE(SUM(fps.paidamt),0)
+      INTO v_prepayment_inorders
+    FROM fin_payment_schedule fps
+      JOIN c_order o ON o.c_order_id=fps.c_order_id
+      JOIN c_orderline ol ON ol.c_order_id = o.c_order_id
+      JOIN c_invoiceline il ON il.c_orderline_id = ol.c_orderline_id
+    WHERE il.c_invoice_id = v_Record_ID;
+
     -- Finish up -------------------------------------------------------------
     UPDATE C_INVOICE
     SET DocStatus='CO',
         Processed='Y',
         DocAction='RE',
+        PrepaymentAmt=v_prepayment_inorders,
         Updated=now(),
         UpdatedBy=v_UpdatedBy
     WHERE C_Invoice_ID=v_Record_ID;
@@ -1819,6 +1831,11 @@
     -- Commented by cromero 19102006 END IF;
   END IF;--FINISH_PROCESS
 
+  -- Round and Adjust taxes when 'CO' and Recalculate amounts and taxes when 'RE'
+  IF (v_isTaxIncluded = 'Y' AND v_DocAction IN ('CO', 'RE')) THEN
+    C_INVOICETAX_ADJUSTMENT(v_Record_ID, v_stdPrecision, v_DocAction);
+  END IF;
+
   --C_Invoice_Post - Finish_Process Extension Point
   SELECT count(*) INTO v_count FROM DUAL
   WHERE EXISTS (SELECT 1 FROM ad_ep_procedures WHERE ad_extension_points_id = 'CBE7DD2E561E4D3D8257ECEA5F19687F');
--- a/model/src-db/database/model/functions/C_ORDERLINETAX_INSERT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_ORDERLINETAX_INSERT.xml	Thu May 25 06:12:59 2017 +0000
@@ -40,7 +40,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2010-2016 Openbravo SLU
+* All portions are Copyright (C) 2010-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -51,7 +51,7 @@
   v_TaxBaseAmount NUMBER;
   v_BaseAmount C_TAX.BASEAMOUNT%TYPE;
   v_C_TaxBase_ID C_TAX.C_TAXBASE_ID%TYPE;
-  v_LineNo C_INVOICETAX.LINE%TYPE;
+  v_LineNo C_ORDERTAX.LINE%TYPE;
   v_Rate C_TAX.RATE%TYPE;
   v_Client_ID VARCHAR2(32) ;
   v_istaxincluded CHAR(1);
@@ -78,7 +78,7 @@
       v_TaxBaseAmount:=0;
     END IF;
     IF (v_BaseAmount='TAX' OR v_BaseAmount='LNATAX' OR v_BaseAmount='TBATAX') THEN
-      SELECT COALESCE(SUM(TAXAMT),0) + v_TaxBaseAmount
+      SELECT COALESCE(SUM(TAXAMT), 0) + v_TaxBaseAmount
       INTO v_TaxBaseAmount
       FROM C_ORDERLINETAX, C_TAX
       WHERE C_ORDERLINETAX.C_TAX_ID = C_TAX.C_TAX_ID
@@ -103,12 +103,12 @@
       INSERT
       INTO C_ORDERLINETAX (
       C_OrderLineTax_ID, C_OrderLine_ID, C_Order_ID, C_Tax_ID, AD_Client_ID, AD_Org_ID,
-      IsActive, Created, CreatedBy, Updated,
-      UpdatedBy, TaxBaseAmt, TaxAmt, Line)
+      IsActive, Created, CreatedBy, Updated, UpdatedBy,
+      TaxBaseAmt, TaxAmt, Line)
       VALUES (
       GET_UUID(), p_orderline_id, p_order_id, p_tax_id, v_Client_ID, p_org_id,
-      'Y', now(), p_user_id, now(),
-      p_user_id, v_TaxBaseAmount, ROUND(v_TaxBaseAmount*v_Rate / 100, p_StdPrecision), v_LineNo);
+      'Y', now(), p_user_id, now(), p_user_id,
+      v_TaxBaseAmount, ROUND(ROUND(v_TaxBaseAmount, p_StdPrecision) * v_Rate/100, p_StdPrecision), v_LineNo);
     ELSE
       FOR Cur_Taxes IN
         (SELECT C_Tax_ID, RATE
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/C_ORDERTAX_ADJUSTMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,189 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION C_ORDERTAX_ADJUSTMENT">
+    <function name="C_ORDERTAX_ADJUSTMENT" type="NULL">
+      <parameter name="p_order_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_precision" type="NUMERIC" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_action" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2017 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+/*
+* It rounds C_OrderLineTax and C_OrderTax TaxBaseAmt and adjusts C_OrderTax TaxAmt and C_OrderLine LineNetAmt
+* when completing the p_order_id order.
+* It removes C_OrderLineTax and C_OrderTax taxes and C_OrderLine and C_Order amounts and recalculates them again
+* when reactivating the p_order_id order.
+*/
+
+-- Variables
+v_amount C_ORDERLINE.Line_Gross_Amount%TYPE;
+TYPE RECORD IS REF CURSOR;
+CUR_Tax RECORD;
+CUR_Line RECORD;
+
+BEGIN --BODY
+
+  -- Round and Adjust taxes
+  IF (p_action = 'CO') THEN
+
+    -- Disable triggers
+    INSERT INTO AD_Session_Status (ad_session_status_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, isimporting)
+    VALUES (get_uuid(), '0', '0', 'Y', now(), '0', now(), '0', 'Y');
+
+    -- Round
+    UPDATE C_ORDERLINETAX
+    SET TaxBaseAmt = round(TaxBaseAmt, p_precision)
+    WHERE C_Order_ID = p_order_id;
+
+    UPDATE C_ORDERTAX
+    SET TaxBaseAmt = round(TaxBaseAmt, p_precision)
+    WHERE C_Order_ID = p_order_id;
+
+    -- Adjust
+    FOR CUR_Tax IN (
+      SELECT ot.C_Tax_ID, COALESCE((MIN(ot.DocTaxBaseAmt) + MIN(ot.DocTaxAmt)) - (SUM(olt.LineTaxBaseAmt) + SUM(olt.LineTaxAmt)), 0) as TaxAdjustment, COALESCE(MIN(ot.DocTaxBaseAmt) - SUM(olt.LineTaxBaseAmt), 0) as LineAdjustment
+      FROM (
+        SELECT c_tax_get_root(ot.c_tax_id) as C_Tax_ID, CASE WHEN MIN(ot.TaxBaseAmt) > 0 THEN MIN(ot.TaxBaseAmt) ELSE MAX(ot.TaxBaseAmt) END as DocTaxBaseAmt, SUM(ot.TaxAmt) as DocTaxAmt, MIN(ot.Line) as Line
+        FROM C_OrderTax ot
+        JOIN C_Tax t
+        ON ot.C_Tax_ID = t.C_Tax_ID
+        WHERE ot.C_Order_ID = p_order_id
+        AND t.DocTaxAmount = 'D'
+        GROUP BY c_tax_get_root(ot.c_tax_id)
+      ) ot
+      JOIN (
+        SELECT c_tax_get_root(olt.c_tax_id) as C_Tax_ID, CASE WHEN MIN(olt.TaxBaseAmt) > 0 THEN MIN(olt.TaxBaseAmt) ELSE MAX(olt.TaxBaseAmt) END as LineTaxBaseAmt, SUM(olt.TaxAmt) as LineTaxAmt
+        FROM C_OrderLineTax olt
+        JOIN C_Tax t
+        ON olt.C_Tax_ID = t.C_Tax_ID
+        WHERE olt.C_Order_ID = p_order_id
+        AND t.DocTaxAmount = 'D'
+        GROUP BY olt.C_OrderLine_ID, c_tax_get_root(olt.c_tax_id)
+      ) olt
+      ON olt.C_Tax_ID = ot.C_Tax_ID
+      GROUP BY ot.C_Tax_ID, ot.Line
+      HAVING COALESCE(MIN(ot.DocTaxBaseAmt), 0) <> COALESCE(SUM(olt.LineTaxBaseAmt), 0)
+      OR COALESCE(MIN(ot.DocTaxBaseAmt) + MIN(ot.DocTaxAmt), 0) <> COALESCE(SUM(olt.LineTaxBaseAmt) + SUM(olt.LineTaxAmt), 0)
+      ORDER BY ot.Line
+    )
+    LOOP
+      -- Adjust TaxAmt
+      IF (CUR_Tax.TaxAdjustment <> 0) THEN
+        FOR CUR_Line IN (
+          SELECT ot.C_OrderTax_ID, ot.C_Tax_ID, t.Line
+          FROM C_OrderTax ot
+          JOIN C_Tax t
+          ON ot.C_Tax_ID = t.C_Tax_ID
+          WHERE ot.C_Order_ID = p_order_id
+          AND c_tax_get_root(ot.C_Tax_ID) = CUR_Tax.C_Tax_ID
+          ORDER BY ABS(ot.TaxAmt) DESC, t.Line DESC
+        )
+        LOOP
+          UPDATE C_ORDERTAX
+          SET TaxAmt = TaxAmt - CUR_Tax.TaxAdjustment
+          WHERE C_OrderTax_ID = CUR_Line.C_OrderTax_ID;
+
+          UPDATE C_ORDERTAX ot
+          SET TaxBaseAmt = TaxBaseAmt - CUR_Tax.TaxAdjustment
+          WHERE ot.C_Order_ID = p_order_id
+          AND c_tax_get_root(ot.C_Tax_ID) = CUR_Tax.C_Tax_ID
+          AND EXISTS (
+            SELECT 1
+            FROM C_Tax t
+            WHERE t.C_Tax_ID = ot.C_Tax_ID
+            AND ((t.Cascade = 'Y'
+            AND t.Line > CUR_Line.Line)
+            OR (t.BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+            AND C_TAX_ISMEMBER(t.C_TaxBase_ID, CUR_Line.C_Tax_ID) = 1
+            AND t.IsSummary = 'N'))
+          );
+
+          EXIT;
+        END LOOP;
+      END IF;
+
+      -- Adjust LineNetAmt
+      IF (CUR_Tax.LineAdjustment <> 0) THEN
+        FOR CUR_Line IN (
+          SELECT ol.C_OrderLine_ID
+          FROM C_OrderLine ol
+          WHERE ol.C_Order_ID = p_order_id
+          AND EXISTS (
+            SELECT 1
+            FROM C_OrderLineTax olt
+            WHERE ol.C_OrderLine_ID = olt.C_OrderLine_ID
+            AND c_tax_get_root(olt.C_Tax_ID) = CUR_Tax.c_Tax_ID
+          )
+          ORDER BY ABS(ol.LineNetAmt) DESC, ol.Line DESC
+        )
+        LOOP
+          UPDATE C_ORDERLINE
+          SET LineNetAmt = LineNetAmt + CUR_Tax.LineAdjustment
+          WHERE C_OrderLine_ID = CUR_Line.C_OrderLine_ID;
+
+          -- TODO: Adjust C_OrderLineTax accordingly
+
+          EXIT;
+        END LOOP;
+      END IF;
+    END LOOP;
+
+    -- Enable triggers
+    DELETE FROM AD_Session_Status
+    WHERE isimporting = 'Y';
+
+  -- Recalculate amounts and taxes
+  ELSIF (p_action = 'RE') THEN
+
+    -- Remove header amounts and taxes
+    DELETE FROM C_ORDERTAX WHERE C_Order_ID = p_order_id;
+    UPDATE C_ORDER SET TotalLines = 0, GrandTotal = 0 WHERE C_Order_ID = p_order_id;
+
+    FOR Cur_line IN (
+      SELECT C_OrderLine_ID
+      FROM C_ORDERLINE
+      WHERE C_Order_ID = p_order_id
+    ) LOOP
+
+      -- Disable triggers
+      INSERT INTO AD_Session_Status (ad_session_status_id, ad_client_id, ad_org_id, isactive, created, createdby, updated, updatedby, isimporting)
+      VALUES (get_uuid(), '0', '0', 'Y', now(), '0', now(), '0', 'Y');
+
+      -- Remove line amounts and taxes
+      DELETE FROM C_ORDERLINETAX WHERE C_OrderLine_ID = Cur_line.C_OrderLine_ID;
+      SELECT Line_Gross_Amount INTO v_amount FROM C_ORDERLINE WHERE C_OrderLine_ID = Cur_line.C_OrderLine_ID;
+      UPDATE C_ORDERLINE SET Line_Gross_Amount = 0 WHERE C_OrderLine_ID = Cur_line.C_OrderLine_ID;
+
+      -- Enable triggers
+      DELETE FROM AD_Session_Status
+      WHERE isimporting = 'Y';
+
+      -- Recalculate amounts and taxes
+      UPDATE C_ORDERLINE SET Line_Gross_Amount = v_amount WHERE C_OrderLine_ID = Cur_line.C_OrderLine_ID;
+
+    END LOOP;
+
+  END IF;
+END C_ORDERTAX_ADJUSTMENT
+]]></body>
+    </function>
+  </database>
--- a/model/src-db/database/model/functions/C_ORDER_POST1.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/C_ORDER_POST1.xml	Thu May 25 06:12:59 2017 +0000
@@ -22,7 +22,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2001-2016 Openbravo SLU
+* All portions are Copyright (C) 2001-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -95,7 +95,6 @@
   v_c_Bpartner_ID VARCHAR2(32);
   v_c_currency_ID VARCHAR2(32);
   v_C_PROJECT_ID VARCHAR2(32);
-  v_PriceList_ID VARCHAR2(32);
   FINISH_PROCESS BOOLEAN:=FALSE;
   END_PROCESSING BOOLEAN:=FALSE;
   v_CBPartner_ID VARCHAR2(32);
@@ -108,7 +107,8 @@
   Cur_TaxDiscount RECORD;
   v_OrderLine VARCHAR2(32);
   v_Discount NUMBER;
-  v_precision NUMBER;
+  v_pricePrecision C_Currency.PricePrecision%TYPE;
+  v_stdPrecision C_Currency.StdPrecision%TYPE;
   Cur_OrderLine RECORD;
   v_DiscountExist NUMBER;
   v_gross_unit_price NUMBER;
@@ -156,13 +156,17 @@
     END IF;
     DBMS_OUTPUT.PUT_LINE('  Record_ID=' || v_Record_ID) ;
   BEGIN --BODY
-  
+
+  SELECT o.ISSOTRX, o.c_bpartner_id, o.DocAction, c.PricePrecision, c.StdPrecision, p.IsTaxIncluded
+  INTO v_IsSOTrx, v_c_Bpartner_ID, v_DocAction, v_pricePrecision, v_stdPrecision, v_isTaxIncluded
+  FROM C_ORDER o
+  JOIN C_CURRENCY c
+  ON o.C_CURRENCY_ID = c.C_CURRENCY_ID
+  JOIN M_PRICELIST p
+  ON o.M_PRICELIST_ID = p.M_PRICELIST_ID
+  WHERE o.C_ORDER_ID = v_Record_ID;
+
   /*Orderline acct dimension*/
-  SELECT C_ORDER.ISSOTRX , C_ORDER.c_bpartner_id, DocAction
-  INTO v_IsSOTrx, v_c_Bpartner_ID, v_DocAction
-  FROM C_ORDER
-  WHERE C_ORDER_ID = v_Record_ID;
-  
   IF (v_IsSOTrx = 'N') THEN
     FOR Cur_line IN
       (SELECT C_ORDERLINE.C_OrderLine_ID,
@@ -214,19 +218,14 @@
       C_DocType_ID, C_DocTypeTarget_ID, c_order.AD_Client_ID,
       c_order.AD_Org_ID, c_order.UpdatedBy, M_Warehouse_ID, TRUNC(DateOrdered),
       Issotrx, c_Bpartner_Id, c_order.c_currency_id, C_PROJECT_ID,
-      C_BPartner_ID, M_PriceList_ID, invoicerule, c_order.IsCashVat
+      C_BPartner_ID, invoicerule, c_order.IsCashVat
     INTO v_IsProcessing, v_IsProcessed, v_DocAction, v_DocStatus,
       v_DocType_ID, v_DocTypeTarget_ID, v_Client_ID,
       v_Org_ID, v_UpdatedBy, v_M_Warehouse_ID, v_Date,
       v_isSoTrx, v_c_Bpartner_Id, v_c_currency_id, v_C_PROJECT_ID,
-      v_CBPartner_ID, v_PriceList_ID, v_invoicerule, v_iscashvat
+      v_CBPartner_ID, v_invoicerule, v_iscashvat
     FROM C_ORDER
     WHERE C_Order_ID=v_Record_ID  FOR UPDATE  ;
-
-    SELECT m_pricelist.istaxincluded
-    INTO v_istaxincluded
-    FROM m_pricelist 
-    WHERE m_pricelist_id= v_PriceList_ID;
     
     -- Get current DocSubTypeSO
     SELECT DocSubTypeSO
@@ -506,6 +505,13 @@
                  AND C.C_ORDER_DISCOUNT_ID IS NOT NULL AND C.C_ORDER_ID = v_Record_ID) = 'VO'
                  AND C_ORDERLINE_ID IN (SELECT C_ORDERLINE_ID FROM C_ORDERLINE WHERE C_ORDER_DISCOUNT_ID IS NOT NULL 
                  AND C_ORDER_ID = v_Record_ID);
+	DELETE
+	FROM C_ORDERLINETAX
+	WHERE EXISTS (SELECT 1
+                     FROM C_ORDERLINE
+                     WHERE C_ORDER_DISCOUNT_ID IS NOT NULL
+		      AND C_ORDER_ID = v_Record_ID
+		      AND C_ORDERLINE.C_ORDERLINE_ID = C_ORDERLINETAX.C_ORDERLINE_ID);
         DELETE
         FROM C_ORDERLINE
         WHERE C_ORDER_DISCOUNT_ID IS NOT NULL
@@ -678,6 +684,7 @@
       DECLARE
           Cur_Inventory RECORD;
           v_QtyOrdered NUMBER;
+          v_QtyAum NUMBER;
           v_QuantityOrder NUMBER;
           v_linenetamt NUMBER;
           v_linegrossamt NUMBER;
@@ -711,6 +718,7 @@
             )
             LOOP
               v_QtyOrdered := CASE WHEN (Cur_Inventory.QtyDelivered < 0) THEN LEAST(Cur_Inventory.QtyDelivered, Cur_Inventory.QtyInvoiced) ELSE GREATEST(Cur_Inventory.QtyDelivered, Cur_Inventory.QtyInvoiced) END;
+              v_QtyAum := M_GET_CONVERTED_AUMQTY(Cur_Inventory.M_Product_ID, v_QtyOrdered, Cur_Inventory.C_AUM);
               v_linenetamt := ROUND(v_QtyOrdered * Cur_Inventory.priceactual, C_GET_CURRENCY_PRECISION(Cur_Inventory.C_Currency_ID, 'A'));
               v_linegrossamt := ROUND(v_QtyOrdered * Cur_Inventory.gross_unit_price, C_GET_CURRENCY_PRECISION(Cur_Inventory.C_Currency_ID, 'A'));
               SELECT MAX(UOM.C_UOM_ID)
@@ -729,6 +737,7 @@
               -- UPDATE C_ORDERLINE
               UPDATE C_ORDERLINE
               SET QtyOrdered=v_QtyOrdered,
+                AumQty = v_QtyAum,
                 linenetamt=v_linenetamt,
                 line_gross_amount=v_linegrossamt,
                 QuantityOrder=v_QuantityOrder,
@@ -776,6 +785,7 @@
             )
             LOOP
               v_QtyOrdered := COALESCE(CASE WHEN (Cur_Inventory.QtyDelivered < 0) THEN LEAST(Cur_Inventory.QtyDelivered, Cur_Inventory.QtyInvoiced) ELSE GREATEST(Cur_Inventory.QtyDelivered, Cur_Inventory.QtyInvoiced) END, 0);
+              v_QtyAum := M_GET_CONVERTED_AUMQTY(Cur_Inventory.M_Product_ID, v_QtyOrdered, Cur_Inventory.C_AUM);
               v_linenetamt := ROUND(COALESCE(v_QtyOrdered, 0) * Cur_Inventory.priceactual, C_GET_CURRENCY_PRECISION(Cur_Inventory.C_Currency_ID, 'A'));
               v_linegrossamt := ROUND(COALESCE(v_QtyOrdered, 0) * Cur_Inventory.gross_unit_price, C_GET_CURRENCY_PRECISION(Cur_Inventory.C_Currency_ID, 'A'));
 
@@ -794,6 +804,7 @@
               -- UPDATE C_ORDERLINE
               UPDATE C_ORDERLINE
               SET QtyOrdered=v_QtyOrdered,
+                AumQty = v_QtyAum,
                 linenetamt=v_linenetamt,
                 line_gross_amount=v_linegrossamt,
                 QuantityOrder=v_QuantityOrder,
@@ -935,14 +946,10 @@
         v_CumDiscount:=0;
         v_OldCumDiscount:=0;
         v_Line:=10;
-        v_precision:=0;
         SELECT MAX(LINE)
           INTO v_OrderLineSeqNo
         FROM C_ORDERLINE
         WHERE C_ORDER_ID=v_Record_ID;
-        SELECT PricePrecision INTO v_precision
-        FROM C_ORDER o, C_CURRENCY c
-        WHERE o.C_ORDER_ID = v_Record_ID AND  o.C_CURRENCY_ID = c.C_CURRENCY_ID;
         FOR Cur_COrderDiscount IN
            (SELECT C_ORDER_DISCOUNT.C_ORDER_DISCOUNT_ID, C_DISCOUNT.DISCOUNT, C_DISCOUNT.M_PRODUCT_ID, C_DISCOUNT.NAME,
               C_ORDER_DISCOUNT.CASCADE, C_DISCOUNT.C_DISCOUNT_ID, M_PRODUCT.C_UOM_ID
@@ -974,7 +981,7 @@
               ELSE
                 v_line_gross_amount:=(-1) * Cur_TaxDiscount.LINEGROSSAMT * Cur_COrderDiscount.Discount/100;
               END IF;
-              v_Discount:= C_GET_NET_PRICE_FROM_GROSS(Cur_TaxDiscount.C_TAX_ID, v_line_gross_amount, 0, v_precision, 1);
+              v_Discount:= C_GET_NET_AMOUNT_FROM_GROSS(Cur_TaxDiscount.C_TAX_ID, v_line_gross_amount, 0, v_stdPrecision);
               v_gross_unit_price:= v_line_gross_amount;
             ELSE
               IF (Cur_COrderDiscount.CASCADE='Y') THEN
@@ -1013,11 +1020,11 @@
                   now(), now(), now(), now(), Cur_COrderDiscount.NAME,
                   Cur_COrderDiscount.M_PRODUCT_ID, v_M_Warehouse_ID, 'N', Cur_COrderDiscount.C_UOM_ID, 1,
                   0, 0, 0, NULL, v_c_currency_id,
-                  ROUND(v_Discount,v_precision), ROUND(v_Discount,v_precision), ROUND(v_Discount,v_precision), ROUND(v_Discount,v_precision), 0, 0,
+                  ROUND(v_Discount, v_pricePrecision), ROUND(v_Discount, v_pricePrecision), ROUND(v_Discount, v_pricePrecision), ROUND(v_Discount, v_pricePrecision), 0, 0,
                   NULL, NULL, Cur_TaxDiscount.C_TAX_ID, NULL, NULL,
                   NULL, 'N', NULL, NULL, NULL, NULL,
-                  NULL, ROUND(v_Discount,v_precision), NULL,
-                  ROUND(v_gross_unit_price, v_precision), ROUND(v_Discount,v_precision),ROUND(v_line_gross_amount, v_precision)
+                  NULL, ROUND(v_Discount, v_pricePrecision), NULL,
+                  ROUND(v_gross_unit_price, v_pricePrecision), ROUND(v_Discount, v_pricePrecision),ROUND(v_line_gross_amount, v_pricePrecision)
                 );
 
               UPDATE C_ORDERLINE
@@ -1025,7 +1032,7 @@
               WHERE C_ORDERLINE_ID=v_OrderLine;
             ELSE
               UPDATE C_ORDERLINE 
-              SET pricelist = ROUND(v_Discount,v_precision), priceactual = ROUND(v_Discount,v_precision), pricelimit = ROUND(v_Discount,v_precision), linenetamt = ROUND(v_Discount,v_precision), pricestd = ROUND(v_Discount,v_precision)
+              SET pricelist = ROUND(v_Discount, v_pricePrecision), priceactual = ROUND(v_Discount, v_pricePrecision), pricelimit = ROUND(v_Discount, v_pricePrecision), linenetamt = ROUND(v_Discount, v_pricePrecision), pricestd = ROUND(v_Discount, v_pricePrecision)
               WHERE C_ORDERLINE.C_ORDER_DISCOUNT_ID = Cur_COrderDiscount.C_ORDER_DISCOUNT_ID
                 AND C_ORDERLINE.C_TAX_ID = Cur_TaxDiscount.C_TAX_ID;
             END IF;
@@ -1296,7 +1303,7 @@
                   IF (cur_orderline.qtyordered < v_releasedqty) THEN
                     RAISE_APPLICATION_ERROR(-20000, '@CannotOrderLessThanReleasedQty@');
                   END IF;
-                  IF (cur_orderline.qtyordered < v_reservedqty) THEN
+                  IF (cur_orderline.qtyordered < v_reservedqty) OR (v_releasedqty = 0 AND cur_orderline.qtyordered > 0) THEN
                     --Reservation quantity to decrease with more reserved quantity than new quantity, unreserve stock
                     v_pendingtounreserve := v_reservedqty - cur_orderline.qtyordered;
                     FOR cur_res_stock IN (
@@ -1320,12 +1327,19 @@
                     IF (v_pendingtounreserve > 0) THEN
                       RAISE_APPLICATION_ERROR(-20000, '@CouldNotUnreserveNeededQty@');
                     END IF;
-                    -- Delete reservation lines with quantity zero.
+                    -- Delete reservation lines with zero releasedqty
                     DELETE FROM m_reservation_stock
-                    WHERE quantity = 0
-                      AND COALESCE(releasedqty, 0) = 0
+                    WHERE COALESCE(releasedqty, 0) = 0
                       AND m_reservation_id = v_reservation_id;
                   END IF;
+                  -- Order line orderedqty greater than reservation releasedqty
+                  IF (cur_orderline.qtyordered > v_releasedqty) THEN
+                    UPDATE m_reservation_stock
+                    SET quantity = releasedqty,
+                        updated = now(),
+                        updatedby = v_user
+                    WHERE m_reservation_id = v_reservation_id;
+                  END IF;
                   UPDATE m_reservation
                   SET quantity = cur_orderline.qtyordered,
                       res_status = 'CL',
@@ -1834,6 +1848,11 @@
       END IF;
     END IF;--FINISH_PROCESS
 
+    -- Round and Adjust taxes when 'CO' and Recalculate amounts and taxes when 'RE'
+    IF (v_isTaxIncluded = 'Y' AND v_DocAction IN ('CO', 'RE')) THEN
+      C_ORDERTAX_ADJUSTMENT(v_Record_ID, v_stdPrecision, v_DocAction);
+    END IF;
+
     --C_Order_Post - Finish_Process Extension Point
     SELECT count(*) INTO v_count
     FROM DUAL
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/FIN_AGING_GETDOCNO.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,52 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION FIN_AGING_GETDOCNO">
+    <function name="FIN_AGING_GETDOCNO" type="NVARCHAR">
+      <parameter name="p_poreference" type="NVARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_documentno" type="NVARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_adorgid" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2016 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+v_hasSupplierRef NUMBER:= 0;
+
+BEGIN
+
+  SELECT count(*)
+  INTO v_hasSupplierRef
+  FROM AD_ORGINFO oi
+  WHERE oi.ad_org_id = p_adorgid
+  AND oi.em_aprm_payment_desc = 'Supplier Reference';
+
+  IF (v_hasSupplierRef = 0) THEN
+    RETURN p_documentno;
+  ELSE
+    RETURN p_poreference;
+  END IF;
+
+EXCEPTION
+WHEN OTHERS THEN
+  RETURN p_documentno;
+END FIN_AGING_GETDOCNO
+]]></body>
+    </function>
+  </database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/FIN_AGING_INVOICECURRENCY_RATE.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION FIN_AGING_INVOICECURRENCY_RATE">
+    <function name="FIN_AGING_INVOICECURRENCY_RATE" type="NUMERIC">
+      <parameter name="p_invoice_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curto_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curfrom_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2016 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+v_count NUMBER:=0;
+v_rate NUMBER:=1;
+v_client_id c_invoice.ad_client_id%TYPE;
+v_org_id c_invoice.ad_org_id%TYPE;
+v_dateacct c_invoice.dateacct%TYPE;
+
+BEGIN
+
+IF(p_curfrom_id <> p_curto_id) THEN  
+  SELECT count(*) 
+  INTO v_count 
+  FROM c_conversion_rate_document 
+  WHERE c_invoice_id = p_invoice_id
+  and c_currency_id = p_curfrom_id
+  and c_currency_id_to = p_curto_id;
+
+  IF(v_count = 1) THEN
+    SELECT rate 
+    INTO v_rate 
+    FROM c_conversion_rate_document 
+    WHERE c_invoice_id = p_invoice_id  
+    and c_currency_id = p_curfrom_id
+    and c_currency_id_to = p_curto_id;  
+  ELSE 
+    SELECT dateacct, ad_client_id, ad_org_id 
+    into v_dateacct, v_client_id, v_org_id
+    from c_invoice 
+    where c_invoice_id = p_invoice_id;
+    v_rate:=c_currency_rate(p_curfrom_id, p_curto_id, v_dateacct, 'S', v_client_id, v_org_id);  
+  END IF;
+END IF;
+
+RETURN v_rate;
+
+EXCEPTION
+WHEN OTHERS THEN  
+  RETURN NULL;
+END FIN_AGING_INVOICECURRENCY_RATE
+]]></body>
+    </function>
+  </database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/FIN_AGING_ISDOUBTFULTDEBT.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,53 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION FIN_AGING_ISDOUBTFULTDEBT">
+    <function name="FIN_AGING_ISDOUBTFULTDEBT" type="CHAR">
+      <parameter name="p_finpaymentschedule_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_currentdate" type="TIMESTAMP" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2016 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+ v_count NUMBER:=0;
+BEGIN 
+  SELECT count(*)
+  INTO v_count
+  FROM DUAL
+  WHERE EXISTS (SELECT  1           
+                FROM fin_doubtful_debt dd
+                WHERE dd.fin_payment_schedule_id = p_finpaymentschedule_id
+                AND EXISTS (select 1
+                            from fin_doubtful_debt_run ddr
+                            where ddr.fin_doubtful_debt_run_id = dd.fin_doubtful_debt_run_id
+                            and ddr.rundate <= p_currentdate)
+                );
+  
+  IF v_count = 0 THEN
+    RETURN 'N';
+  ELSE
+    RETURN 'Y';
+  END IF;
+  
+  
+EXCEPTION
+WHEN OTHERS THEN
+  RETURN 'N';
+END FIN_AGING_ISDOUBTFULTDEBT
+]]></body>
+    </function>
+  </database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/model/src-db/database/model/functions/FIN_AGING_PAYMENTCURRENCY_RATE.xml	Thu May 25 06:12:59 2017 +0000
@@ -0,0 +1,70 @@
+<?xml version="1.0"?>
+  <database name="FUNCTION FIN_AGING_PAYMENTCURRENCY_RATE">
+    <function name="FIN_AGING_PAYMENTCURRENCY_RATE" type="NUMERIC">
+      <parameter name="p_payment_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curto_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <parameter name="p_curfrom_id" type="VARCHAR" mode="in">
+        <default/>
+      </parameter>
+      <body><![CDATA[/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2016 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+
+v_count NUMBER:=0;
+v_rate NUMBER:=1;
+v_client_id fin_payment.ad_client_id%TYPE;
+v_org_id fin_payment.ad_org_id%TYPE;
+v_paymentdate fin_payment.paymentdate%TYPE;
+
+BEGIN
+
+IF(p_curfrom_id <> p_curto_id) THEN  
+  SELECT count(*) 
+  INTO v_count 
+  FROM c_conversion_rate_document 
+  WHERE fin_payment_id = p_payment_id
+  and c_currency_id = p_curfrom_id
+  and c_currency_id_to = p_curto_id;
+
+  IF(v_count = 1) THEN
+    SELECT rate 
+    INTO v_rate 
+    FROM c_conversion_rate_document 
+    WHERE fin_payment_id = p_payment_id  
+    and c_currency_id = p_curfrom_id
+    and c_currency_id_to = p_curto_id;  
+  ELSE 
+    SELECT paymentdate, ad_client_id, ad_org_id 
+    into v_paymentdate, v_client_id, v_org_id
+    from fin_payment 
+    where fin_payment_id = p_payment_id;
+    v_rate:=c_currency_rate(p_curfrom_id, p_curto_id, v_paymentdate, 'S', v_client_id, v_org_id);  
+  END IF;
+END IF;
+
+RETURN v_rate;
+
+EXCEPTION
+WHEN OTHERS THEN  
+  RETURN NULL;
+END FIN_AGING_PAYMENTCURRENCY_RATE
+]]></body>
+    </function>
+  </database>
--- a/model/src-db/database/model/functions/MA_STANDARD_COST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/MA_STANDARD_COST.xml	Thu May 25 06:12:59 2017 +0000
@@ -16,13 +16,14 @@
  * under the License.
  * The Original Code is Openbravo ERP.
  * The Initial Developer of the Original Code is Openbravo SLU
- * All portions are Copyright (C) 2001-2013 Openbravo SLU
+ * All portions are Copyright (C) 2001-2017 Openbravo SLU
  * All Rights Reserved.
  * Contributor(s):  ______________________________________.
  ************************************************************************/
   v_ResultStr             VARCHAR2(2000) := '';
   v_Message               VARCHAR2(2000) := '';
   v_Result NUMBER:= 1;
+  v_Client_ID VARCHAR2(32);
 
   p_User VARCHAR2(32);
   p_Currency VARCHAR2(32);
@@ -42,7 +43,29 @@
 BEGIN --BODY
 		v_Count:=0;
 		v_Message:='-';
-			FOR Cur_Sequences IN
+			
+
+  FOR Cur_Parameter IN (SELECT i.ad_client_id, i.Record_ID, i.AD_User_ID, p.ParameterName, 
+                               p.P_String, p.P_Number, p.P_Date, i.UpdatedBy, ad_client.c_currency_id
+                        FROM AD_PINSTANCE i LEFT JOIN AD_PINSTANCE_PARA p ON i.AD_PInstance_ID=p.AD_PInstance_ID,
+                             AD_CLIENT
+                        WHERE i.AD_PInstance_ID=p_PInstance_ID
+                          AND i.ad_client_ID = ad_client.ad_client_id
+                        ORDER BY p.SeqNo) LOOP
+    p_User := Cur_Parameter.AD_User_ID;
+    p_CalcDate := now();
+    p_Currency := cur_parameter.C_Currency_ID;
+    v_Client_ID := cur_parameter.ad_client_id;
+    IF (Cur_Parameter.ParameterName = 'C_Budget_ID') THEN
+      p_Budget_ID := Cur_Parameter.P_String;
+    ELSIF (Cur_Parameter.ParameterName = 'MA_Processplan_ID') THEN
+      p_ProcessPlan := Cur_Parameter.P_String;
+    ELSIF (Cur_Parameter.ParameterName = 'CalcDate') THEN
+      p_CalcDate := COALESCE(Cur_Parameter.P_Date, TRUNC(now()));
+    END IF;
+  END LOOP;
+
+  FOR Cur_Sequences IN
 			(
 			SELECT pp.name||'-'||ppv.documentno AS ProcessPlan
 			FROM MA_SEQUENCEPRODUCT sp, MA_SEQUENCE s
@@ -50,6 +73,7 @@
 			LEFT JOIN MA_ProcessPlan pp ON pp.MA_ProcessPlan_ID = ppv.MA_ProcessPlan_ID
 			WHERE sp.PRODUCTIONTYPE='+'
 			AND sp.MA_SEQUENCE_ID = s.MA_SEQUENCE_ID
+                        AND s.AD_CLIENT_ID = v_Client_ID
 			AND EXISTS
 			(SELECT 1
 			FROM MA_SEQUENCEPRODUCT
@@ -65,25 +89,6 @@
 				RAISE_APPLICATION_ERROR(-20000,'@P+AndP-InSamePlan@'||' Check Process Plan'||v_Message);
 			END IF;
 
-  FOR Cur_Parameter IN (SELECT i.ad_client_id, i.Record_ID, i.AD_User_ID, p.ParameterName, 
-                               p.P_String, p.P_Number, p.P_Date, i.UpdatedBy, ad_client.c_currency_id
-                        FROM AD_PINSTANCE i LEFT JOIN AD_PINSTANCE_PARA p ON i.AD_PInstance_ID=p.AD_PInstance_ID,
-                             AD_CLIENT
-                        WHERE i.AD_PInstance_ID=p_PInstance_ID
-                          AND i.ad_client_ID = ad_client.ad_client_id
-                        ORDER BY p.SeqNo) LOOP
-    p_User := Cur_Parameter.AD_User_ID;
-    p_CalcDate := now();
-    p_Currency := cur_parameter.C_Currency_ID;
-    IF (Cur_Parameter.ParameterName = 'C_Budget_ID') THEN
-      p_Budget_ID := Cur_Parameter.P_String;
-    ELSIF (Cur_Parameter.ParameterName = 'MA_Processplan_ID') THEN
-      p_ProcessPlan := Cur_Parameter.P_String;
-    ELSIF (Cur_Parameter.ParameterName = 'CalcDate') THEN
-      p_CalcDate := COALESCE(Cur_Parameter.P_Date, TRUNC(now()));
-    END IF;
-  END LOOP;
-
   --Initialize, set sequences as calculated = 'N'
   UPDATE MA_SEquence
   SET calculated = 'N'
@@ -92,6 +97,7 @@
                            WHERE s.MA_ProcessPlan_Version_ID = ppv.MA_ProcessPlan_Version_ID
                              AND ppv.DateFrom <= p_CalcDate
                              AND ppv.DateTo > p_CalcDate
+                             AND s.AD_CLIENT_ID = v_Client_ID
                              AND (p_ProcessPlan IS NULL OR ppv.MA_ProcessPlan_ID = p_ProcessPlan)
                              AND EXISTS (SELECT 1 FROM MA_SEQUENCEPRODUCT
                                          WHERE PRODUCTIONTYPE = '+'
@@ -104,6 +110,7 @@
       AND ppv.DateFrom <= p_CalcDate
       AND ppv.DateTo > p_CalcDate
       AND s.calculated = 'N'
+      AND s.AD_CLIENT_ID = v_Client_ID
       AND (p_ProcessPlan IS NULL OR ppv.MA_ProcessPlan_ID = p_ProcessPlan)
       AND EXISTS (SELECT 1 FROM MA_SEQUENCEPRODUCT
                   WHERE PRODUCTIONTYPE = '+'
--- a/model/src-db/database/model/functions/MRP_PURCHASEORDER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/MRP_PURCHASEORDER.xml	Thu May 25 06:12:59 2017 +0000
@@ -16,7 +16,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2001-2016 Openbravo SLU
+* All portions are Copyright (C) 2001-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -55,7 +55,6 @@
   v_LineNetAmt NUMBER:=0;
   v_gross_unit_price NUMBER:=0;
   v_stdprecision NUMBER:=0;
-  v_priceprecision NUMBER:=0;
   v_line_gross_amount NUMBER:=0;
   v_gross_price_std NUMBER:=0;
   v_gross_price_list NUMBER:=0;
@@ -236,20 +235,20 @@
       v_TaxID := C_GetTax(Cur_workproposal.M_Product_ID, v_DateDoc, v_Org_ID, v_M_Warehouse_ID, v_BillTo_ID, v_BPartner_Location_ID, null, 'N');
       v_LineNetAmt:= v_PriceActual*Cur_workproposal.QTY;
       IF (v_istaxincluded = 'Y') THEN
-        SELECT PricePrecision, stdprecision
-            INTO v_priceprecision, v_stdprecision
-          FROM C_CURRENCY
-          WHERE C_CURRENCY_ID = Cur_workproposal.C_Currency_ID;
+        SELECT stdprecision
+        INTO v_stdprecision
+        FROM C_CURRENCY
+        WHERE C_CURRENCY_ID = Cur_workproposal.C_Currency_ID;
 
         v_gross_unit_price:= v_PriceActual;
         v_gross_price_std:= v_PriceStd;
         v_gross_price_list:= v_PriceList;
         v_line_gross_amount:= ROUND(v_gross_unit_price * Cur_workproposal.QTY, v_stdprecision);
-        v_PriceActual:= C_GET_NET_PRICE_FROM_GROSS(v_TaxID, v_PriceActual, 0, v_priceprecision, 1);
-        v_PriceStd:= C_GET_NET_PRICE_FROM_GROSS(v_TaxID, v_PriceStd, 0, v_priceprecision, 1);
-        v_PriceList:= C_GET_NET_PRICE_FROM_GROSS(v_TaxID, v_PriceList, 0, v_priceprecision, 1);
-        v_PriceLimit:= C_GET_NET_PRICE_FROM_GROSS(v_TaxID, v_PriceLimit, 0, v_priceprecision, 1);
-        v_LineNetAmt:= ROUND(v_PriceActual * Cur_workproposal.QTY, v_stdprecision);
+        v_PriceActual:= 0;
+        v_PriceStd:= 0;
+        v_PriceList:= 0;
+        v_PriceLimit:= 0;
+        v_LineNetAmt:= 0;
 
         UPDATE C_ORDER SET ISTAXINCLUDED='Y' WHERE C_ORDER_ID = v_COrder_ID;
 
--- a/model/src-db/database/model/functions/M_EXPLODEBOMNOTSTOCK.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_EXPLODEBOMNOTSTOCK.xml	Thu May 25 06:12:59 2017 +0000
@@ -19,7 +19,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2013-2016 Openbravo SLU
+* All portions are Copyright (C) 2013-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -159,8 +159,8 @@
 					v_gross_unit_price:=M_Get_Offers_Price(CUR_BOM_Line.DateOrdered, v_CBPartner_ID, CUR_BOM.M_ProductBOM_ID, M_BOM_PriceStd(CUR_BOM.M_ProductBOM_ID, v_PriceList_Version_ID), CUR_BOM_Line.QtyInvoiced*CUR_BOM.BOMQty, v_PriceList_ID);
 					v_gross_price_list:=M_Get_Offers_Price(CUR_BOM_Line.DateOrdered, v_CBPartner_ID, CUR_BOM.M_ProductBOM_ID, M_BOM_PriceList(CUR_BOM.M_ProductBOM_ID, v_PriceList_Version_ID), CUR_BOM_Line.QtyInvoiced*CUR_BOM.BOMQty, v_PriceList_ID);
 					v_line_gross_amount:=ROUND(CUR_BOM_Line.QtyOrdered*CUR_BOM.BOMQty*v_gross_unit_price, v_Precision);
-					v_price_actual:=ROUND(C_GET_NET_PRICE_FROM_GROSS(V_C_Tax_Id,  M_Get_Offers_Price(CUR_BOM_Line.DateOrdered, v_CBPartner_ID, CUR_BOM.M_ProductBOM_ID, M_BOM_PriceStd(CUR_BOM.M_ProductBOM_ID, v_PriceList_Version_ID), CUR_BOM_Line.QtyInvoiced*CUR_BOM.BOMQty, v_PriceList_ID), 0, v_Precision, 1),v_Precision);
-					v_line_net_amt:=ROUND(CUR_BOM_Line.QtyOrdered*CUR_BOM.BOMQty*v_price_actual, v_Precision);
+					v_price_actual:=0;
+					v_line_net_amt:=0;
 				ELSE
 					v_gross_unit_price:=0;
 					v_line_gross_amount:=0;
--- a/model/src-db/database/model/functions/M_GET_PARETO_ABC.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_GET_PARETO_ABC.xml	Thu May 25 06:12:59 2017 +0000
@@ -28,11 +28,17 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2001-2016 Openbravo SLU
+* All portions are Copyright (C) 2001-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
 
+/* 
+* This code has very important performance issues and it has been deprecated.
+* ReportParetoProduct_data.xsql, select method has been rewritten so it is not needed anymore.
+* @deprecated
+*/
+
   VARaCUM NUMBER:=0;
   VARaCUMB NUMBER:=0;
   v_limitA NUMBER:=80;
--- a/model/src-db/database/model/functions/M_INOUT_CREATEINVOICE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_INOUT_CREATEINVOICE.xml	Thu May 25 06:12:59 2017 +0000
@@ -19,7 +19,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2001-2016 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2001-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -113,7 +113,6 @@
       --
       v_taxBaseAmt NUMBER;
       v_LineNetAmt NUMBER;
-      v_TotalNet NUMBER;
       -- v_Offer_ID       varchar2(32);
     BEGIN
       FOR CUR_Shipment IN
@@ -265,7 +264,6 @@
             )
             ;
           -- Lines
-          v_TotalNet:=0;
           FOR CUR_ShipmentLines IN
             (SELECT *  FROM M_INOUTLINE  WHERE M_InOut_ID=v_Record_ID)
           LOOP
@@ -318,10 +316,10 @@
                 v_grosspricestd:= v_PriceActual;
                 v_grosspricelist:= v_PriceList;
                 v_line_gross_amount:= ROUND(v_gross_unit_price * CUR_ShipmentLines.MovementQty, v_stdprecision);
-                v_PriceActual:= C_GET_NET_PRICE_FROM_GROSS(v_C_Tax_ID, v_PriceActual, 0, v_priceprecision, 1);
-                v_PriceList:= C_GET_NET_PRICE_FROM_GROSS(v_C_Tax_ID, v_PriceList, 0, v_priceprecision, 1);
-                v_PriceLimit:= C_GET_NET_PRICE_FROM_GROSS(v_C_Tax_ID, v_PriceLimit, 0, v_priceprecision, 1);
-                v_LineNetAmt:= ROUND(v_PriceActual * CUR_ShipmentLines.MovementQty, v_stdprecision);
+                v_PriceActual:= 0;
+                v_PriceList:= 0;
+                v_PriceLimit:= 0;
+                v_LineNetAmt:= 0;
               ELSE
                 v_PriceActual:=M_Get_Offers_Price(now(), CUR_Shipment.C_BPartner_ID, CUR_ShipmentLines.M_Product_ID, v_PriceActual, CUR_ShipmentLines.MovementQty, v_M_PriceList_ID);
                 v_LineNetAmt:=ROUND(M_Get_Offers_Price(now(), CUR_Shipment.C_BPartner_ID, CUR_ShipmentLines.M_Product_ID, v_PriceActual, CUR_ShipmentLines.MovementQty, v_M_PriceList_ID) *CUR_ShipmentLines.MovementQty, v_stdprecision) ;
@@ -384,9 +382,7 @@
                 coalesce(CUR_ShipmentLines.c_costcenter_id, CUR_Shipment.c_costcenter_id),
                 coalesce(CUR_ShipmentLines.a_asset_id, CUR_Shipment.a_asset_id),
                 CUR_ShipmentLines.c_aum, CUR_ShipmentLines.aumqty
-              )
-              ;
-            v_TotalNet:=v_TotalNet + v_LineNetAmt;
+              );
           END LOOP; -- ShipLines
         END IF;
       END LOOP; -- All Shipments
--- a/model/src-db/database/model/functions/M_INOUT_POST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_INOUT_POST.xml	Thu May 25 06:12:59 2017 +0000
@@ -22,7 +22,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2001-2016 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2001-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -510,7 +510,18 @@
           IF(Cur_InOut.Processed='N' AND Cur_InOut.DocStatus='DR' AND Cur_InOut.DocAction='CO') THEN
             -- For all active shipment lines
             v_ResultStr:='HeaderLoop-1';
-            
+
+          -- Update the C_Order_Id of M_InOut accordingly
+          UPDATE M_InOut io
+          SET C_Order_Id = (
+            SELECT CASE WHEN min(ol.c_order_id) = max(ol.c_order_id) THEN min(ol.c_order_id) ELSE NULL END
+            FROM M_InOutLine iol
+            JOIN C_OrderLine ol
+            ON iol.C_OrderLine_Id = ol.C_OrderLine_Id
+            WHERE iol.M_InOut_Id = io.M_InOut_ID
+          )
+          WHERE io.M_InOut_Id = Cur_InOut.M_InOut_ID;
+
         IF v_Aux=0 THEN
         RAISE_APPLICATION_ERROR(-20000, '@ReceiptWithoutLines@');
         END IF;
--- a/model/src-db/database/model/functions/M_PROMOTION_ADJUSTMENT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_PROMOTION_ADJUSTMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -34,7 +34,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2014 Openbravo SLU
+* All portions are Copyright (C) 2014-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -97,8 +97,8 @@
     v_newGrossAmt := round(v_newUnitPrice * v_qty, p_stdprecision);
     v_totalPromotion := v_origGrossAmt - v_newGrossAmt;
 
-    v_newNetPrice := c_get_net_price_from_gross(v_tax, v_newGrossAmt, v_newGrossAmt, p_priceprecision, v_qty);
-    v_newNetAmt := round(v_newNetPrice * v_qty, p_stdprecision);
+    v_newNetPrice := 0;
+    v_newNetAmt := 0;
     v_basePrice := v_unitprice;
   else
     if (v_fixed is not null) then
--- a/model/src-db/database/model/functions/M_REQUISITION_CREATEPO.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_REQUISITION_CREATEPO.xml	Thu May 25 06:12:59 2017 +0000
@@ -16,7 +16,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2008-2016 Openbravo SLU
+* All portions are Copyright (C) 2008-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -264,8 +264,8 @@
       IF (Cur_Lines.istaxincluded = 'Y') THEN
         v_gross_unit_price:= v_Gross;
         v_line_gross_amount:= ROUND(v_gross_unit_price * (Cur_Lines.QTY - Cur_Lines.ORDEREDQTY), v_stdPre);
-        v_PriceActual:= C_GET_NET_PRICE_FROM_GROSS(v_Tax_ID, v_line_gross_amount, v_line_gross_amount, v_priPre, (Cur_Lines.QTY - Cur_Lines.ORDEREDQTY));
-        v_LineNetAmt:= ROUND(v_PriceActual * (Cur_Lines.QTY - Cur_Lines.ORDEREDQTY), v_stdPre);
+        v_PriceActual:= 0;
+        v_LineNetAmt:= 0;
         IF (v_PriceList = 0) THEN
           v_Discount := 0 ;
         ELSE
--- a/model/src-db/database/model/functions/M_UPDATE_INVENTORY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/functions/M_UPDATE_INVENTORY.xml	Thu May 25 06:12:59 2017 +0000
@@ -52,7 +52,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2001-2014 Openbravo SLU
+* All portions are Copyright (C) 2001-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -111,7 +111,6 @@
       PREQTYONHAND=PREQTYONHAND + COALESCE(p_preqty, 0),
       PREQTYORDERONHAND=PREQTYORDERONHAND + v_preqtyorder,
       AD_CLIENT_ID=p_client,
-      AD_ORG_ID=p_org,
       UPDATED=now(),
       UPDATEDBY=p_user
     WHERE M_PRODUCT_ID=p_product
--- a/model/src-db/database/model/postscript-Oracle.sql	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/postscript-Oracle.sql	Thu May 25 06:12:59 2017 +0000
@@ -580,7 +580,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2009-2016 Openbravo SLU
+* All portions are Copyright (C) 2009-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -595,7 +595,7 @@
   cur_triggers RECORD;
   cur_tables RECORD;
   cur_cols RECORD;
-  triggerName varchar2(30);
+  targetTriggerName varchar2(30);
   recordIdName varchar2(30);
   datatype varchar2(30);
   clientinfo number;
@@ -603,6 +603,9 @@
   created number :=0;
   v_message varchar2(500);
   v_isObps number;
+  isavailablename number :=0;
+  suffixNumber number :=0;
+  numberCharsToRemove number;
   
   
   FUNCTION splitClob(code clob, splitcode out dbms_sql.varchar2s ) RETURN number AS 
@@ -644,7 +647,19 @@
                       and dataOriginType = 'Table'
                       order by tablename) loop
     dbms_output.put_line('Creating trigger for table '||cur_tables.tablename);
-    triggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23)||'_TRG';
+    targetTriggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23)||'_TRG';
+    LOOP
+        select count(*)
+          into isavailablename
+        from user_triggers
+        where upper(trigger_name) = upper(targetTriggerName);
+
+        EXIT WHEN isavailablename = 0;
+
+        suffixNumber := suffixNumber + 1;
+        numberCharsToRemove :=LENGTH(suffixNumber);
+        targetTriggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23-numberCharsToRemove)||''||suffixNumber||'_TRG';
+    END LOOP;
     
     select count(*) into clientinfo
       from dual
@@ -662,7 +677,7 @@
      where ad_table_id = cur_tables.ad_table_id
        and iskey='Y';
     
-      code := 'create or replace TRIGGER '||triggerName||' 
+      code := 'create or replace TRIGGER '||targetTriggerName||' 
 AFTER INSERT OR UPDATE OR DELETE
 ON '|| cur_tables.tablename||' FOR EACH ROW
 DECLARE
@@ -824,6 +839,7 @@
 DBMS_SQL.close_cursor(cursor_id);
 
     created := created + 1;
+    suffixNumber :=0;
   end loop;
   
   v_Message := '@Deleted@: '||deleted||' @Created@: '||created;
--- a/model/src-db/database/model/postscript-PostgreSql.sql	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/postscript-PostgreSql.sql	Thu May 25 06:12:59 2017 +0000
@@ -375,7 +375,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2009-2016 Openbravo SLU
+* All portions are Copyright (C) 2009-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -383,7 +383,7 @@
   cur_triggers RECORD;
   cur_tables RECORD;
   cur_cols RECORD;
-  triggerName VARCHAR(30); 
+  targetTriggerName VARCHAR(30);
   recordIdName VARCHAR(30);
   datatype VARCHAR(30); 
   clientinfo NUMERIC;
@@ -391,6 +391,9 @@
   created NUMERIC :=0;
   v_message VARCHAR(500);
   v_isObps NUMERIC;
+  isavailablename NUMERIC :=0;
+  suffixNumber NUMERIC :=0;
+  numberCharsToRemove NUMERIC;
 BEGIN 
   select count(*) 
     into v_isObps
@@ -418,8 +421,21 @@
                       and dataOriginType = 'Table'
                       order by tablename) loop
     
-    triggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23)||'_TRG';
-    raise notice '%', triggerName;
+    targetTriggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23)||'_TRG';
+    LOOP
+        select count(*)
+         into isavailablename
+        from user_triggers u
+        where upper(trigger_name) = upper(targetTriggerName);
+
+        EXIT WHEN isavailablename = 0;
+
+	 suffixNumber := suffixNumber + 1;
+	 raise notice '%', targetTriggerName || ' is already exists. Renaming...';
+	 numberCharsToRemove :=LENGTH(CAST(suffixNumber AS VARCHAR));
+	 targetTriggerName := 'AU_'||SUBSTR(cur_tables.tablename,1,23-numberCharsToRemove)||''||suffixNumber||'_TRG';
+    END LOOP;
+    raise notice '%', targetTriggerName;
     
     select count(*) into clientinfo
       from dual
@@ -437,7 +453,7 @@
      where ad_table_id = cur_tables.ad_table_id
        and iskey='Y';
     
-      code := 'create or replace FUNCTION '||triggerName||'() 
+      code := 'create or replace FUNCTION '||targetTriggerName||'()
 RETURNS trigger AS
 $BODY$
 DECLARE
@@ -611,15 +627,15 @@
 EXECUTE(code);
 
  code := 
-    'CREATE TRIGGER '||triggerName||'
+    'CREATE TRIGGER '||targetTriggerName||'
       BEFORE INSERT OR UPDATE OR DELETE
       ON '||cur_cols.table_name||'
       FOR EACH ROW
-      EXECUTE PROCEDURE '||triggerName||'()';
+      EXECUTE PROCEDURE '||targetTriggerName||'()';
       execute(code);
       
     created := created + 1;
-
+    suffixNumber :=0;
   end loop;
   
   v_Message := '@Deleted@: '||deleted||' @Created@: '||created;
--- a/model/src-db/database/model/prescript-Oracle.sql	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/prescript-Oracle.sql	Thu May 25 06:12:59 2017 +0000
@@ -123,7 +123,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2009 Openbravo SLU
+* All portions are Copyright (C) 2009-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -139,7 +139,7 @@
 for c1 in (select text from user_source where not (type = 'TRIGGER' and name like 'AU\_%' escape '\') order by name,line) loop
      v_md5 := dbms_obfuscation_toolkit.md5(input_string => v_md5||c1.text);
 end loop;
-for c1 in (select * from user_tab_cols order by table_name, column_id) loop
+for c1 in (select * from user_tab_cols where hidden_column = 'NO' order by table_name, column_id) loop
      v_md5 := dbms_obfuscation_toolkit.md5(input_string => v_md5||c1.column_name||c1.data_type||c1.data_length||c1.nullable);
 end loop;
 for c1 in (select * from user_views order by view_name) loop
@@ -234,3 +234,38 @@
   RETURN p_date + p_hours/24 + p_minutes/1440 + p_seconds/86400;
 end ADD_HMS;
 /-- END
+
+create or replace
+FUNCTION OBEQUALS(p_number_a IN NUMBER, p_number_b IN NUMBER) RETURN CHAR DETERMINISTIC
+
+AS
+/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2017 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+/**
+* Returns 'Y' when both numbers are equals, else returns 'N'
+* This function is used as index in FIN_Payment table
+**/
+ v_dif NUMBER;
+begin
+    v_dif := coalesce(p_number_a, 0) - coalesce(p_number_b, 0);
+    IF (v_dif = 0) THEN
+     return 'Y';
+    ELSE
+     return 'N';
+    END IF;
+end OBEQUALS;
+/-- END
--- a/model/src-db/database/model/prescript-PostgreSql.sql	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/prescript-PostgreSql.sql	Thu May 25 06:12:59 2017 +0000
@@ -1184,6 +1184,7 @@
 RETURNS uuid
 AS '$libdir/uuid-ossp', 'uuid_generate_v4'
 VOLATILE STRICT LANGUAGE C;
+/-- END
 
 CREATE OR REPLACE FUNCTION get_uuid()
   RETURNS varchar AS
@@ -1531,3 +1532,44 @@
 END ; $BODY$
   LANGUAGE plpgsql IMMUTABLE
 /-- END
+
+-- INSTALL PG_TRGM EXTENSION
+CREATE EXTENSION IF NOT EXISTS "pg_trgm"
+/-- END
+
+CREATE OR REPLACE FUNCTION obequals(
+    p_number_a numeric,
+    p_number_b numeric)
+  RETURNS char AS
+$BODY$ DECLARE
+/*************************************************************************
+* The contents of this file are subject to the Openbravo  Public  License
+* Version  1.1  (the  "License"),  being   the  Mozilla   Public  License
+* Version 1.1  with a permitted attribution clause; you may not  use this
+* file except in compliance with the License. You  may  obtain  a copy of
+* the License at http://www.openbravo.com/legal/license.html
+* Software distributed under the License  is  distributed  on  an "AS IS"
+* basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+* License for the specific  language  governing  rights  and  limitations
+* under the License.
+* The Original Code is Openbravo ERP.
+* The Initial Developer of the Original Code is Openbravo SLU
+* All portions are Copyright (C) 2017 Openbravo SLU
+* All Rights Reserved.
+* Contributor(s):  ______________________________________.
+************************************************************************/
+/**
+* Returns 'Y' when both numbers are equals, else returns 'N'
+* This function is used as index in FIN_Payment table
+**/
+ v_dif NUMERIC;
+BEGIN
+    v_dif := coalesce(p_number_a, 0) - coalesce(p_number_b, 0);
+    IF (v_dif = 0) THEN
+     return 'Y';
+    ELSE
+     return 'N';
+    END IF;
+END; $BODY$
+  LANGUAGE plpgsql IMMUTABLE
+/-- END
--- a/model/src-db/database/model/tables/AD_COLUMN.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_COLUMN.xml	Thu May 25 06:12:59 2017 +0000
@@ -256,6 +256,7 @@
       </index>
       <index name="AD_COLUMN_PROCESS" unique="false">
         <index-column name="AD_PROCESS_ID"/>
+        <whereClause><![CDATA[AD_PROCESS_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_COLUMN_TABLE" unique="false">
         <index-column name="AD_TABLE_ID"/>
--- a/model/src-db/database/model/tables/AD_MODEL_OBJECT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_MODEL_OBJECT.xml	Thu May 25 06:12:59 2017 +0000
@@ -111,15 +111,19 @@
       </foreign-key>
       <index name="AD_MODELOBJECT_CALLOUT_IDX" unique="false">
         <index-column name="AD_CALLOUT_ID"/>
+        <whereClause><![CDATA[AD_CALLOUT_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_MODELOBJECT_FORM_IDX" unique="false">
         <index-column name="AD_FORM_ID"/>
+        <whereClause><![CDATA[AD_FORM_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_MODELOBJECT_PROCESS_IDX" unique="false">
         <index-column name="AD_PROCESS_ID"/>
+        <whereClause><![CDATA[AD_PROCESS_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_MODELOBJECT_REFERENCE_IDX" unique="false">
         <index-column name="AD_REFERENCE_ID"/>
+        <whereClause><![CDATA[AD_REFERENCE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="AD_MODEL_OBJECT_ISACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="AD_MODEL_OBJECT_ISDEFAULT_CHK"><![CDATA[ISDEFAULT IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/AD_ORGMODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_ORGMODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -54,12 +54,6 @@
       <foreign-key foreignTable="AD_ORG" name="AD_ORGMODULE_AD_ORG">
         <reference local="AD_ORG_ID" foreign="AD_ORG_ID"/>
       </foreign-key>
-      <unique name="AD_ORGMODULE_APPLY_UNIQUE">
-        <unique-column name="AD_CLIENT_ID"/>
-        <unique-column name="AD_ORG_ID"/>
-        <unique-column name="AD_MODULE_ID"/>
-        <unique-column name="VERSION"/>
-      </unique>
       <check name="AD_ORGMODULE_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
   </database>
--- a/model/src-db/database/model/tables/AD_PROCESS_RUN.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_PROCESS_RUN.xml	Thu May 25 06:12:59 2017 +0000
@@ -86,6 +86,7 @@
       </index>
       <index name="AD_PROCESS_RUN_ADPRGROUP_ID" unique="false">
         <index-column name="AD_PROCESS_RUN_GROUP_ID"/>
+        <whereClause><![CDATA[AD_PROCESS_RUN_GROUP_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_PROCESS_RUN_STATUS" unique="false">
         <index-column name="STATUS"/>
--- a/model/src-db/database/model/tables/AD_TAB.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_TAB.xml	Thu May 25 06:12:59 2017 +0000
@@ -237,6 +237,7 @@
       </index>
       <index name="AD_TAB_TABLETREE_FK" unique="false">
         <index-column name="AD_TABLE_TREE_ID"/>
+        <whereClause><![CDATA[AD_TABLE_TREE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_TAB_WINDOW" unique="false">
         <index-column name="AD_WINDOW_ID"/>
--- a/model/src-db/database/model/tables/AD_USER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/AD_USER.xml	Thu May 25 06:12:59 2017 +0000
@@ -206,6 +206,7 @@
       </foreign-key>
       <index name="AD_USER_EMAIL" unique="false">
         <index-column name="EMAIL"/>
+        <whereClause><![CDATA[EMAIL IS NOT NULL]]></whereClause>
       </index>
       <index name="AD_USER_NAME" unique="false">
         <index-column name="AD_CLIENT_ID"/>
--- a/model/src-db/database/model/tables/A_AMORTIZATIONLINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/A_AMORTIZATIONLINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -109,6 +109,7 @@
       </index>
       <index name="A_AMORTIZATIONLINE_ASSET_IDX" unique="false">
         <index-column name="A_ASSET_ID"/>
+        <whereClause><![CDATA[A_ASSET_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="A_AMORTIZATIONL_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/A_ASSET.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/A_ASSET.xml	Thu May 25 06:12:59 2017 +0000
@@ -291,6 +291,7 @@
       </foreign-key>
       <index name="A_ASSET_BPARTNER_IDX" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="A_ASSET_IS30DAYMONTH_CHK"><![CDATA[IS30DAYMONTH IN ('Y', 'N')]]></check>
       <check name="A_ASSET_ISACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/C_ACCTSCHEMA_PROCESS.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_ACCTSCHEMA_PROCESS.xml	Thu May 25 06:12:59 2017 +0000
@@ -63,6 +63,7 @@
       </foreign-key>
       <index name="C_ACCTSCHEMAPRC_ACCTSCHEMA_IDX" unique="false">
         <index-column name="C_ACCTSCHEMA_ID"/>
+        <whereClause><![CDATA[C_ACCTSCHEMA_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="C_ACCTSCHEMA_PROCESS_ISACT_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="C_ACCTSCHEMA_PROCESS_ISDAT_CHK"><![CDATA[ISDATASET IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/C_BPARTNER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_BPARTNER.xml	Thu May 25 06:12:59 2017 +0000
@@ -471,6 +471,7 @@
       <index name="C_BPARTNER_REFNO_ID" unique="false">
         <index-column name="REFERENCENO"/>
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[REFERENCENO IS NOT NULL]]></whereClause>
       </index>
       <index name="C_BPARTNER_VALUE_ID" unique="false">
         <index-column name="VALUE"/>
--- a/model/src-db/database/model/tables/C_CITY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_CITY.xml	Thu May 25 06:12:59 2017 +0000
@@ -75,6 +75,7 @@
       </foreign-key>
       <index name="C_CITY_REGION_IDX" unique="false">
         <index-column name="C_REGION_ID"/>
+        <whereClause><![CDATA[C_REGION_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="C_CITY_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/C_CONVERSION_RATE_DOCUMENT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_CONVERSION_RATE_DOCUMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -98,9 +98,14 @@
       </foreign-key>
       <index name="C_CONVRATEDOC_FINACCTRX_IDX" unique="false">
         <index-column name="FIN_FINACC_TRANSACTION_ID"/>
+        <whereClause><![CDATA[FIN_FINACC_TRANSACTION_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_CONVRATEDOC_GLJOURNAL_IDX" unique="false">
         <index-column name="GL_JOURNAL_ID"/>
+        <whereClause><![CDATA[GL_JOURNAL_ID IS NOT NULL]]></whereClause>
+      </index>
+      <index name="C_CONVRATEDOC_INVOICE_IDX" unique="false">
+        <index-column name="C_INVOICE_ID"/>
       </index>
       <index name="C_CONVRATEDOC_PAYMENT_IDX" unique="false">
         <index-column name="FIN_PAYMENT_ID"/>
--- a/model/src-db/database/model/tables/C_INVOICE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_INVOICE.xml	Thu May 25 06:12:59 2017 +0000
@@ -363,6 +363,7 @@
       </index>
       <index name="C_INVOICE_ORDER" unique="false">
         <index-column name="C_ORDER_ID"/>
+        <whereClause><![CDATA[C_ORDER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_INVOICE_PAID" unique="false">
         <index-column name="ISPAID"/>
--- a/model/src-db/database/model/tables/C_INVOICELINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_INVOICELINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -306,12 +306,14 @@
       </foreign-key>
       <index name="C_INVOICELINE_INOUTLINE" unique="false">
         <index-column name="M_INOUTLINE_ID"/>
+        <whereClause><![CDATA[M_INOUTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_INVOICELINE_INVOICE" unique="false">
         <index-column name="C_INVOICE_ID"/>
       </index>
       <index name="C_INVOICELINE_ORDERLINE" unique="false">
         <index-column name="C_ORDERLINE_ID"/>
+        <whereClause><![CDATA[C_ORDERLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_INVOICELINE_PRODUCT" unique="false">
         <index-column name="M_PRODUCT_ID"/>
--- a/model/src-db/database/model/tables/C_ORDER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_ORDER.xml	Thu May 25 06:12:59 2017 +0000
@@ -469,6 +469,7 @@
       </index>
       <index name="C_ORDER_C_RETURN_REASON" unique="false">
         <index-column name="C_RETURN_REASON_ID"/>
+        <whereClause><![CDATA[C_RETURN_REASON_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_ORDER_CLIENT_ORG_DATE_DOCNO" unique="false">
         <index-column name="AD_CLIENT_ID"/>
--- a/model/src-db/database/model/tables/C_ORDERLINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_ORDERLINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -382,9 +382,11 @@
       </foreign-key>
       <index name="C_ORDERLINE_C_RETURN_REASON" unique="false">
         <index-column name="C_RETURN_REASON_ID"/>
+        <whereClause><![CDATA[C_RETURN_REASON_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_ORDERLINE_INOUTLINE" unique="false">
         <index-column name="M_INOUTLINE_ID"/>
+        <whereClause><![CDATA[M_INOUTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="C_ORDERLINE_ORDER" unique="false">
         <index-column name="C_ORDER_ID"/>
--- a/model/src-db/database/model/tables/C_ORDERLINETAX.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_ORDERLINETAX.xml	Thu May 25 06:12:59 2017 +0000
@@ -72,6 +72,9 @@
       <foreign-key foreignTable="C_TAX" name="C_ORDERLINETAX_C_TAX">
         <reference local="C_TAX_ID" foreign="C_TAX_ID"/>
       </foreign-key>
+      <index name="C_ORDERLINETAX_ORDERID" unique="false">
+        <index-column name="C_ORDER_ID"/>
+      </index>
       <index name="C_ORDERLINETAX_ORDERLINE" unique="false">
         <index-column name="C_ORDERLINE_ID"/>
       </index>
--- a/model/src-db/database/model/tables/C_ORDERTAX.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_ORDERTAX.xml	Thu May 25 06:12:59 2017 +0000
@@ -65,6 +65,9 @@
       <foreign-key foreignTable="C_TAX" name="C_ORDERTAX_C_TAX">
         <reference local="C_TAX_ID" foreign="C_TAX_ID"/>
       </foreign-key>
+      <index name="C_ORDERTAX_ORDERID" unique="false">
+        <index-column name="C_ORDER_ID"/>
+      </index>
       <unique name="C_ORDERTAX_ORDER_TAX_UN">
         <unique-column name="C_ORDER_ID"/>
         <unique-column name="C_TAX_ID"/>
--- a/model/src-db/database/model/tables/C_POC_DOCTYPE_TEMPLATE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_POC_DOCTYPE_TEMPLATE.xml	Thu May 25 06:12:59 2017 +0000
@@ -80,6 +80,7 @@
       </foreign-key>
       <index name="C_POC_DOCTYPE_TEMP_DOCTYPE_IDX" unique="false">
         <index-column name="C_DOCTYPE_ID"/>
+        <whereClause><![CDATA[C_DOCTYPE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="C_POC_DOCTYPETEMP_SHOWCOMP_CHK"><![CDATA[SHOWCOMPANYDATA IN ('Y', 'N')]]></check>
       <check name="C_POC_DOCTYPETEMP_SHOWLOGO_CHK"><![CDATA[SHOWLOGO IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/C_POC_EMAILDEFINITION.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_POC_EMAILDEFINITION.xml	Thu May 25 06:12:59 2017 +0000
@@ -67,6 +67,7 @@
       </foreign-key>
       <index name="C_POCEMAILDEF_DOCTYPETEMPL_IDX" unique="false">
         <index-column name="C_POC_DOCTYPE_TEMPLATE_ID"/>
+        <whereClause><![CDATA[C_POC_DOCTYPE_TEMPLATE_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/src-db/database/model/tables/C_TAXREGISTER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_TAXREGISTER.xml	Thu May 25 06:12:59 2017 +0000
@@ -71,6 +71,7 @@
       </foreign-key>
       <index name="C_TAXREGISTER_TAXPAYMENT_IDX" unique="false">
         <index-column name="C_TAXPAYMENT_ID"/>
+        <whereClause><![CDATA[C_TAXPAYMENT_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/src-db/database/model/tables/C_TAXREGISTERLINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_TAXREGISTERLINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -98,6 +98,7 @@
       </foreign-key>
       <index name="C_TAXREGISTERLINE_TAXREGIS_IDX" unique="false">
         <index-column name="C_TAXREGISTER_ID"/>
+        <whereClause><![CDATA[C_TAXREGISTER_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/src-db/database/model/tables/C_TAXREGISTER_TYPE_LINES.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/C_TAXREGISTER_TYPE_LINES.xml	Thu May 25 06:12:59 2017 +0000
@@ -62,6 +62,7 @@
       </foreign-key>
       <index name="C_TAXREGTYPELIN_TAXREGTYPE_IDX" unique="false">
         <index-column name="C_TAXREGISTER_TYPE_ID"/>
+        <whereClause><![CDATA[C_TAXREGISTER_TYPE_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/src-db/database/model/tables/FACT_ACCT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FACT_ACCT.xml	Thu May 25 06:12:59 2017 +0000
@@ -302,6 +302,10 @@
       <index name="FACT_ACCT_GROUP" unique="false">
         <index-column name="FACT_ACCT_GROUP_ID"/>
       </index>
+      <index name="FACT_ACCT_LINE_ID" unique="false">
+        <index-column name="LINE_ID"/>
+        <whereClause><![CDATA[LINE_ID IS NOT NULL]]></whereClause>
+      </index>
       <index name="FACT_ACCT_RECORD_ID2" unique="false">
         <index-column name="RECORD_ID2"/>
       </index>
--- a/model/src-db/database/model/tables/FIN_DOUBTFUL_DEBT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_DOUBTFUL_DEBT.xml	Thu May 25 06:12:59 2017 +0000
@@ -161,6 +161,10 @@
       <index name="FIN_DOUBTDBT_DOUBTDBTRUN_IDX" unique="false">
         <index-column name="FIN_DOUBTFUL_DEBT_RUN_ID"/>
       </index>
+      <index name="FIN_DOUBTDBT_PAYSCHED_IDX" unique="false">
+        <index-column name="FIN_PAYMENT_SCHEDULE_ID"/>
+        <whereClause><![CDATA[FIN_PAYMENT_SCHEDULE_ID IS NOT NULL]]></whereClause>
+      </index>
       <index name="FIN_DOUBTFUL_DEBT_POSTED" unique="false">
         <index-column name="POSTED"/>
       </index>
--- a/model/src-db/database/model/tables/FIN_ORIG_PAYMENT_SCHEDULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_ORIG_PAYMENT_SCHEDULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -88,6 +88,7 @@
       </foreign-key>
       <index name="FIN_ORIG_PAYM_SCHED_IND" unique="false">
         <index-column name="C_INVOICE_ID"/>
+        <whereClause><![CDATA[C_INVOICE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="FIN_PAYORIGSCHED_ISAC_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="FIN_PAYORIGSCHED_UPP_CHK"><![CDATA[UPDATE_PAYMENT_PLAN IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/FIN_ORIG_PAYM_SCHEDDETAIL.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_ORIG_PAYM_SCHEDDETAIL.xml	Thu May 25 06:12:59 2017 +0000
@@ -67,6 +67,7 @@
       </foreign-key>
       <index name="FIN_ORIG_PAYM_SCHDET_IND" unique="false">
         <index-column name="FIN_ORIG_PAYMENT_SCHEDULE_ID"/>
+        <whereClause><![CDATA[FIN_ORIG_PAYMENT_SCHEDULE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="FIN_ORIG_PAY_SCHDET_ISCANC_CHK"><![CDATA[ISCANCELED IN ('Y', 'N')]]></check>
       <check name="FIN_ORIG_PAYM_SCHDET_ACT_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/FIN_PAYMENT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_PAYMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -187,9 +187,17 @@
       <foreign-key foreignTable="USER2" name="FIN_PAYMENT_USER2">
         <reference local="USER2_ID" foreign="USER2_ID"/>
       </foreign-key>
+      <index name="FIN_PAYMENT_BPARTNER_CREDIT" unique="false">
+        <index-column name="C_BPARTNER_ID"/>
+        <index-column name="functionBasedColumn" functionExpression="OBEQUALS(GENERATED_CREDIT,USED_CREDIT)"/>
+      </index>
       <index name="FIN_PAYMENT_POSTED" unique="false">
         <index-column name="POSTED"/>
       </index>
+      <index name="FIN_PAYMENT_REVERSEPAYMENT" unique="false">
+        <index-column name="FIN_REV_PAYMENT_ID"/>
+        <whereClause><![CDATA[FIN_REV_PAYMENT_ID IS NOT NULL]]></whereClause>
+      </index>
       <check name="FIN_PAYMENT_BP_CREDIT_CHECK"><![CDATA[C_BPARTNER_ID IS NULL AND COALESCE(GENERATED_CREDIT, 0) = 0 OR C_BPARTNER_ID IS NOT NULL]]></check>
       <check name="FIN_PAYMENT_CREATE_ALGORIT_CHK"><![CDATA[CREATEDBYALGORITHM IN ('Y', 'N')]]></check>
       <check name="FIN_PAYMENT_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -108,9 +108,11 @@
       </foreign-key>
       <index name="FIN_PAYM_SCH_INV_IDX" unique="false">
         <index-column name="C_INVOICE_ID"/>
+        <whereClause><![CDATA[C_INVOICE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="FIN_PAYM_SCH_ORD_IDX" unique="false">
         <index-column name="C_ORDER_ID"/>
+        <whereClause><![CDATA[C_ORDER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="FIN_PAYMENT_SCHEDULE_OUTAMT" unique="false">
         <index-column name="OUTSTANDINGAMT"/>
--- a/model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULEDETAIL.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/FIN_PAYMENT_SCHEDULEDETAIL.xml	Thu May 25 06:12:59 2017 +0000
@@ -145,6 +145,7 @@
       </foreign-key>
       <index name="FIN_PAY_SCHEDULEDETAIL_BP" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="FIN_PAY_SCHEDULEDETAIL_IN" unique="false">
         <index-column name="FIN_PAYMENT_SCHEDULE_INVOICE"/>
--- a/model/src-db/database/model/tables/GL_JOURNAL.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/GL_JOURNAL.xml	Thu May 25 06:12:59 2017 +0000
@@ -215,6 +215,7 @@
       </foreign-key>
       <index name="GL_JOURNAL_JOURNALBATCH_IDX" unique="false">
         <index-column name="GL_JOURNALBATCH_ID"/>
+        <whereClause><![CDATA[GL_JOURNALBATCH_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="GL_JOURNAL_POSTED" unique="false">
         <index-column name="POSTED"/>
--- a/model/src-db/database/model/tables/MA_MAINTENANCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/MA_MAINTENANCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -82,9 +82,11 @@
       </foreign-key>
       <index name="MA_MAINTENANCE_MACHINE_IDX" unique="false">
         <index-column name="MA_MACHINE_ID"/>
+        <whereClause><![CDATA[MA_MACHINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="MA_MAINTENANCE_MACHINETYPE_IDX" unique="false">
         <index-column name="MA_MACHINE_TYPE_ID"/>
+        <whereClause><![CDATA[MA_MACHINE_TYPE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="MA_MAINTENANCE_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/MA_MEASURE_GROUP.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/MA_MEASURE_GROUP.xml	Thu May 25 06:12:59 2017 +0000
@@ -59,6 +59,7 @@
       </foreign-key>
       <index name="MA_MEASUREGRP_MEASURESHIFT_IDX" unique="false">
         <index-column name="MA_MEASURE_SHIFT_ID"/>
+        <whereClause><![CDATA[MA_MEASURE_SHIFT_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="MA_MEASURE_GROU_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/MA_PROCESS.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/MA_PROCESS.xml	Thu May 25 06:12:59 2017 +0000
@@ -67,6 +67,7 @@
       </foreign-key>
       <index name="MA_PROCESS_WORKSTATION_IDX" unique="false">
         <index-column name="MA_WORKSTATION_ID"/>
+        <whereClause><![CDATA[MA_WORKSTATION_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="MA_PROCESS_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/MA_WEINCIDENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/MA_WEINCIDENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -74,6 +74,7 @@
       </foreign-key>
       <index name="MA_WEINCIDENCE_PRODPLAN_IDX" unique="false">
         <index-column name="M_PRODUCTIONPLAN_ID"/>
+        <whereClause><![CDATA[M_PRODUCTIONPLAN_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="MA_WEINCIDENCE_PRODUCTION_IDX" unique="false">
         <index-column name="M_PRODUCTION_ID"/>
--- a/model/src-db/database/model/tables/MRP_RUN_PRODUCTIONLINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/MRP_RUN_PRODUCTIONLINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -144,6 +144,7 @@
       </index>
       <index name="MRP_RUN_PRODUCTIONLINE_PARENT" unique="false">
         <index-column name="PARENT_ID"/>
+        <whereClause><![CDATA[PARENT_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="MRP_RUN_PRODUCTIONLINE_ISA_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="MRP_RUN_PRODUCTIONLINE_ISF_CHK"><![CDATA[ISFIXED IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_COSTADJUSTMENTLINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_COSTADJUSTMENTLINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -108,9 +108,11 @@
       </index>
       <index name="M_COSTADJLINE_PARENT_IDX" unique="false">
         <index-column name="PARENT_COSTADJUSTMENTLINE_ID"/>
+        <whereClause><![CDATA[PARENT_COSTADJUSTMENTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_COSTADJLINE_TRX_IDX" unique="false">
         <index-column name="M_TRANSACTION_ID"/>
+        <whereClause><![CDATA[M_TRANSACTION_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_COSTADJLINE_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_COSTADJLINE_POSTING_CHK"><![CDATA[NEEDSPOSTING IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_COSTING.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_COSTING.xml	Thu May 25 06:12:59 2017 +0000
@@ -146,6 +146,7 @@
       </index>
       <index name="M_COSTING_TRANSACTION" unique="false">
         <index-column name="M_TRANSACTION_ID"/>
+        <whereClause><![CDATA[M_TRANSACTION_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_COSTING_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/M_INOUT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_INOUT.xml	Thu May 25 06:12:59 2017 +0000
@@ -346,6 +346,7 @@
       </index>
       <index name="M_INOUT_ORDER" unique="false">
         <index-column name="C_ORDER_ID"/>
+        <whereClause><![CDATA[C_ORDER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_INOUT_POSTED" unique="false">
         <index-column name="POSTED"/>
--- a/model/src-db/database/model/tables/M_LANDEDCOST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LANDEDCOST.xml	Thu May 25 06:12:59 2017 +0000
@@ -91,6 +91,7 @@
       </foreign-key>
       <index name="M_LANDEDCOST_COSTADJ" unique="false">
         <index-column name="M_COSTADJUSTMENT_ID"/>
+        <whereClause><![CDATA[M_COSTADJUSTMENT_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LANDEDCOST_POSTED" unique="false">
         <index-column name="POSTED"/>
--- a/model/src-db/database/model/tables/M_LC_COST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LC_COST.xml	Thu May 25 06:12:59 2017 +0000
@@ -145,15 +145,19 @@
       </foreign-key>
       <index name="M_LC_COST_INOUT" unique="false">
         <index-column name="M_INOUT_ID"/>
+        <whereClause><![CDATA[M_INOUT_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LC_COST_INVOICELINE" unique="false">
         <index-column name="C_INVOICELINE_ID"/>
+        <whereClause><![CDATA[C_INVOICELINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LC_COST_LANDEDCOST" unique="false">
         <index-column name="M_LANDEDCOST_ID"/>
+        <whereClause><![CDATA[M_LANDEDCOST_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LC_COST_POSTED" unique="false">
         <index-column name="POSTED"/>
+        <whereClause><![CDATA[POSTED IS NOT NULL]]></whereClause>
       </index>
       <check name="M_LC_COST_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_LC_COST_MATCHADJ"><![CDATA[ISMATCHINGADJUSTED IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_LC_MATCHED.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LC_MATCHED.xml	Thu May 25 06:12:59 2017 +0000
@@ -67,9 +67,11 @@
       </foreign-key>
       <index name="M_LC_MATCHED_INVOICELINE" unique="false">
         <index-column name="C_INVOICELINE_ID"/>
+        <whereClause><![CDATA[C_INVOICELINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LC_MATCHED_LCCOST" unique="false">
         <index-column name="M_LC_COST_ID"/>
+        <whereClause><![CDATA[M_LC_COST_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_LC_MATCHED_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_LC_MATCHED_ISCONVERSIONMATCH"><![CDATA[ISCONVERSIONMATCHING IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_LC_RECEIPT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LC_RECEIPT.xml	Thu May 25 06:12:59 2017 +0000
@@ -62,6 +62,7 @@
       </foreign-key>
       <index name="M_LC_RECEIPT_INOUT" unique="false">
         <index-column name="M_INOUT_ID"/>
+        <whereClause><![CDATA[M_INOUT_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_LC_RECEIPT_INOUTLINE" unique="false">
         <index-column name="M_INOUTLINE_ID"/>
--- a/model/src-db/database/model/tables/M_LC_RECEIPTLINE_AMT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LC_RECEIPTLINE_AMT.xml	Thu May 25 06:12:59 2017 +0000
@@ -73,6 +73,7 @@
       </index>
       <index name="M_LC_RECEIPTLINE_LCRECEIPT" unique="false">
         <index-column name="M_LC_RECEIPT_ID"/>
+        <whereClause><![CDATA[M_LC_RECEIPT_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_LC_RECEIPTLINEAMT_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_LC_RECEIPTLINEAMT_ISMATCH"><![CDATA[ISMATCHADJUSTMENT IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_LOCATOR.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_LOCATOR.xml	Thu May 25 06:12:59 2017 +0000
@@ -76,6 +76,7 @@
       </foreign-key>
       <index name="M_LOCATOR_BARCODE_IDX" unique="false">
         <index-column name="BARCODE"/>
+        <whereClause><![CDATA[BARCODE IS NOT NULL]]></whereClause>
       </index>
       <unique name="M_LOCATION_WHERE">
         <unique-column name="M_WAREHOUSE_ID"/>
--- a/model/src-db/database/model/tables/M_MATCHPO.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_MATCHPO.xml	Thu May 25 06:12:59 2017 +0000
@@ -89,6 +89,7 @@
       </foreign-key>
       <index name="M_MATCHPO_INOUT" unique="false">
         <index-column name="M_INOUTLINE_ID"/>
+        <whereClause><![CDATA[M_INOUTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_MATCHPO_POSTED" unique="false">
         <index-column name="POSTED"/>
@@ -96,6 +97,7 @@
       <index name="M_MATCHPO_SHIP" unique="false">
         <index-column name="C_ORDERLINE_ID"/>
         <index-column name="M_INOUTLINE_ID"/>
+        <whereClause><![CDATA[M_INOUTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_MATCHPO_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_MATCHPO_PROCESSED_CHECK"><![CDATA[PROCESSED IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_PRODUCT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_PRODUCT.xml	Thu May 25 06:12:59 2017 +0000
@@ -470,12 +470,15 @@
       </index>
       <index name="M_PRODUCT_BPARTNER" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_PRODUCT_BRAND_ID" unique="false">
         <index-column name="M_BRAND_ID"/>
+        <whereClause><![CDATA[M_BRAND_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_PRODUCT_GEN_PROD" unique="false">
         <index-column name="GENERIC_PRODUCT_ID"/>
+        <whereClause><![CDATA[GENERIC_PRODUCT_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_PRODUCT_NAME_ID" unique="false">
         <index-column name="NAME"/>
@@ -487,6 +490,7 @@
       <index name="M_PRODUCT_UPC_ID" unique="false">
         <index-column name="UPC"/>
         <index-column name="M_PRODUCT_ID"/>
+        <whereClause><![CDATA[UPC IS NOT NULL]]></whereClause>
       </index>
       <index name="M_PRODUCT_VALUE_ID" unique="false">
         <index-column name="VALUE"/>
--- a/model/src-db/database/model/tables/M_RAPPEL_BPARTNER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RAPPEL_BPARTNER.xml	Thu May 25 06:12:59 2017 +0000
@@ -75,9 +75,11 @@
       </foreign-key>
       <index name="M_RAPPELBPARTNER_BPARTNER_IDX" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_RAPPELBPARTNER_RAPPEL_IDX" unique="false">
         <index-column name="M_RAPPEL_ID"/>
+        <whereClause><![CDATA[M_RAPPEL_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_RAPPEL_BPARTNER_ISACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_RAPPEL_BPARTNER_ISSOTRX_CHK"><![CDATA[ISSOTRX IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_RAPPEL_INVOICE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RAPPEL_INVOICE.xml	Thu May 25 06:12:59 2017 +0000
@@ -59,6 +59,7 @@
       </foreign-key>
       <index name="M_RAPPELINVOICE_RAPPELBP_IDX" unique="false">
         <index-column name="M_RAPPEL_BPARTNER_ID"/>
+        <whereClause><![CDATA[M_RAPPEL_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_RAPPEL_INVOIC_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/M_RAPPEL_PRODUCT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RAPPEL_PRODUCT.xml	Thu May 25 06:12:59 2017 +0000
@@ -55,6 +55,7 @@
       </foreign-key>
       <index name="M_RAPPELPRODUCT_RAPPEL_IDX" unique="false">
         <index-column name="M_RAPPEL_ID"/>
+        <whereClause><![CDATA[M_RAPPEL_ID IS NOT NULL]]></whereClause>
       </index>
     </table>
   </database>
--- a/model/src-db/database/model/tables/M_RAPPEL_PRODUCTCATEGORY.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RAPPEL_PRODUCTCATEGORY.xml	Thu May 25 06:12:59 2017 +0000
@@ -55,6 +55,7 @@
       </foreign-key>
       <index name="M_RAPPELPRODUCTCTG_RAPPEL_IDX" unique="false">
         <index-column name="M_RAPPEL_ID"/>
+        <whereClause><![CDATA[M_RAPPEL_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_RAPPEL_PRODUCTCATEGORY_I_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/M_RAPPEL_SCALE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RAPPEL_SCALE.xml	Thu May 25 06:12:59 2017 +0000
@@ -60,6 +60,7 @@
       </foreign-key>
       <index name="M_RAPPELSCALE_RAPPEL_IDX" unique="false">
         <index-column name="M_RAPPEL_ID"/>
+        <whereClause><![CDATA[M_RAPPEL_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_RAPPEL_SCALE_DISCOUNT_CHK"><![CDATA[DISCOUNT >= 0 AND DISCOUNT <= 100]]></check>
     </table>
--- a/model/src-db/database/model/tables/M_RESERVATION.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RESERVATION.xml	Thu May 25 06:12:59 2017 +0000
@@ -125,12 +125,14 @@
       </foreign-key>
       <index name="M_RESERVATION_ORDERLINE_IDX" unique="false">
         <index-column name="C_ORDERLINE_ID"/>
+        <whereClause><![CDATA[C_ORDERLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_RESERVATION_PRODUCT_IDX" unique="false">
         <index-column name="M_PRODUCT_ID"/>
       </index>
       <index name="M_RESERVATION_RESSTATUS_IDX" unique="false">
         <index-column name="RES_STATUS"/>
+        <whereClause><![CDATA[RES_STATUS IS NOT NULL]]></whereClause>
       </index>
       <index name="M_RESERVATION_UOM_IDX" unique="false">
         <index-column name="C_UOM_ID"/>
--- a/model/src-db/database/model/tables/M_RESERVATION_STOCK.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_RESERVATION_STOCK.xml	Thu May 25 06:12:59 2017 +0000
@@ -84,12 +84,14 @@
       </index>
       <index name="M_RESERVSTOCK_ATTRSETINS_IDX" unique="false">
         <index-column name="M_ATTRIBUTESETINSTANCE_ID"/>
+        <whereClause><![CDATA[M_ATTRIBUTESETINSTANCE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_RESERVSTOCK_LOCATOR_IDX" unique="false">
         <index-column name="M_LOCATOR_ID"/>
       </index>
       <index name="M_RESERVSTOCK_ORDERLINE_IDX" unique="false">
         <index-column name="C_ORDERLINE_ID"/>
+        <whereClause><![CDATA[C_ORDERLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_RESERVATION_STOCK_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_RESERVATION_STOCK_ALLOC_CHK"><![CDATA[ISALLOCATED IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_STOCK_AUX.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_STOCK_AUX.xml	Thu May 25 06:12:59 2017 +0000
@@ -71,6 +71,7 @@
       </foreign-key>
       <index name="M_STOCK_AUX_AUX_ID" unique="false">
         <index-column name="AUX_ID"/>
+        <whereClause><![CDATA[AUX_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_STOCK_AUX_STORAGE_DETAIL_ID" unique="false">
         <index-column name="M_STORAGE_DETAIL_ID"/>
--- a/model/src-db/database/model/tables/M_STOCK_VALUATION.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_STOCK_VALUATION.xml	Thu May 25 06:12:59 2017 +0000
@@ -73,6 +73,7 @@
       </index>
       <index name="M_STOCK_VALUATION_WH_IDX" unique="false">
         <index-column name="M_WAREHOUSE_ID"/>
+        <whereClause><![CDATA[M_WAREHOUSE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_STOCK_VALUATION_ISACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/M_TRANSACTION.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_TRANSACTION.xml	Thu May 25 06:12:59 2017 +0000
@@ -187,9 +187,11 @@
       </index>
       <index name="M_TRANSACTION_INOUTLINE" unique="false">
         <index-column name="M_INOUTLINE_ID"/>
+        <whereClause><![CDATA[M_INOUTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_TRANSACTION_INVENTORYLINE" unique="false">
         <index-column name="M_INVENTORYLINE_ID"/>
+        <whereClause><![CDATA[M_INVENTORYLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_TRANSACTION_LOCATOR_IDX" unique="false">
         <index-column name="M_LOCATOR_ID"/>
@@ -199,12 +201,14 @@
       </index>
       <index name="M_TRANSACTION_MOVEMENTLINE" unique="false">
         <index-column name="M_MOVEMENTLINE_ID"/>
+        <whereClause><![CDATA[M_MOVEMENTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_TRANSACTION_PROCESSED" unique="false">
         <index-column name="ISPROCESSED"/>
       </index>
       <index name="M_TRANSACTION_PRODUCTIONLINE" unique="false">
         <index-column name="M_PRODUCTIONLINE_ID"/>
+        <whereClause><![CDATA[M_PRODUCTIONLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_TRANSACTION_TRXPROCDATE" unique="false">
         <index-column name="TRXPROCESSDATE"/>
--- a/model/src-db/database/model/tables/M_TRANSACTION_COST.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_TRANSACTION_COST.xml	Thu May 25 06:12:59 2017 +0000
@@ -76,11 +76,15 @@
       <foreign-key foreignTable="C_CURRENCY" name="M_TRANSCOST_CURRENCY">
         <reference local="C_CURRENCY_ID" foreign="C_CURRENCY_ID"/>
       </foreign-key>
+      <index name="M_TRANSACTION_COST_DATEACCT" unique="false">
+        <index-column name="DATEACCT"/>
+      </index>
       <index name="M_TRANSACTION_COST_TRX" unique="false">
         <index-column name="M_TRANSACTION_ID"/>
       </index>
       <index name="M_TRXCOST_COSTADJLINE_IDX" unique="false">
         <index-column name="M_COSTADJUSTMENTLINE_ID"/>
+        <whereClause><![CDATA[M_COSTADJUSTMENTLINE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_TRANSACTION_COST_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="M_TRANSACTION_COST_UNITCOST"><![CDATA[ISUNITCOST IN ('Y', 'N')]]></check>
--- a/model/src-db/database/model/tables/M_VALUED_STOCK_AGG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_VALUED_STOCK_AGG.xml	Thu May 25 06:12:59 2017 +0000
@@ -106,12 +106,13 @@
       <index name="M_VALUED_STOCK_AGG_DATEFROM" unique="false">
         <index-column name="DATEFROM"/>
       </index>
-      <index name="M_VALUED_STOCK_AGG_DATETO" unique="false">
-        <index-column name="DATETO"/>
-      </index>
       <index name="M_VALUED_STOCK_AGG_LOCATOR" unique="false">
         <index-column name="M_LOCATOR_ID"/>
       </index>
+      <index name="M_VALUED_STOCK_AGG_ORG_DATETO" unique="false">
+        <index-column name="AD_ORG_ID"/>
+        <index-column name="DATETO"/>
+      </index>
       <index name="M_VALUED_STOCK_AGG_PERIOD" unique="false">
         <index-column name="C_PERIOD_ID"/>
       </index>
--- a/model/src-db/database/model/tables/M_WAREHOUSE_SHIPPER.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/M_WAREHOUSE_SHIPPER.xml	Thu May 25 06:12:59 2017 +0000
@@ -59,9 +59,11 @@
       </foreign-key>
       <index name="M_WAREHOUSESHIPPER_BP_IDX" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="M_WRHSSHIPPER_WRHS_IDX" unique="false">
         <index-column name="M_WAREHOUSE_ID"/>
+        <whereClause><![CDATA[M_WAREHOUSE_ID IS NOT NULL]]></whereClause>
       </index>
       <check name="M_WAREHOUSE_SHI_ISACTIVE_CHECK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
     </table>
--- a/model/src-db/database/model/tables/S_TIMEEXPENSELINE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/tables/S_TIMEEXPENSELINE.xml	Thu May 25 06:12:59 2017 +0000
@@ -207,6 +207,7 @@
       </foreign-key>
       <index name="S_TIMEEXPENSELINE_BPARTNER_IDX" unique="false">
         <index-column name="C_BPARTNER_ID"/>
+        <whereClause><![CDATA[C_BPARTNER_ID IS NOT NULL]]></whereClause>
       </index>
       <index name="S_TIMEEXPENSELN_TIMEEXPESE_IDX" unique="false">
         <index-column name="S_TIMEEXPENSE_ID"/>
--- a/model/src-db/database/model/triggers/C_INVLINE_CHK_RESTRICTIONS_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_INVLINE_CHK_RESTRICTIONS_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -18,7 +18,7 @@
     * under the License.
     * The Original Code is Openbravo ERP.
     * The Initial Developer of the Original Code is Openbravo SLU
-    * All portions are Copyright (C) 2001-2016 Openbravo SLU
+    * All portions are Copyright (C) 2001-2017 Openbravo SLU
     * All Rights Reserved.
     * Contributor(s):  ______________________________________.
     ************************************************************************/
@@ -107,8 +107,6 @@
     INTO v_Prec
     FROM C_CURRENCY
     WHERE C_CURRENCY_ID=v_Currency;
-    :NEW.LineNetAmt:=ROUND(:NEW.LineNetAmt, v_Prec) ;
-    :NEW.ChargeAmt:=ROUND(:NEW.ChargeAmt, v_Prec) ;
 
     IF (:NEW.ISEDITLINENETAMT='Y' AND ROUND(TO_NUMBER(:NEW.QTYINVOICED) * TO_NUMBER(:NEW.PRICEACTUAL),v_Prec)!=TO_NUMBER(:NEW.LINENETAMT)) THEN
       RAISE_APPLICATION_ERROR(-20000, '@LineAmountNotCorrect@') ;
--- a/model/src-db/database/model/triggers/C_INVOICELINETAX_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_INVOICELINETAX_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -17,7 +17,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2010-2016 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2010-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -27,14 +27,17 @@
 v_LineNo  NUMBER;
 v_C_Invoice_ID C_INVOICELINETAX.C_INVOICE_ID%TYPE;
 v_C_Tax_ID C_INVOICELINETAX.C_TAX_ID%TYPE;
-v_c_invoicetax_id C_INVOICETAX.C_INVOICETAX_ID%TYPE;
+v_C_InvoiceTax_ID C_INVOICETAX.C_INVOICETAX_ID%TYPE;
 v_Prec C_CURRENCY.STDPRECISION%TYPE;
 v_DocTaxAmount C_TAX.DOCTAXAMOUNT%TYPE;
 v_Rate  C_TAX.RATE%TYPE;
+v_Cascade C_TAX.CASCADE%TYPE;
+v_BaseAmount C_TAX.BASEAMOUNT%TYPE;
+v_TaxBase_ID C_TAX.C_TAXBASE_ID%TYPE;
+v_Line C_TAX.LINE%TYPE;
 v_Processed   VARCHAR(60);
-v_Increment_Amount C_ORDERTAX.TAXAMT%TYPE ;
-v_Increment_Base C_ORDERTAX.TAXBASEAMT%TYPE ;
-v_istaxincluded CHAR(1);
+v_Increment_Amount C_INVOICETAX.TAXAMT%TYPE;
+v_Increment_Base C_INVOICETAX.TAXBASEAMT%TYPE;
     
 BEGIN
     
@@ -49,17 +52,18 @@
       v_C_Invoice_ID:=:OLD.C_INVOICE_ID;
     END IF;
 
-    SELECT C_CURRENCY.STDPRECISION, PROCESSED,  M_PRICELIST.istaxincluded
-    INTO v_Prec, v_Processed, v_istaxincluded
-    FROM C_INVOICE, C_CURRENCY, M_PRICELIST
+    SELECT C_CURRENCY.STDPRECISION, PROCESSED
+    INTO v_Prec, v_Processed
+    FROM C_INVOICE, C_CURRENCY
     WHERE C_INVOICE.C_CURRENCY_ID = C_CURRENCY.C_CURRENCY_ID
-    AND C_INVOICE.M_PRICELIST_ID = M_PRICELIST.M_PRICELIST_ID
+
     AND C_INVOICE_ID = v_C_Invoice_ID;
     
-    SELECT DOCTAXAMOUNT, RATE
-    INTO v_DocTaxAmount, v_Rate
+    SELECT DocTaxAmount, Rate, Cascade, BaseAmount, C_TaxBase_ID, Line
+    INTO v_DocTaxAmount, v_Rate, v_Cascade, v_BaseAmount, v_TaxBase_ID, v_Line
     FROM C_TAX
     WHERE C_TAX_ID = v_C_Tax_ID;
+
   IF ( INSERTING ) THEN
     v_Increment_Amount := :NEW.TAXAMT ;
     v_Increment_Base := :NEW.TAXBASEAMT ;
@@ -72,15 +76,37 @@
   END IF;
 
   IF (INSERTING OR UPDATING) THEN
-    SELECT COUNT(C_TAX_ID), MAX(c_invoicetax_id) INTO v_Count, v_c_invoicetax_id
+    SELECT COUNT(C_TAX_ID), MAX(c_invoicetax_id) INTO v_Count, v_C_InvoiceTax_ID
     FROM C_INVOICETAX
-    WHERE C_INVOICE_ID = :NEW.C_Invoice_ID
-    AND C_TAX_ID = :NEW.C_TAX_ID
+    WHERE C_Invoice_ID = :new.C_Invoice_ID
+    AND C_Tax_ID = :new.C_Tax_ID
     AND Recalculate = 'Y';
     IF(v_Count>0) THEN
-      UPDATE C_INVOICETAX SET TAXAMT = (CASE WHEN v_DocTaxAmount='D' THEN ROUND((TAXBASEAMT + v_Increment_Base) * v_Rate/100, v_Prec) ELSE (TAXAMT + v_Increment_Amount) END), 
-      TAXBASEAMT=TAXBASEAMT + v_Increment_Base
-      WHERE C_INVOICETAX_ID = v_c_invoicetax_id;
+      IF (v_DocTaxAmount = 'D' AND (v_Cascade = 'Y' OR v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX'))) THEN
+        SELECT COALESCE(CASE WHEN MAX(it.TaxBaseAmt) > 0 THEN MAX(ROUND(it.TaxBaseAmt, v_Prec)) + MAX(it.TaxAmt) ELSE MIN(ROUND(it.TaxBaseAmt, v_Prec)) + MIN(it.TaxAmt) END, 0)
+        INTO v_Increment_Base
+        FROM C_InvoiceTax it
+        JOIN C_Tax t
+        ON it.C_Tax_ID = t.C_Tax_ID
+        WHERE it.C_Invoice_ID = :new.C_Invoice_ID
+        AND c_tax_get_root(it.C_Tax_ID) = c_tax_get_root(:new.C_Tax_ID)
+        AND it.Recalculate = 'Y'
+        AND ((v_Cascade = 'Y'
+        AND t.Line < v_Line)
+        OR (v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+        AND C_TAX_ISMEMBER(v_TaxBase_ID, t.C_Tax_ID) = 1
+        AND t.IsSummary = 'N'));
+
+        UPDATE C_INVOICETAX
+        SET TAXAMT = ROUND((v_Increment_Base) * v_Rate/100, v_Prec),
+        TAXBASEAMT = v_Increment_Base
+        WHERE C_InvoiceTax_ID = v_C_InvoiceTax_ID;
+      ELSE
+        UPDATE C_INVOICETAX
+        SET TAXAMT = CASE WHEN v_DocTaxAmount='D' THEN ROUND(ROUND(TAXBASEAMT + v_Increment_Base, v_Prec) * v_Rate/100, v_Prec) ELSE (TAXAMT + v_Increment_Amount) END,
+        TAXBASEAMT = TAXBASEAMT + v_Increment_Base
+        WHERE C_InvoiceTax_ID = v_C_InvoiceTax_ID;
+      END IF;
     ELSE
       SELECT COALESCE(MAX(LINE),0) + 10
       INTO v_LineNo
@@ -100,15 +126,41 @@
   IF (v_Processed='Y') THEN 
     RAISE_APPLICATION_ERROR(-20000, '@20501@') ;
   ELSE
-    UPDATE C_INVOICETAX SET TAXAMT = (CASE WHEN v_DocTaxAmount='D' THEN ROUND((TAXBASEAMT - :OLD.TAXBASEAMT) * v_Rate/100, v_Prec) ELSE (TAXAMT - :OLD.TAXAMT) END), TAXBASEAMT=TAXBASEAMT - :OLD.TAXBASEAMT
-    WHERE C_INVOICE_ID = :OLD.C_Invoice_ID
-    AND C_TAX_ID = :OLD.C_TAX_ID
-    AND Recalculate = 'Y';
-    
+    IF (v_DocTaxAmount = 'D' AND (v_Cascade = 'Y' OR v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX'))) THEN
+      SELECT COALESCE(CASE WHEN MAX(it.TaxBaseAmt) > 0 THEN MAX(ROUND(it.TaxBaseAmt, v_Prec)) + MAX(it.TaxAmt) ELSE MIN(ROUND(it.TaxBaseAmt, v_Prec)) + MIN(it.TaxAmt) END, 0)
+      INTO v_Increment_Base
+      FROM C_InvoiceTax it
+      JOIN C_Tax t
+      ON it.C_Tax_ID = t.C_Tax_ID
+      WHERE it.C_Invoice_ID = :old.C_Invoice_ID
+      AND c_tax_get_root(it.C_Tax_ID) = c_tax_get_root(:old.C_Tax_ID)
+      AND it.Recalculate = 'Y'
+      AND ((v_Cascade = 'Y'
+      AND t.Line < v_Line)
+      OR (v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+      AND C_TAX_ISMEMBER(v_TaxBase_ID, t.C_Tax_ID) = 1
+      AND t.IsSummary = 'N'));
+
+      UPDATE C_INVOICETAX
+      SET TAXAMT = ROUND(v_Increment_Base * v_Rate/100, v_Prec),
+      TAXBASEAMT = v_Increment_Base
+      WHERE C_Invoice_ID = :old.C_Invoice_ID
+      AND C_Tax_ID = :old.C_Tax_ID
+      AND Recalculate = 'Y';
+    ELSE
+      UPDATE C_INVOICETAX
+      SET TAXAMT = CASE WHEN v_DocTaxAmount = 'D' THEN ROUND(ROUND(TAXBASEAMT - :OLD.TAXBASEAMT, v_Prec) * v_Rate/100, v_Prec) ELSE (TAXAMT - :OLD.TAXAMT) END,
+      TAXBASEAMT = TAXBASEAMT - :OLD.TAXBASEAMT
+      WHERE C_Invoice_ID = :old.C_Invoice_ID
+      AND C_Tax_ID = :old.C_Tax_ID
+      AND Recalculate = 'Y';
+    END IF;
+
     DELETE FROM C_INVOICETAX 
     WHERE C_INVOICE_ID = :OLD.C_Invoice_ID
     AND C_TAX_ID = :OLD.C_TAX_ID
-    AND TAXAMT=0 AND TAXBASEAMT=0;
+    AND ROUND(TAXBASEAMT, v_Prec) = 0
+    AND TAXAMT = 0;
     
   END IF;
 END IF;
--- a/model/src-db/database/model/triggers/C_INVOICELINE_BEFORE_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_INVOICELINE_BEFORE_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -14,7 +14,7 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2015-2016 Openbravo SLU
+* All portions are Copyright (C) 2015-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
@@ -63,11 +63,12 @@
     JOIN m_pricelist ON i.m_pricelist_id = m_pricelist.m_pricelist_id
   WHERE i.c_invoice_id = v_invoice_id;
 
-  IF (v_istaxincluded = 'Y') THEN
+  IF (v_istaxincluded = 'Y' AND :new.c_tax_id IS NOT NULL) THEN
     IF (INSERTING) THEN
           v_execute:='Y';
     ELSIF(UPDATING) THEN
         IF(:old.LineNetAmt <> :new.LineNetAmt
+          OR :old.Line_Gross_Amount <> :new.Line_Gross_Amount
           OR :old.gross_unit_price <> :new.gross_unit_price
           OR :old.c_tax_id <> :new.c_tax_id
           OR :old.qtyinvoiced <> :new.qtyinvoiced) THEN
@@ -113,17 +114,18 @@
           ELSE -- The last willaccummulate rounding
             v_Line := v_BaseLine - v_LineAcum;
           END IF;
-
-          v_PriceLine := C_GET_NET_PRICE_FROM_GROSS(Cur_BOM.TAX, v_Line, v_Line, v_price_prec, :new.qtyinvoiced);
-          v_CalcLine := ROUND(:new.qtyinvoiced * v_PriceLine, v_std_Prec); -- In price including taxes the net and net alternate are equals.
-
+          v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_Line, v_std_Prec);
           v_NetActual := v_NetActual + v_CalcLine; -- Acum the net
         END LOOP;    
         v_PriceActual := v_NetActual / :new.qtyinvoiced;     
       ELSE
         -- Regular taxes
-        v_PriceActual := C_GET_NET_PRICE_FROM_GROSS(:new.c_tax_id, :new.gross_unit_price * :new.qtyinvoiced, :new.taxbaseamt, v_price_prec, :new.qtyinvoiced);
-        v_NetActual := ROUND(:new.Qtyinvoiced * v_PriceActual, v_std_Prec);
+        v_NetActual := C_GET_NET_AMOUNT_FROM_GROSS(:new.c_tax_id, :new.line_gross_amount, :new.taxbaseamt, v_std_Prec);
+        IF (:new.qtyinvoiced <> 0) THEN
+          v_PriceActual := ROUND(v_NetActual / :new.qtyinvoiced, v_price_prec);
+        ELSE
+          v_PriceActual := 0;
+        END IF;
       END IF;      
       
       :NEW.pricestd := v_priceactual;
@@ -132,6 +134,7 @@
       :NEW.priceactual := v_priceactual;
       :new.taxbaseamt := v_NetActual;
       :new.LineNetAmt := v_NetActual;
+
     END IF;
   END IF;
 
--- a/model/src-db/database/model/triggers/C_INVOICELINE_TRG2.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_INVOICELINE_TRG2.xml	Thu May 25 06:12:59 2017 +0000
@@ -14,22 +14,24 @@
 * under the License.
 * The Original Code is Openbravo ERP.
 * The Initial Developer of the Original Code is Openbravo SLU
-* All portions are Copyright (C) 2001-2015 Openbravo SLU
+* All portions are Copyright (C) 2001-2017 Openbravo SLU
 * All Rights Reserved.
 * Contributor(s):  ______________________________________.
 ************************************************************************/
 
 
 
-
   v_Processed C_ORDER.PROCESSED%TYPE;
-  v_ID VARCHAR2(32);
+  v_ID C_INVOICELINE.C_INVOICE_ID%TYPE;
   v_oldLine NUMBER;
   v_newLineNetAmt NUMBER;
   v_newLineAlternate NUMBER;
-  v_taxAmt NUMBER;
+  v_taxBaseAmt C_INVOICETAX.TAXBASEAMT%TYPE;
+  v_taxAmt C_INVOICETAX.TAXAMT%TYPE;
   v_Prec C_CURRENCY.STDPRECISION%TYPE;
   v_PricePrec C_CURRENCY.PRICEPRECISION%TYPE;
+  v_DocTaxAmount C_TAX.DocTaxAmount%TYPE;
+
   v_istaxincluded CHAR(1) ;
   v_oldGrossAmt NUMBER:=0;
   v_newGrossAmt NUMBER:=0;
@@ -55,7 +57,6 @@
   
   v_PriceLine NUMBER;
   v_CalcLine NUMBER;
-  v_maxline NUMBER;    
           
   TYPE RECORD IS REF CURSOR;
   Cur_BOM RECORD;          
@@ -68,9 +69,9 @@
 -- This trigger is used for calculate the applied offers f0r the invoice
 
 IF (DELETING) THEN
-  v_ID:=:OLD.C_INVOICE_ID;
+  v_ID := :OLD.C_INVOICE_ID;
 ELSE
-  v_ID:=:NEW.C_INVOICE_ID;
+  v_ID := :NEW.C_INVOICE_ID;
 END IF;
  IF INSERTING OR UPDATING THEN
    IF (:new.c_orderline_id IS NULL) THEN
@@ -101,6 +102,8 @@
         v_newgrossamt := :new.line_gross_amount;
      ELSIF (INSERTING) THEN
         v_newgrossamt := :new.line_gross_amount;
+     ELSIF (DELETING) THEN
+        v_oldgrossamt := :old.line_gross_amount;
      END IF;
    END IF;  
   IF(UPDATING OR DELETING) THEN
@@ -168,9 +171,12 @@
           v_LineAlternate := v_BaseLineAlternate - v_LineAlternateAcum;
         END IF;
         IF (v_istaxincluded = 'Y') THEN
-          v_PriceLine := C_GET_NET_PRICE_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate, v_PricePrec, :new.qtyinvoiced);
-          v_CalcLine := ROUND(:new.qtyinvoiced * v_PriceLine, v_Prec); -- In price including taxes the net and net alternate are equals.
-          select coalesce(max(line), 0) into v_maxline from c_invoicelinetax where c_invoiceline_id = :new.C_InvoiceLine_ID;
+          SELECT COALESCE(MIN(DocTaxAmount), 'L') INTO v_DocTaxAmount FROM C_Tax WHERE (C_Tax_ID = Cur_BOM.TAX OR Parent_Tax_ID = Cur_BOM.TAX) AND IsSummary = 'N';
+          IF (v_DocTaxAmount = 'D') THEN
+            v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate);
+          ELSE
+            v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate, v_Prec);
+          END IF;
           C_INVOICELINETAX_INSERT(:new.AD_Org_ID, :new.C_Invoice_ID, :new.C_InvoiceLine_ID, :new.UpdatedBy, Cur_BOM.TAX, Cur_BOM.TAX, v_CalcLine, v_CalcLine, v_Prec);
         ELSE
           C_INVOICELINETAX_INSERT(:new.AD_Org_ID, :new.C_Invoice_ID, :new.C_InvoiceLine_ID, :new.UpdatedBy, Cur_BOM.TAX, Cur_BOM.TAX, v_Line, v_LineAlternate, v_Prec);
@@ -178,57 +184,63 @@
       END LOOP;       
     ELSE
       -- Regular taxes
-      C_INVOICELINETAX_INSERT(:new.AD_Org_ID, :new.C_Invoice_ID, :new.C_InvoiceLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineAlternate, v_Prec);    
-    END IF;  
-
+      SELECT COALESCE(MIN(DocTaxAmount), 'L') INTO v_DocTaxAmount FROM C_Tax WHERE (C_Tax_ID = :new.C_Tax_ID OR Parent_Tax_ID = :new.C_Tax_ID) AND IsSummary = 'N';
+      IF (v_istaxincluded = 'Y' AND v_DocTaxAmount = 'D') THEN
+        v_newLineNetAmt := C_GET_NET_AMOUNT_FROM_GROSS(:new.c_tax_id, :new.line_gross_amount, :new.taxbaseamt);
+        C_INVOICELINETAX_INSERT(:new.AD_Org_ID, :new.C_Invoice_ID, :new.C_InvoiceLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineNetAmt, v_Prec);
+      ELSE
+        C_INVOICELINETAX_INSERT(:new.AD_Org_ID, :new.C_Invoice_ID, :new.C_InvoiceLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineAlternate, v_Prec);
+      END IF;
+    END IF;
     IF (v_istaxincluded = 'Y') THEN
-      C_INVOICELINETAX_ROUNDING(:new.C_InvoiceLine_ID, :new.line_gross_amount, v_newLineNetAmt);
-    END IF;  
+      C_INVOICELINETAX_ROUNDING(:new.C_InvoiceLine_ID, :new.line_gross_amount, ROUND(v_newLineNetAmt, v_Prec));
+    END IF;
               
    END IF;
-  -- Get Total Tax Amt
-   SELECT SUM(TaxAmt)
-     INTO v_taxAmt
-   FROM C_InvoiceTax
-   WHERE C_Invoice_ID=:new.C_Invoice_ID;
+   -- Get Total Tax Base Amt and Tax Amt
+   SELECT COALESCE(SUM(it.TaxBaseAmt), 0)
+   INTO v_taxBaseAmt
+   FROM (
+     SELECT CASE WHEN MIN(it.TaxBaseAmt) > 0 THEN MIN(ROUND(it.TaxBaseAmt, v_Prec)) ELSE MAX(ROUND(it.TaxBaseAmt, v_Prec)) END as TaxBaseAmt
+     FROM C_InvoiceTax it
+     WHERE it.C_Invoice_ID = :new.C_Invoice_ID
+     AND it.Recalculate = 'Y'
+     GROUP BY c_tax_get_root(it.c_tax_id)
+   ) it;
+   SELECT COALESCE(SUM(it.TaxAmt), 0)
+   INTO v_taxAmt
+   FROM C_InvoiceTax it
+   WHERE it.C_Invoice_ID = :new.C_Invoice_ID;
   -- DBMS_OUTPUT.PUT_LINE('TaxAmt = ' || v_taxAmt);
    -- Update Header
-       -- Get Total Tax Amt
    UPDATE C_Invoice
-     SET TotalLines = TotalLines - v_oldLine + v_newLineNetAmt,
-     GrandTotal = CASE v_istaxincluded
-                     WHEN 'Y' THEN grandtotal - v_oldgrossamt + v_newgrossamt
-                     ELSE TotalLines - v_oldLine + v_newLineNetAmt + COALESCE(v_taxAmt, 0)
-                  END
-   --  Updated = SysDate -- Don't update as otherwise it does not save changes
+   SET TotalLines = CASE WHEN v_istaxincluded = 'Y' THEN CASE WHEN v_taxAmt = 0 THEN grandtotal - v_oldgrossamt + v_newgrossamt ELSE v_taxBaseAmt END ELSE TotalLines - v_oldLine + v_newLineNetAmt END,
+   GrandTotal = CASE WHEN v_istaxincluded = 'Y' THEN grandtotal - v_oldgrossamt + v_newgrossamt ELSE TotalLines - v_oldLine + v_newLineNetAmt + v_taxAmt END
    WHERE C_Invoice_ID = :new.C_Invoice_ID;
    END IF;
   ELSE -- DELETING
-   IF (v_istaxincluded = 'Y') THEN
-     v_oldgrossamt := :old.line_gross_amount;
-   END IF;
-   SELECT SUM(TaxAmt)
-     INTO v_taxAmt
-   FROM C_InvoiceTax
-   WHERE C_Invoice_ID=:old.C_Invoice_ID;
+   -- Get Total Tax Base Amt and Tax Amt
+   SELECT COALESCE(SUM(it.TaxBaseAmt), 0)
+   INTO v_taxBaseAmt
+   FROM (
+     SELECT CASE WHEN MIN(it.TaxBaseAmt) > 0 THEN MIN(ROUND(it.TaxBaseAmt, v_Prec)) ELSE MAX(ROUND(it.TaxBaseAmt, v_Prec)) END as TaxBaseAmt
+     FROM C_InvoiceTax it
+     WHERE it.C_Invoice_ID = :old.C_Invoice_ID
+     AND it.Recalculate = 'Y'
+     GROUP BY c_tax_get_root(it.c_tax_id)
+   ) it;
+   SELECT COALESCE(SUM(it.TaxAmt), 0)
+   INTO v_taxAmt
+   FROM C_InvoiceTax it
+   WHERE it.C_Invoice_ID = :old.C_Invoice_ID;
   -- DBMS_OUTPUT.PUT_LINE('TaxAmt = ' || v_taxAmt);
    -- Update Header
    UPDATE C_Invoice
-     SET TotalLines = TotalLines - v_oldLine + v_newLineNetAmt,
-     GrandTotal = CASE v_istaxincluded
-                       WHEN 'Y' THEN grandtotal - v_oldgrossamt
-                       ELSE TotalLines - v_oldLine + v_newLineNetAmt + COALESCE(v_taxAmt, 0)
-                  END
-   --  Updated = SysDate -- Don't update as otherwise it does not save changes
+   SET TotalLines = CASE WHEN v_istaxincluded = 'Y' THEN CASE WHEN v_taxAmt = 0 THEN grandtotal - v_oldgrossamt ELSE v_taxBaseAmt END ELSE TotalLines - v_oldLine + v_newLineNetAmt END,
+   GrandTotal = CASE WHEN v_istaxincluded = 'Y' THEN grandtotal - v_oldgrossamt ELSE TotalLines - v_oldLine + v_newLineNetAmt + v_taxAmt END
    WHERE C_Invoice_ID=:old.C_Invoice_ID;
   END IF;
-  IF (v_istaxincluded = 'Y') THEN
-    SELECT totallines, grandtotal INTO v_totallines, v_grandtotal
-    FROM C_invoice
-    WHERE c_invoice_id = v_id;
-    C_INVOICETAX_ROUNDING(v_id, v_grandtotal, v_totallines);
-  END IF;
-   
+
  END IF;
 
 
--- a/model/src-db/database/model/triggers/C_ORDERLINETAX_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_ORDERLINETAX_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -17,7 +17,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2010-2014 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2010-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -27,11 +27,16 @@
 v_LineNo  NUMBER;
 v_C_Order_ID C_ORDERLINETAX.C_ORDER_ID%TYPE;
 v_C_Tax_ID C_ORDERLINETAX.C_TAX_ID%TYPE;
+v_C_OrderTax_ID C_ORDERTAX.C_ORDERTAX_ID%TYPE;
 v_Prec C_CURRENCY.STDPRECISION%TYPE;
 v_DocTaxAmount C_TAX.DOCTAXAMOUNT%TYPE;
 v_Rate  C_TAX.RATE%TYPE;
-v_Increment_Amount C_ORDERTAX.TAXAMT%TYPE ;
-v_Increment_Base C_ORDERTAX.TAXBASEAMT%TYPE ;
+v_Cascade C_TAX.CASCADE%TYPE;
+v_BaseAmount C_TAX.BASEAMOUNT%TYPE;
+v_TaxBase_ID C_TAX.C_TAXBASE_ID%TYPE;
+v_Line C_TAX.LINE%TYPE;
+v_Increment_Amount C_ORDERTAX.TAXAMT%TYPE;
+v_Increment_Base C_ORDERTAX.TAXBASEAMT%TYPE;
 v_Processed VARCHAR(60) ;
 v_DocAction VARCHAR(60);
 BEGIN
@@ -53,8 +58,8 @@
     WHERE C_ORDER.C_CURRENCY_ID = C_CURRENCY.C_CURRENCY_ID
     AND C_ORDER_ID = v_C_Order_ID;
     
-    SELECT DOCTAXAMOUNT, RATE
-    INTO v_DocTaxAmount, v_Rate
+    SELECT DocTaxAmount, Rate, Cascade, BaseAmount, C_TaxBase_ID, Line
+    INTO v_DocTaxAmount, v_Rate, v_Cascade, v_BaseAmount, v_TaxBase_ID, v_Line
     FROM C_TAX
     WHERE C_TAX_ID = v_C_Tax_ID;
 
@@ -70,17 +75,35 @@
   END IF;
     
   IF (INSERTING OR UPDATING) THEN
-    SELECT COUNT(1) INTO v_Count
+    SELECT COUNT(C_TAX_ID), MAX(c_ordertax_id) INTO v_Count, v_C_OrderTax_ID
     FROM C_ORDERTAX
-    WHERE C_ORDER_ID = :NEW.C_Order_ID
-    AND C_TAX_ID = :NEW.C_TAX_ID;
+    WHERE C_Order_ID = :new.C_Order_ID
+    AND C_Tax_ID = :new.C_Tax_ID;
     IF(v_Count>0) THEN
-      UPDATE C_ORDERTAX
-      SET TAXAMT = (CASE WHEN v_DocTaxAmount='D' THEN ROUND((TAXBASEAMT + v_Increment_Base) * v_Rate/100, v_Prec) ELSE (TAXAMT + v_Increment_Amount) END),
-          TAXBASEAMT=TAXBASEAMT + v_Increment_Base
-      WHERE C_ORDER_ID = :NEW.C_Order_ID
-        AND C_TAX_ID = :NEW.C_TAX_ID;
+      IF (v_DocTaxAmount = 'D' AND (v_Cascade = 'Y' OR v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX'))) THEN
+        SELECT COALESCE(CASE WHEN MAX(ot.TaxBaseAmt) > 0 THEN MAX(ROUND(ot.TaxBaseAmt, v_Prec)) + MAX(ot.TaxAmt) ELSE MIN(ROUND(ot.TaxBaseAmt, v_Prec)) + MIN(ot.TaxAmt) END, 0)
+        INTO v_Increment_Base
+        FROM C_OrderTax ot
+        JOIN C_Tax t
+        ON ot.C_Tax_ID = t.C_Tax_ID
+        WHERE ot.C_Order_ID = :new.C_Order_ID
+        AND c_tax_get_root(ot.C_Tax_ID) = c_tax_get_root(:new.C_Tax_ID)
+        AND ((v_Cascade = 'Y'
+        AND t.Line < v_Line)
+        OR (v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+        AND C_TAX_ISMEMBER(v_TaxBase_ID, t.C_Tax_ID) = 1
+        AND t.IsSummary = 'N'));
 
+        UPDATE C_ORDERTAX
+        SET TAXAMT = ROUND(v_Increment_Base * v_Rate/100, v_Prec),
+        TAXBASEAMT = v_Increment_Base
+        WHERE C_OrderTax_ID = v_C_OrderTax_ID;
+      ELSE
+        UPDATE C_ORDERTAX
+        SET TAXAMT = CASE WHEN v_DocTaxAmount='D' THEN ROUND(ROUND(TAXBASEAMT + v_Increment_Base, v_Prec) * v_Rate/100, v_Prec) ELSE (TAXAMT + v_Increment_Amount) END,
+        TAXBASEAMT = TAXBASEAMT + v_Increment_Base
+        WHERE C_OrderTax_ID = v_C_OrderTax_ID;
+      END IF;
     ELSE
       SELECT COALESCE(MAX(LINE),0) + 10
       INTO v_LineNo
@@ -106,14 +129,37 @@
     IF (v_Processed='Y' AND v_DocAction <> 'CL') THEN
 	RAISE_APPLICATION_ERROR(-20000, '@20501@') ;
     END IF;
-    UPDATE C_ORDERTAX SET TAXAMT = (CASE WHEN v_DocTaxAmount='D' THEN ROUND((TAXBASEAMT - :OLD.TAXBASEAMT) * v_Rate/100, v_Prec) ELSE (TAXAMT - :OLD.TAXAMT) END), TAXBASEAMT=TAXBASEAMT - :OLD.TAXBASEAMT
-    WHERE C_ORDER_ID = :OLD.C_Order_ID
-    AND C_TAX_ID = :OLD.C_TAX_ID;
-    
+    IF (v_DocTaxAmount = 'D' AND (v_Cascade = 'Y' OR v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX'))) THEN
+      SELECT COALESCE(CASE WHEN MAX(ot.TaxBaseAmt) > 0 THEN MAX(ROUND(ot.TaxBaseAmt, v_Prec)) + MAX(ot.TaxAmt) ELSE MIN(ROUND(ot.TaxBaseAmt, v_Prec)) + MIN(ot.TaxAmt) END, 0)
+      INTO v_Increment_Base
+      FROM C_OrderTax ot
+      JOIN C_Tax t
+      ON ot.C_Tax_ID = t.C_Tax_ID
+      WHERE ot.C_Order_ID = :old.C_Order_ID
+      AND c_tax_get_root(ot.C_Tax_ID) = c_tax_get_root(:old.C_Tax_ID)
+      AND ((v_Cascade = 'Y'
+      AND t.Line < v_Line)
+      OR (v_BaseAmount IN ('TAX', 'LNATAX', 'TBATAX')
+      AND C_TAX_ISMEMBER(v_TaxBase_ID, t.C_Tax_ID) = 1
+      AND t.IsSummary = 'N'));
+
+      UPDATE C_ORDERTAX
+      SET TAXAMT = ROUND(v_Increment_Base * v_Rate/100, v_Prec),
+      TAXBASEAMT = v_Increment_Base
+      WHERE C_Order_ID = :old.C_Order_ID
+      AND C_Tax_ID = :old.C_Tax_ID;
+    ELSE
+      UPDATE C_ORDERTAX
+      SET TAXAMT = CASE WHEN v_DocTaxAmount = 'D' THEN ROUND(ROUND(TAXBASEAMT - :OLD.TAXBASEAMT, v_Prec) * v_Rate/100, v_Prec) ELSE (TAXAMT - :OLD.TAXAMT) END,
+      TAXBASEAMT = TAXBASEAMT - :OLD.TAXBASEAMT
+      WHERE C_Order_ID = :OLD.C_Order_ID
+      AND C_Tax_ID = :OLD.C_Tax_ID;
+    END IF;
     DELETE FROM C_ORDERTAX 
     WHERE C_ORDER_ID = :OLD.C_Order_ID
     AND C_TAX_ID = :OLD.C_TAX_ID
-    AND TAXAMT=0 AND TAXBASEAMT=0;
+    AND ROUND(TAXBASEAMT, v_Prec) = 0
+    AND TAXAMT = 0;
   END IF;
 END C_ORDERLINETAX_TRG
 ]]></body>
--- a/model/src-db/database/model/triggers/C_ORDERLINE_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_ORDERLINE_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -17,7 +17,7 @@
   * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
   * All Rights Reserved.
   * Contributor(s): Openbravo SLU
-  * Contributions are Copyright (C) 2001-2016 Openbravo, S.L.U.
+  * Contributions are Copyright (C) 2001-2017 Openbravo, S.L.U.
   *
   * Specifically, this derivative work is based upon the following Compiere
   * file and version.
@@ -47,7 +47,7 @@
   v_NetActual NUMBER;
   v_PriceLine NUMBER;
   v_CalcLine NUMBER;
-          
+
   TYPE RECORD IS REF CURSOR;
   Cur_BOM RECORD;
 
@@ -183,11 +183,10 @@
   */
  IF (INSERTING OR UPDATING) THEN
   IF (v_istaxincluded = 'Y') THEN
+
     -- If tax included taxes recalculate net price
     :new.line_gross_amount := ROUND(:new.gross_unit_price * :new.qtyordered, v_prec);
-    
-    
-    
+
     SELECT tc.ASBOM INTO v_AsBOM FROM C_TAXCATEGORY tc, C_tax t WHERE tc.C_TAXCATEGORY_ID = t.C_TAXCATEGORY_ID AND t.C_TAX_ID = :new.C_Tax_ID;
     IF (v_AsBOM = 'Y') THEN
       -- BOM taxes
@@ -223,16 +222,18 @@
         ELSE -- The last willaccummulate rounding
           v_Line := v_BaseLine - v_LineAcum;
         END IF;
-
-        v_PriceLine := C_GET_NET_PRICE_FROM_GROSS(Cur_BOM.TAX, v_Line, v_Line, v_price_prec, :new.qtyordered);     
-        v_CalcLine := ROUND(:new.qtyordered * v_PriceLine, v_Prec); -- In price including taxes the net and net alternate are equals.
+        v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_Line, v_Prec);
         v_NetActual := v_NetActual + v_CalcLine; -- Acum the net
       END LOOP;    
       v_PriceActual := ROUND(v_NetActual / :new.qtyordered, v_price_prec);     
     ELSE
       -- Regular taxes
-      v_PriceActual := C_GET_NET_PRICE_FROM_GROSS(:new.c_tax_id, :new.gross_unit_price * :new.qtyordered, :new.taxbaseamt, v_price_prec, :new.qtyordered);
-      v_NetActual := ROUND(:new.QtyOrdered * v_PriceActual, v_Prec);
+      v_NetActual := C_GET_NET_AMOUNT_FROM_GROSS(:new.c_tax_id, :new.line_gross_amount, :new.taxbaseamt, v_Prec);
+      IF (:new.qtyordered <> 0) THEN
+        v_PriceActual := ROUND(v_NetActual / :new.qtyordered, v_price_prec);
+      ELSE
+        v_PriceActual := 0;
+      END IF;
     END IF;      
     
     :NEW.pricestd := v_priceactual;
@@ -241,6 +242,7 @@
     :NEW.priceactual := v_priceactual;
     :new.taxbaseamt := v_NetActual;
     :new.LineNetAmt := v_NetActual;
+
   ELSE
     -- Price including taxes = 'N'
     -- Modified by I.Ciordia. Sometimes js fails calculting lineNet
--- a/model/src-db/database/model/triggers/C_ORDERLINE_TRG2.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/C_ORDERLINE_TRG2.xml	Thu May 25 06:12:59 2017 +0000
@@ -19,25 +19,25 @@
     * under the License.
     * The Original Code is Openbravo ERP.
     * The Initial Developer of the Original Code is Openbravo SLU
-    * All portions are Copyright (C) 2001-2015 Openbravo SLU
+    * All portions are Copyright (C) 2001-2017 Openbravo SLU
     * All Rights Reserved.
     * Contributor(s):  ______________________________________.
     ************************************************************************/
 
   v_istaxincluded CHAR(1) ;
   v_Processed C_ORDER.PROCESSED%TYPE;
-  v_ID VARCHAR2(32);
+  v_ID C_ORDERLINE.C_ORDER_ID%TYPE;
   v_oldLine NUMBER;
   v_newLineNetAmt NUMBER;
   v_newLineAlternate NUMBER;
   v_oldGrossAmt NUMBER:=0;
   v_newGrossAmt NUMBER:=0;
-  v_totallines NUMBER:=0;
-  v_grandtotal NUMBER:=0;
-  v_taxAmt NUMBER;
+  v_taxBaseAmt C_ORDERTAX.TAXBASEAMT%TYPE;
+  v_taxAmt C_ORDERTAX.TAXAMT%TYPE;
   v_Prec C_CURRENCY.STDPRECISION%TYPE;
   v_PricePrec C_CURRENCY.PRICEPRECISION%TYPE;
   v_AttrSetValueType M_Product.AttrSetValueType%TYPE;
+  v_DocTaxAmount C_TAX.DocTaxAmount%TYPE;
 
   v_oldLineAlternate NUMBER;
   v_create CHAR(1):='Y';
@@ -59,7 +59,6 @@
   
   v_PriceLine NUMBER;
   v_CalcLine NUMBER;
-  v_maxline NUMBER;
           
   TYPE RECORD IS REF CURSOR;
   Cur_BOM RECORD;        
@@ -69,9 +68,9 @@
     END IF;
 
 IF (DELETING) THEN
-  v_ID:=:OLD.C_ORDER_ID;
+  v_ID := :OLD.C_ORDER_ID;
 ELSE
-  v_ID:=:NEW.C_ORDER_ID;
+  v_ID := :NEW.C_ORDER_ID;
 END IF;
 
 IF (UPDATING) THEN
@@ -179,9 +178,12 @@
           v_LineAlternate := v_BaseLineAlternate - v_LineAlternateAcum;
         END IF;
         IF (v_istaxincluded = 'Y') THEN
-          v_PriceLine := C_GET_NET_PRICE_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate, v_PricePrec, :new.qtyordered);
-          v_CalcLine := ROUND(:new.qtyordered * v_PriceLine, v_Prec); -- In price including taxes the net and net alternate are equals.
-          select coalesce(max(line), 0) into v_maxline from c_orderlinetax where c_orderline_id = :new.C_OrderLine_ID;
+          SELECT COALESCE(MIN(DocTaxAmount), 'L') INTO v_DocTaxAmount FROM C_Tax WHERE (C_Tax_ID = Cur_BOM.TAX OR Parent_Tax_ID = Cur_BOM.TAX) AND IsSummary = 'N';
+          IF (v_DocTaxAmount = 'D') THEN
+            v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate);
+          ELSE
+            v_CalcLine := C_GET_NET_AMOUNT_FROM_GROSS(Cur_BOM.TAX, v_Line, v_LineAlternate, v_Prec);
+          END IF;
           C_ORDERLINETAX_INSERT(:new.AD_Org_ID, :new.C_Order_ID, :new.C_OrderLine_ID, :new.UpdatedBy, Cur_BOM.TAX, Cur_BOM.TAX, v_CalcLine, v_CalcLine, v_Prec);
         ELSE
           C_ORDERLINETAX_INSERT(:new.AD_Org_ID, :new.C_Order_ID, :new.C_OrderLine_ID, :new.UpdatedBy, Cur_BOM.TAX, Cur_BOM.TAX, v_Line, v_LineAlternate, v_Prec);
@@ -189,47 +191,51 @@
       END LOOP;         
     ELSE
       -- Regular taxes
-      C_ORDERLINETAX_INSERT(:new.AD_Org_ID, :new.C_Order_ID, :new.C_OrderLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineAlternate, v_Prec);    
+      SELECT COALESCE(MIN(DocTaxAmount), 'L') INTO v_DocTaxAmount FROM C_Tax WHERE (C_Tax_ID = :new.C_Tax_ID OR Parent_Tax_ID = :new.C_Tax_ID) AND IsSummary = 'N';
+      IF (v_istaxincluded = 'Y' AND v_DocTaxAmount = 'D') THEN
+        v_newLineNetAmt := C_GET_NET_AMOUNT_FROM_GROSS(:new.c_tax_id, :new.line_gross_amount, :new.taxbaseamt);
+        C_ORDERLINETAX_INSERT(:new.AD_Org_ID, :new.C_Order_ID, :new.C_OrderLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineNetAmt, v_Prec);
+      ELSE
+        C_ORDERLINETAX_INSERT(:new.AD_Org_ID, :new.C_Order_ID, :new.C_OrderLine_ID, :new.UpdatedBy, :new.C_Tax_ID, :new.C_Tax_ID, v_newLineNetAmt, v_newLineAlternate, v_Prec);
+      END IF;
     END IF;
-    
     IF (v_istaxincluded = 'Y') THEN
-      C_ORDERLINETAX_ROUNDING(:new.C_OrderLine_ID, :new.line_gross_amount, v_newLineNetAmt);
+      C_ORDERLINETAX_ROUNDING(:new.C_OrderLine_ID, :new.line_gross_amount, ROUND(v_newLineNetAmt, v_Prec));
     END IF;
 
-    -- Get Total Tax Amt
-    SELECT SUM(TaxAmt) INTO v_taxAmt
-    FROM C_OrderTax
-    WHERE C_Order_ID=:new.C_Order_ID;
+    -- Get Total Tax Base Amt and Tax Amt
+    SELECT COALESCE(SUM(ot.TaxBaseAmt), 0), COALESCE(SUM(ot.TaxAmt), 0)
+    INTO v_taxBaseAmt, v_taxAmt
+    FROM (
+      SELECT CASE WHEN MIN(ot.TaxBaseAmt) > 0 THEN MIN(ROUND(ot.TaxBaseAmt, v_Prec)) ELSE MAX(ROUND(ot.TaxBaseAmt, v_Prec)) END as TaxBaseAmt, SUM(ot.TaxAmt) as TaxAmt
+      FROM C_OrderTax ot
+      WHERE ot.C_Order_ID = :new.C_Order_ID
+      GROUP BY c_tax_get_root(ot.c_tax_id)
+    ) ot;
     -- DBMS_OUTPUT.PUT_LINE('TaxAmt = ' || v_taxAmt);
     -- Update Header
     UPDATE C_Order
-    SET TotalLines = TotalLines - v_oldLine + v_newLineNetAmt,
-        GrandTotal = CASE v_istaxincluded
-                       WHEN 'Y' THEN grandtotal - v_oldgrossamt + v_newgrossamt
-                       ELSE TotalLines - v_oldLine + v_newLineNetAmt + COALESCE(v_taxAmt, 0)
-                       END
-      WHERE C_Order_ID = :new.C_Order_ID;
+    SET TotalLines = CASE WHEN v_istaxincluded = 'Y' THEN CASE WHEN v_taxAmt = 0 THEN grandtotal - v_oldgrossamt + v_newgrossamt ELSE v_taxBaseAmt END ELSE TotalLines - v_oldLine + v_newLineNetAmt END,
+    GrandTotal = CASE WHEN v_istaxincluded = 'Y' THEN grandtotal - v_oldgrossamt + v_newgrossamt ELSE TotalLines - v_oldLine + v_newLineNetAmt + v_taxAmt END
+    WHERE C_Order_ID = :new.C_Order_ID;
     END IF;
   ELSE -- DELETING
-    SELECT SUM(TaxAmt) INTO v_taxAmt
-    FROM C_OrderTax
-    WHERE C_Order_ID=:old.C_Order_ID;
+    -- Get Total Tax Base Amt and Tax Amt
+    SELECT COALESCE(SUM(ot.TaxBaseAmt), 0), COALESCE(SUM(ot.TaxAmt), 0)
+    INTO v_taxBaseAmt, v_taxAmt
+    FROM (
+      SELECT CASE WHEN MIN(ot.TaxBaseAmt) > 0 THEN MIN(ROUND(ot.TaxBaseAmt, v_Prec)) ELSE MAX(ROUND(ot.TaxBaseAmt, v_Prec)) END as TaxBaseAmt, SUM(ot.TaxAmt) as TaxAmt
+      FROM C_OrderTax ot
+      WHERE ot.C_Order_ID = :old.C_Order_ID
+      GROUP BY c_tax_get_root(ot.c_tax_id)
+    ) ot;
     -- DBMS_OUTPUT.PUT_LINE('TaxAmt = ' || v_taxAmt);
     -- Update Header
     UPDATE C_Order
-    SET TotalLines = TotalLines - v_oldLine + v_newLineNetAmt,
-        GrandTotal = CASE v_istaxincluded
-                       WHEN 'Y' THEN grandtotal - v_oldgrossamt
-                       ELSE TotalLines - v_oldLine + v_newLineNetAmt + COALESCE(v_taxAmt, 0)
-                     END
+    SET TotalLines = CASE WHEN v_istaxincluded = 'Y' THEN CASE WHEN v_taxAmt = 0 THEN grandtotal - v_oldgrossamt ELSE v_taxBaseAmt END ELSE TotalLines - v_oldLine + v_newLineNetAmt END,
+    GrandTotal = CASE WHEN v_istaxincluded = 'Y' THEN grandtotal - v_oldgrossamt ELSE TotalLines - v_oldLine + v_newLineNetAmt + v_taxAmt END
     WHERE C_Order_ID=:old.C_Order_ID;
   END IF;
-  IF (v_istaxincluded = 'Y') THEN
-    SELECT totallines, grandtotal INTO v_totallines, v_grandtotal
-    FROM c_order
-    WHERE c_order_id = v_id;
-    C_ORDERTAX_ROUNDING(v_id, v_grandtotal, v_totallines);
-  END IF;
 
  IF (INSERTING OR UPDATING) THEN
   --Does not allow to change the attribute set value
--- a/model/src-db/database/model/triggers/M_PRODUCT_CATEGORY_TRG.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/triggers/M_PRODUCT_CATEGORY_TRG.xml	Thu May 25 06:12:59 2017 +0000
@@ -17,7 +17,7 @@
     * parts created by ComPiere are Copyright (C) ComPiere, Inc.;
     * All Rights Reserved.
     * Contributor(s): Openbravo SLU
-    * Contributions are Copyright (C) 2001-2012 Openbravo, S.L.U.
+    * Contributions are Copyright (C) 2001-2017 Openbravo, S.L.U.
     *
     * Specifically, this derivative work is based upon the following Compiere
     * file and version.
@@ -108,6 +108,17 @@
   ELSIF (UPDATING) THEN
     UPDATE M_PRODUCT_CATEGORY_ACCT SET AD_ORG_ID = :new.AD_ORG_ID
     WHERE M_PRODUCT_CATEGORY_ID = :new.M_PRODUCT_CATEGORY_ID;
+
+    SELECT c.AD_Tree_Product_Category_ID
+    INTO v_xTree_ID
+    FROM AD_ClientInfo c
+    WHERE c.AD_Client_ID=:new.AD_Client_ID;
+	
+    UPDATE AD_TREENODE
+    SET AD_ORG_ID = :new.AD_ORG_ID
+    WHERE AD_CLIENT_ID=:new.AD_Client_ID
+      AND AD_Tree_ID=v_xTree_ID
+      AND Node_ID=:new.M_Product_Category_ID;
   ELSIF (DELETING) THEN
     --  Delete TreeNode --
     --  get AD_Tree_ID
--- a/model/src-db/database/model/views/C_INVOICETAX_CASHVAT_V.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/views/C_INVOICETAX_CASHVAT_V.xml	Thu May 25 06:12:59 2017 +0000
@@ -1,4 +1,4 @@
 <?xml version="1.0"?>
   <database name="VIEW C_INVOICETAX_CASHVAT_V">
-    <view name="C_INVOICETAX_CASHVAT_V"><![CDATA[SELECT itcv.c_invoicetax_cashvat_id AS c_invoicetax_cashvat_v_id, itcv.ad_client_id, itcv.ad_org_id, itcv.created, itcv.createdby, itcv.updated, itcv.updatedby, itcv.isactive, fp.paymentdate, itcv.percentage, itcv.taxamt, itcv.taxbaseamt, COALESCE(fpsd.iscanceled, 'N') AS iscanceled, fp.fin_payment_id, fpd.fin_payment_detail_id, fp.isreceipt, fp.c_bpartner_id, fp.fin_paymentmethod_id, fp.status, fp.amount, fp.c_currency_id, itcv.c_invoicetax_id, itcv.ismanualsettlement FROM c_invoicetax_cashvat itcv LEFT JOIN c_invoicetax it ON it.c_invoicetax_id = itcv.c_invoicetax_id LEFT JOIN fin_payment_detail fpd ON fpd.fin_payment_detail_id = itcv.fin_payment_detail_id LEFT JOIN fin_payment fp ON fp.fin_payment_id = fpd.fin_payment_id LEFT JOIN fin_payment_scheduledetail fpsd ON fpd.fin_payment_detail_id = fpsd.fin_payment_detail_id LEFT JOIN fin_payment_schedule fpsi ON fpsi.fin_payment_schedule_id = fpsd.fin_payment_schedule_invoice WHERE itcv.ismanualsettlement = 'N' AND fpsi.c_invoice_id = it.c_invoice_id OR itcv.ismanualsettlement = 'Y']]></view>
+    <view name="C_INVOICETAX_CASHVAT_V"><![CDATA[SELECT itcv.c_invoicetax_cashvat_id AS c_invoicetax_cashvat_v_id, itcv.ad_client_id, itcv.ad_org_id, itcv.created, itcv.createdby, itcv.updated, itcv.updatedby, itcv.isactive, fp.paymentdate, itcv.percentage, itcv.taxamt, itcv.taxbaseamt, COALESCE(fpsd.iscanceled, 'N') AS iscanceled, fp.fin_payment_id, fpd.fin_payment_detail_id, fp.isreceipt, fp.c_bpartner_id, fp.fin_paymentmethod_id, fp.status, fp.amount, fp.c_currency_id, itcv.c_invoicetax_id, itcv.ismanualsettlement, it.c_invoice_id, it.c_tax_id, fpd.isprepayment FROM c_invoicetax_cashvat itcv LEFT JOIN c_invoicetax it ON it.c_invoicetax_id = itcv.c_invoicetax_id LEFT JOIN fin_payment_detail fpd ON fpd.fin_payment_detail_id = itcv.fin_payment_detail_id LEFT JOIN fin_payment fp ON fp.fin_payment_id = fpd.fin_payment_id LEFT JOIN fin_payment_scheduledetail fpsd ON fpd.fin_payment_detail_id = fpsd.fin_payment_detail_id LEFT JOIN fin_payment_schedule fpsi ON fpsi.fin_payment_schedule_id = fpsd.fin_payment_schedule_invoice WHERE itcv.ismanualsettlement = 'N' AND fpsi.c_invoice_id = it.c_invoice_id OR itcv.ismanualsettlement = 'Y']]></view>
   </database>
--- a/model/src-db/database/model/views/C_INVOICE_CANDIDATE_V.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/model/views/C_INVOICE_CANDIDATE_V.xml	Thu May 25 06:12:59 2017 +0000
@@ -1,4 +1,4 @@
 <?xml version="1.0"?>
   <database name="VIEW C_INVOICE_CANDIDATE_V">
-    <view name="C_INVOICE_CANDIDATE_V"><![CDATA[SELECT o.ad_client_id, o.ad_org_id, o.c_bpartner_id, o.c_order_id, o.documentno, o.dateordered, o.c_doctype_id, o.totallines AS amountlines, o.grandtotal AS amountlinesgross, sum(round((l.qtyordered - l.qtyinvoiced) * l.priceactual, c.stdprecision)) AS notinvoicedlines, round(sum(round((l.qtyordered - l.qtyinvoiced) * l.priceactual, c.stdprecision) * (1 + t.rate / 100)), c.stdprecision) AS notinvoicedlinesgross, o.invoicerule AS term, sum(round((l.qtydelivered - l.qtyinvoiced) * l.priceactual, c.stdprecision)) AS pendinglines, round(sum(round((l.qtydelivered - l.qtyinvoiced) * l.priceactual, c.stdprecision) * (1 + t.rate / 100)), c.stdprecision) AS pendinglinesgross, sum(abs(l.qtyordered)) AS qtyordered, sum(abs(l.qtydelivered)) AS qtydelivered FROM c_order o JOIN c_doctype dt ON o.c_doctype_id = dt.c_doctype_id JOIN c_bpartner bp ON o.c_bpartner_id = bp.c_bpartner_id JOIN c_currency c ON o.c_currency_id = c.c_currency_id JOIN c_orderline l ON o.c_order_id = l.c_order_id JOIN c_tax t ON t.c_tax_id = l.c_tax_id LEFT JOIN c_invoiceschedule si ON bp.c_invoiceschedule_id = si.c_invoiceschedule_id WHERE (o.docstatus IN ('CO', 'CL', 'IP')) AND dt.docbasetype = 'SOO' AND (dt.docsubtypeso NOT IN ('ON', 'OB', 'WR')) AND (o.invoicerule IN ('I', 'O', 'D', 'S')) AND (si.invoicefrequency IS NULL OR (si.invoicefrequency IN ('D', 'W', 'T')) AND trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff - 1) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday - 1) OR trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff + 14) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday + 14) OR si.invoicefrequency = 'M' AND trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff - 1) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday - 1)) AND (abs(l.qtyordered - l.qtyinvoiced) <> 0 OR abs(l.qtydelivered - l.qtyinvoiced) <> 0) GROUP BY o.ad_client_id, o.ad_org_id, o.c_bpartner_id, o.c_order_id, o.documentno, o.dateordered, o.c_doctype_id, o.totallines, o.grandtotal, o.invoicerule, c.c_currency_id, c.stdprecision]]></view>
+    <view name="C_INVOICE_CANDIDATE_V"><![CDATA[SELECT o.ad_client_id, o.ad_org_id, o.c_bpartner_id, o.c_order_id, o.documentno, o.dateordered, o.c_doctype_id, o.totallines AS amountlines, o.grandtotal AS amountlinesgross, sum(round((l.qtyordered - l.qtyinvoiced) * l.priceactual, c.stdprecision)) AS notinvoicedlines, round(sum(round((l.qtyordered - l.qtyinvoiced) * l.priceactual, c.stdprecision) * (1 + t.rate / 100)), c.stdprecision) AS notinvoicedlinesgross, o.invoicerule AS term, sum(round((l.qtydelivered - l.qtyinvoiced) * l.priceactual, c.stdprecision)) AS pendinglines, round(sum(round((l.qtydelivered - l.qtyinvoiced) * l.priceactual, c.stdprecision) * (1 + t.rate / 100)), c.stdprecision) AS pendinglinesgross, sum(abs(l.qtyordered)) AS qtyordered, sum(abs(l.qtydelivered)) AS qtydelivered FROM c_order o JOIN c_doctype dt ON o.c_doctype_id = dt.c_doctype_id JOIN c_bpartner bp ON o.c_bpartner_id = bp.c_bpartner_id JOIN c_currency c ON o.c_currency_id = c.c_currency_id JOIN c_orderline l ON o.c_order_id = l.c_order_id JOIN c_tax t ON t.c_tax_id = l.c_tax_id LEFT JOIN c_invoiceschedule si ON bp.c_invoiceschedule_id = si.c_invoiceschedule_id WHERE (o.docstatus IN ('CO', 'CL', 'IP')) AND dt.docbasetype = 'SOO' AND (dt.docsubtypeso NOT IN ('ON', 'OB', 'WR')) AND (o.invoicerule = 'I' OR o.invoicerule = 'O' OR o.invoicerule = 'D' OR o.invoicerule = 'S' AND (si.invoicefrequency IS NULL OR si.invoicefrequency = 'D' OR si.invoicefrequency = 'W' OR si.invoicefrequency = 'T' AND trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff - 1) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday - 1) OR trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff + 14) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday + 14) OR si.invoicefrequency = 'M' AND trunc(o.dateordered) <= (trunc(now(), 'MM') + si.invoicedaycutoff - 1) AND trunc(now()) >= (trunc(o.dateordered, 'MM') + si.invoiceday - 1))) AND (abs(l.qtyordered - l.qtyinvoiced) <> 0 OR abs(l.qtydelivered - l.qtyinvoiced) <> 0) GROUP BY o.ad_client_id, o.ad_org_id, o.c_bpartner_id, o.c_order_id, o.documentno, o.dateordered, o.c_doctype_id, o.totallines, o.grandtotal, o.invoicerule, c.c_currency_id, c.stdprecision]]></view>
   </database>
--- a/model/src-db/database/sourcedata/AD_CALLOUT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_CALLOUT.xml	Thu May 25 06:12:59 2017 +0000
@@ -987,6 +987,15 @@
 <!--52AA6F882A0B4BF7A7BB4ABA6496DF4D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--52AA6F882A0B4BF7A7BB4ABA6496DF4D--></AD_CALLOUT>
 
+<!--57752E7EA3D1463DBEF39996BAEBAB98--><AD_CALLOUT>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <AD_CALLOUT_ID><![CDATA[57752E7EA3D1463DBEF39996BAEBAB98]]></AD_CALLOUT_ID>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <NAME><![CDATA[SE_Amount_Transaction]]></NAME>
+<!--57752E7EA3D1463DBEF39996BAEBAB98-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--57752E7EA3D1463DBEF39996BAEBAB98--></AD_CALLOUT>
+
 <!--5B737680E16D42E6887B3099E2EFA961--><AD_CALLOUT>
 <!--5B737680E16D42E6887B3099E2EFA961-->  <AD_CALLOUT_ID><![CDATA[5B737680E16D42E6887B3099E2EFA961]]></AD_CALLOUT_ID>
 <!--5B737680E16D42E6887B3099E2EFA961-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_COLUMN.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_COLUMN.xml	Thu May 25 06:12:59 2017 +0000
@@ -107849,7 +107849,7 @@
 <!--7027-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
 <!--7027-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
 <!--7027-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
-<!--7027-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--7027-->  <DEVELOPMENTSTATUS><![CDATA[DP]]></DEVELOPMENTSTATUS>
 <!--7027-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--7027-->  <POSITION><![CDATA[31]]></POSITION>
 <!--7027-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
@@ -155257,7 +155257,7 @@
 <!--800880-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
 <!--800880-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
 <!--800880-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
-<!--800880-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--800880-->  <DEVELOPMENTSTATUS><![CDATA[DP]]></DEVELOPMENTSTATUS>
 <!--800880-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--800880-->  <POSITION><![CDATA[34]]></POSITION>
 <!--800880-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
@@ -257560,6 +257560,44 @@
 <!--31A70D5921994990B17329ECB16314A0-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
 <!--31A70D5921994990B17329ECB16314A0--></AD_COLUMN>
 
+<!--31B9D2FEEEAE4C2FAC945529513D115D--><AD_COLUMN>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_COLUMN_ID><![CDATA[31B9D2FEEEAE4C2FAC945529513D115D]]></AD_COLUMN_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <NAME><![CDATA[isPrepayment]]></NAME>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <DESCRIPTION><![CDATA[Indicates that the payment is a prepayment]]></DESCRIPTION>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <HELP><![CDATA[When the payment is created against order it is considered to be a prepayment]]></HELP>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <COLUMNNAME><![CDATA[Isprepayment]]></COLUMNNAME>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_TABLE_ID><![CDATA[468BC822115146B8B67E82F671F570B3]]></AD_TABLE_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_REFERENCE_ID><![CDATA[20]]></AD_REFERENCE_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <FIELDLENGTH><![CDATA[1]]></FIELDLENGTH>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISKEY><![CDATA[N]]></ISKEY>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISPARENT><![CDATA[N]]></ISPARENT>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISMANDATORY><![CDATA[N]]></ISMANDATORY>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <SEQNO><![CDATA[270]]></SEQNO>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISSELECTIONCOLUMN><![CDATA[N]]></ISSELECTIONCOLUMN>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_ELEMENT_ID><![CDATA[8055D7355E4FEA87E040007F01001969]]></AD_ELEMENT_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <POSITION><![CDATA[26]]></POSITION>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <IMAGESIZEVALUESACTION><![CDATA[N]]></IMAGESIZEVALUESACTION>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ALLOWSORTING><![CDATA[Y]]></ALLOWSORTING>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ALLOWFILTERING><![CDATA[Y]]></ALLOWFILTERING>
+<!--31B9D2FEEEAE4C2FAC945529513D115D-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
+<!--31B9D2FEEEAE4C2FAC945529513D115D--></AD_COLUMN>
+
 <!--31CEE3F2AE9A439B9F4A49B93FFE9758--><AD_COLUMN>
 <!--31CEE3F2AE9A439B9F4A49B93FFE9758-->  <AD_COLUMN_ID><![CDATA[31CEE3F2AE9A439B9F4A49B93FFE9758]]></AD_COLUMN_ID>
 <!--31CEE3F2AE9A439B9F4A49B93FFE9758-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -302627,6 +302665,7 @@
 <!--7891269C841C655DE040007F010155CE-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
 <!--7891269C841C655DE040007F010155CE-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
 <!--7891269C841C655DE040007F010155CE-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--7891269C841C655DE040007F010155CE-->  <AD_CALLOUT_ID><![CDATA[57752E7EA3D1463DBEF39996BAEBAB98]]></AD_CALLOUT_ID>
 <!--7891269C841C655DE040007F010155CE-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--7891269C841C655DE040007F010155CE-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--7891269C841C655DE040007F010155CE-->  <POSITION><![CDATA[16]]></POSITION>
@@ -302665,6 +302704,7 @@
 <!--7891269C841D655DE040007F010155CE-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
 <!--7891269C841D655DE040007F010155CE-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
 <!--7891269C841D655DE040007F010155CE-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--7891269C841D655DE040007F010155CE-->  <AD_CALLOUT_ID><![CDATA[57752E7EA3D1463DBEF39996BAEBAB98]]></AD_CALLOUT_ID>
 <!--7891269C841D655DE040007F010155CE-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--7891269C841D655DE040007F010155CE-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--7891269C841D655DE040007F010155CE-->  <POSITION><![CDATA[17]]></POSITION>
@@ -336778,6 +336818,44 @@
 <!--A269590856C443468BEA02704D3AB1DA-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
 <!--A269590856C443468BEA02704D3AB1DA--></AD_COLUMN>
 
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87--><AD_COLUMN>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_COLUMN_ID><![CDATA[A2921A7F2FC346EB8F11CE54AC4CAC87]]></AD_COLUMN_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <NAME><![CDATA[Tax]]></NAME>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <DESCRIPTION><![CDATA[The percentage of money requested by the government for this specified product or transaction.]]></DESCRIPTION>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <HELP><![CDATA[The Tax indicates the type of tax for this document line.]]></HELP>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <COLUMNNAME><![CDATA[C_Tax_ID]]></COLUMNNAME>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_TABLE_ID><![CDATA[468BC822115146B8B67E82F671F570B3]]></AD_TABLE_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_REFERENCE_ID><![CDATA[19]]></AD_REFERENCE_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <FIELDLENGTH><![CDATA[32]]></FIELDLENGTH>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISKEY><![CDATA[N]]></ISKEY>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISPARENT><![CDATA[N]]></ISPARENT>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISMANDATORY><![CDATA[N]]></ISMANDATORY>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <SEQNO><![CDATA[260]]></SEQNO>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISSELECTIONCOLUMN><![CDATA[N]]></ISSELECTIONCOLUMN>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_ELEMENT_ID><![CDATA[213]]></AD_ELEMENT_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <POSITION><![CDATA[25]]></POSITION>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <IMAGESIZEVALUESACTION><![CDATA[N]]></IMAGESIZEVALUESACTION>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ALLOWSORTING><![CDATA[Y]]></ALLOWSORTING>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ALLOWFILTERING><![CDATA[Y]]></ALLOWFILTERING>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
+<!--A2921A7F2FC346EB8F11CE54AC4CAC87--></AD_COLUMN>
+
 <!--A299657C67C841EBB8E51AFB606EE4EF--><AD_COLUMN>
 <!--A299657C67C841EBB8E51AFB606EE4EF-->  <AD_COLUMN_ID><![CDATA[A299657C67C841EBB8E51AFB606EE4EF]]></AD_COLUMN_ID>
 <!--A299657C67C841EBB8E51AFB606EE4EF-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -349044,6 +349122,44 @@
 <!--B99B30BC8FDB4137AA3DBAB7D2CF0F2B-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
 <!--B99B30BC8FDB4137AA3DBAB7D2CF0F2B--></AD_COLUMN>
 
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7--><AD_COLUMN>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_COLUMN_ID><![CDATA[B9CF022F66984C6CA7C6CED8B01EF1E7]]></AD_COLUMN_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <NAME><![CDATA[Invoice]]></NAME>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <DESCRIPTION><![CDATA[A document listing products, quantities and prices, payment terms, etc.]]></DESCRIPTION>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <HELP><![CDATA[The Invoice ID uniquely identifies an Invoice Document.]]></HELP>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <COLUMNNAME><![CDATA[C_Invoice_ID]]></COLUMNNAME>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_TABLE_ID><![CDATA[468BC822115146B8B67E82F671F570B3]]></AD_TABLE_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_REFERENCE_ID><![CDATA[19]]></AD_REFERENCE_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <FIELDLENGTH><![CDATA[32]]></FIELDLENGTH>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISKEY><![CDATA[N]]></ISKEY>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISPARENT><![CDATA[N]]></ISPARENT>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISMANDATORY><![CDATA[N]]></ISMANDATORY>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISUPDATEABLE><![CDATA[Y]]></ISUPDATEABLE>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISIDENTIFIER><![CDATA[N]]></ISIDENTIFIER>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <SEQNO><![CDATA[250]]></SEQNO>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISTRANSLATED><![CDATA[N]]></ISTRANSLATED>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISSELECTIONCOLUMN><![CDATA[N]]></ISSELECTIONCOLUMN>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_ELEMENT_ID><![CDATA[1008]]></AD_ELEMENT_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISSESSIONATTR><![CDATA[N]]></ISSESSIONATTR>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISSECONDARYKEY><![CDATA[N]]></ISSECONDARYKEY>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <POSITION><![CDATA[24]]></POSITION>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <IMAGESIZEVALUESACTION><![CDATA[N]]></IMAGESIZEVALUESACTION>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ISUSEDSEQUENCE><![CDATA[N]]></ISUSEDSEQUENCE>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ALLOWSORTING><![CDATA[Y]]></ALLOWSORTING>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ALLOWFILTERING><![CDATA[Y]]></ALLOWFILTERING>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7-->  <ALLOWED_CROSS_ORG_LINK><![CDATA[N]]></ALLOWED_CROSS_ORG_LINK>
+<!--B9CF022F66984C6CA7C6CED8B01EF1E7--></AD_COLUMN>
+
 <!--B9CF105C680D4E568EC68F05F8522446--><AD_COLUMN>
 <!--B9CF105C680D4E568EC68F05F8522446-->  <AD_COLUMN_ID><![CDATA[B9CF105C680D4E568EC68F05F8522446]]></AD_COLUMN_ID>
 <!--B9CF105C680D4E568EC68F05F8522446-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -355751,8 +355867,8 @@
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <NAME><![CDATA[Returnable]]></NAME>
-<!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <DESCRIPTION><![CDATA[Indicates is the Service is Returnable or not]]></DESCRIPTION>
-<!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <HELP><![CDATA[Indicates is the Service is Returnable or not]]></HELP>
+<!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <DESCRIPTION><![CDATA[Indicates if the Product is Returnable or not]]></DESCRIPTION>
+<!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <HELP><![CDATA[Indicates if the Product is Returnable or not]]></HELP>
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <COLUMNNAME><![CDATA[Returnable]]></COLUMNNAME>
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <AD_TABLE_ID><![CDATA[208]]></AD_TABLE_ID>
 <!--C93C575B07E74FAD8AAB0F49E6FDA907-->  <AD_REFERENCE_ID><![CDATA[20]]></AD_REFERENCE_ID>
@@ -373691,6 +373807,7 @@
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <ISDESENCRYPTABLE><![CDATA[N]]></ISDESENCRYPTABLE>
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <DEVELOPMENTSTATUS><![CDATA[RE]]></DEVELOPMENTSTATUS>
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--E9C75CC455C44F1A9D39878102D1DDE5-->  <POSITION><![CDATA[23]]></POSITION>
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <ISTRANSIENT><![CDATA[N]]></ISTRANSIENT>
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <ISAUTOSAVE><![CDATA[Y]]></ISAUTOSAVE>
 <!--E9C75CC455C44F1A9D39878102D1DDE5-->  <VALIDATEONNEW><![CDATA[Y]]></VALIDATEONNEW>
--- a/model/src-db/database/sourcedata/AD_ELEMENT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_ELEMENT.xml	Thu May 25 06:12:59 2017 +0000
@@ -21252,6 +21252,18 @@
 <!--0BD29E7F540B4C12A0F4E02B7A1F4061-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--0BD29E7F540B4C12A0F4E02B7A1F4061--></AD_ELEMENT>
 
+<!--0BD34701040243379D33B8A27AAD2308--><AD_ELEMENT>
+<!--0BD34701040243379D33B8A27AAD2308-->  <AD_ELEMENT_ID><![CDATA[0BD34701040243379D33B8A27AAD2308]]></AD_ELEMENT_ID>
+<!--0BD34701040243379D33B8A27AAD2308-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--0BD34701040243379D33B8A27AAD2308-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--0BD34701040243379D33B8A27AAD2308-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--0BD34701040243379D33B8A27AAD2308-->  <COLUMNNAME><![CDATA[CurrentDate]]></COLUMNNAME>
+<!--0BD34701040243379D33B8A27AAD2308-->  <NAME><![CDATA[As Of Date]]></NAME>
+<!--0BD34701040243379D33B8A27AAD2308-->  <PRINTNAME><![CDATA[As Of Date]]></PRINTNAME>
+<!--0BD34701040243379D33B8A27AAD2308-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--0BD34701040243379D33B8A27AAD2308-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--0BD34701040243379D33B8A27AAD2308--></AD_ELEMENT>
+
 <!--0CC014AD7EFD4D949B995E8DCC256EEC--><AD_ELEMENT>
 <!--0CC014AD7EFD4D949B995E8DCC256EEC-->  <AD_ELEMENT_ID><![CDATA[0CC014AD7EFD4D949B995E8DCC256EEC]]></AD_ELEMENT_ID>
 <!--0CC014AD7EFD4D949B995E8DCC256EEC-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -21610,6 +21622,18 @@
 <!--17485BBD94A447C2A0C823181EF0F066-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--17485BBD94A447C2A0C823181EF0F066--></AD_ELEMENT>
 
+<!--1781EBA322894DF58835305F5D6B26DA--><AD_ELEMENT>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <AD_ELEMENT_ID><![CDATA[1781EBA322894DF58835305F5D6B26DA]]></AD_ELEMENT_ID>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <COLUMNNAME><![CDATA[BusinessPartner]]></COLUMNNAME>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <NAME><![CDATA[Business Partner]]></NAME>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <PRINTNAME><![CDATA[Business Partner]]></PRINTNAME>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--1781EBA322894DF58835305F5D6B26DA-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--1781EBA322894DF58835305F5D6B26DA--></AD_ELEMENT>
+
 <!--17ADA898A5534B858EC8BD7651492088--><AD_ELEMENT>
 <!--17ADA898A5534B858EC8BD7651492088-->  <AD_ELEMENT_ID><![CDATA[17ADA898A5534B858EC8BD7651492088]]></AD_ELEMENT_ID>
 <!--17ADA898A5534B858EC8BD7651492088-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -21745,6 +21769,18 @@
 <!--1B0CF5AAAD40140FE0530100007F2562-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--1B0CF5AAAD40140FE0530100007F2562--></AD_ELEMENT>
 
+<!--1C5C8314A52C45819097381E72843369--><AD_ELEMENT>
+<!--1C5C8314A52C45819097381E72843369-->  <AD_ELEMENT_ID><![CDATA[1C5C8314A52C45819097381E72843369]]></AD_ELEMENT_ID>
+<!--1C5C8314A52C45819097381E72843369-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--1C5C8314A52C45819097381E72843369-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--1C5C8314A52C45819097381E72843369-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--1C5C8314A52C45819097381E72843369-->  <COLUMNNAME><![CDATA[CurrentDate]]></COLUMNNAME>
+<!--1C5C8314A52C45819097381E72843369-->  <NAME><![CDATA[As Of Date]]></NAME>
+<!--1C5C8314A52C45819097381E72843369-->  <PRINTNAME><![CDATA[As Of Date]]></PRINTNAME>
+<!--1C5C8314A52C45819097381E72843369-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--1C5C8314A52C45819097381E72843369-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--1C5C8314A52C45819097381E72843369--></AD_ELEMENT>
+
 <!--1CF418C350EA368FE0530100007F5EDF--><AD_ELEMENT>
 <!--1CF418C350EA368FE0530100007F5EDF-->  <AD_ELEMENT_ID><![CDATA[1CF418C350EA368FE0530100007F5EDF]]></AD_ELEMENT_ID>
 <!--1CF418C350EA368FE0530100007F5EDF-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -21769,6 +21805,18 @@
 <!--1D5007B3718D4A808987DE155B83BDDE-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--1D5007B3718D4A808987DE155B83BDDE--></AD_ELEMENT>
 
+<!--1DB9E812404D49AFBB90A48D5DDFBC17--><AD_ELEMENT>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <AD_ELEMENT_ID><![CDATA[1DB9E812404D49AFBB90A48D5DDFBC17]]></AD_ELEMENT_ID>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <COLUMNNAME><![CDATA[Column2]]></COLUMNNAME>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <NAME><![CDATA[Number Of Days Overdue: Group Two]]></NAME>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Two]]></PRINTNAME>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--1DB9E812404D49AFBB90A48D5DDFBC17--></AD_ELEMENT>
+
 <!--1E09C68B2939415897A5BC5BC7321AB2--><AD_ELEMENT>
 <!--1E09C68B2939415897A5BC5BC7321AB2-->  <AD_ELEMENT_ID><![CDATA[1E09C68B2939415897A5BC5BC7321AB2]]></AD_ELEMENT_ID>
 <!--1E09C68B2939415897A5BC5BC7321AB2-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22148,6 +22196,30 @@
 <!--29ADAE46594E4364B62CB72C8D029D6F-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--29ADAE46594E4364B62CB72C8D029D6F--></AD_ELEMENT>
 
+<!--2A3C73D7FB9545B7943D32C575C655C5--><AD_ELEMENT>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <AD_ELEMENT_ID><![CDATA[2A3C73D7FB9545B7943D32C575C655C5]]></AD_ELEMENT_ID>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <COLUMNNAME><![CDATA[breakByDate]]></COLUMNNAME>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <NAME><![CDATA[Break By Date]]></NAME>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <PRINTNAME><![CDATA[Break By Date]]></PRINTNAME>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--2A3C73D7FB9545B7943D32C575C655C5-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--2A3C73D7FB9545B7943D32C575C655C5--></AD_ELEMENT>
+
+<!--2A4C92F5C77A40739DEEDE85201C42C1--><AD_ELEMENT>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <AD_ELEMENT_ID><![CDATA[2A4C92F5C77A40739DEEDE85201C42C1]]></AD_ELEMENT_ID>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <COLUMNNAME><![CDATA[AccSchema]]></COLUMNNAME>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <NAME><![CDATA[General Ledger]]></NAME>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <PRINTNAME><![CDATA[General Ledger]]></PRINTNAME>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--2A4C92F5C77A40739DEEDE85201C42C1-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--2A4C92F5C77A40739DEEDE85201C42C1--></AD_ELEMENT>
+
 <!--2AA5DD33C625410DAC1FDEB71C80ECC1--><AD_ELEMENT>
 <!--2AA5DD33C625410DAC1FDEB71C80ECC1-->  <AD_ELEMENT_ID><![CDATA[2AA5DD33C625410DAC1FDEB71C80ECC1]]></AD_ELEMENT_ID>
 <!--2AA5DD33C625410DAC1FDEB71C80ECC1-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22371,6 +22443,18 @@
 <!--30D58ABF2103491FBCDDAB69E5E5D967-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--30D58ABF2103491FBCDDAB69E5E5D967--></AD_ELEMENT>
 
+<!--314D557225BB42C2BE1F312928AB6FFA--><AD_ELEMENT>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <AD_ELEMENT_ID><![CDATA[314D557225BB42C2BE1F312928AB6FFA]]></AD_ELEMENT_ID>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <COLUMNNAME><![CDATA[organization]]></COLUMNNAME>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <NAME><![CDATA[Organization]]></NAME>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <PRINTNAME><![CDATA[Organization]]></PRINTNAME>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--314D557225BB42C2BE1F312928AB6FFA-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--314D557225BB42C2BE1F312928AB6FFA--></AD_ELEMENT>
+
 <!--3214384084114F38B297AD4448B6D3F6--><AD_ELEMENT>
 <!--3214384084114F38B297AD4448B6D3F6-->  <AD_ELEMENT_ID><![CDATA[3214384084114F38B297AD4448B6D3F6]]></AD_ELEMENT_ID>
 <!--3214384084114F38B297AD4448B6D3F6-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22465,6 +22549,18 @@
 <!--361ED16139BD40CBA4DB049380EE1641-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--361ED16139BD40CBA4DB049380EE1641--></AD_ELEMENT>
 
+<!--368925A36BB74DC5951D46E861D99EC4--><AD_ELEMENT>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <AD_ELEMENT_ID><![CDATA[368925A36BB74DC5951D46E861D99EC4]]></AD_ELEMENT_ID>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <COLUMNNAME><![CDATA[ShowVoid]]></COLUMNNAME>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <NAME><![CDATA[Voided invoices needs to be included]]></NAME>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <PRINTNAME><![CDATA[Voided invoices needs to be included]]></PRINTNAME>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--368925A36BB74DC5951D46E861D99EC4-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--368925A36BB74DC5951D46E861D99EC4--></AD_ELEMENT>
+
 <!--3809065C3B754137BA7DE6709ECE8A74--><AD_ELEMENT>
 <!--3809065C3B754137BA7DE6709ECE8A74-->  <AD_ELEMENT_ID><![CDATA[3809065C3B754137BA7DE6709ECE8A74]]></AD_ELEMENT_ID>
 <!--3809065C3B754137BA7DE6709ECE8A74-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22610,6 +22706,18 @@
 <!--3B80C5B8926B4057B9F683236CB6BD1E-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--3B80C5B8926B4057B9F683236CB6BD1E--></AD_ELEMENT>
 
+<!--3C1055164B7E4DF380ABF9C3A912A129--><AD_ELEMENT>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <AD_ELEMENT_ID><![CDATA[3C1055164B7E4DF380ABF9C3A912A129]]></AD_ELEMENT_ID>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <COLUMNNAME><![CDATA[Column4]]></COLUMNNAME>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <NAME><![CDATA[Number Of Days Overdue: Group Four]]></NAME>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Four]]></PRINTNAME>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--3C1055164B7E4DF380ABF9C3A912A129-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--3C1055164B7E4DF380ABF9C3A912A129--></AD_ELEMENT>
+
 <!--3C45DFEEC7B8494F8A8F2043D43DBED4--><AD_ELEMENT>
 <!--3C45DFEEC7B8494F8A8F2043D43DBED4-->  <AD_ELEMENT_ID><![CDATA[3C45DFEEC7B8494F8A8F2043D43DBED4]]></AD_ELEMENT_ID>
 <!--3C45DFEEC7B8494F8A8F2043D43DBED4-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22660,8 +22768,8 @@
 <!--3CB911FAA1D54CABB7A38AF0CC989151-->  <COLUMNNAME><![CDATA[Returnable]]></COLUMNNAME>
 <!--3CB911FAA1D54CABB7A38AF0CC989151-->  <NAME><![CDATA[Returnable]]></NAME>
 <!--3CB911FAA1D54CABB7A38AF0CC989151-->  <PRINTNAME><![CDATA[Returnable]]></PRINTNAME>
-<!--3CB911FAA1D54CABB7A38AF0CC989151-->  <DESCRIPTION><![CDATA[Indicates is the Service is Returnable or not]]></DESCRIPTION>
-<!--3CB911FAA1D54CABB7A38AF0CC989151-->  <HELP><![CDATA[Indicates is the Service is Returnable or not]]></HELP>
+<!--3CB911FAA1D54CABB7A38AF0CC989151-->  <DESCRIPTION><![CDATA[Indicates if the Product is Returnable or not]]></DESCRIPTION>
+<!--3CB911FAA1D54CABB7A38AF0CC989151-->  <HELP><![CDATA[Indicates if the Product is Returnable or not]]></HELP>
 <!--3CB911FAA1D54CABB7A38AF0CC989151-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--3CB911FAA1D54CABB7A38AF0CC989151-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--3CB911FAA1D54CABB7A38AF0CC989151--></AD_ELEMENT>
@@ -22746,6 +22854,18 @@
 <!--3EB8EDF04F25440E9810F0C9CF5408A5-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--3EB8EDF04F25440E9810F0C9CF5408A5--></AD_ELEMENT>
 
+<!--3EE7E55425EC4595AA3B11F7E7BE0834--><AD_ELEMENT>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <AD_ELEMENT_ID><![CDATA[3EE7E55425EC4595AA3B11F7E7BE0834]]></AD_ELEMENT_ID>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <COLUMNNAME><![CDATA[Column3]]></COLUMNNAME>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <NAME><![CDATA[Number Of Days Overdue: Group Three]]></NAME>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Three]]></PRINTNAME>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--3EE7E55425EC4595AA3B11F7E7BE0834--></AD_ELEMENT>
+
 <!--3EEEF6E328C342E98BB1687FEBAD8D51--><AD_ELEMENT>
 <!--3EEEF6E328C342E98BB1687FEBAD8D51-->  <AD_ELEMENT_ID><![CDATA[3EEEF6E328C342E98BB1687FEBAD8D51]]></AD_ELEMENT_ID>
 <!--3EEEF6E328C342E98BB1687FEBAD8D51-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -23274,6 +23394,18 @@
 <!--4AFD554ABDCB488B87F326A3101B50DE-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--4AFD554ABDCB488B87F326A3101B50DE--></AD_ELEMENT>
 
+<!--4B46432C90EA4D8B959AB48FD0B43EF6--><AD_ELEMENT>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <AD_ELEMENT_ID><![CDATA[4B46432C90EA4D8B959AB48FD0B43EF6]]></AD_ELEMENT_ID>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <COLUMNNAME><![CDATA[Column1]]></COLUMNNAME>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <NAME><![CDATA[Number Of Days Overdue: Group One]]></NAME>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group One]]></PRINTNAME>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--4B46432C90EA4D8B959AB48FD0B43EF6--></AD_ELEMENT>
+
 <!--4B4FE5FD9E234FC3A704B77C67C8ECFB--><AD_ELEMENT>
 <!--4B4FE5FD9E234FC3A704B77C67C8ECFB-->  <AD_ELEMENT_ID><![CDATA[4B4FE5FD9E234FC3A704B77C67C8ECFB]]></AD_ELEMENT_ID>
 <!--4B4FE5FD9E234FC3A704B77C67C8ECFB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -23392,6 +23524,18 @@
 <!--4F27F46890FD44578A592E5CD486CEBB-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--4F27F46890FD44578A592E5CD486CEBB--></AD_ELEMENT>
 
+<!--4F2C1502849044E79CE1915B40677213--><AD_ELEMENT>
+<!--4F2C1502849044E79CE1915B40677213-->  <AD_ELEMENT_ID><![CDATA[4F2C1502849044E79CE1915B40677213]]></AD_ELEMENT_ID>
+<!--4F2C1502849044E79CE1915B40677213-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--4F2C1502849044E79CE1915B40677213-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--4F2C1502849044E79CE1915B40677213-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--4F2C1502849044E79CE1915B40677213-->  <COLUMNNAME><![CDATA[Details]]></COLUMNNAME>
+<!--4F2C1502849044E79CE1915B40677213-->  <NAME><![CDATA[Show Details]]></NAME>
+<!--4F2C1502849044E79CE1915B40677213-->  <PRINTNAME><![CDATA[Show Details]]></PRINTNAME>
+<!--4F2C1502849044E79CE1915B40677213-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--4F2C1502849044E79CE1915B40677213-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--4F2C1502849044E79CE1915B40677213--></AD_ELEMENT>
+
 <!--50574D2DA84B4F3E9ED8272F414D3B1A--><AD_ELEMENT>
 <!--50574D2DA84B4F3E9ED8272F414D3B1A-->  <AD_ELEMENT_ID><![CDATA[50574D2DA84B4F3E9ED8272F414D3B1A]]></AD_ELEMENT_ID>
 <!--50574D2DA84B4F3E9ED8272F414D3B1A-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -24136,6 +24280,18 @@
 <!--53DB74229B26454385ACDCEF07EBBFFF-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--53DB74229B26454385ACDCEF07EBBFFF--></AD_ELEMENT>
 
+<!--5427423DD74041B6808EDD00E54854B4--><AD_ELEMENT>
+<!--5427423DD74041B6808EDD00E54854B4-->  <AD_ELEMENT_ID><![CDATA[5427423DD74041B6808EDD00E54854B4]]></AD_ELEMENT_ID>
+<!--5427423DD74041B6808EDD00E54854B4-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--5427423DD74041B6808EDD00E54854B4-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--5427423DD74041B6808EDD00E54854B4-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--5427423DD74041B6808EDD00E54854B4-->  <COLUMNNAME><![CDATA[RecOrPay]]></COLUMNNAME>
+<!--5427423DD74041B6808EDD00E54854B4-->  <NAME><![CDATA[Rec Or Pay]]></NAME>
+<!--5427423DD74041B6808EDD00E54854B4-->  <PRINTNAME><![CDATA[Rec Or Pay]]></PRINTNAME>
+<!--5427423DD74041B6808EDD00E54854B4-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--5427423DD74041B6808EDD00E54854B4-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--5427423DD74041B6808EDD00E54854B4--></AD_ELEMENT>
+
 <!--5491745132934260A5F00EF178EBC04B--><AD_ELEMENT>
 <!--5491745132934260A5F00EF178EBC04B-->  <AD_ELEMENT_ID><![CDATA[5491745132934260A5F00EF178EBC04B]]></AD_ELEMENT_ID>
 <!--5491745132934260A5F00EF178EBC04B-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -26258,6 +26414,18 @@
 <!--65F38EB415F049629A3ED49DD6BABF31-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--65F38EB415F049629A3ED49DD6BABF31--></AD_ELEMENT>
 
+<!--65FE089F258E4E07BE7B04300B9DD0CA--><AD_ELEMENT>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <AD_ELEMENT_ID><![CDATA[65FE089F258E4E07BE7B04300B9DD0CA]]></AD_ELEMENT_ID>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <COLUMNNAME><![CDATA[Doubtful]]></COLUMNNAME>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <NAME><![CDATA[Show Doubtful Debt]]></NAME>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <PRINTNAME><![CDATA[Show Doubtful Debt]]></PRINTNAME>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--65FE089F258E4E07BE7B04300B9DD0CA-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--65FE089F258E4E07BE7B04300B9DD0CA--></AD_ELEMENT>
+
 <!--666DC9641DCD4F84A24188AFFC251687--><AD_ELEMENT>
 <!--666DC9641DCD4F84A24188AFFC251687-->  <AD_ELEMENT_ID><![CDATA[666DC9641DCD4F84A24188AFFC251687]]></AD_ELEMENT_ID>
 <!--666DC9641DCD4F84A24188AFFC251687-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -28174,6 +28342,18 @@
 <!--80E839B16932298FE040007F01005AAF-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--80E839B16932298FE040007F01005AAF--></AD_ELEMENT>
 
+<!--80FB76B079A541199EE5B1650B729CDB--><AD_ELEMENT>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <AD_ELEMENT_ID><![CDATA[80FB76B079A541199EE5B1650B729CDB]]></AD_ELEMENT_ID>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <COLUMNNAME><![CDATA[Column4]]></COLUMNNAME>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <NAME><![CDATA[Number Of Days Overdue: Group Four]]></NAME>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Four]]></PRINTNAME>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--80FB76B079A541199EE5B1650B729CDB-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--80FB76B079A541199EE5B1650B729CDB--></AD_ELEMENT>
+
 <!--80FF6B5C86144AC698F8EE5AAF09B96C--><AD_ELEMENT>
 <!--80FF6B5C86144AC698F8EE5AAF09B96C-->  <AD_ELEMENT_ID><![CDATA[80FF6B5C86144AC698F8EE5AAF09B96C]]></AD_ELEMENT_ID>
 <!--80FF6B5C86144AC698F8EE5AAF09B96C-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -30051,6 +30231,18 @@
 <!--92B735EF8049459BB5DDF6E17174EC6E-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--92B735EF8049459BB5DDF6E17174EC6E--></AD_ELEMENT>
 
+<!--92F58598478D4D2E91B0D45471EB3A59--><AD_ELEMENT>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <AD_ELEMENT_ID><![CDATA[92F58598478D4D2E91B0D45471EB3A59]]></AD_ELEMENT_ID>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <COLUMNNAME><![CDATA[Column2]]></COLUMNNAME>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <NAME><![CDATA[Number Of Days Overdue: Group Two]]></NAME>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Two]]></PRINTNAME>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--92F58598478D4D2E91B0D45471EB3A59-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--92F58598478D4D2E91B0D45471EB3A59--></AD_ELEMENT>
+
 <!--92FDCF62998E480CB897FF620CC6C0EE--><AD_ELEMENT>
 <!--92FDCF62998E480CB897FF620CC6C0EE-->  <AD_ELEMENT_ID><![CDATA[92FDCF62998E480CB897FF620CC6C0EE]]></AD_ELEMENT_ID>
 <!--92FDCF62998E480CB897FF620CC6C0EE-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -30257,8 +30449,8 @@
 <!--967BCCFCAA234A13AF1F6C087F6437B6-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--967BCCFCAA234A13AF1F6C087F6437B6-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--967BCCFCAA234A13AF1F6C087F6437B6-->  <COLUMNNAME><![CDATA[C_Year_Close_V_ID]]></COLUMNNAME>
-<!--967BCCFCAA234A13AF1F6C087F6437B6-->  <NAME><![CDATA[C_Year_Close_V_ID]]></NAME>
-<!--967BCCFCAA234A13AF1F6C087F6437B6-->  <PRINTNAME><![CDATA[C_Year_Close_V_ID]]></PRINTNAME>
+<!--967BCCFCAA234A13AF1F6C087F6437B6-->  <NAME><![CDATA[End Year Close]]></NAME>
+<!--967BCCFCAA234A13AF1F6C087F6437B6-->  <PRINTNAME><![CDATA[End Year Close]]></PRINTNAME>
 <!--967BCCFCAA234A13AF1F6C087F6437B6-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--967BCCFCAA234A13AF1F6C087F6437B6-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--967BCCFCAA234A13AF1F6C087F6437B6--></AD_ELEMENT>
@@ -30871,6 +31063,18 @@
 <!--A93D6B07CA89486F9518DD4FBA889EF7-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--A93D6B07CA89486F9518DD4FBA889EF7--></AD_ELEMENT>
 
+<!--A9C578B487FB4BE6A048D88A01E4BC1D--><AD_ELEMENT>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <AD_ELEMENT_ID><![CDATA[A9C578B487FB4BE6A048D88A01E4BC1D]]></AD_ELEMENT_ID>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <COLUMNNAME><![CDATA[AccSchema]]></COLUMNNAME>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <NAME><![CDATA[General Ledger]]></NAME>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <PRINTNAME><![CDATA[General Ledger]]></PRINTNAME>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--A9C578B487FB4BE6A048D88A01E4BC1D--></AD_ELEMENT>
+
 <!--AA0437E8332546539BCE11E8D36C562A--><AD_ELEMENT>
 <!--AA0437E8332546539BCE11E8D36C562A-->  <AD_ELEMENT_ID><![CDATA[AA0437E8332546539BCE11E8D36C562A]]></AD_ELEMENT_ID>
 <!--AA0437E8332546539BCE11E8D36C562A-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -31976,6 +32180,18 @@
 <!--BCCA60D6DD2C4FB78F895E745F9348C0-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--BCCA60D6DD2C4FB78F895E745F9348C0--></AD_ELEMENT>
 
+<!--BCCF3C250B0A4DC6903E3F4B28A26917--><AD_ELEMENT>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <AD_ELEMENT_ID><![CDATA[BCCF3C250B0A4DC6903E3F4B28A26917]]></AD_ELEMENT_ID>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <COLUMNNAME><![CDATA[Column3]]></COLUMNNAME>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <NAME><![CDATA[Number Of Days Overdue: Group Three]]></NAME>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group Three]]></PRINTNAME>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--BCCF3C250B0A4DC6903E3F4B28A26917--></AD_ELEMENT>
+
 <!--BD206BB6091A40A2A4F6AEE47A8266AF--><AD_ELEMENT>
 <!--BD206BB6091A40A2A4F6AEE47A8266AF-->  <AD_ELEMENT_ID><![CDATA[BD206BB6091A40A2A4F6AEE47A8266AF]]></AD_ELEMENT_ID>
 <!--BD206BB6091A40A2A4F6AEE47A8266AF-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -32356,6 +32572,18 @@
 <!--C5AAA8BD231D4072990E0C9B08D48372-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--C5AAA8BD231D4072990E0C9B08D48372--></AD_ELEMENT>
 
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB--><AD_ELEMENT>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <AD_ELEMENT_ID><![CDATA[C5C3047EEDBF42F5990FEDA75CCCA3FB]]></AD_ELEMENT_ID>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <COLUMNNAME><![CDATA[Details]]></COLUMNNAME>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <NAME><![CDATA[Show Details]]></NAME>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <PRINTNAME><![CDATA[Show Details]]></PRINTNAME>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--C5C3047EEDBF42F5990FEDA75CCCA3FB--></AD_ELEMENT>
+
 <!--C6ACAA689C7EBBDEE040007F01005838--><AD_ELEMENT>
 <!--C6ACAA689C7EBBDEE040007F01005838-->  <AD_ELEMENT_ID><![CDATA[C6ACAA689C7EBBDEE040007F01005838]]></AD_ELEMENT_ID>
 <!--C6ACAA689C7EBBDEE040007F01005838-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -33300,6 +33528,18 @@
 <!--D50985CA0CA5436ABFD922D3D68D1F59-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--D50985CA0CA5436ABFD922D3D68D1F59--></AD_ELEMENT>
 
+<!--D5121B539F7F4D659781891599F0AE80--><AD_ELEMENT>
+<!--D5121B539F7F4D659781891599F0AE80-->  <AD_ELEMENT_ID><![CDATA[D5121B539F7F4D659781891599F0AE80]]></AD_ELEMENT_ID>
+<!--D5121B539F7F4D659781891599F0AE80-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--D5121B539F7F4D659781891599F0AE80-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--D5121B539F7F4D659781891599F0AE80-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--D5121B539F7F4D659781891599F0AE80-->  <COLUMNNAME><![CDATA[ShowVoid]]></COLUMNNAME>
+<!--D5121B539F7F4D659781891599F0AE80-->  <NAME><![CDATA[Voided invoices needs to be included]]></NAME>
+<!--D5121B539F7F4D659781891599F0AE80-->  <PRINTNAME><![CDATA[Voided invoices needs to be included]]></PRINTNAME>
+<!--D5121B539F7F4D659781891599F0AE80-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--D5121B539F7F4D659781891599F0AE80-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--D5121B539F7F4D659781891599F0AE80--></AD_ELEMENT>
+
 <!--D523A78BC3797401E040007F010045B1--><AD_ELEMENT>
 <!--D523A78BC3797401E040007F010045B1-->  <AD_ELEMENT_ID><![CDATA[D523A78BC3797401E040007F010045B1]]></AD_ELEMENT_ID>
 <!--D523A78BC3797401E040007F010045B1-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -33553,6 +33793,18 @@
 <!--D7AEA610F9D56CA4E040007F0100048A-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--D7AEA610F9D56CA4E040007F0100048A--></AD_ELEMENT>
 
+<!--D7D363B69C984C8DAF72F5E46DEC4024--><AD_ELEMENT>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <AD_ELEMENT_ID><![CDATA[D7D363B69C984C8DAF72F5E46DEC4024]]></AD_ELEMENT_ID>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <COLUMNNAME><![CDATA[BusinessPartner]]></COLUMNNAME>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <NAME><![CDATA[Business Partner]]></NAME>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <PRINTNAME><![CDATA[Business Partner]]></PRINTNAME>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--D7D363B69C984C8DAF72F5E46DEC4024-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--D7D363B69C984C8DAF72F5E46DEC4024--></AD_ELEMENT>
+
 <!--D8028ED62BC34DAFBD15048D0AB458BB--><AD_ELEMENT>
 <!--D8028ED62BC34DAFBD15048D0AB458BB-->  <AD_ELEMENT_ID><![CDATA[D8028ED62BC34DAFBD15048D0AB458BB]]></AD_ELEMENT_ID>
 <!--D8028ED62BC34DAFBD15048D0AB458BB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -33676,6 +33928,18 @@
 <!--DA174D36C0B2AF43E040007F010076A9-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--DA174D36C0B2AF43E040007F010076A9--></AD_ELEMENT>
 
+<!--DA2E971FD6AE4F1B904B0562281704AB--><AD_ELEMENT>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <AD_ELEMENT_ID><![CDATA[DA2E971FD6AE4F1B904B0562281704AB]]></AD_ELEMENT_ID>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <COLUMNNAME><![CDATA[Column1]]></COLUMNNAME>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <NAME><![CDATA[Number Of Days Overdue: Group One]]></NAME>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <PRINTNAME><![CDATA[Number Of Days Overdue: Group One]]></PRINTNAME>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--DA2E971FD6AE4F1B904B0562281704AB-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--DA2E971FD6AE4F1B904B0562281704AB--></AD_ELEMENT>
+
 <!--DA64BA4D7BAC470DE040007F0100463D--><AD_ELEMENT>
 <!--DA64BA4D7BAC470DE040007F0100463D-->  <AD_ELEMENT_ID><![CDATA[DA64BA4D7BAC470DE040007F0100463D]]></AD_ELEMENT_ID>
 <!--DA64BA4D7BAC470DE040007F0100463D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -34871,6 +35135,18 @@
 <!--FAD7A4095B904B23A8A9292EEC110C6D-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
 <!--FAD7A4095B904B23A8A9292EEC110C6D--></AD_ELEMENT>
 
+<!--FAE5DB9F569548768509689F4D452A51--><AD_ELEMENT>
+<!--FAE5DB9F569548768509689F4D452A51-->  <AD_ELEMENT_ID><![CDATA[FAE5DB9F569548768509689F4D452A51]]></AD_ELEMENT_ID>
+<!--FAE5DB9F569548768509689F4D452A51-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--FAE5DB9F569548768509689F4D452A51-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--FAE5DB9F569548768509689F4D452A51-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--FAE5DB9F569548768509689F4D452A51-->  <COLUMNNAME><![CDATA[RecOrPay]]></COLUMNNAME>
+<!--FAE5DB9F569548768509689F4D452A51-->  <NAME><![CDATA[Rec Or Pay]]></NAME>
+<!--FAE5DB9F569548768509689F4D452A51-->  <PRINTNAME><![CDATA[Rec Or Pay]]></PRINTNAME>
+<!--FAE5DB9F569548768509689F4D452A51-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--FAE5DB9F569548768509689F4D452A51-->  <ISGLOSSARY><![CDATA[N]]></ISGLOSSARY>
+<!--FAE5DB9F569548768509689F4D452A51--></AD_ELEMENT>
+
 <!--FB0D51F86B9A4D8E9976BC1A224075A2--><AD_ELEMENT>
 <!--FB0D51F86B9A4D8E9976BC1A224075A2-->  <AD_ELEMENT_ID><![CDATA[FB0D51F86B9A4D8E9976BC1A224075A2]]></AD_ELEMENT_ID>
 <!--FB0D51F86B9A4D8E9976BC1A224075A2-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_FIELD.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_FIELD.xml	Thu May 25 06:12:59 2017 +0000
@@ -72131,7 +72131,7 @@
 <!--5707-->  <AD_FIELD_ID><![CDATA[5707]]></AD_FIELD_ID>
 <!--5707-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--5707-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
-<!--5707-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--5707-->  <ISACTIVE><![CDATA[N]]></ISACTIVE>
 <!--5707-->  <NAME><![CDATA[Sequence Tab]]></NAME>
 <!--5707-->  <DESCRIPTION><![CDATA[The Tab determines the Order]]></DESCRIPTION>
 <!--5707-->  <HELP><![CDATA[The Tab determines the Order.]]></HELP>
@@ -116981,7 +116981,7 @@
 <!--801108-->  <AD_FIELD_ID><![CDATA[801108]]></AD_FIELD_ID>
 <!--801108-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--801108-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
-<!--801108-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--801108-->  <ISACTIVE><![CDATA[N]]></ISACTIVE>
 <!--801108-->  <NAME><![CDATA[Master Detail Form]]></NAME>
 <!--801108-->  <DESCRIPTION><![CDATA[The form referenced in the edition command]]></DESCRIPTION>
 <!--801108-->  <HELP><![CDATA[The form referenced in the edition command]]></HELP>
@@ -116989,7 +116989,7 @@
 <!--801108-->  <AD_TAB_ID><![CDATA[106]]></AD_TAB_ID>
 <!--801108-->  <AD_COLUMN_ID><![CDATA[800880]]></AD_COLUMN_ID>
 <!--801108-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
-<!--801108-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
+<!--801108-->  <ISDISPLAYED><![CDATA[N]]></ISDISPLAYED>
 <!--801108-->  <DISPLAYLENGTH><![CDATA[44]]></DISPLAYLENGTH>
 <!--801108-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
 <!--801108-->  <SEQNO><![CDATA[200]]></SEQNO>
@@ -180779,7 +180779,7 @@
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--081A8D9AB991476EA452D2F1BD112C69-->  <NAME><![CDATA[C_Year_Close_V_ID]]></NAME>
+<!--081A8D9AB991476EA452D2F1BD112C69-->  <NAME><![CDATA[End Year Close]]></NAME>
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <AD_TAB_ID><![CDATA[97E1F35BE08840AFB1DA4FE66D329542]]></AD_TAB_ID>
 <!--081A8D9AB991476EA452D2F1BD112C69-->  <AD_COLUMN_ID><![CDATA[96D06E95BC0A44BBA5657F37BCA29350]]></AD_COLUMN_ID>
@@ -192735,7 +192735,7 @@
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <AD_COLUMN_ID><![CDATA[CD35A6659453BC17E040007F010017DB]]></AD_COLUMN_ID>
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
-<!--244ECD2DC27B4939BF9B89F44732E3DE-->  <DISPLAYLOGIC><![CDATA[@quantity@!@releasedqty@]]></DISPLAYLOGIC>
+<!--244ECD2DC27B4939BF9B89F44732E3DE-->  <DISPLAYLOGIC><![CDATA[@quantity@!@releasedqty@&@RES_Status@!'CL']]></DISPLAYLOGIC>
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <DISPLAYLENGTH><![CDATA[1]]></DISPLAYLENGTH>
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
 <!--244ECD2DC27B4939BF9B89F44732E3DE-->  <SEQNO><![CDATA[140]]></SEQNO>
@@ -212951,12 +212951,11 @@
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <AD_TAB_ID><![CDATA[180]]></AD_TAB_ID>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <AD_COLUMN_ID><![CDATA[5E02C5CF3E894313AE8EF4A35287843D]]></AD_COLUMN_ID>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
-<!--531A555CFD1F41DEBE871293A23DC9C6-->  <AD_FIELDGROUP_ID><![CDATA[AA044EC1D74D4F43A2C7CC7CE3246DC3]]></AD_FIELDGROUP_ID>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
-<!--531A555CFD1F41DEBE871293A23DC9C6-->  <DISPLAYLOGIC><![CDATA[@Returnable@='Y' & @ProductType@='S']]></DISPLAYLOGIC>
+<!--531A555CFD1F41DEBE871293A23DC9C6-->  <DISPLAYLOGIC><![CDATA[@Returnable@='Y' ]]></DISPLAYLOGIC>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <DISPLAYLENGTH><![CDATA[12]]></DISPLAYLENGTH>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
-<!--531A555CFD1F41DEBE871293A23DC9C6-->  <SEQNO><![CDATA[1270]]></SEQNO>
+<!--531A555CFD1F41DEBE871293A23DC9C6-->  <SEQNO><![CDATA[590]]></SEQNO>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--531A555CFD1F41DEBE871293A23DC9C6-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
@@ -230550,18 +230549,16 @@
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <NAME><![CDATA[Returnable]]></NAME>
-<!--6AB0D715CF1148F083F2E6C1964009C1-->  <DESCRIPTION><![CDATA[Indicates is the Service is Returnable or not]]></DESCRIPTION>
-<!--6AB0D715CF1148F083F2E6C1964009C1-->  <HELP><![CDATA[Indicates is the Service is Returnable or not]]></HELP>
+<!--6AB0D715CF1148F083F2E6C1964009C1-->  <DESCRIPTION><![CDATA[Indicates if the Product is Returnable or not]]></DESCRIPTION>
+<!--6AB0D715CF1148F083F2E6C1964009C1-->  <HELP><![CDATA[Indicates if the Product is Returnable or not]]></HELP>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <AD_TAB_ID><![CDATA[180]]></AD_TAB_ID>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <AD_COLUMN_ID><![CDATA[C93C575B07E74FAD8AAB0F49E6FDA907]]></AD_COLUMN_ID>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <IGNOREINWAD><![CDATA[N]]></IGNOREINWAD>
-<!--6AB0D715CF1148F083F2E6C1964009C1-->  <AD_FIELDGROUP_ID><![CDATA[AA044EC1D74D4F43A2C7CC7CE3246DC3]]></AD_FIELDGROUP_ID>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISDISPLAYED><![CDATA[Y]]></ISDISPLAYED>
-<!--6AB0D715CF1148F083F2E6C1964009C1-->  <DISPLAYLOGIC><![CDATA[@ProductType@='S']]></DISPLAYLOGIC>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <DISPLAYLENGTH><![CDATA[1]]></DISPLAYLENGTH>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
-<!--6AB0D715CF1148F083F2E6C1964009C1-->  <SEQNO><![CDATA[1260]]></SEQNO>
+<!--6AB0D715CF1148F083F2E6C1964009C1-->  <SEQNO><![CDATA[580]]></SEQNO>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--6AB0D715CF1148F083F2E6C1964009C1-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
@@ -255086,7 +255083,7 @@
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--9032F35F112B4FA9A57DE6BD59260E91-->  <NAME><![CDATA[C_Year_Close_V_ID]]></NAME>
+<!--9032F35F112B4FA9A57DE6BD59260E91-->  <NAME><![CDATA[End Year Close]]></NAME>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISCENTRALLYMAINTAINED><![CDATA[Y]]></ISCENTRALLYMAINTAINED>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <AD_TAB_ID><![CDATA[6A77F910DAF24EA8BE7FF3F5084FED67]]></AD_TAB_ID>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <AD_COLUMN_ID><![CDATA[BAA6CA23A3634F68944B85B9423DF8A0]]></AD_COLUMN_ID>
@@ -255094,11 +255091,10 @@
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISDISPLAYED><![CDATA[N]]></ISDISPLAYED>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <DISPLAYLENGTH><![CDATA[32]]></DISPLAYLENGTH>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
-<!--9032F35F112B4FA9A57DE6BD59260E91-->  <SEQNO><![CDATA[30]]></SEQNO>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
-<!--9032F35F112B4FA9A57DE6BD59260E91-->  <SHOWINRELATION><![CDATA[Y]]></SHOWINRELATION>
+<!--9032F35F112B4FA9A57DE6BD59260E91-->  <SHOWINRELATION><![CDATA[N]]></SHOWINRELATION>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <ISFIRSTFOCUSEDFIELD><![CDATA[N]]></ISFIRSTFOCUSEDFIELD>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--9032F35F112B4FA9A57DE6BD59260E91-->  <STARTINODDCOLUMN><![CDATA[N]]></STARTINODDCOLUMN>
@@ -313911,6 +313907,7 @@
 <!--FD0D66CE5B74096DE040007F010024B1-->  <ISDISPLAYED><![CDATA[N]]></ISDISPLAYED>
 <!--FD0D66CE5B74096DE040007F010024B1-->  <DISPLAYLENGTH><![CDATA[32]]></DISPLAYLENGTH>
 <!--FD0D66CE5B74096DE040007F010024B1-->  <ISREADONLY><![CDATA[N]]></ISREADONLY>
+<!--FD0D66CE5B74096DE040007F010024B1-->  <SEQNO><![CDATA[15]]></SEQNO>
 <!--FD0D66CE5B74096DE040007F010024B1-->  <ISSAMELINE><![CDATA[N]]></ISSAMELINE>
 <!--FD0D66CE5B74096DE040007F010024B1-->  <ISFIELDONLY><![CDATA[N]]></ISFIELDONLY>
 <!--FD0D66CE5B74096DE040007F010024B1-->  <ISENCRYPTED><![CDATA[N]]></ISENCRYPTED>
--- a/model/src-db/database/sourcedata/AD_MENU.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MENU.xml	Thu May 25 06:12:59 2017 +0000
@@ -4624,6 +4624,20 @@
 <!--134C41C58C8945FAB0C18D88B33C08FE-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
 <!--134C41C58C8945FAB0C18D88B33C08FE--></AD_MENU>
 
+<!--17E054F552B443C5B3438B7E38FDD09D--><AD_MENU>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <AD_MENU_ID><![CDATA[17E054F552B443C5B3438B7E38FDD09D]]></AD_MENU_ID>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <NAME><![CDATA[Cashflow Forecast Report]]></NAME>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <DESCRIPTION><![CDATA[Cashflow Forecast]]></DESCRIPTION>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <ISSUMMARY><![CDATA[N]]></ISSUMMARY>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <ACTION><![CDATA[OBUIAPP_Process]]></ACTION>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
+<!--17E054F552B443C5B3438B7E38FDD09D-->  <EM_OBUIAPP_PROCESS_ID><![CDATA[1B0BF927933A4F41A73739CB6E4A9AD0]]></EM_OBUIAPP_PROCESS_ID>
+<!--17E054F552B443C5B3438B7E38FDD09D--></AD_MENU>
+
 <!--1A99A1553A0F4EF1AF5EB20F69238C2E--><AD_MENU>
 <!--1A99A1553A0F4EF1AF5EB20F69238C2E-->  <AD_MENU_ID><![CDATA[1A99A1553A0F4EF1AF5EB20F69238C2E]]></AD_MENU_ID>
 <!--1A99A1553A0F4EF1AF5EB20F69238C2E-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -5159,6 +5173,20 @@
 <!--B362D98BEA924E0A9424546BBF7FF6C4-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
 <!--B362D98BEA924E0A9424546BBF7FF6C4--></AD_MENU>
 
+<!--B6D984F9FEFB412D827A37BACF2F1D66--><AD_MENU>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <AD_MENU_ID><![CDATA[B6D984F9FEFB412D827A37BACF2F1D66]]></AD_MENU_ID>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <NAME><![CDATA[Payables Aging Schedule]]></NAME>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <DESCRIPTION><![CDATA[Payables Aging Schedule]]></DESCRIPTION>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <ISSUMMARY><![CDATA[N]]></ISSUMMARY>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <ACTION><![CDATA[OBUIAPP_Process]]></ACTION>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
+<!--B6D984F9FEFB412D827A37BACF2F1D66-->  <EM_OBUIAPP_PROCESS_ID><![CDATA[EB4C4053F3B94A17A08D1DD7E89CEB7E]]></EM_OBUIAPP_PROCESS_ID>
+<!--B6D984F9FEFB412D827A37BACF2F1D66--></AD_MENU>
+
 <!--B73A1BE38C6F4F4BB17A3B6FA8C3293E--><AD_MENU>
 <!--B73A1BE38C6F4F4BB17A3B6FA8C3293E-->  <AD_MENU_ID><![CDATA[B73A1BE38C6F4F4BB17A3B6FA8C3293E]]></AD_MENU_ID>
 <!--B73A1BE38C6F4F4BB17A3B6FA8C3293E-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -5295,6 +5323,20 @@
 <!--C62EBC52C8DF463B9B720D52F250A8CF-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
 <!--C62EBC52C8DF463B9B720D52F250A8CF--></AD_MENU>
 
+<!--CC226771DE354AEEAA5D69F696F1A676--><AD_MENU>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <AD_MENU_ID><![CDATA[CC226771DE354AEEAA5D69F696F1A676]]></AD_MENU_ID>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <NAME><![CDATA[Receivables Aging Schedule]]></NAME>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <DESCRIPTION><![CDATA[Receivables Aging Schedule]]></DESCRIPTION>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <ISSUMMARY><![CDATA[N]]></ISSUMMARY>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <ACTION><![CDATA[OBUIAPP_Process]]></ACTION>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <OPENLINKINBROWSER><![CDATA[N]]></OPENLINKINBROWSER>
+<!--CC226771DE354AEEAA5D69F696F1A676-->  <EM_OBUIAPP_PROCESS_ID><![CDATA[0D37A9F6109549DEB058373EF2DAEB6A]]></EM_OBUIAPP_PROCESS_ID>
+<!--CC226771DE354AEEAA5D69F696F1A676--></AD_MENU>
+
 <!--CC8E287A0B0743D69C53D8F678F9AD41--><AD_MENU>
 <!--CC8E287A0B0743D69C53D8F678F9AD41-->  <AD_MENU_ID><![CDATA[CC8E287A0B0743D69C53D8F678F9AD41]]></AD_MENU_ID>
 <!--CC8E287A0B0743D69C53D8F678F9AD41-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_MESSAGE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MESSAGE.xml	Thu May 25 06:12:59 2017 +0000
@@ -9377,7 +9377,7 @@
 <!--800191-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--800191-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--800191-->  <VALUE><![CDATA[notColumnInQuery]]></VALUE>
-<!--800191-->  <MSGTEXT><![CDATA[Needed columns are not in query:]]></MSGTEXT>
+<!--800191-->  <MSGTEXT><![CDATA[Needed columns are not in query: ]]></MSGTEXT>
 <!--800191-->  <MSGTYPE><![CDATA[E]]></MSGTYPE>
 <!--800191-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--800191-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
@@ -16391,6 +16391,18 @@
 <!--104A1B3C8B6446FA8F75225ADE49820D-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--104A1B3C8B6446FA8F75225ADE49820D--></AD_MESSAGE>
 
+<!--10A9180DF8404DE8AADE87D62AD8D321--><AD_MESSAGE>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <AD_MESSAGE_ID><![CDATA[10A9180DF8404DE8AADE87D62AD8D321]]></AD_MESSAGE_ID>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <VALUE><![CDATA[AGING_ORAS]]></VALUE>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <MSGTEXT><![CDATA[Receivables Aging Schedule]]></MSGTEXT>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <MSGTYPE><![CDATA[M]]></MSGTYPE>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--10A9180DF8404DE8AADE87D62AD8D321-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--10A9180DF8404DE8AADE87D62AD8D321--></AD_MESSAGE>
+
 <!--10E779E8F227496B86B3136A09EB6043--><AD_MESSAGE>
 <!--10E779E8F227496B86B3136A09EB6043-->  <AD_MESSAGE_ID><![CDATA[10E779E8F227496B86B3136A09EB6043]]></AD_MESSAGE_ID>
 <!--10E779E8F227496B86B3136A09EB6043-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -17683,6 +17695,18 @@
 <!--272961BF12DB4930A0F8EDDADE8827CA-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--272961BF12DB4930A0F8EDDADE8827CA--></AD_MESSAGE>
 
+<!--27D70A51233E44C9B1319F3BE1453507--><AD_MESSAGE>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <AD_MESSAGE_ID><![CDATA[27D70A51233E44C9B1319F3BE1453507]]></AD_MESSAGE_ID>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <VALUE><![CDATA[Home_Purpose_Tooltip]]></VALUE>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <MSGTEXT><![CDATA[Instance purpose is unknown.]]></MSGTEXT>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <MSGTYPE><![CDATA[C]]></MSGTYPE>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--27D70A51233E44C9B1319F3BE1453507-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--27D70A51233E44C9B1319F3BE1453507--></AD_MESSAGE>
+
 <!--27E849F814F44C49B92DE060C2E12074--><AD_MESSAGE>
 <!--27E849F814F44C49B92DE060C2E12074-->  <AD_MESSAGE_ID><![CDATA[27E849F814F44C49B92DE060C2E12074]]></AD_MESSAGE_ID>
 <!--27E849F814F44C49B92DE060C2E12074-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -17875,6 +17899,18 @@
 <!--2C3304D1DF4C4709A298FD8DCBCB61FE-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--2C3304D1DF4C4709A298FD8DCBCB61FE--></AD_MESSAGE>
 
+<!--2C36998207C542C5ABFA4E8D2C0101CF--><AD_MESSAGE>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <AD_MESSAGE_ID><![CDATA[2C36998207C542C5ABFA4E8D2C0101CF]]></AD_MESSAGE_ID>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <VALUE><![CDATA[OBUIAPP_OverdueNotValid]]></VALUE>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <MSGTEXT><![CDATA[Overdue days range is not valid]]></MSGTEXT>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <MSGTYPE><![CDATA[E]]></MSGTYPE>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--2C36998207C542C5ABFA4E8D2C0101CF-->  <ISINCLUDEINI18N><![CDATA[Y]]></ISINCLUDEINI18N>
+<!--2C36998207C542C5ABFA4E8D2C0101CF--></AD_MESSAGE>
+
 <!--2C4B3517005F4CDAAD3D72202314EBA9--><AD_MESSAGE>
 <!--2C4B3517005F4CDAAD3D72202314EBA9-->  <AD_MESSAGE_ID><![CDATA[2C4B3517005F4CDAAD3D72202314EBA9]]></AD_MESSAGE_ID>
 <!--2C4B3517005F4CDAAD3D72202314EBA9-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -21046,6 +21082,18 @@
 <!--6CB5276BCE5B473B8FF9FD86CFC82247-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--6CB5276BCE5B473B8FF9FD86CFC82247--></AD_MESSAGE>
 
+<!--6CC478903B6A4A358A787E38FA82B918--><AD_MESSAGE>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <AD_MESSAGE_ID><![CDATA[6CC478903B6A4A358A787E38FA82B918]]></AD_MESSAGE_ID>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <VALUE><![CDATA[AGING_PAS]]></VALUE>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <MSGTEXT><![CDATA[Payables Aging Schedule]]></MSGTEXT>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <MSGTYPE><![CDATA[M]]></MSGTYPE>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--6CC478903B6A4A358A787E38FA82B918-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--6CC478903B6A4A358A787E38FA82B918--></AD_MESSAGE>
+
 <!--6D2758613C5F44AF9204D818EB0085C8--><AD_MESSAGE>
 <!--6D2758613C5F44AF9204D818EB0085C8-->  <AD_MESSAGE_ID><![CDATA[6D2758613C5F44AF9204D818EB0085C8]]></AD_MESSAGE_ID>
 <!--6D2758613C5F44AF9204D818EB0085C8-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -22938,6 +22986,18 @@
 <!--926CA161FD5F49E5A993BED838A423D6-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--926CA161FD5F49E5A993BED838A423D6--></AD_MESSAGE>
 
+<!--928EB0B49A2445E1B024AA4AA19624FF--><AD_MESSAGE>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <AD_MESSAGE_ID><![CDATA[928EB0B49A2445E1B024AA4AA19624FF]]></AD_MESSAGE_ID>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <VALUE><![CDATA[AGING_PASD]]></VALUE>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <MSGTEXT><![CDATA[Payables Aging Schedule Details]]></MSGTEXT>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <MSGTYPE><![CDATA[M]]></MSGTYPE>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--928EB0B49A2445E1B024AA4AA19624FF-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--928EB0B49A2445E1B024AA4AA19624FF--></AD_MESSAGE>
+
 <!--92B1EEF0AB18416DB602DD1B8CE55ACE--><AD_MESSAGE>
 <!--92B1EEF0AB18416DB602DD1B8CE55ACE-->  <AD_MESSAGE_ID><![CDATA[92B1EEF0AB18416DB602DD1B8CE55ACE]]></AD_MESSAGE_ID>
 <!--92B1EEF0AB18416DB602DD1B8CE55ACE-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -24767,6 +24827,18 @@
 <!--B9EE1302AB724B3FA76024DB096412EE-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--B9EE1302AB724B3FA76024DB096412EE--></AD_MESSAGE>
 
+<!--BA67D141662B401C86DEE35102A9ABA7--><AD_MESSAGE>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <AD_MESSAGE_ID><![CDATA[BA67D141662B401C86DEE35102A9ABA7]]></AD_MESSAGE_ID>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <VALUE><![CDATA[ReportsLimit]]></VALUE>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <MSGTEXT><![CDATA[The filtering criteria you have specified for this report return a number of rows that exceeds the maximum allowed. The limit of rows to display in a report is @limit@. Please, use more selective filtering criteria and execute the report again.]]></MSGTEXT>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <MSGTYPE><![CDATA[I]]></MSGTYPE>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--BA67D141662B401C86DEE35102A9ABA7-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--BA67D141662B401C86DEE35102A9ABA7--></AD_MESSAGE>
+
 <!--BAD33CDEBE2547A9A2FF7E87DA0B4C38--><AD_MESSAGE>
 <!--BAD33CDEBE2547A9A2FF7E87DA0B4C38-->  <AD_MESSAGE_ID><![CDATA[BAD33CDEBE2547A9A2FF7E87DA0B4C38]]></AD_MESSAGE_ID>
 <!--BAD33CDEBE2547A9A2FF7E87DA0B4C38-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -27823,6 +27895,18 @@
 <!--F977FE65113F43B0ADD5D6BF3E4819A1-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
 <!--F977FE65113F43B0ADD5D6BF3E4819A1--></AD_MESSAGE>
 
+<!--F98B965275EB48DA96F763AFF2C9D457--><AD_MESSAGE>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <AD_MESSAGE_ID><![CDATA[F98B965275EB48DA96F763AFF2C9D457]]></AD_MESSAGE_ID>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <VALUE><![CDATA[AGING_ORASD]]></VALUE>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <MSGTEXT><![CDATA[Receivables Aging Schedule Details]]></MSGTEXT>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <MSGTYPE><![CDATA[M]]></MSGTYPE>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--F98B965275EB48DA96F763AFF2C9D457-->  <ISINCLUDEINI18N><![CDATA[N]]></ISINCLUDEINI18N>
+<!--F98B965275EB48DA96F763AFF2C9D457--></AD_MESSAGE>
+
 <!--FA5C4E4CAED74DEFA58E298F8771E547--><AD_MESSAGE>
 <!--FA5C4E4CAED74DEFA58E298F8771E547-->  <AD_MESSAGE_ID><![CDATA[FA5C4E4CAED74DEFA58E298F8771E547]]></AD_MESSAGE_ID>
 <!--FA5C4E4CAED74DEFA58E298F8771E547-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_MODEL_OBJECT.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MODEL_OBJECT.xml	Thu May 25 06:12:59 2017 +0000
@@ -900,6 +900,18 @@
 <!--800665-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
 <!--800665--></AD_MODEL_OBJECT>
 
+<!--800666--><AD_MODEL_OBJECT>
+<!--800666-->  <AD_MODEL_OBJECT_ID><![CDATA[800666]]></AD_MODEL_OBJECT_ID>
+<!--800666-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--800666-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--800666-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--800666-->  <ACTION><![CDATA[X]]></ACTION>
+<!--800666-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.utility.Log]]></CLASSNAME>
+<!--800666-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--800666-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--800666-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--800666--></AD_MODEL_OBJECT>
+
 <!--800667--><AD_MODEL_OBJECT>
 <!--800667-->  <AD_MODEL_OBJECT_ID><![CDATA[800667]]></AD_MODEL_OBJECT_ID>
 <!--800667-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -912,6 +924,18 @@
 <!--800667-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
 <!--800667--></AD_MODEL_OBJECT>
 
+<!--800668--><AD_MODEL_OBJECT>
+<!--800668-->  <AD_MODEL_OBJECT_ID><![CDATA[800668]]></AD_MODEL_OBJECT_ID>
+<!--800668-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--800668-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--800668-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--800668-->  <ACTION><![CDATA[X]]></ACTION>
+<!--800668-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.utility.Home]]></CLASSNAME>
+<!--800668-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--800668-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--800668-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--800668--></AD_MODEL_OBJECT>
+
 <!--800669--><AD_MODEL_OBJECT>
 <!--800669-->  <AD_MODEL_OBJECT_ID><![CDATA[800669]]></AD_MODEL_OBJECT_ID>
 <!--800669-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -1781,11 +1805,12 @@
 <!--801168-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--801168-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--801168-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--801168-->  <ACTION><![CDATA[C]]></ACTION>
+<!--801168-->  <ACTION><![CDATA[M]]></ACTION>
 <!--801168-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.ad_callouts.SL_MInOutTraceReports]]></CLASSNAME>
 <!--801168-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
-<!--801168-->  <AD_CALLOUT_ID><![CDATA[800007]]></AD_CALLOUT_ID>
+<!--801168-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--801168-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--801168-->  <NAME><![CDATA[Manual callout for Traceability Report]]></NAME>
 <!--801168--></AD_MODEL_OBJECT>
 
 <!--801237--><AD_MODEL_OBJECT>
@@ -2016,6 +2041,18 @@
 <!--801418-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
 <!--801418--></AD_MODEL_OBJECT>
 
+<!--801419--><AD_MODEL_OBJECT>
+<!--801419-->  <AD_MODEL_OBJECT_ID><![CDATA[801419]]></AD_MODEL_OBJECT_ID>
+<!--801419-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--801419-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--801419-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--801419-->  <ACTION><![CDATA[X]]></ACTION>
+<!--801419-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.ad_forms.Role]]></CLASSNAME>
+<!--801419-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--801419-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--801419-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--801419--></AD_MODEL_OBJECT>
+
 <!--801428--><AD_MODEL_OBJECT>
 <!--801428-->  <AD_MODEL_OBJECT_ID><![CDATA[801428]]></AD_MODEL_OBJECT_ID>
 <!--801428-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -2064,6 +2101,18 @@
 <!--801431-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
 <!--801431--></AD_MODEL_OBJECT>
 
+<!--801432--><AD_MODEL_OBJECT>
+<!--801432-->  <AD_MODEL_OBJECT_ID><![CDATA[801432]]></AD_MODEL_OBJECT_ID>
+<!--801432-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--801432-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--801432-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--801432-->  <ACTION><![CDATA[X]]></ACTION>
+<!--801432-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.ad_forms.AlertManagement]]></CLASSNAME>
+<!--801432-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--801432-->  <AD_FORM_ID><![CDATA[800016]]></AD_FORM_ID>
+<!--801432-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--801432--></AD_MODEL_OBJECT>
+
 <!--801433--><AD_MODEL_OBJECT>
 <!--801433-->  <AD_MODEL_OBJECT_ID><![CDATA[801433]]></AD_MODEL_OBJECT_ID>
 <!--801433-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -4832,6 +4881,18 @@
 <!--E656BA54FAED4AC2885DDC63F9748C5D-->  <OBJECT_TYPE><![CDATA[P]]></OBJECT_TYPE>
 <!--E656BA54FAED4AC2885DDC63F9748C5D--></AD_MODEL_OBJECT>
 
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2--><AD_MODEL_OBJECT>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <AD_MODEL_OBJECT_ID><![CDATA[E8FC8F30DC7D4C2AB2113E149D9E13F2]]></AD_MODEL_OBJECT_ID>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <ACTION><![CDATA[C]]></ACTION>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <CLASSNAME><![CDATA[org.openbravo.erpCommon.ad_callouts.SE_Amount_Transaction]]></CLASSNAME>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <AD_CALLOUT_ID><![CDATA[57752E7EA3D1463DBEF39996BAEBAB98]]></AD_CALLOUT_ID>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2-->  <OBJECT_TYPE><![CDATA[S]]></OBJECT_TYPE>
+<!--E8FC8F30DC7D4C2AB2113E149D9E13F2--></AD_MODEL_OBJECT>
+
 <!--E9352B3E424544B285B83E9950931164--><AD_MODEL_OBJECT>
 <!--E9352B3E424544B285B83E9950931164-->  <AD_MODEL_OBJECT_ID><![CDATA[E9352B3E424544B285B83E9950931164]]></AD_MODEL_OBJECT_ID>
 <!--E9352B3E424544B285B83E9950931164-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_MODEL_OBJECT_MAPPING.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MODEL_OBJECT_MAPPING.xml	Thu May 25 06:12:59 2017 +0000
@@ -730,6 +730,16 @@
 <!--800840-->  <ISDEFAULT><![CDATA[N]]></ISDEFAULT>
 <!--800840--></AD_MODEL_OBJECT_MAPPING>
 
+<!--800841--><AD_MODEL_OBJECT_MAPPING>
+<!--800841-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[800841]]></AD_MODEL_OBJECT_MAPPING_ID>
+<!--800841-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--800841-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--800841-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--800841-->  <AD_MODEL_OBJECT_ID><![CDATA[800666]]></AD_MODEL_OBJECT_ID>
+<!--800841-->  <MAPPINGNAME><![CDATA[/utility/Log.html]]></MAPPINGNAME>
+<!--800841-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--800841--></AD_MODEL_OBJECT_MAPPING>
+
 <!--800842--><AD_MODEL_OBJECT_MAPPING>
 <!--800842-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[800842]]></AD_MODEL_OBJECT_MAPPING_ID>
 <!--800842-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -740,6 +750,16 @@
 <!--800842-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
 <!--800842--></AD_MODEL_OBJECT_MAPPING>
 
+<!--800843--><AD_MODEL_OBJECT_MAPPING>
+<!--800843-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[800843]]></AD_MODEL_OBJECT_MAPPING_ID>
+<!--800843-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--800843-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--800843-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--800843-->  <AD_MODEL_OBJECT_ID><![CDATA[800668]]></AD_MODEL_OBJECT_ID>
+<!--800843-->  <MAPPINGNAME><![CDATA[/utility/Home.html]]></MAPPINGNAME>
+<!--800843-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--800843--></AD_MODEL_OBJECT_MAPPING>
+
 <!--800844--><AD_MODEL_OBJECT_MAPPING>
 <!--800844-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[800844]]></AD_MODEL_OBJECT_MAPPING_ID>
 <!--800844-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -2100,6 +2120,16 @@
 <!--802155-->  <ISDEFAULT><![CDATA[N]]></ISDEFAULT>
 <!--802155--></AD_MODEL_OBJECT_MAPPING>
 
+<!--802156--><AD_MODEL_OBJECT_MAPPING>
+<!--802156-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[802156]]></AD_MODEL_OBJECT_MAPPING_ID>
+<!--802156-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--802156-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--802156-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--802156-->  <AD_MODEL_OBJECT_ID><![CDATA[801419]]></AD_MODEL_OBJECT_ID>
+<!--802156-->  <MAPPINGNAME><![CDATA[/ad_forms/Role.html]]></MAPPINGNAME>
+<!--802156-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--802156--></AD_MODEL_OBJECT_MAPPING>
+
 <!--802174--><AD_MODEL_OBJECT_MAPPING>
 <!--802174-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[802174]]></AD_MODEL_OBJECT_MAPPING_ID>
 <!--802174-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -2140,6 +2170,16 @@
 <!--802177-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
 <!--802177--></AD_MODEL_OBJECT_MAPPING>
 
+<!--802178--><AD_MODEL_OBJECT_MAPPING>
+<!--802178-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[802178]]></AD_MODEL_OBJECT_MAPPING_ID>
+<!--802178-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--802178-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--802178-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--802178-->  <AD_MODEL_OBJECT_ID><![CDATA[801432]]></AD_MODEL_OBJECT_ID>
+<!--802178-->  <MAPPINGNAME><![CDATA[/ad_forms/AlertManagement.html]]></MAPPINGNAME>
+<!--802178-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--802178--></AD_MODEL_OBJECT_MAPPING>
+
 <!--802179--><AD_MODEL_OBJECT_MAPPING>
 <!--802179-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[802179]]></AD_MODEL_OBJECT_MAPPING_ID>
 <!--802179-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
@@ -4490,6 +4530,16 @@
 <!--CA9DD61616584938849A97BBFBA87D60-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
 <!--CA9DD61616584938849A97BBFBA87D60--></AD_MODEL_OBJECT_MAPPING>
 
+<!--CADE2BEAA9CA47D098FF8BBF47564B79--><AD_MODEL_OBJECT_MAPPING>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[CADE2BEAA9CA47D098FF8BBF47564B79]]></AD_MODEL_OBJECT_MAPPING_ID>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <AD_MODEL_OBJECT_ID><![CDATA[E8FC8F30DC7D4C2AB2113E149D9E13F2]]></AD_MODEL_OBJECT_ID>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <MAPPINGNAME><![CDATA[/ad_callouts/SE_Amount_Transaction.html]]></MAPPINGNAME>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79-->  <ISDEFAULT><![CDATA[Y]]></ISDEFAULT>
+<!--CADE2BEAA9CA47D098FF8BBF47564B79--></AD_MODEL_OBJECT_MAPPING>
+
 <!--CB0093CB5B34AA24E040007F010049A5--><AD_MODEL_OBJECT_MAPPING>
 <!--CB0093CB5B34AA24E040007F010049A5-->  <AD_MODEL_OBJECT_MAPPING_ID><![CDATA[CB0093CB5B34AA24E040007F010049A5]]></AD_MODEL_OBJECT_MAPPING_ID>
 <!--CB0093CB5B34AA24E040007F010049A5-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_MODEL_OBJECT_PARA.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MODEL_OBJECT_PARA.xml	Thu May 25 06:12:59 2017 +0000
@@ -141,6 +141,17 @@
 <!--8AD44BF5C47B41F384661FC8F9ABD954-->  <VALUE><![CDATA[${webPath}]]></VALUE>
 <!--8AD44BF5C47B41F384661FC8F9ABD954--></AD_MODEL_OBJECT_PARA>
 
+<!--916D71F114CD45958A7EDCD7887EAE73--><AD_MODEL_OBJECT_PARA>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <AD_MODEL_OBJECT_PARA_ID><![CDATA[916D71F114CD45958A7EDCD7887EAE73]]></AD_MODEL_OBJECT_PARA_ID>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <AD_MODEL_OBJECT_ID><![CDATA[F22C501A5088415DBD7D9DC2134D5DA9]]></AD_MODEL_OBJECT_ID>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <LINE><![CDATA[140]]></LINE>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <NAME><![CDATA[ServletSinIdentificar]]></NAME>
+<!--916D71F114CD45958A7EDCD7887EAE73-->  <VALUE><![CDATA[/utility/Log.html]]></VALUE>
+<!--916D71F114CD45958A7EDCD7887EAE73--></AD_MODEL_OBJECT_PARA>
+
 <!--91960135229C4B77B686CA14A23254F4--><AD_MODEL_OBJECT_PARA>
 <!--91960135229C4B77B686CA14A23254F4-->  <AD_MODEL_OBJECT_PARA_ID><![CDATA[91960135229C4B77B686CA14A23254F4]]></AD_MODEL_OBJECT_PARA_ID>
 <!--91960135229C4B77B686CA14A23254F4-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
--- a/model/src-db/database/sourcedata/AD_MODULE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_MODULE.xml	Thu May 25 06:12:59 2017 +0000
@@ -6,7 +6,7 @@
 <!--0-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--0-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
 <!--0-->  <NAME><![CDATA[Core]]></NAME>
-<!--0-->  <VERSION><![CDATA[3.0.31087]]></VERSION>
+<!--0-->  <VERSION><![CDATA[3.0.31787]]></VERSION>
 <!--0-->  <DESCRIPTION><![CDATA[Core module is the base one]]></DESCRIPTION>
 <!--0-->  <HELP><![CDATA[Core module is the base one, all developments in core are included as part of the standard Openbravo ERP.]]></HELP>
 <!--0-->  <URL><![CDATA[www.openbravo.com]]></URL>
@@ -22,7 +22,7 @@
 <!--0-->  <ISTRANSLATIONMODULE><![CDATA[N]]></ISTRANSLATIONMODULE>
 <!--0-->  <HASREFERENCEDATA><![CDATA[Y]]></HASREFERENCEDATA>
 <!--0-->  <REFERENCEDATAINFO><![CDATA[Standard document types for orders, invoices, etc. and settings]]></REFERENCEDATAINFO>
-<!--0-->  <VERSION_LABEL><![CDATA[PR17Q1]]></VERSION_LABEL>
+<!--0-->  <VERSION_LABEL><![CDATA[PR17Q2]]></VERSION_LABEL>
 <!--0-->  <ISCOMMERCIAL><![CDATA[N]]></ISCOMMERCIAL>
 <!--0-->  <ISTRIALALLOWED><![CDATA[N]]></ISTRIALALLOWED>
 <!--0--></AD_MODULE>
--- a/model/src-db/database/sourcedata/AD_PREFERENCE.xml	Mon May 15 08:34:27 2017 +0200
+++ b/model/src-db/database/sourcedata/AD_PREFERENCE.xml	Thu May 25 06:12:59 2017 +0000
@@ -24,6 +24,1722 @@
 <!--9B4A5EB695FDA841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
 <!--9B4A5EB695FDA841E040A8C0E1077381--></AD_PREFERENCE>
 
+<!--9B4A5EB696D6A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4A5EB696D6A841E040A8C0E1077381]]></AD_PREFERENCE_ID>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <ATTRIBUTE><![CDATA[ModalProcess124]]></ATTRIBUTE>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <VALUE><![CDATA[N]]></VALUE>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <ISPROPERTYLIST><![CDATA[N]]></ISPROPERTYLIST>
+<!--9B4A5EB696D6A841E040A8C0E1077381-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>
+<!--9B4A5EB696D6A841E040A8C0E1077381--></AD_PREFERENCE>
+
+<!--9B4A5EB696D7A841E040A8C0E1077381--><AD_PREFERENCE>
+<!--9B4A5EB696D7A841E040A8C0E1077381-->  <AD_PREFERENCE_ID><![CDATA[9B4