1

ツリー ビューのボタンにアイコンを追加する必要があります

<button name="gen_link" type="object" icon="/custom_module/static/src/img/image.png" string="MyButton"/>

しかし、ブラウザで要素を調べると、それが表示されます

<button type="button" class="" title="MyButton">
    <img alt="MyButton" src="http://localhost:8000/web/static/src/img/icons//custom_module/static/src/img/image.png.png">
</button>

デフォルトでは、常にデフォルト パスを使用します。アイコンにカスタム パスを指定することはできません。

なにか提案を。. .

4

1 に答える 1

0

ディレクトリ /..を上に移動するために使用できます。/web/static/src/img/icons//

次のようにボタンを挿入します(テスト済み):

<button name="gen_link" 
        type="object" 
        icon="/../../../../../../custom_module/static/src/img/image"/>
于 2016-08-17T09:02:30.993 に答える