Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
2 Відповіді
1253 Переглядів

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

Аватар
Відмінити
Найкраща відповідь

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

Аватар
Відмінити
Автор

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.

Автор

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

Найкраща відповідь


\`\`\`

<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.               



Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
3
лют. 24
4008
3
лют. 18
7406
4
бер. 15
5468
4
квіт. 24
2878