From b678af621508a6cd3cdbfd7fa49dc1da31e7e104 Mon Sep 17 00:00:00 2001 From: Abdul Aziz Amrullah Date: Mon, 30 Mar 2026 11:26:25 +0700 Subject: [PATCH] add README.md --- README.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..37bb738 --- /dev/null +++ b/README.md @@ -0,0 +1,21 @@ +Purchase Export BC Module +This plan covers the implementation of the "export PO to BC Format" feature for Odoo 19, added as a custom module. + +purchase_export_bc (New Module) +Module Structure: +- init.py and manifest.py: Describe the new module and its dependency on purchase. +- models/__init__.py and models/purchase_order.py: Extend the purchase.order model by adding the "action_export_bc" method. This method will filter order_line, group them by the product's category name (product_id.categ_id.name), create a new sheet per category, evaluate x_studio_bc_item_id and the units/packaging, generate the Excel document using xlsxwriter, and return an ir.actions.act_url to download it. +- views/purchase_order_views.xml: Extend purchase.view_purchase_order_form to inject a new button "action_export_bc" into the existing
. + +Verification Plan +Manual Verification +1. Access Odoo -> App -> Update App List and install the new "Purchase Export BC Format" module. +2. Go to the Purchase application and open an existing Purchase Order. +3. Click the new button "Export PO to BC Format" in the header. +4. Verify an Excel file is downloaded. +5. Open the Excel file and verify: + - There is one sheet per item category. + - The headers are: "Type", "Item No.", "Description", "Qty", "Satuan". + - The "Type" column has the static value "Item". + - "Qty" perfectly matches the ordered quantity. + - The packaging name and product categories map properly. \ No newline at end of file