跳至內容
選單
此問題已被標幟
1 回覆
4666 瀏覽次數

Hello Odoo community,

I was thinking if there is any example that let say if invoice date is less then current date lock particular fields or field?

Any example or ideas would be appreciated

Thank you

頭像
捨棄
最佳答案

Have you tried using the readonly attribute with something like

('date','<=', ((context_today()-datetime.timedelta(days=10)).strftime('%Y-%m-%d')))  

(I haven't - just an idea)

 

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
2
1月 24
2371
2
6月 22
4322
2
6月 18
5897
2
11月 16
13402
2
2月 24
12369