تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
2 الردود
4573 أدوات العرض

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?

الصورة الرمزية
إهمال
أفضل إجابة

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)

الصورة الرمزية
إهمال
أفضل إجابة

Check example of Functional Field. link text

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
1
أبريل 24
2181
1
أغسطس 22
2943
0
مايو 17
7622
1
مارس 15
4041
0
ديسمبر 24
852