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

Can I use the  contract start date as condition in salary rules? To calculate the end of service of employee

So if the contract is less than 1 years this rules will appear?

The rule will be like


Today - contract.start_date > 1 year


Thanks

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

Hi,

Yes, you can use the contract start date as a condition in salary rules to calculate the end of service of an employee.You would typically achieve this using Python code within the salary rule.


time_difference = datetime.now() - contract.start_date

result = time_difference > relativedelta(years=1)


Hope it helps

الصورة الرمزية
إهمال

Thank you.

الكاتب أفضل إجابة

thanks dear,

it dose work,

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
0
يونيو 20
3797
0
مارس 15
3979
0
مايو 23
3799
1
فبراير 20
3973
1
مارس 18
4620