| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Odoo Apps Dependencies |
Discuss (mail)
|
| Lines of code | 236 |
| Technical Name |
product_variant_generator |
| License | OPL-1 |
| Website | https://www.orado.cn |
Product Variant Generator
Preview and batch-generate product variants for dynamic attribute mode
Overview
Odoo's dynamic variant mode creates variants on-demand when a sales or manufacturing order is confirmed — meaning variants are never pre-generated on the product template. This is ideal for products with a large number of possible combinations, but it makes it impossible to browse, price, or manage variants in advance.
Product Variant Generator solves this by adding a single button on the product template form that opens an interactive wizard. You can preview every possible combination, see which variants already exist, and selectively generate only the ones you need — all without leaving the product page.
Key Features
🔍 Full Combination Preview
The wizard computes every possible attribute combination and presents them in a single list, grouped by status: Existing, To Create, and Excluded. No more guessing which variants are missing.
✅ Selective Generation
Choose exactly which variants to create. Use Select All / Deselect All for bulk operations, or toggle individual rows. Only selected “To Create” variants are generated.
⚡ Conflict-Safe
Each variant is created with a concurrent-safe lookup using
combination_indices. If a variant was created by another user between
the time you opened the wizard and clicked Generate, it is silently skipped —
no duplicates, no errors.
📋 Exclusion Awareness
Combinations blocked by Odoo's attribute exclusion rules are automatically marked as Excluded and shown in muted style. They cannot be selected or generated.
🔄 Archived Variant Reactivation
If a matching variant exists but is archived, the wizard reactivates it instead of creating a duplicate. Archived variants are not counted as “Existing” so they remain available for regeneration.
🛡️ Variant Limit Guard
Respects Odoo's product.dynamic_variant_limit system parameter
(default 1 000). If the total combination count exceeds the limit, the
wizard refuses to open and displays a clear error message.
How It Works
- Open any product template that has at least one attribute in dynamic variant mode.
- Click the Generate Variants smart button in the top action area.
- Review the combination list — green rows are already existing, muted rows are excluded by rules.
- Select the combinations you want to create, then click Generate Selected Variants.
- You are redirected to the product variants list filtered to this template.
Requirements
- Odoo 19.0 (Community or Enterprise)
- The Variants feature must be enabled (Inventory › Configuration › Settings › Variants)
- At least one product attribute must be set to dynamic variant creation mode
- User must belong to the Manage Product Variants group to see the smart button
Support
If you have any questions or issues, please contact us at feihu.zhang@orado.cn.
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module