Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0021737
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 09. Financial managementmajorN/A2012-09-25 09:512012-09-25 16:04
ReportervmromanosView Statuspublic 
Assigned Tovmromanos 
PriorityimmediateResolutionfixedFixed in Version
StatusclosedFix in branchpiFixed in SCM revisione2de02cedf58
ProjectionnoneETAnoneTarget Version3.0MP16
OSLinux 32 bitDatabasePostgreSQLJava version1.6.0_12
OS VersionDebian 5.0Database version8.3.8Ant version1.7.0
Product VersionSCM revision 
Review Assigned Tovmromanos
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0021737: API Change request for new Bank Account Format Layout

DescriptionDue to the new Bank Account Format Layout 0021665 we have increased the length of some columns in charge of storing bank account number information.

This way we ensure that any possible bank account number can be introduced in Openbravo.

The changes are:
C_BP_BANKACCOUNT.ACCOUNTNO from 20 to 100. This column stores a generic account number. In case there is no localization module that supports a concrete bank account, the user can introduce here any possible value (for example a concatenation of a bank routing number, control digits, account number, etc.)

C_BP_BANKACCOUNT.DISPLAYEDACCOUNT from 34 to 120. This column is the one used as the official bank account number and it's automatically generated (read only) from other fields (like the generic account number, IBAN, SWIFT, or other fields introduced by a localization module)

FIN_FINANCIAL_ACCOUNT.ACCOUNTNO from 20 to 120. This column is the one used as the official bank account number and it's automatically generated (read only) from other fields (like the generic account number, IBAN, SWIFT, or other fields introduced by a localization module)



The impact of this API change should be low.
Code that can be affected is the one that expects values with the previous length and that can't manage the new one.
Steps To ReproduceSee http://builds.openbravo.com/view/try/job/try-api/1043/console [^]
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0052540)
vmromanos (manager)
2012-09-25 10:48

Only one place affected: src-db/database/model/functions/C_PROJECT_WON.xml
"Process a Winning Bid". This process is used in the Service Project window, which is not shown by default.

The C_PROJECT.ACCOUNTNO length is 20.
The process declares variable v_Accountno NVARCHAR2(20)
The following cursor gets the accountno from the C_BP_BANKACCOUNT table (length > 20)
FOR Cur_CBPBancAcct IN
            (SELECT MAX(ACCOUNTNO) AS Accountno
            FROM C_BP_BANKACCOUNT
            WHERE C_BPARTNER_ID=v_cBPartnerId
              AND ISACTIVE='Y'
            )
          LOOP
            v_Accountno:=Cur_CBPBancAcct.Accountno;
            EXIT;
          END LOOP;


After that an update is done into the C_PROJECT table:
UPDATE C_PROJECT
          SET Updated=now(),
          UpdatedBy='0',
          C_BPartner_ID=v_cBPartnerId,
          C_BPartner_Location_ID=v_cBPartnerLocationId, --Salesrep_ID = v_adUserId,
          BillTo_ID=v_billToId,
          PaymentRule=v_paymentRule,
          FIN_paymentmethod_id=v_FINpayment,
          C_Paymentterm_ID=v_cPaymenttermId,
          accountno=v_Accountno
        WHERE C_Project_ID=v_cProjectId;

This can fail in case v_Accountno length > 20


Proposed solution:
Declare v_Accountno C_BP_BANKACCOUNT.ACCOUNTNO%TYPE;
Truncate v_Accountno to 20
(0052541)
vmromanos (manager)
2012-09-25 11:14

Approved by Ismael
(0052542)
hgbot (developer)
2012-09-25 11:15

Repository: erp/devel/api-checks
Changeset: e020026239608299c99908ee446d7520f55677f7
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Tue Sep 25 11:15:23 2012 +0200
URL: http://code.openbravo.com/erp/devel/api-checks/rev/e020026239608299c99908ee446d7520f55677f7 [^]

Fixed bug 21737: API Change new Bank Account Format Layout

---
M model/src-db/database/model/tables/C_BP_BANKACCOUNT.xml
M model/src-db/database/model/tables/FIN_FINANCIAL_ACCOUNT.xml
---
(0052588)
hgbot (developer)
2012-09-25 16:03

Repository: erp/devel/api-checks
Changeset: e2de02cedf58b29fb872b97532e7ffef1795df67
Author: Víctor Martínez Romanos <victor.martinez <at> openbravo.com>
Date: Tue Sep 25 11:15:23 2012 +0200
URL: http://code.openbravo.com/erp/devel/api-checks/rev/e2de02cedf58b29fb872b97532e7ffef1795df67 [^]

Fixed bug 21737: API Change new Bank Account Format Layout

---
M model/src-db/database/model/tables/C_BP_BANKACCOUNT.xml
M model/src-db/database/model/tables/FIN_FINANCIAL_ACCOUNT.xml
---

- Issue History
Date Modified Username Field Change
2012-09-25 09:51 vmromanos New Issue
2012-09-25 09:51 vmromanos Assigned To => iciordia
2012-09-25 09:51 vmromanos Modules => Core
2012-09-25 10:48 vmromanos Note Added: 0052540
2012-09-25 11:14 vmromanos Note Added: 0052541
2012-09-25 11:14 vmromanos Status new => scheduled
2012-09-25 11:14 vmromanos Assigned To iciordia => vmromanos
2012-09-25 11:14 vmromanos fix_in_branch => pi
2012-09-25 11:15 hgbot Checkin
2012-09-25 11:15 hgbot Note Added: 0052542
2012-09-25 11:15 hgbot Status scheduled => resolved
2012-09-25 11:15 hgbot Resolution open => fixed
2012-09-25 11:15 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/api-checks/rev/e020026239608299c99908ee446d7520f55677f7 [^]
2012-09-25 12:12 vmromanos Closed by => vmromanos
2012-09-25 12:12 vmromanos Status resolved => closed
2012-09-25 16:03 hgbot Checkin
2012-09-25 16:03 hgbot Note Added: 0052588
2012-09-25 16:03 hgbot Status closed => resolved
2012-09-25 16:03 hgbot Fixed in SCM revision http://code.openbravo.com/erp/devel/api-checks/rev/e020026239608299c99908ee446d7520f55677f7 [^] => http://code.openbravo.com/erp/devel/api-checks/rev/e2de02cedf58b29fb872b97532e7ffef1795df67 [^]
2012-09-25 16:04 vmromanos Status resolved => closed


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker