IDEMPIERE-1770 created code for a non-existing column

Description

As reported by at
https://idempiere.atlassian.net/browse/IDEMPIERE-1770?focusedCommentId=26006&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-26006

With ticket code was integrated referencing a non-existing column M_InOutLineMA.returnedQty

Impact must be reviewed.

Environment

None

Activity

Show:
Deepak Pansheriya
April 19, 2016, 12:35 PM

Thanks Bayu Cahya P,I am looking on this and trying to findout issue. Can you point me to the code I should focus?

Deepak Pansheriya
April 19, 2016, 12:42 PM

Carlos/Bayu,

I reviewed code. This may be my partial review based on what I think it may be wrong. There is no field name returnedQty on M_InoutLine_MA, But that column is introduced as just pojo value loaded from function MInoutLineMA.getNonReturned function.

If you give test case and how it is failing, I can further investigate and provide you fix.

With Regards
--Deepak Pansheriya

Carlos Ruiz
April 19, 2016, 6:33 PM

thanks , I haven't checked for a failing case (don't know if that code is reached), but I think is a mistake to introduce code related to non-existing columns into core.

Deepak Pansheriya
May 19, 2016, 3:51 PM

Carlos/ Bayu Cahya P,

Thanks for reminder. I had reviewed code and it is deviation from good practice but there is no expectation to have returnedQty column on table when I wrote it. returnedQty should be calculated value.

Bayu, If you think that need to store in DB then please explain use case. I am asking as it need more efforts to keep it updated. But if there is no need to store in database, then can refactor it to not use PO object to hold it.

With Regards,
--Deepak

Fixed

Assignee

Carlos Ruiz

Reporter

Carlos Ruiz

Labels

None

Tested By

None

Priority

Major
Configure