Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

1

filter invoices for this month

By
Atchuthan
on 6/21/13, 5:52 AM 610 views

Hi guyz,

I need to know how to create a filter in which the invoices for this month(06/June) to be displayed.

For example :

I have 3 records with  datetime field :
rec1                        -           12/06/2013  13:54:39                            
rec2                        -           20/06/2013  12:12:58
rec3                        -           05/05/2013  05:30:25

So when the filter is created using todays date: 'date1': fields.date.context_today,

I need to show only rec1 and rec2 as the current month is 06.

If we need the invoice for todays date, we can use this query :

[['date_invoice','=',time.strftime('%Y-%m-%d')]]

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 6/21/13, 5:52 AM
Seen: 610 times
Last updated: 3/16/15, 8:10 AM