odoo-shopinvader icon indicating copy to clipboard operation
odoo-shopinvader copied to clipboard

[WIP] Split shopinvader in 2 modules base and product

Open matthieusaison opened this issue 1 year ago • 8 comments

Resolves https://github.com/shopinvader/odoo-shopinvader/issues/1372

matthieusaison avatar Jul 03 '23 09:07 matthieusaison

Hi @matthieusaison

All this seems to be a hard work. Do you plan to finalize this work in the coming days or do you need some helo on it?

Regards,

lmi

lmignon avatar Jul 17 '23 07:07 lmignon

Hi @lmignon I was in vacation last weeks. I'm back on this work. It's a tricky work, thanks to propose your help.

matthieusaison avatar Aug 02 '23 15:08 matthieusaison

Test are green !! \o/ We need to add the migration script and test it with a real project

sebastienbeau avatar Aug 09 '23 22:08 sebastienbeau

@lmignon you can start to review

sebastienbeau avatar Aug 10 '23 12:08 sebastienbeau

@matthieusaison @sebastienbeau Thank you for this hard work. All this seems to go into the right way. I haven't found any issue at first read of this giant PR.

lmignon avatar Aug 21 '23 12:08 lmignon

shopinvader.variant and shopinvader.variant.binding.wizard are now defined in shopinvader_product_binding which is not a dependency of shopinvader_restapi. This test class methods must thus be adapted: https://github.com/shopinvader/odoo-shopinvader/blob/e42e6848ed9875d848daf4c49528d2c022e38bb0/shopinvader_restapi/tests/common.py#L53C5-L74C19 and https://github.com/shopinvader/odoo-shopinvader/blob/e42e6848ed9875d848daf4c49528d2c022e38bb0/shopinvader_restapi/tests/common.py#L41C5-L51C36

marielejeune avatar Sep 13 '23 11:09 marielejeune

Yes it's wanted, the variant case is now handle in shopinvader_product_binding, because the class ShopinvaderVariant has moved here too. https://github.com/shopinvader/odoo-shopinvader/blob/6d3ed9e88adb1f6e718184dba1fd37506a690de8/shopinvader_product_binding/services/abstract_sale.py#L33

Le lun. 18 sept. 2023 à 17:40, Marie Lejeune @.***> a écrit :

@.**** commented on this pull request.

In shopinvader_restapi/services/abstract_sale.py https://github.com/shopinvader/odoo-shopinvader/pull/1382#discussion_r1328926014 :

@@ -43,27 +43,14 @@ def _convert_step(self, sale): def _is_item(self, line): return True

  • def _get_product_information(self, line):
  •    return {"id": line.product_id.id}
    

Before, due to the shopinvader product variant, we got all info about a product inside the SO data (product name, prices, + various custom fields...). Now I see that we just get the product ID. Is it wanted? What are the benefits?

— Reply to this email directly, view it on GitHub https://github.com/shopinvader/odoo-shopinvader/pull/1382#pullrequestreview-1631388276, or unsubscribe https://github.com/notifications/unsubscribe-auth/A5CI2NJ6AMSSISR4ILDKDQTX3BTPVANCNFSM6AAAAAAZ4EY2WM . You are receiving this because you were mentioned.Message ID: @.***>

matthieusaison avatar Sep 19 '23 05:09 matthieusaison