Openbravo Issue Tracking System - Retail Modules
View Issue Details
0036864Retail ModulesWeb POSpublic2017-09-15 12:302017-09-25 14:16
marvintm 
jorge-garcia 
normalmajorhave not tried
closedfixed 
5
 
RR17Q4 
marvintm
No
0036864: Product Image thumbnails should be generated to reduce the consumed bandwidth of the Web POS
The Web POS by default stores the product images in the local database, but if the number of products is too great, they cannot fit here. There is another configuration which can be used to prevent this problem which can be set by using the preference "Web POS Product Images from server instead of cache".

When this preference is set, a process called "Generate Product Images" must be used. This process reads all product images in a given assortment, and stores them as separate files. The images are then requested by the Web POS as separate images every time the products are searched or browsed, and also in the Product Information tab.

This works correctly, but currently has two aspects which could be improved:

- The process generates just one image for each product (with maximum width 160 pixels). The size of this image is correct for the Product Information tab, but it's too big for the product thumbnails that are used in the Product SEARCH and BROWSE tabs. Having images this big has proved to consume a very significant amount of network bandwidth on real customers.

- The process always generates every image for every product in the assortment. If the assortment is very big, and only a few products have been added, this is very inefficient.


Therefore, the following two improvements are proposed:
- Apart from the big product image used in the Product Information tab, a new, smaller image, will be generated. This smaller image will be then used in the Product SEARCH and BROWSE components.

- A new check parameter will be added to the Generate Product Image process: "Overwrite all images". If this check is enabled, the process will always generate both images for every single product in any case, overwriting each file if it already exists. If it is not checked, the process will then avoid generating images that already exist, generating only the images that do not exist already.
.
No tags attached.
Issue History
2017-09-15 12:30marvintmNew Issue
2017-09-15 12:30marvintmAssigned To => Retail
2017-09-15 12:30marvintmTriggers an Emergency Pack => No
2017-09-15 12:31marvintmDescription Updatedbug_revision_view_page.php?rev_id=15908#r15908
2017-09-15 12:32marvintmDescription Updatedbug_revision_view_page.php?rev_id=15909#r15909
2017-09-18 13:46jorge-garciaStatusnew => scheduled
2017-09-18 13:46jorge-garciaAssigned ToRetail => jorge-garcia
2017-09-25 13:48hgbotCheckin
2017-09-25 13:48hgbotNote Added: 0099545
2017-09-25 13:48hgbotCheckin
2017-09-25 13:48hgbotNote Added: 0099546
2017-09-25 13:48hgbotStatusscheduled => resolved
2017-09-25 13:48hgbotResolutionopen => fixed
2017-09-25 13:48hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/471b61ac827ed55eb67718f59813417c34e86d3a [^]
2017-09-25 14:16hgbotCheckin
2017-09-25 14:16hgbotNote Added: 0099548
2017-09-25 14:16marvintmReview Assigned To => marvintm
2017-09-25 14:16marvintmStatusresolved => closed
2017-09-25 14:16marvintmFixed in Version => RR17Q4

Notes
(0099545)
hgbot   
2017-09-25 13:48   
Repository: retail/api-checks-retail
Changeset: 43291f95b35fd391ede6645a8035ad84c4a53af8
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Mon Sep 25 13:29:48 2017 +0200
URL: http://code.openbravo.com/retail/api-checks-retail/rev/43291f95b35fd391ede6645a8035ad84c4a53af8 [^]

Related to issue 36864: Product Image thumbnails should be generated to reduce
the consumed bandwidth of the Web POS

Added changes to openbravo api check.

This change is a false positive in the API.

---
M model/modules/org.openbravo.retail.posterminal/src-db/database/sourcedata/AD_PROCESS_PARA.xml
---
(0099546)
hgbot   
2017-09-25 13:48   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 471b61ac827ed55eb67718f59813417c34e86d3a
Author: Jorge Garcia <jorge.garcia <at> openbravo.com>
Date: Wed Sep 20 09:02:14 2017 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/471b61ac827ed55eb67718f59813417c34e86d3a [^]

Fixed issue 36864: Product Image thumbnails should be generated to reduce
the consumed bandwidth of the Web POS

The solution implemented is:

* The process to generate the product images generates also small images of 49
pixels.

* In the client side, search and browse tabs request small images from server
if the preference is defined.

* The process has a new checkbox called generate all images. If this checkbox
is checked, the process creates all the images. If this checkbox is unchecked,
the process only generate those images that were not generated previously.

---
M src-db/database/sourcedata/AD_ELEMENT.xml
M src-db/database/sourcedata/AD_PROCESS_PARA.xml
M src/org/openbravo/retail/posterminal/utility/GenerateProductImages.java
M web/org.openbravo.retail.posterminal/js/components/renderproduct.js
---
(0099548)
hgbot   
2017-09-25 14:16   
Repository: erp/pmods/org.openbravo.retail.posterminal
Changeset: 8a090e8be306ec4057039fdbc67c2083910b715f
Author: Antonio Moreno <antonio.moreno <at> openbravo.com>
Date: Mon Sep 25 13:58:12 2017 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.retail.posterminal/rev/8a090e8be306ec4057039fdbc67c2083910b715f [^]

Related to issue 36864. Improved name of new parameter and added description and help. Changed to lines to debug.

---
M src-db/database/sourcedata/AD_ELEMENT.xml
M src-db/database/sourcedata/AD_PROCESS_PARA.xml
M src/org/openbravo/retail/posterminal/utility/GenerateProductImages.java
---