Hello,
I want to add a computed field in the leave form for wage adversary if the employees take leave before the trial period, their wages should be an adversary.
Thank you in advance for any help
Hello,
I want to add a computed field in the leave form for wage adversary if the employees take leave before the trial period, their wages should be an adversary.
Thank you in advance for any help
Hi,
Here is an example:
from odoo import api, fields, models
class TestComputed(models.Model):
_name = "test.computed"
wage = fields.Float(compute="_compute_wage_adversary")
trail_period = fields.Integer()
@api.depends("trail_period")
def _compute_wage_adversary(self):
"""You can write your condition here"""
Hope it helps
สร้างบัญชีวันนี้เพื่อเพลิดเพลินไปกับฟีเจอร์พิเศษและมีส่วนร่วมกับคอมมูนิตี้ที่ยอดเยี่ยมของเรา!
ลงชื่อ| Related Posts | ตอบกลับ | มุมมอง | กิจกรรม | |
|---|---|---|---|---|
|
2
ม.ค. 25
|
8557 | |||
|
1
ธ.ค. 23
|
8016 | |||
|
Menu item for users and group only
แก้ไขแล้ว
|
2
พ.ย. 22
|
6373 | ||
|
0
พ.ย. 22
|
5682 | |||
|
0
ต.ค. 22
|
3855 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.