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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0016417
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 07. Sales managementmajoralways2011-03-22 12:212012-04-02 06:12
ReporterXpand-ITView Statuspublic 
Assigned ToSandrahuguet 
PriorityurgentResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revisione630342dafb1
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionpiSCM revision 
Review Assigned To
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0016417: Ad_Sequence_Doc function increments the sequence for all clients

DescriptionAd_Sequence_Doc does not take into consideration the p_ad_client_id argument when updating CurrentNext in AD_Sequence table.
Proposed SolutionReplace:

  IF p_Update_Next='Y' THEN
    UPDATE AD_Sequence
      SET CurrentNext=CurrentNext + IncrementNo, Updated=TO_DATE(NOW())
    WHERE Name=p_SequenceName;
  END IF;
  p_DocumentNo:=COALESCE(v_Prefix, '') || v_NextNo || COALESCE(v_Suffix, '') ;


By:


  IF p_Update_Next='Y' THEN
    UPDATE AD_Sequence
      SET CurrentNext=CurrentNext + IncrementNo, Updated=TO_DATE(NOW())
    WHERE Name=p_SequenceName
    AND ad_client_id=p_ad_client_id;
  END IF;
  p_DocumentNo:=COALESCE(v_Prefix, '') || v_NextNo || COALESCE(v_Suffix, '') ;
TagsVMA-Reviewed
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0046653)
Sandrahuguet (developer)
2012-03-22 13:12

Test Plan:

F&B Client
-Create a Sales Invoice
  -Organization: F&B España, S.A.
  -Transaction Document: AR Invoice

QA Testing
-Create a Sales Invoice
  -Organization: Spain
  -Transaction Document: AR Invoice

F&B Client
-Create a Sales Invoice
  -Organization: F&B España, S.A.
  -Transaction Document: AR Invoice

You can see that Document No. has a different sequence for each client
(0046760)
vmromanos (manager)
2012-03-27 13:06

Alternative test plan:
Run the following queries directly into the database:

1. SELECT CurrentNext, Prefix, Suffix, ad_client_id
FROM AD_Sequence
WHERE Name='AR Invoice' AND IsActive='Y' AND IsTableID='N' AND IsAutoSequence='Y'

2. Remember the CurrentNext values

3. Select AD_Sequence_Doc('AR Invoice', 'FF8080812AFBCB14012AFBD3E373001F', 'Y') from dual;

4. SELECT CurrentNext, Prefix, Suffix, ad_client_id
FROM AD_Sequence
WHERE Name='AR Invoice' AND IsActive='Y' AND IsTableID='N' AND IsAutoSequence='Y'

5. Ensure the CurrentNext has been incremented only for the 'FF8080812AFBCB14012AFBD3E373001F' client
(0046761)
hgbot (developer)
2012-03-27 13:09

Repository: erp/devel/pi
Changeset: e630342dafb1ebab21e85100c0aa082a27c97ffd
Author: Sandra Huguet <sandra.huguet <at> openbravo.com>
Date: Thu Mar 22 12:34:56 2012 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/e630342dafb1ebab21e85100c0aa082a27c97ffd [^]

Fixed issue 16417 Incremets the sequence number at correct form in Ad_Sequence_Doc

---
M src-db/database/model/functions/AD_SEQUENCE_DOC.xml
---
(0046762)
vmromanos (manager)
2012-03-27 13:09

code review + testing OK
(0047238)
hudsonbot (developer)
2012-04-02 06:12

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/7814864461ac [^]

Maturity status: Test

- Issue History
Date Modified Username Field Change
2011-03-22 12:21 Xpand-IT New Issue
2011-03-22 12:21 Xpand-IT Assigned To => adrianromero
2011-03-22 12:21 Xpand-IT Modules => Core
2011-06-03 10:58 dalsasua Assigned To adrianromero => dalsasua
2011-07-20 18:16 dalsasua Assigned To dalsasua => jonalegriaesarte
2011-09-19 22:21 psarobe Status new => scheduled
2011-09-19 22:21 psarobe version => pi
2012-02-15 19:04 iciordia Assigned To jonalegriaesarte => vmromanos
2012-02-16 16:18 vmromanos Tag Attached: VMA-Reviewed
2012-03-22 11:39 Sandrahuguet Assigned To vmromanos => Sandrahuguet
2012-03-22 13:12 Sandrahuguet Note Added: 0046653
2012-03-27 13:06 vmromanos Note Added: 0046760
2012-03-27 13:09 hgbot Checkin
2012-03-27 13:09 hgbot Note Added: 0046761
2012-03-27 13:09 hgbot Status scheduled => resolved
2012-03-27 13:09 hgbot Resolution open => fixed
2012-03-27 13:09 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/e630342dafb1ebab21e85100c0aa082a27c97ffd [^]
2012-03-27 13:09 vmromanos Note Added: 0046762
2012-03-27 13:09 vmromanos Status resolved => closed
2012-04-02 06:12 hudsonbot Checkin
2012-04-02 06:12 hudsonbot Note Added: 0047238


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker