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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0020680
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] 07. Sales managementmajoralways2012-06-05 15:572012-06-06 11:13
ReportermiruritaView Statuspublic 
Assigned Tomirurita 
PrioritynormalResolutionfixedFixed in Version3.0MP12
StatusclosedFix in branchFixed in SCM revisionb93e89d8bd60
ProjectionnoneETAnoneTarget Version
OSLinux 32 bitDatabasePostgreSQLJava version1.6.0_18
OS VersionCommunity ApplianceDatabase version8.3.9Ant version1.7.1
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

0020680: Return From Customer/To Vendor (pick&edit): error when returning a line

DescriptionWhen there is no tax loaded in the pick&edit the tax is not calculated.
As the c_tax_id is mandatory on c_orderline table the process fails.

The problem is on SRMOPickEditLines.java class.
getString("tax") return the "null" string instead of null value when there is no tax.

// tax
String taxId = selectedLine.getString("tax");
if (taxId == null) {
 ...
}


a3196480 347536 [TP-Processor7] ERROR org.hibernate.util.JDBCExceptionReporter - Batch entry 0 insert into C_OrderLine (AD_Client_ID, AD_Org_ID, IsActive, Created, CreatedBy, Updated, UpdatedBy, C_Order_ID, Line, DateOrdered, M_Product_ID, M_Warehouse_ID, DirectShip, C_UOM_ID, QtyOrdered, C_Currency_ID, PriceList, PriceActual, PriceLimit, Discount, ChargeAmt, IsDescription, PriceStd, CANCELPRICEAD, Iseditlinenetamt, M_Inoutline_ID, C_OrderLine_ID) values ('23C59575B9CF467C9620760EB255B389', 'E443A31992CB4635AFCAEABE7183CE85', 'Y', '2012-06-05 15:51:58.489000 +02:00:00', '100', '2012-06-05 15:51:58.489000 +02:00:00', '100', '84CF302B46DE43A28E4D5ED6E75E639F', '10', '2012-06-05 00:00:00.000000 +02:00:00', 'BDE2F1CF46B54EF58D33E20A230DA8D2', 'B2D40D8A5D644DD89E329DC297309055', 'N', '100', '-3', '102', '1.53', '1.53', '0', '0', '0', 'N', '1.53', 'N', 'N', '7CDC29AA7ADE4AB58B66D1C87A826574', 'DCDA26867C6E4F92AF11E9880498458C') was aborted. Call getNextException to see the cause.
a3196480 347567 [TP-Processor7] ERROR org.hibernate.util.JDBCExceptionReporter - ERROR: null value in column "c_tax_id" violates not-null constraint
a3196480 347570 [TP-Processor7] ERROR org.openbravo.common.actionhandler.SRMOPickEditLines - Could not execute JDBC batch update
org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update
    at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:96)
    at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
Steps To Reproduce1) Create a new Goods Shipment for Hoteles Buenas Noches, S.A.
2) Create a new Return for Customer for Hoteles Buenas Noches, S.A.
3) Click on Pick/Edit
4) Select goods shipment created on step 1)
5) Fully return the shipment.
6) Click on Done button
7) Error:
Could not execute JDBC batch update
Realize that the line is not inserted.
Proposed SolutionChange the comparation

// tax
String taxId = selectedLine.getString("tax");
if (taxId == null) {
 ...
}

to

if ("null".equals(taxId)) {
TagsNo tags attached.
Attached Filespng file icon Return_from_customer_Tax_null.png [^] (70,378 bytes) 2012-06-05 15:58

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0049627)
hgbot (developer)
2012-06-05 16:03

Repository: erp/devel/pi
Changeset: b93e89d8bd607fc38596295310df2831a22a3685
Author: Mikel Irurita <mikel.irurita <at> openbravo.com>
Date: Tue Jun 05 16:02:14 2012 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/b93e89d8bd607fc38596295310df2831a22a3685 [^]

Fixes issue 20680: RFC/RTV (pick&edit): error when returning a line

---
M src/org/openbravo/common/actionhandler/SRMOPickEditLines.java
---
(0049643)
psarobe (manager)
2012-06-06 11:13

Works fine

- Issue History
Date Modified Username Field Change
2012-06-05 15:57 mirurita New Issue
2012-06-05 15:57 mirurita Assigned To => mirurita
2012-06-05 15:57 mirurita Modules => Core
2012-06-05 15:58 mirurita File Added: Return_from_customer_Tax_null.png
2012-06-05 16:03 hgbot Checkin
2012-06-05 16:03 hgbot Note Added: 0049627
2012-06-05 16:03 hgbot Status new => resolved
2012-06-05 16:03 hgbot Resolution open => fixed
2012-06-05 16:03 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/b93e89d8bd607fc38596295310df2831a22a3685 [^]
2012-06-06 11:13 psarobe Note Added: 0049643
2012-06-06 11:13 psarobe Status resolved => closed
2012-06-06 11:13 psarobe Fixed in Version => 3.0MP12


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker