Fixes issue 13604: payment method - financial account assignment
authorMikel Irurita <mikel.irurita@openbravo.com>
Tue, 27 Jul 2010 10:12:12 +0200
changeset 159 0628a7ed4126
parent 158 7cd643e1b56d
child 160 addbbb9ce000
Fixes issue 13604: payment method - financial account assignment
Changed name of the message (FIN_FINACC_PAYMETHOD_UN)
More meaningful message is shown now when you try to assign the same
method twice to the same financial account.
model/model/tables/FIN_FINACC_PAYMENTMETHOD.xml
model/sourcedata/AD_MESSAGE.xml
--- a/model/model/tables/FIN_FINACC_PAYMENTMETHOD.xml	Mon Jul 26 18:10:08 2010 +0200
+++ b/model/model/tables/FIN_FINACC_PAYMENTMETHOD.xml	Tue Jul 27 10:12:12 2010 +0200
@@ -131,10 +131,10 @@
       <foreign-key foreignTable="FIN_PAY_EXEC_PROCESS" name="FIN_FINACCMETH_PAYOUTEXECPROC">
         <reference local="PAYOUT_EXECUTION_PROCESS_ID" foreign="FIN_PAY_EXEC_PROCESS_ID"/>
       </foreign-key>
-      <index name="FIN_FINACC_PAYMETHOD_UNIQUEKEY" unique="true">
-        <index-column name="FIN_PAYMENTMETHOD_ID"/>
-        <index-column name="FIN_FINANCIAL_ACCOUNT_ID"/>
-      </index>
+      <unique name="FIN_FINACC_PAYMENTMETHOD_UN">
+        <unique-column name="FIN_PAYMENTMETHOD_ID"/>
+        <unique-column name="FIN_FINANCIAL_ACCOUNT_ID"/>
+      </unique>
       <check name="FIN_FINACC_METHOD_ACTIVE_CHK"><![CDATA[ISACTIVE IN ('Y', 'N')]]></check>
       <check name="FIN_FINACC_METHOD_DEPOSIT_CHK"><![CDATA[AUTOMATIC_DEPOSIT IN ('Y', 'N')]]></check>
       <check name="FIN_FINACC_METHOD_PAYMENT_CHK"><![CDATA[AUTOMATIC_PAYMENT IN ('Y', 'N')]]></check>
--- a/model/sourcedata/AD_MESSAGE.xml	Mon Jul 26 18:10:08 2010 +0200
+++ b/model/sourcedata/AD_MESSAGE.xml	Tue Jul 27 10:12:12 2010 +0200
@@ -31921,7 +31921,7 @@
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <AD_CLIENT_ID><![CDATA[0]]></AD_CLIENT_ID>
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <AD_ORG_ID><![CDATA[0]]></AD_ORG_ID>
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <ISACTIVE><![CDATA[Y]]></ISACTIVE>
-<!--968C37CD41AD45C3AD92D394CC357A90-->  <VALUE><![CDATA[FIN_FINACC_PAYMETHOD_UNIQUEKEY]]></VALUE>
+<!--968C37CD41AD45C3AD92D394CC357A90-->  <VALUE><![CDATA[FIN_FINACC_PAYMENTMETHOD_UN]]></VALUE>
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <MSGTEXT><![CDATA[There already exists a configuration defined for this Financial Account and Payment Method.]]></MSGTEXT>
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <MSGTYPE><![CDATA[E]]></MSGTYPE>
 <!--968C37CD41AD45C3AD92D394CC357A90-->  <AD_MODULE_ID><![CDATA[0]]></AD_MODULE_ID>