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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0047727
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[POS2] Restaurantsminorhave not tried2021-09-21 10:452021-10-18 09:34
ReporterAugustoMauchView Statuspublic 
Assigned Tojorge-garcia 
PrioritynormalResolutionfixedFixed in Version
StatusclosedFix in branchFixed in SCM revision
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned ToAugustoMauch
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0047727: Improvements on GetTicketMenuLineWithSameInformation

DescriptionThe web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/GetTicketLineMenuWithSameInformation.js is in charge of, given a ticket and a menu (with menu items), determining if they are equivalent. This is used for instance to decide whether to add a menu in a new ticket line, or to merge into an existing one.

The way this check is done makes it difficult to maintain. Each time a new relevant property is added to the menu items (i.e. product configuration), someone has to remember to update GetTicketLineMenuWithSameInformation to take into account the new info.

There are already two relevant properties that are not being taken into account:
- schema (at menu level)
- product configuration (at menu and menu item level)

In this issue, we should either:
- Update getTicketMenuLineWithSameInformation to take into account the missing relevant properties, or
- Change the way the comparison is done to make maintenance easier (i.e. to check by default the equality of all the properties (doing a deep object comparison), excluding only the irrelevant properties (i.e. order line ID).
Steps To Reproduce- See implementation of https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2.restaurant/-/blob/master/web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/GetTicketLineMenuWithSameInformation.js [^]
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0131977)
hgbot (developer)
2021-09-22 16:07

Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2.restaurant/-/merge_requests/79 [^]
(0132382)
hgbot (developer)
2021-10-18 09:34

Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2.restaurant [^]
Changeset: 9bcf74bd453dd639de8becb65e2c4709f365c869
Author: Jorge Garcia <jorge.garcia@openbravo.com>
Date: 2021-10-07T18:24:26+02:00
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2.restaurant/-/commit/9bcf74bd453dd639de8becb65e2c4709f365c869 [^]

Fixed ISSUE-47727: Improve GetTicketLineMenuWithSameInformation to be configurable

In configuration, it is possible to define the relevant properties to check to conclude
two menu lines are the same

---
A web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/GetTicketMenuLineInfoChecks.js
A web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/TicketLineMenuHeaderInfo.config.json
A web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/TicketLineMenuItemInfo.config.json
A web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/__mock__/Config/MockTicketLineMenuHeaderInfo.config.json
A web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/__mock__/Config/MockTicketLineMenuItemInfo.config.json
M web-jspack/org.openbravo.pos2.restaurant/src/application-window/MainWindowHooks.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/GetTicketLineMenuWithSameInformation.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/__test__/GetTicketLineMenuWithSameInformation.test.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/best-deal/addMenuToTicket.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/food-menu/best-deal/discoverMenus.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/ticket/actions/UpdateMenuPostActionHook.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/user-interface/__test__/AddProductToMenu.test.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/user-interface/__test__/SetMenuItemNote.test.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/user-interface/user-actions/AddProductToMenu.js
M web-jspack/org.openbravo.pos2.restaurant/src/model/user-interface/user-actions/SetMenuItemNote.js
M web-jspack/org.openbravo.pos2.restaurant/src/ob-init.js
---
(0132383)
hgbot (developer)
2021-10-18 09:34

Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2.restaurant/-/merge_requests/79 [^]

- Issue History
Date Modified Username Field Change
2021-09-21 10:45 AugustoMauch New Issue
2021-09-21 10:45 AugustoMauch Assigned To => Retail
2021-09-21 10:45 AugustoMauch Triggers an Emergency Pack => No
2021-09-21 12:54 jorge-garcia Status new => scheduled
2021-09-21 12:54 jorge-garcia Assigned To Retail => jorge-garcia
2021-09-22 16:07 hgbot Note Added: 0131977
2021-09-23 08:43 jorge-garcia Review Assigned To => AugustoMauch
2021-10-18 09:34 hgbot Resolution open => fixed
2021-10-18 09:34 hgbot Status scheduled => closed
2021-10-18 09:34 hgbot Note Added: 0132382
2021-10-18 09:34 hgbot Note Added: 0132383


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker