Openbravo Issue Tracking System - Retail Modules
View Issue Details
0032787Retail ModulesReturn Receiptpublic2016-04-26 15:482016-06-07 17:32
lorenzofidalgo 
shivum039 
immediatemajoralways
closedfixed 
5
main 
RR16Q3 
guilleaer
No
0032787: [RR16Q2] "Return Line" button should be hidden when receipt is marked as "To be Returned", but that button is shown
In documentation it is written "Since 15Q4 It will NOT be possible to have positive lines in return tickets". In RR16Q2 is still possible to use the "Return Line" button in Return Receipts due to "Return Line" button is not hidden. Only clicking in EDIT tab hides the "Return Line" button.
Using the following "Steps To Reproduce", "Return Line" button does not appear in RR16Q1 or RR15Q4.
A) Can only be reproduced in Q2, not in tip
0-Login POS as vallblanca.
1-In dropdown menu, click "Return this Receipt".
2-Add 1x "Adhesive body warmers".
3-Click the just added product. DEFECT: Check "Return Line" button is still shown. It must not be shown. It is still clickable, so, currently, it is possible to create positive lines in a Return Receipt.

B)
Add product
Select line
Menu > Return this receipt
Verify that the 'Return line' option is shown in the right menu

Note that there is a test called 'I30075_NoPositiveLinesInReturnTickets'
1) Create a function called 'rearrangeEditButtonBar' (if it does not exists) that decides which buttons should be shown in the buttons' bar and paints them

2) The 'rearrangeEditButtonBar' should be called when:
- A menu option like "Return this receipt" or "Layaway this receipt" is selected
- A line of the receipt is tapped
- The EDIT tab is shown

3) Create 2 tests with the following flows (Note that there is a test called 'I30075_NoPositiveLinesInReturnTickets')

test 1:

1-In the menu, select "Return this Receipt"
2-Add 1x "Adhesive body warmers"
3-Click the just added product
4-Verify "Return Line" button is hidden
4-Click in the EDIT tab button
5-Verify "Return Line" button is hidden

test 2:

1-Add product
2-Select the line of the product
3-In the menu, select "Return this Receipt"
4-Verify "Return Line" button is hidden
5-Clicking again in product line
6-Verify "Return Line" button is hidden

No tags attached.
related to defect 0032557 closed mario_castello Return Line button is displayed even "Switch from positive to return line" preference is set to "N" 
depends on backport 0032886RR16Q2 closed shivum039 [RR16Q2] "Return Line" button should be hidden when receipt is marked as "To be Returned", but that button is shown 
related to defect 0032789 closed Retail It is still shown (and clickable) "Return Line" button in certain flow when the receipt is marked as "To be Returned" 
png ReturnLineIsShownInReturnTickets.png (293,263) 2016-04-26 15:48
https://issues.openbravo.com/file_download.php?file_id=9323&type=bug
png PositiveLineInReturnReceipt.png (158,120) 2016-04-26 15:48
https://issues.openbravo.com/file_download.php?file_id=9324&type=bug
png
Issue History
2016-04-26 15:48lorenzofidalgoNew Issue
2016-04-26 15:48lorenzofidalgoAssigned To => Retail
2016-04-26 15:48lorenzofidalgoFile Added: ReturnLineIsShownInReturnTickets.png
2016-04-26 15:48lorenzofidalgoRegression level => Packaging and release
2016-04-26 15:48lorenzofidalgoRegression introduced in release => main
2016-04-26 15:48lorenzofidalgoTriggers an Emergency Pack => No
2016-04-26 15:48lorenzofidalgoFile Added: PositiveLineInReturnReceipt.png
2016-04-26 15:49lorenzofidalgoDescription Updatedbug_revision_view_page.php?rev_id=11873#r11873
2016-04-26 16:04lorenzofidalgoRelationship addedrelated to 0032789
2016-04-26 16:14lorenzofidalgoSummary[RR16Q2] "Return Line" button should be disabled when receipt is marked as "To be Returned", but that button is shown => [RR16Q2] "Return Line" button should be hidden when receipt is marked as "To be Returned", but that button is shown
2016-04-26 17:48OrekariaSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=11879#r11879
2016-04-26 17:48OrekariaProposed Solution updated
2016-04-26 17:56OrekariaSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=11880#r11880
2016-04-26 17:57OrekariaNote Added: 0086003
2016-04-26 17:57OrekariaStatusnew => feedback
2016-04-27 08:59lorenzofidalgoNote Added: 0086008
2016-04-27 09:13lorenzofidalgoStatusfeedback => new
2016-04-27 10:17OrekariaStatusnew => acknowledged
2016-04-27 10:17OrekariaSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=11881#r11881
2016-04-27 10:54OrekariaRelationship addedrelated to 0032557
2016-04-27 11:44OrekariaProposed Solution updated
2016-04-27 12:02OrekariaProposed Solution updated
2016-04-27 17:18OrekariaStatusacknowledged => scheduled
2016-04-27 17:18OrekariaAssigned ToRetail => shivum039
2016-04-30 13:02shivum039Note Added: 0086097
2016-04-30 13:03shivum039Note Edited: 0086097bug_revision_view_page.php?bugnote_id=0086097#r11925
2016-05-05 06:37hgbotCheckin
2016-05-05 06:37hgbotNote Added: 0086193
2016-05-05 06:37hgbotStatusscheduled => resolved
2016-05-05 06:37hgbotResolutionopen => fixed
2016-05-05 06:37hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/79d8beaf34f6db33e23ba5d02336d7797728c6e2 [^]
2016-05-05 06:37hgbotCheckin
2016-05-05 06:37hgbotNote Added: 0086194
2016-05-06 10:34OrekariaStatusresolved => new
2016-05-06 10:34OrekariaResolutionfixed => open
2016-05-06 10:35OrekariaStatusnew => scheduled
2016-05-06 10:35OrekariaStatusscheduled => resolved
2016-05-06 10:35OrekariaResolutionopen => fixed
2016-06-01 10:28dmitry_mezentsevNote Added: 0086876
2016-06-03 10:35guilleaerReview Assigned To => guilleaer
2016-06-03 10:35guilleaerStatusresolved => closed
2016-06-03 10:35guilleaerFixed in Version => RR16Q3
2016-06-03 11:12guilleaerRegression levelPackaging and release =>
2016-06-03 11:12guilleaerRegression introduced in releasemain =>
2016-06-03 11:43jorge-garciaNote Added: 0086980
2016-06-03 11:43jorge-garciaStatusclosed => new
2016-06-03 11:43jorge-garciaResolutionfixed => open
2016-06-03 11:43jorge-garciaFixed in VersionRR16Q3 =>
2016-06-07 17:30guilleaerStatusnew => scheduled
2016-06-07 17:31guilleaerStatusscheduled => resolved
2016-06-07 17:31guilleaerFixed in Version => RR16Q3
2016-06-07 17:31guilleaerResolutionopen => fixed
2016-06-07 17:32guilleaerNote Added: 0087072
2016-06-07 17:32guilleaerStatusresolved => closed

Notes
(0086003)
Orekaria   
2016-04-26 17:57   
The issue as reported in A) cannot be reproduced
(0086008)
lorenzofidalgo   
2016-04-27 08:59   
I have just reproduced again this issue in RR16Q2
(0086097)
shivum039   
2016-04-30 13:02   
(edited on: 2016-04-30 13:03)
General Observation After Code Analysis .

1)Yes, There is a defect ,But it Only when you click on " return this receipt",
Option from menu When After You Add a product and Edit Tool Bar Still Being Shown.

2) The Reason For the Above defect is ,Code which does the Arrangement Of action Buttons of Edit Mode (Edit Bar) is Not Reachable when you Choose it From Menu Option . But its Reachable When You tap on Added product and Click on Edit Bar ,Hence All Buttons are in the Arranged properly .

3)To Resolve the Defect : Facing Only Problem With Return Line So ,To Resolve the Problem we need to Implement the All Logic in a Single Function and Make that in Such a way that It Should get Call When You Click Return Receipt Option From Menu Also.

(0086193)
hgbot   
2016-05-05 06:37   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 79d8beaf34f6db33e23ba5d02336d7797728c6e2
Author: Shivanand Madiwalar <shivanand.madiwalar <at> promantia.com>
Date: Thu May 05 10:05:01 2016 +0530
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/79d8beaf34f6db33e23ba5d02336d7797728c6e2 [^]

Fixes Issue 32787 : Logic Has Been Added to Hide the ReturnLine Button When Its Return Receipt or LayAway .

---
M web/org.openbravo.retail.posterminal/js/components/menu.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/editline.js
M web/org.openbravo.retail.posterminal/js/pointofsale/view/pointofsale.js
---
(0086194)
hgbot   
2016-05-05 06:37   
Repository: tools/automation/pi-mobile
Changeset: 8371eeea084450da61ddc5c2c584627e1d12e329
Author: Shivanand Madiwalar <shivanand.madiwalar <at> promantia.com>
Date: Thu May 05 10:05:57 2016 +0530
URL: http://code.openbravo.com/tools/automation/pi-mobile/rev/8371eeea084450da61ddc5c2c584627e1d12e329 [^]

Verifies Issue 32787 : Automated Test Has Been Created which will hide the ReturnLine Button When Its Return Receipt or LayAway .

---
A src-test/org/openbravo/test/mobile/retail/pack/selenium/tests/receipts/I32787_HideReturnLine_Button.java
---
(0086876)
dmitry_mezentsev   
2016-06-01 10:28   
Not closed for 26 days!!!
Please react ASAP.
(0086980)
jorge-garcia   
2016-06-03 11:43   
It's necessary to beautify this code[1] to have a clean code. Use JsBeautifier plugin of Eclipse.

[1] https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/79d8beaf34f6db33e23ba5d02336d7797728c6e2 [^]
(0087072)
guilleaer   
2016-06-07 17:32   
closed. It is true that jsbeauty was needed, but a commit done after that one has fixed this format problem.
https://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/f3cdfee595c1 [^]