Hi all
i am trying to make overtime rule and get wrong python code
the rule
result = (((contract.wage/30)/8)*0.25)*(inputs.OVERTIME_DAY_DAYS and inputs.OVERTIME_DAY_DAYS.amount)
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- 客戶關係
- e-Commerce
- 會計
- 庫存
- PoS
- 專案管理
- MRP
此問題已被標幟
1
回覆
3525
瀏覽次數
I guess the problem is with this part: (inputs.OVERTIME_DAY_DAYS and inputs.OVERTIME_DAY_DAYS.amount).
Try to write it as: (bool(inputs.OVERTIME_DAY_DAYS.amount) and inputs.OVERTIME_DAY_DAYS.amount).
| 相關帖文 | 回覆 | 瀏覽次數 | 活動 | |
|---|---|---|---|---|
|
|
0
5月 22
|
3583 | ||
|
|
1
5月 22
|
2910 | ||
|
|
1
1月 22
|
2599 | ||
|
|
1
10月 21
|
15282 | ||
|
|
2
1月 24
|
15375 |