Project: 	
  | View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
| ID | ||||||||
| 0043462 | ||||||||
| Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
| defect | [Retail Modules] Web POS | major | always | 2020-03-09 17:09 | 2020-03-26 12:38 | |||
| Reporter | samuel_nicuesa | View Status | public | |||||
| Assigned To | rqueralta | |||||||
| Priority | high | Resolution | fixed | Fixed in Version | RR20Q2 | |||
| Status | closed | Fix in branch | Fixed in SCM revision | 65aaf8b03792 | ||||
| Projection | none | ETA | none | Target Version | ||||
| OS | Any | Database | Any | Java version | ||||
| OS Version | Database version | Ant version | ||||||
| Product Version | pi | SCM revision | ||||||
| Merge Request Status | ||||||||
| Review Assigned To | jorge-garcia | |||||||
| OBNetwork customer | Gold | |||||||
| Support ticket | 14898 | |||||||
| Regression level | ||||||||
| Regression date | ||||||||
| Regression introduced in release | ||||||||
| Regression introduced by commit | ||||||||
| Triggers an Emergency Pack | No | |||||||
| Summary | 0043462: The query to find Bags and Gift Card products in Self Checkout is too slow. | |||||||
| Description | The query to find Bags and Gift Card products in Self Checkout is too slow. We need to have installed this module org.openbravo.retail.selfcheckout  | |||||||
| Steps To Reproduce | The first time we load product bags and gift card products the query takes a lot of time to return the results. We need to include 2 Index in M_PRODUCT table This code loads the M_Product bags : if (OB.MobileApp.model.hasPermission('OBPOS_remote.product', true)) { criteria.remoteFilters = [{ columns: ['obscoIsBag'], operator: 'equals', value: 'Y' }]; } OB.Dal.findUsingCache('bagSearch', OB.Model.Product, criteria, function(data) { if (data.length > 0) { data.forEach(function(product) { button = me.$.bagsArea.createComponent({ And this code loads the Gift Card products OB.UI.GiftCardUtils.service( 'org.openbravo.retail.giftcards.CancelGiftCard', { giftcard: card, _tryCentralFromStore: true, _executeInOneServer: true }, function(result) { OB.UI.GiftCardUtils.findProductModel(result.product.id, function( transactionproduct ) {  | |||||||
| Proposed Solution | Add these 2 indexes in M_PRODUCT TABLE <index name="M_PRODUCT_IDX" unique="false"> <index-column name="M_PRODUCT_ID"/> </index> <index name="EM_OBSCO_ISBAG_IDX" unique="false"> <index-column name="EM_OBSCO_ISBAG"/> </index>  | |||||||
| Tags | No tags attached. | |||||||
| Attached Files | ||||||||
		  Relationships		[ Relation Graph ] 
		[ Dependency Graph ] 
			 | 
|
  		Notes	 | 
|
| 
				(0118813) hgbot (developer) 2020-03-25 15:48  | 
	
		Repository: erp/pmods/org.openbravo.retail.selfcheckout Changeset: 65aaf8b0379299123090ba158da2fa7f53ad3aa7 Author: Rafael Queralta <rafaelcuba81 <at> gmail.com> Date: Thu Mar 19 10:04:20 2020 -0400 URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.selfcheckout/rev/65aaf8b0379299123090ba158da2fa7f53ad3aa7 [^] Fixed BUG-43462: The query to find Bags and Gift Card products in Self Checkout is too slow. - Added a new index in m_product table --- M src-db/database/model/modifiedTables/M_PRODUCT.xml ---  | 
| 
				(0118832) jorge-garcia (viewer) 2020-03-26 12:38  | 
	
		Finally, the problem detected in giftcards was caused by a custom module implementation of Gift Cards in a client. The code only affects to Bags products and it was tested and reviewed.  | 
  Issue History	 | 
|||
| Date Modified | Username | Field | Change | 
| 2020-03-09 17:09 | samuel_nicuesa | New Issue | |
| 2020-03-09 17:09 | samuel_nicuesa | Assigned To | => Retail | 
| 2020-03-09 17:09 | samuel_nicuesa | OBNetwork customer | => Gold | 
| 2020-03-09 17:09 | samuel_nicuesa | Support ticket | => 14898 | 
| 2020-03-09 17:09 | samuel_nicuesa | Resolution time | => 1585519200 | 
| 2020-03-09 17:09 | samuel_nicuesa | Triggers an Emergency Pack | => No | 
| 2020-03-18 00:13 | rqueralta | Assigned To | Retail => rqueralta | 
| 2020-03-18 00:13 | rqueralta | Status | new => scheduled | 
| 2020-03-25 15:48 | hgbot | Checkin | |
| 2020-03-25 15:48 | hgbot | Note Added: 0118813 | |
| 2020-03-25 15:48 | hgbot | Status | scheduled => resolved | 
| 2020-03-25 15:48 | hgbot | Resolution | open => fixed | 
| 2020-03-25 15:48 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/pmods/org.openbravo.retail.selfcheckout/rev/65aaf8b0379299123090ba158da2fa7f53ad3aa7 [^] | 
| 2020-03-26 08:53 | jorge-garcia | Review Assigned To | => jorge-garcia | 
| 2020-03-26 12:38 | jorge-garcia | Note Added: 0118832 | |
| 2020-03-26 12:38 | jorge-garcia | Status | resolved => closed | 
| 2020-03-26 12:38 | jorge-garcia | Fixed in Version | => RR20Q2 | 
| Copyright © 2000 - 2009 MantisBT Group |