Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
6512 Представления

Hi, I'm working on displaying and updating the stock quantity of products in the pos module. When I click the "validate' button to finish ordered products, I want to update the quantities of products in the browser, without talking to the server (in order to avoid breaking the offline feature of pos) The idea is that I retrive the products data using :

self.pos.get('products').models

I would like to update the 'products' field contained in the static/src/js/models.js of the point of sale module.

Where "self" is the object that inherits from the pos_baseWidget Widget.

then I change the content of that data and I wonder how can I push it to the stored data?

Another concern is that I wonder if the widget containing the products get redrawn after clicking on the "validate" button. Otherwise, I need to redraw the ProductScreenWidget myself.

If anyone knows how widgets are drawn after clicking at this button, please help me.

Thank you

Аватар
Отменить
Related Posts Ответы Просмотры Активность
2
сент. 25
498
1
авг. 25
455
0
июл. 25
354
2
июн. 25
1694
1
мая 25
1644