pos-addons icon indicating copy to clipboard operation
pos-addons copied to clipboard

pos_sync

Open yelizariev opened this issue 7 years ago • 8 comments

There is a need for new module, which will sync data from backed.

What List of information, which need to be synced:

pos_sync:

  • res.partner
  • product.product

pos_sync_restaurant

  • restaurant.floor
  • restaurant.table
  • restaurant.printer

How

I should be based on pos_longpolling module and built-in base.action.rule utitliy

  • Create new base.action.rule for each table. Example: https://github.com/it-projects-llc/pos-addons/blob/10.0/pos_debt_notebook_sync/data/base_action_rule.xml
  • in POS js: subscribe to updates from longpolling. Example: https://github.com/it-projects-llc/pos-addons/blob/10.0/pos_debt_notebook_sync/static/src/js/sync.js#L17
  • Send notification to channels. Example: https://github.com/it-projects-llc/pos-addons/blob/10.0/pos_debt_notebook_sync/models/pos_config.py#L45

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

yelizariev avatar Dec 10 '17 06:12 yelizariev

@ArtyomLosev Did you make other module that syncs something in POS via base.action.rule and longpolling?

yelizariev avatar Dec 10 '17 06:12 yelizariev

pos_sync module should be added as dependency to pos_multi_session to avoid problems like described here: https://github.com/it-projects-llc/pos-addons/pull/519#issuecomment-350498125 cc @KolushovAlexandr

yelizariev avatar Dec 10 '17 06:12 yelizariev

@yelizariev https://github.com/it-projects-llc/addons-dev/tree/pos-addons-10.0-pos_orders_history/pos_orders_history or this one: https://github.com/it-projects-llc/addons-dev/tree/pos-addons-10.0-pos_invoice_pay/pos_invoice_pay

ArtyomLosev avatar Dec 11 '17 09:12 ArtyomLosev

@yelizariev I agree for the need, however, this is the big solution. I'll probably develop something intermediate, which handles gracefully failed syncs from the backend in the meantime... (also good for analysis)

blaggacao avatar Dec 11 '17 17:12 blaggacao

addresses also #523

blaggacao avatar Dec 11 '17 17:12 blaggacao

@yelizariev I can start to solve the issue

GabbasovDinar avatar Jun 22 '18 10:06 GabbasovDinar

Waiting for this one 😺

gustavovalverde avatar Mar 20 '19 23:03 gustavovalverde

@gustavovalverde we have sync module for res.partner. Do you think other syncs are needed?

yelizariev avatar Mar 25 '19 22:03 yelizariev