Fixes issue 13604: payment method - financial account assignment
authorMikel Irurita <mikel.irurita@openbravo.com>
Tue, 27 Jul 2010 10:12:49 +0200
changeset 7922 6834c4694499
parent 7921 f1b53dfc9e0d
child 7923 ff9d8e6fe070
child 7984 1df90310fec9
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.
src-db/database/model/tables/FIN_FINACC_PAYMENTMETHOD.xml
src-db/database/sourcedata/AD_MESSAGE.xml
--- a/src-db/database/model/tables/FIN_FINACC_PAYMENTMETHOD.xml	Mon Jul 26 19:27:40 2010 +0200
+++ b/src-db/database/model/tables/FIN_FINACC_PAYMENTMETHOD.xml	Tue Jul 27 10:12:49 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/src-db/database/sourcedata/AD_MESSAGE.xml	Mon Jul 26 19:27:40 2010 +0200
+++ b/src-db/database/sourcedata/AD_MESSAGE.xml	Tue Jul 27 10:12:49 2010 +0200
@@ -31932,7 +31932,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>