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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0037836
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Retail Modules] Web POSmajoralways2018-02-05 16:102018-03-19 13:21
Reporterinaki_garciaView Statuspublic 
Assigned Toranjith_qualiantech_com 
PrioritynormalResolutionfixedFixed in VersionRR18Q2
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionmainSCM revision 
Review Assigned Toguilleaer
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0037836: [RR18Q1] [Stock Validation] [Support for Attributes] Error when adding a product with attributes to a receipt causes POS failure

DescriptionAdding a product with an Attribute Set that has more than one attribute to the receipt returns a parsing error of the
attribute value inputted in the "Attribute Set Value" popup, no matter whether the value is correct or not. This issue
is reproducible when Enable Stock Validation ("Web POS stock validation" module) and Support for Attributes
preferences are enabled and causes complete failure of the Web POS (the parsing error is repeatedly shown for any
action attempted and the UI can completely freeze).

The setup to reproduce this issue (unless it were a misconfiguration issue) is detailed in Steps to Reproduce section.
Steps To ReproducePRECONDITIONS:
- "Web POS stock validation" module must be installed
- Support for Attributes preference must be activated
- The subject product and attributes to reproduced this issue were configured as follows:
* Product:
  * Search Key: NTP
  * Name: New Test Product
  * Product Category: Backpacks & Travel
  * Records in "Price" tab: "The White Valley Group Purchase Price List Version" and
    "The White Valley Group Sale Price list (Opening Store)"
  * Attribute Set: NTP Attributes
* Attribute Set (NTP Attributes):
  * Require At Least One Value and Active checkboxes: checked | Rest of the checkboxes unchecked
  * In "Assigned Attributes" tab: Attribute 1, Attribute 2
* "Attribute Value"s for "Attribute 1":
  * Search Key: "PS-ASB" | Name: "VAL1"
  * Search Key: "PS-ASC" | Name: "VAL2"
* "Attribute Value"s for "Attribute 2":
  * Search Key: "PS-BSB" | Name: "VAL3"
  * Search Key: "PS-BSC" | Name: "VAL4"
- Add the product to the Assortment of the subject store
- Ensure that there's enough stock for the product. To do so, Purchase Order, Good Receipt and Purchase Invoice were made for the Posets organization an store with the product's attribute set value set as "VAL1_VAL3".

0. Log in the Web POS' "PS-1" terminal as "posets" user
1. Click on the "Browse" button and hit the "Backpack & Travel" button
2. Select the "New Test Product" product. "Attribute Set Value" popup will be shown
3. Enter "VAL1_VAL3" value.

NOTICE that, in spite of having entered the correct attribute set value for the product available in stock, error
popups are shown which are JSON malformatting and field parsing related, as well as the related Javascript errors:

TypeError: callback is not a function
    at OB.DS.HWServer._print (8863469d9c6db472fbebd79379158bdf.js:1746)
    at OB.DS.HWServer.print (8863469d9c6db472fbebd79379158bdf.js:1745)
    at 8863469d9c6db472fbebd79379158bdf.js:1745
    at OB.DS.HWResource.getData (8863469d9c6db472fbebd79379158bdf.js:1736)
    at OB.DS.HWServer.print (8863469d9c6db472fbebd79379158bdf.js:1745)
    at PrintReceiptLine.print (8863469d9c6db472fbebd79379158bdf.js:2435)
    at G.d.trigger (backbone-0.9.2.min.js:9)
    at G.d.change (backbone-0.9.2.min.js:15)
    at G.d.set (backbone-0.9.2.min.js:12)
    at openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:3340:781; line: Object.OB.UTIL.showError (8863469d9c6db472fbebd79379158bdf.js:641) (*,+)

