product-attribute icon indicating copy to clipboard operation
product-attribute copied to clipboard

[18.0][REF] product_pricelist_direct_print_xlsx

Open maciej-wichowski opened this issue 2 months ago • 3 comments

Code refactoring made with purpose of making the module easier to extend. Since xlsxwriter is "write only" library, there was no way to easily change the properties of printed table. The changes are focused on separating preparation of data / labels / formats.

That way any extension module can change the order of the columns, data formats or add new columns anywhere in the table. For example, prior to this change, to add a new column before the "Description" column, only way was to override _create_product_pricelist_sheet and _fill_data methods or rewrite whole workbook from scratch after the original methods are done.

maciej-wichowski avatar Oct 20 '25 09:10 maciej-wichowski

ping @CarlosRoca13 @pedrobaeza @carlosdauden @eduezerouali-tecnativa I'm not sure who is the maintainer of the module, so I'm pinging last contributors / reviewers.

maciej-wichowski avatar Oct 20 '25 09:10 maciej-wichowski

OK about the initial purpose. Please check CI.

pedrobaeza avatar Oct 20 '25 10:10 pedrobaeza

@pedrobaeza CI is failing, but it's not related to current changes.

maciej-wichowski avatar Oct 21 '25 07:10 maciej-wichowski

@pedrobaeza rebased, tests passing.

maciej-wichowski avatar Nov 26 '25 15:11 maciej-wichowski

/ocabot merge patch

pedrobaeza avatar Nov 26 '25 15:11 pedrobaeza

What a great day to merge this nice PR. Let's do it! Prepared branch 18.0-ocabot-merge-pr-2108-by-pedrobaeza-bump-patch, awaiting test results.

OCA-git-bot avatar Nov 26 '25 15:11 OCA-git-bot

Congratulations, your PR was merged at 481a98a77c64634dd042638ba3194d3854e9b92a. Thanks a lot for contributing to OCA. ❤️

OCA-git-bot avatar Nov 26 '25 15:11 OCA-git-bot