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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0030925
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajoralways2015-09-24 17:232015-10-19 17:23
ReporterguillermogilView Statuspublic 
Assigned Tomario_castello 
PrioritynormalResolutionfixedFixed in VersionRR16Q1
StatusclosedFix in branchFixed in SCM revision5c5d1f2807a6
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tomarvintm
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0030925: PreAddProductToOrder Hook and AddProductToOrder Hook shows the property qtyToAdd as undefined

DescriptionPreAddProductToOrder Hook and AddProductToOrder Hook shows the property qtyToAdd as undefined.
On the wiki it is defined as the QTY of the product to add:
http://wiki.openbravo.com/wiki/List_of_Hooks_in_Web_POS [^]
Steps To ReproduceOpen the developer tools.
Add a breakpoint in the callback of PreAddProductToOrder Hook.
Go to Browse tab and select a product.
Notice that args.qtyToAdd is undefined
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0080847)
hgbot (developer)
2015-10-06 18:17

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 5c5d1f2807a67b49f5540527deba7d466f85fa22
Author: Mario Castello <mario.castello <at> peoplewalking.com>
Date: Tue Oct 06 10:16:15 2015 -0600
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5c5d1f2807a67b49f5540527deba7d466f85fa22 [^]

Fixed issue 30925: Set qtyToAdd in PreAddProductToOrder Hook

---
M web/org.openbravo.retail.posterminal/js/pointofsale/view/pointofsale.js
---
(0080849)
guillermogil (manager)
2015-10-07 07:27

Are you also taking into account negative values?
e.g.- when you add a negative line while returning a receipt
(0081080)
marvintm (manager)
2015-10-19 13:15

As discussed, a new property should be added to the hook, so that the code which is being executed inside the hook can know whether the line is negative or not.
(0081098)
marvintm (manager)
2015-10-19 17:23

Finally, after analyzing the hooks and where they are located, it was deemed that it's not possible to add the property to the PreAddProductToOrder or AddProductToOrder hooks, because the logic to select and modify the lines is executed after the hooks, so if somebody needs to know whether the line is negative or positive it should use the PostAddProductToOrder, which receives the order line as a parameter.

- Issue History
Date Modified Username Field Change
2015-09-24 17:23 guillermogil New Issue
2015-09-24 17:23 guillermogil Assigned To => Retail
2015-09-24 17:23 guillermogil Resolution time => 1444168800
2015-09-24 17:23 guillermogil Triggers an Emergency Pack => No
2015-09-30 17:58 mario_castello Assigned To Retail => mario_castello
2015-10-05 12:09 Orekaria Status new => scheduled
2015-10-06 18:17 hgbot Checkin
2015-10-06 18:17 hgbot Note Added: 0080847
2015-10-06 18:17 hgbot Status scheduled => resolved
2015-10-06 18:17 hgbot Resolution open => fixed
2015-10-06 18:17 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/5c5d1f2807a67b49f5540527deba7d466f85fa22 [^]
2015-10-07 07:27 guillermogil Note Added: 0080849
2015-10-08 10:03 Orekaria Review Assigned To => guilleaer
2015-10-19 13:15 marvintm Note Added: 0081080
2015-10-19 13:15 marvintm Status resolved => new
2015-10-19 13:15 marvintm Resolution fixed => open
2015-10-19 17:23 marvintm Note Added: 0081098
2015-10-19 17:23 marvintm Status new => scheduled
2015-10-19 17:23 marvintm Status scheduled => resolved
2015-10-19 17:23 marvintm Resolution open => fixed
2015-10-19 17:23 marvintm Review Assigned To guilleaer => marvintm
2015-10-19 17:23 marvintm Status resolved => closed
2015-10-19 17:23 marvintm Fixed in Version => RR16Q1


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker