-
-
Notifications
You must be signed in to change notification settings - Fork 264
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] all: fix pre-commit new checks
- Loading branch information
Showing
3 changed files
with
86 additions
and
90 deletions.
There are no files selected for viewing
Empty file.
38 changes: 18 additions & 20 deletions
38
product_variant_configurator_manual_creation/views/product_template_view.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,24 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<odoo> | ||
<data> | ||
|
||
<record id="product_template_form_view" model="ir.ui.view"> | ||
<field name="name">product.template.form.view</field> | ||
<field name="model">product.template</field> | ||
<field name="inherit_id" ref="product.product_template_form_view" /> | ||
<field name="arch" type="xml"> | ||
<record id="product_template_form_view" model="ir.ui.view"> | ||
<field name="name">product.template.form.view</field> | ||
<field name="model">product.template</field> | ||
<field name="inherit_id" ref="product.product_template_form_view" /> | ||
<field name="arch" type="xml"> | ||
<button | ||
name="%(product.product_attribute_value_action)d" | ||
position="before" | ||
> | ||
<button | ||
name="%(product.product_attribute_value_action)d" | ||
position="before" | ||
> | ||
<button | ||
name="%(wizard_product_variant_configurator_manual_creation_action)d" | ||
type="action" | ||
string="Create Pending Variants" | ||
attrs="{'invisible': [('has_pending_variants', '=', False)]}" | ||
/> | ||
<field name="has_pending_variants" invisible="1" /> | ||
</button> | ||
</field> | ||
</record> | ||
name="%(wizard_product_variant_configurator_manual_creation_action)d" | ||
type="action" | ||
string="Create Pending Variants" | ||
attrs="{'invisible': [('has_pending_variants', '=', False)]}" | ||
/> | ||
<field name="has_pending_variants" invisible="1" /> | ||
</button> | ||
</field> | ||
</record> | ||
|
||
</data> | ||
</odoo> |
138 changes: 68 additions & 70 deletions
138
...ator_manual_creation/wizards/wizard_product_variant_configurator_manual_creation_view.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,76 +1,74 @@ | ||
<?xml version="1.0" encoding="utf-8" ?> | ||
<odoo> | ||
<data> | ||
|
||
<record | ||
id="wizard_product_variant_configurator_manual_creation_view_form" | ||
model="ir.ui.view" | ||
> | ||
<field | ||
name="name" | ||
>wizard_product_variant_configurator_manual_creation_view_form</field> | ||
<field | ||
name="model" | ||
>wizard.product.variant.configurator.manual.creation</field> | ||
<field name="arch" type="xml"> | ||
<form string="Variants Manual Creation"> | ||
<sheet> | ||
<group name="product_info"> | ||
<field name="product_tmpl_id" /> | ||
<field name="variants_to_create" /> | ||
</group> | ||
<field name="line_ids" nolabel="1"> | ||
<tree editable="top" create="false" delete="false"> | ||
<field | ||
name="attribute_id" | ||
readonly="1" | ||
force_save="1" | ||
/> | ||
<field name="required" readonly="1" force_save="1" /> | ||
<field | ||
name="attribute_value_ids" | ||
widget="many2many_tags" | ||
invisible="1" | ||
/> | ||
<field | ||
name="selected_value_ids" | ||
attrs="{'required': [('required', '=', True)]}" | ||
widget="many2many_tags" | ||
domain="[('id', 'in', attribute_value_ids or [])]" | ||
options="{'no_create': True}" | ||
/> | ||
</tree> | ||
</field> | ||
</sheet> | ||
<footer> | ||
<button | ||
string="Create Variants" | ||
name="action_create_variants" | ||
type="object" | ||
class="btn-primary" | ||
/> | ||
<button | ||
string="Cancel" | ||
class="btn-secondary" | ||
special="cancel" | ||
/> | ||
</footer> | ||
</form> | ||
</field> | ||
</record> | ||
<record | ||
id="wizard_product_variant_configurator_manual_creation_view_form" | ||
model="ir.ui.view" | ||
> | ||
<field | ||
name="name" | ||
>wizard_product_variant_configurator_manual_creation_view_form</field> | ||
<field | ||
name="model" | ||
>wizard.product.variant.configurator.manual.creation</field> | ||
<field name="arch" type="xml"> | ||
<form string="Variants Manual Creation"> | ||
<sheet> | ||
<group name="product_info"> | ||
<field name="product_tmpl_id" /> | ||
<field name="variants_to_create" /> | ||
</group> | ||
<field name="line_ids" nolabel="1"> | ||
<tree editable="top" create="false" delete="false"> | ||
<field | ||
name="attribute_id" | ||
readonly="1" | ||
force_save="1" | ||
/> | ||
<field name="required" readonly="1" force_save="1" /> | ||
<field | ||
name="attribute_value_ids" | ||
widget="many2many_tags" | ||
invisible="1" | ||
/> | ||
<field | ||
name="selected_value_ids" | ||
attrs="{'required': [('required', '=', True)]}" | ||
widget="many2many_tags" | ||
domain="[('id', 'in', attribute_value_ids or [])]" | ||
options="{'no_create': True}" | ||
/> | ||
</tree> | ||
</field> | ||
</sheet> | ||
<footer> | ||
<button | ||
string="Create Variants" | ||
name="action_create_variants" | ||
type="object" | ||
class="btn-primary" | ||
/> | ||
<button | ||
string="Cancel" | ||
class="btn-secondary" | ||
special="cancel" | ||
/> | ||
</footer> | ||
</form> | ||
</field> | ||
</record> | ||
|
||
<record | ||
id="wizard_product_variant_configurator_manual_creation_action" | ||
model="ir.actions.act_window" | ||
> | ||
<field name="name">Variants Manual Creation</field> | ||
<field name="type">ir.actions.act_window</field> | ||
<field | ||
name="res_model" | ||
>wizard.product.variant.configurator.manual.creation</field> | ||
<field name="view_mode">form</field> | ||
<field name="target">new</field> | ||
</record> | ||
<record | ||
id="wizard_product_variant_configurator_manual_creation_action" | ||
model="ir.actions.act_window" | ||
> | ||
<field name="name">Variants Manual Creation</field> | ||
<field name="type">ir.actions.act_window</field> | ||
<field | ||
name="res_model" | ||
>wizard.product.variant.configurator.manual.creation</field> | ||
<field name="view_mode">form</field> | ||
<field name="target">new</field> | ||
</record> | ||
|
||
</data> | ||
</odoo> |