I need to extract month from invoice_date as a custom Character or selection field (NO DATE).
Thanks
I need to extract month from invoice_date as a custom Character or selection field (NO DATE).
Thanks
Hi,
Please try like this:-
import datetime
month = datetime.strptime(self.date_invoice, '%Y-%m-%d').strftime("%B")
It will return the month name.
Regards
I forgot to comment that I would like to do it in the frontend, directly in the web as a custom field x_MONTH. And in the model invoice.account.report
أنشئ حساباً اليوم لتستمتع بالخصائص الحصرية، وتفاعل مع مجتمعنا الرائع!
تسجيل| المنشورات ذات الصلة | الردود | أدوات العرض | النشاط | |
|---|---|---|---|---|
|
2
نوفمبر 22
|
5549 | |||
|
1
يوليو 22
|
3862 | |||
|
3
نوفمبر 21
|
28734 | |||
|
1
أغسطس 15
|
7204 | |||
|
2
مارس 15
|
5277 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.