Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
1 ตอบกลับ
2892 มุมมอง

I have seen some decorators that are used to save or write, and others work with change events of the forms...

Is there a way to execute a method on read call for a model?, i.e., when the model is called for read records, because I need to process the data before displaying it. 

My model is only a table, no views, no froms, but I call if from come another module as need


อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Hi Jose:

There is no decorator for read. But, you can define a computed field that does the required pre-processing of the data and use the computed field in your custom module.

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
3
พ.ย. 24
30176
0
ธ.ค. 21
2394
0
เม.ย. 15
4745
2
มี.ค. 15
10536
1
มี.ค. 15
4024