Skip to Content
Menu
This question has been flagged
2 Replies
1128 Views

Dear Community,


I have a problem with the logo on the settings form.


I have add the icon in the static/icon.png and the icon is showing in the apps form but it's not showing in the settings form.





Is It necesary any configuration?


Kind regards

Avatar
Discard
Best Answer

Hi,To add an icon in general settings, include the following code in the res.config.settings view file:

<div class="app_settings_block" data-string="Materials Construction"
                     string="Materials Construction"
                     data-key="your_module_name">

In data-key add your module name


Hope it helps

Avatar
Discard
Author

Dear Cybrosys,

I'm trying the option but it's not working.
The code is :

<xpath expr="//form" position="inside">
<app data-string="construction_material"
id="cm" string="Materiales Construcción" name="cm"
>
<div
class="app_settings_block" data-string="Materials Construction"
string="Materials Construction"
data-key="construction_material"
>
<block title="Calculos inventario"
id="end_inventory_settings"
>
<setting string="Inventario Uom Ampliada">
<div class="text-muted content-group mt16">
<field name="inventory_uom_expanded" />
</div>
</setting>
</block>
<block title="Facturación" id="end_invoicing_settings">
<setting string="Diario contable por almacén">
<div class="text-muted content-group mt16">
<field name="journal_for_location" />
</div>
</setting>
</block>
</div>
</app>
</xpath>

Kind regards.

Author

Dear Cybrosys

I have do a lot of test, I changed the res.config.settings and I have find the solution, it's similar that your solutions but the name of the data-key should the same name of the name folder of your module.

Example :
<app data-string="name_folder"
id="name_folder" string="Module Name" name="name_folder"
>

Kind regards

Best Answer


\`\`\`

<record id="res_config_settings_view_form" model="ir.ui.view">

    <field name="name">res.config.settings.view.form.inheritz</field>

    <field name="model">res.config.settings</field>          

    <field name="inherit_id" ref="base.res_config_settings_view_form" />

    <field name="arch" type="xml">

        <xpath expr="//form" position="inside">

            <app data-string="Module Name" string="Module Name" name="module_name" groups="base.group_user">

                -- add your configuration here --

            </app>

        </xpath>

    </field>

</record>

\`\`\`


   


It is for odoo v17.               



Avatar
Discard
Related Posts Replies Views Activity
3
Feb 24
3775
3
Feb 18
7324
4
Mar 15
5371
4
Apr 24
2645