Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
3907 Widoki

Is there a way to hide the text "Activate here a new currency before creating a new company." in the company form view bellow the currency field? Or at least change the text?

Awatar
Odrzuć
Najlepsza odpowiedź

Hi Samo Arko,
I couldn't find the field you mentioned. You can simply solve your problem by:

1) Activating the developer mode (Settings/ Activate Developer Mode)
2) Go to the form you want to edit(where is the field) and click "Edit form view"

3) Find the object or field that you want to edit and add change/attribute:


When it comes to field these are the commone attributes
- invisible="1" if you want to make the entire field invisible

- placeholder="some text" if you want to change the placeholder(like odoo.com to your website)
- help="some help" - this is displayed when you hover over the field
4) Save and refresh

Remember that if you want to make apermament chage you will have to write a module for that. If not your field attributes will come back to the previous state as soon as you update the Odoo

Awatar
Odrzuć
Autor

I know how to hide fields and using the developer tools. With it I found that it's shown bellow the currency field. The problem is I think that it is text that is shown with javascript and it's reletad to the filed by the currency fields id. I tried to set the ID to empty '' with xpath expresion, but then I gotten an error that it can't find the ID in the view. And the way you described is the absolute wrong way of doing changes!

I have updated the post with screenshots and it works. I disagree with you - changing first in a developer mode is a good practice so you can see if the logic was good before starting to write a module

Autor

OK I found the code you posted. Had to look into the inherited views. Now how can I hide the html code without just comment it out in the edit form view but from a custom inherited view?

I would catch the "p" from inherited view and replace it with something:

<xpath expr="//p[1]" position="replace">

<br/>

</xpath>

or create another view with different sequence or just set the attribute of p for invisible

Autor

Thanks that worked.

Powiązane posty Odpowiedzi Widoki Czynność
0
lis 19
3507
6
sie 19
4365
3
lut 19
6931
0
lut 18
4359
2
lis 17
9040