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

I have a Custom module, that has a data that changes as time goes on, and i wish to change that data before its gets viewed. How can i achieve this in the easiest way?

Awatar
Odrzuć
Najlepsza odpowiedź

make it a functional field, the value of that type of field is calculated on the fly, you give it a function name in your class and the return value of that function is the field value (it actually has to return a dictionary of values so that it works in tree views as well as form views) there is some documentation on them here: https://doc.openerp.com/v6.0/developer/2_5_Objects_Fields_Methods/field_type.html/#functional-fields the main non-obvious trick is that the function definition has to be above the field definition (before the _columns={} bit)

Awatar
Odrzuć
Najlepsza odpowiedź

Check example of Functional Field. link text

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
kwi 24
2190
1
sie 22
2955
0
maj 17
7632
1
mar 15
4045
0
gru 24
853