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

Hello,

How i can exclude weekend from number of days in Leave Requests. ex: start day (from_dt) = 12/04/2013 end day (to_dt) = 15/04/2013 it should be display 2 days in Number of Days not 4 days

plz help

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

Try the this method of python,, Isoweekday() is a method of the DateTime class that tells the day of the given date. It returns an integer that corresponds to a particular day.

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

It seems like since 2013 and Odoo v6 -  this problems still wasn't fixed?

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

You need to modify this method '_get_number_of_days', defined in hr.holidays object by using some datetime attributes that will exclude weekend from number of days.

Thanks, Priyesh Solanki

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
1
يوليو 17
4816
0
مارس 15
3623
3
أكتوبر 22
5212
0
مايو 18
4014
1
مارس 15
4294