8863469d9c6db472fbebd79379158bdf.js:163 TypeError: Cannot read property 'toString' of undefined
    at toBigDecimal (8863469d9c6db472fbebd79379158bdf.js:663)
    at Object.OB.DEC.toBigDecimal (8863469d9c6db472fbebd79379158bdf.js:663)
    at G.d.printQty (8863469d9c6db472fbebd79379158bdf.js:1291)
    at Object.initComponents (8863469d9c6db472fbebd79379158bdf.js:2011)
    at Object.create (enyo.js:531)
    at Object.enyo.kind.inherited (enyo.js:410)
    at Object.create (enyo.js:690)
    at Object.enyo.kind.inherited (enyo.js:410)
    at Object.create (enyo.js:1313)
    at Object.enyo.kind.inherited (enyo.js:410); line: Object.OB.UTIL.showError (http://q [^]

-- Trying to delete the receipt shows the following error:
8863469d9c6db472fbebd79379158bdf.js:663 Uncaught TypeError: Cannot read property 'toString' of null
    at toBigDecimal (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:663:1024)
    at Object.OB.DEC.sub (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:663:1716)
    at G.d.<anonymous> (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:1302:427)
    at Array.forEach (<anonymous>)
    at Function.b.each.b.forEach (openbravo/web/org.openbravo.mobile.core/lib/vendor/underscore-1.3.3.min.js:11:39)
    at G.d.r.(anonymous function) [as each] (openbravo/web/org.openbravo.mobile.core/lib/vendor/backbone-0.9.2.min.js:25:314)
    at G.d.adjustPrices (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:1301:291)
    at G.d.prepareToSend (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:1301:175)
    at finishRemoveOrder (openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:1598:186)
    at openbravo/web/js/gen/8863469d9c6db472fbebd79379158bdf.js:1601:125
TagsNo tags attached.
Attached Filespng file icon error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active.png [^] (144,257 bytes) 2018-02-06 13:37


png file icon error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-2.png [^] (60,709 bytes) 2018-02-06 13:38


png file icon error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-3-onLogout.png [^] (252,870 bytes) 2018-02-06 13:38

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0102522)
hgbot (developer)
2018-02-20 12:28

Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 931cfbc7f10280a92452b34420837d75fa493ed5
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Tue Feb 20 16:58:14 2018 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/931cfbc7f10280a92452b34420837d75fa493ed5 [^]

Related to issue 37836 : Validate Attribute Set Description with Attributes

* if attributes if not matched with product in backoffice, product should not be added and error should be shown
* Added AdMessage for existing errors

---
M src-db/database/sourcedata/AD_MESSAGE.xml
M src/org/openbravo/retail/posterminal/utility/AttributesUtils.java
M web/org.openbravo.retail.posterminal/js/model/order.js
---
(0102540)
hgbot (developer)
2018-02-21 08:12

Repository: erp/pmods/org.openbravo.retail.stockvalidation
Changeset: 5068afacf9b2ff7402e46d1e09f611caa54b714d
Author: Ranjith S R <ranjith <at> qualiantech.com>
Date: Wed Feb 21 12:42:37 2018 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.stockvalidation/rev/5068afacf9b2ff7402e46d1e09f611caa54b714d [^]

Related to issue 37836 : Line should be removed if any exception occured in stock checker

* When line is changed, if qty is less than or zero then StockChecker should not be executed

---
M web/org.openbravo.retail.stockvalidation/js/modals.js
---

- Issue History
Date Modified Username Field Change
2018-02-05 16:10 inaki_garcia New Issue
2018-02-05 16:10 inaki_garcia Assigned To => Retail
2018-02-05 16:10 inaki_garcia Triggers an Emergency Pack => No
2018-02-05 16:30 inaki_garcia Steps to Reproduce Updated View Revisions
2018-02-05 16:42 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active.png
2018-02-05 16:42 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-2.png
2018-02-05 16:43 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-3-onLogout.png
2018-02-06 13:32 inaki_garcia Steps to Reproduce Updated View Revisions
2018-02-06 13:33 inaki_garcia File Deleted: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active.png
2018-02-06 13:33 inaki_garcia File Deleted: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-3-onLogout.png
2018-02-06 13:33 inaki_garcia File Deleted: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-2.png
2018-02-06 13:37 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active.png
2018-02-06 13:38 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-2.png
2018-02-06 13:38 inaki_garcia File Added: error-when-adding-a-product-with-attributes-with-enable-stock-validation-preference-active-3-onLogout.png
2018-02-07 13:20 marvintm Severity critical => major
2018-02-08 13:36 ranjith_qualiantech_com Assigned To Retail => ranjith_qualiantech_com
2018-02-08 13:36 ranjith_qualiantech_com Status new => scheduled
2018-02-20 12:28 hgbot Checkin
2018-02-20 12:28 hgbot Note Added: 0102522
2018-02-21 08:12 hgbot Checkin
2018-02-21 08:12 hgbot Note Added: 0102540
2018-02-21 10:17 ranjith_qualiantech_com Status scheduled => resolved
2018-02-21 10:17 ranjith_qualiantech_com Resolution open => fixed
2018-03-19 13:21 guilleaer Review Assigned To => guilleaer
2018-03-19 13:21 guilleaer Status resolved => closed
2018-03-19 13:21 guilleaer Fixed in Version => RR18Q2


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker