[IMP] sale(_*): settings display of default SO values
This commit reworks the display of the default SO values in the settings to make it clear to the users what those settings impact and that they are overridden by the quotation template when specified. task-2880950 Part-of: odoo/odoo#97565
This commit is contained in:
@@ -63,20 +63,40 @@
|
||||
</setting>
|
||||
</block>
|
||||
<block title="Quotations & Orders" name="quotation_order_setting_container">
|
||||
<setting id="sale_config_online_confirmation_sign" company_dependent="1" documentation="/applications/sales/sales/send_quotations/get_signature_to_validate.html" help="Request an online signature to confirm orders">
|
||||
<field name="portal_confirmation_sign"/>
|
||||
</setting>
|
||||
<setting id="sale_config_online_confirmation_pay" company_dependent="1" documentation="/applications/sales/sales/send_quotations/get_paid_to_validate.html" help="Request an online payment to confirm orders">
|
||||
<field name="portal_confirmation_pay"/>
|
||||
<div class="mt8" attrs="{'invisible': [('portal_confirmation_pay', '=', False)]}">
|
||||
<button name='%(payment.action_payment_provider)d' icon="fa-arrow-right" type="action" string="Payment Providers" class="btn-link"/>
|
||||
</div>
|
||||
</setting>
|
||||
<setting id="quotation_validity_days" company_dependent="1" help="Set a default validity on your quotations">
|
||||
<field name="use_quotation_validity_days"/>
|
||||
<div class="content-group" attrs="{'invisible': [('use_quotation_validity_days','=',False)]}">
|
||||
<setting id="order_default_values"
|
||||
string="Default values"
|
||||
help="Default values used when creating new quotations. Those can still be changed on each quotation."
|
||||
company_dependent="1">
|
||||
<div class="mt16" id="order_default_values_div">
|
||||
<div>
|
||||
<field name="portal_confirmation_sign" class="w-auto"/>
|
||||
<label for="portal_confirmation_sign"/>
|
||||
<a href="https://www.odoo.com/documentation/master/applications/sales/sales/send_quotations/get_signature_to_validate.html"
|
||||
title="Documentation"
|
||||
class="me-2 o_doc_link"
|
||||
target="_blank"/>
|
||||
</div>
|
||||
<div class="text-muted">
|
||||
Request an online signature to confirm orders
|
||||
</div>
|
||||
<div class="mt16">
|
||||
<span class="col-lg-3">Default Limit: <field name="quotation_validity_days" attrs="{'required': [('use_quotation_validity_days', '=', True)]}"/> days</span>
|
||||
<field name="portal_confirmation_pay" class="col-lg-4 oe_inline"/>
|
||||
<label for="portal_confirmation_pay"/>
|
||||
<a href="https://www.odoo.com/documentation/master/applications/sales/sales/send_quotations/get_paid_to_validate.html"
|
||||
title="Documentation"
|
||||
class="me-2 o_doc_link"
|
||||
target="_blank"/>
|
||||
</div>
|
||||
<div class="text-muted">
|
||||
Request an online payment to confirm orders
|
||||
</div>
|
||||
<div class="mt8" attrs="{'invisible': [('portal_confirmation_pay', '=', False)]}">
|
||||
<button name='%(payment.action_payment_provider)d' icon="fa-arrow-right" type="action" string="Payment Providers" class="btn-link"/>
|
||||
</div>
|
||||
<div class="mt16" title="Days between quotation proposal and expiration. 0 days means automatic expiration is disabled">
|
||||
<label for="quotation_validity_days"/>
|
||||
<field name="quotation_validity_days" class="text-center" style="width: 5rem;"/>
|
||||
<div class="d-inline-block">days</div>
|
||||
</div>
|
||||
</div>
|
||||
</setting>
|
||||
|
||||
@@ -6,8 +6,7 @@
|
||||
<field name="model">res.config.settings</field>
|
||||
<field name="inherit_id" ref="sale.res_config_settings_view_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//setting[@id='sale_config_online_confirmation_pay']" position="after">
|
||||
<field name="module_sale_quotation_builder" invisible="1"/>
|
||||
<setting id="order_default_values" position="after">
|
||||
<setting id="standardized_offers_setting" help="Create standardized offers with default products" documentation="/applications/sales/sales/send_quotations/quote_template.html">
|
||||
<field name="group_sale_order_template"/>
|
||||
<div class="content-group" attrs="{'invisible': [('group_sale_order_template', '=', False)]}">
|
||||
@@ -22,26 +21,28 @@
|
||||
<button name="%(sale_management.sale_order_template_action)d" icon="fa-arrow-right" type="action" string="Quotation Templates" class="btn-link"/>
|
||||
</div>
|
||||
</div>
|
||||
</setting>
|
||||
<setting id="design_quotation_template_setting" attrs="{'invisible': [('group_sale_order_template','=',False)]}">
|
||||
<field name="module_sale_quotation_builder"/>
|
||||
<div class="text-muted">
|
||||
Design your quotation templates using building blocks<br/>
|
||||
<em attrs="{'invisible': [('module_sale_quotation_builder','=',False)]}">Warning: this option will install the Website app.</em>
|
||||
<div class="mt16 oe_inline"
|
||||
attrs="{'invisible': [('group_sale_order_template', '=', False)]}"
|
||||
id="module_sale_quotation_builder">
|
||||
<field name="module_sale_quotation_builder" class="col-lg-4 oe_inline"/>
|
||||
<label for="module_sale_quotation_builder"/>
|
||||
</div>
|
||||
<div class="text-muted"
|
||||
attrs="{'invisible': [('group_sale_order_template', '=', False)]}"
|
||||
id="module_sale_quotation_builder_description">
|
||||
Design your quotation templates using building blocks
|
||||
</div>
|
||||
</setting>
|
||||
</setting>
|
||||
<xpath expr="//div[@id='order_default_values_div']" position="before">
|
||||
<div attrs="{'invisible': [('group_sale_order_template', '=', False)]}"
|
||||
class="container text-info text-center border border-info">
|
||||
Default values will be overwritten by values provided by the quotation template.
|
||||
</div>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="res_config_settings_view_form_inherit_sale_management" model="ir.ui.view">
|
||||
<field name="name">res.config.settings.view.form.inherit.sale.management</field>
|
||||
<field name="model">res.config.settings</field>
|
||||
<field name="inherit_id" ref="sale.res_config_settings_view_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//app[@name='sale_management']" position="attributes">
|
||||
<app name="sale_management" position="attributes">
|
||||
<attribute name="notApp">0</attribute>
|
||||
</xpath>
|
||||
</app>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<record id="sale_quotation_builder.res_config_settings_view_form_inherit" model="ir.ui.view">
|
||||
<field name="name">res.config.settings.view.form.inherit.sale.management.inherit.sale.quotation.builder</field>
|
||||
|
||||
<record id="res_config_settings_view_form_inherit" model="ir.ui.view">
|
||||
<field name="name">res.config.settings.view.form</field>
|
||||
<field name="model">res.config.settings</field>
|
||||
<field name="inherit_id" ref="sale_management.res_config_settings_view_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//field[@name='module_sale_quotation_builder']/following::div/em" position="replace"/>
|
||||
<xpath expr="//div[@id='module_sale_quotation_builder']" position="replace"/>
|
||||
<xpath expr="//div[@id='module_sale_quotation_builder_description']" position="replace"/>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user