[IMP] stock : Removed all filters related to a date field and added the related date field in the search view.

bzr revid: mdi@tinyerp.com-20120530050727-2nk2v9nvegwnc1il
This commit is contained in:
Divyesh Makwana (Open ERP) 2012-05-30 10:37:27 +05:30
parent 4077d10f71
commit bcf2099bac
2 changed files with 1 additions and 31 deletions

View File

@ -67,21 +67,6 @@
<field name="arch" type="xml">
<search string="Moves Analysis">
<group>
<filter icon="terp-go-year" string="Year"
name="year"
domain="[('date','&lt;=', time.strftime('%%Y-%%m-%%d')),('date','&gt;=',time.strftime('%%Y-01-01'))]"
help="Current year"/>
<separator orientation="vertical"/>
<filter icon="terp-go-month" string="Month"
name="month"
domain="[('date','&lt;=',(datetime.date.today()+relativedelta(day=31)).strftime('%%Y-%%m-%%d')),('date','&gt;=',(datetime.date.today()-relativedelta(day=1)).strftime('%%Y-%%m-%%d'))]"
help="Current month"/>
<filter icon="terp-go-month"
string="Month-1"
name="month-1"
domain="[('date','&lt;=', (datetime.date.today() - relativedelta(day=31, months=1)).strftime('%%Y-%%m-%%d')),('date','&gt;=',(datetime.date.today() - relativedelta(day=1,months=1)).strftime('%%Y-%%m-%%d'))]"
help="Last month"/>
<separator orientation="vertical"/>
<filter string="Done"
name="done"
icon="terp-dialog-close"
@ -190,21 +175,6 @@
<field name="arch" type="xml">
<search string="Inventory Analysis">
<group>
<filter icon="terp-go-year" string="Year"
name="year"
domain="[('date','&lt;=', time.strftime('%%Y-%%m-%%d')),('date','&gt;=',time.strftime('%%Y-01-01'))]"
help="Current year"/>
<separator orientation="vertical"/>
<filter icon="terp-go-month" string="Month"
name="month"
domain="[('date','&lt;=',(datetime.date.today()+relativedelta(day=31)).strftime('%%Y-%%m-%%d')),('date','&gt;=',(datetime.date.today()-relativedelta(day=1)).strftime('%%Y-%%m-%%d'))]"
help="Current month"/>
<filter icon="terp-go-month"
string="Month-1"
name="month-1"
domain="[('date','&lt;=', (datetime.date.today() - relativedelta(day=31, months=1)).strftime('%%Y-%%m-%%d')),('date','&gt;=',(datetime.date.today() - relativedelta(day=1,months=1)).strftime('%%Y-%%m-%%d'))]"
help="Last month"/>
<separator orientation="vertical"/>
<filter string="Real"
name="real"
icon="terp-check"

View File

@ -1485,7 +1485,7 @@
<field name="arch" type="xml">
<search string="Stock Moves">
<group>
<filter icon="terp-gtk-go-back-rtl" name="receive" string=" Waiting" domain="[('state','in',('confirmed','assigned'))]" help="Stock to be delivered (Available or not)"/>
<filter icon="terp-gtk-go-back-rtl" name="receive" string="Waiting" domain="[('state','in',('confirmed','assigned'))]" help="Stock to be delivered (Available or not)"/>
<filter icon="terp-check" name="available" string="Available" domain="[('state','in',('assigned',))]" help="Stock available to be delivered"/>
<filter icon="terp-dialog-close" name="received" string="Done" domain="[('state','=','done')]"/>
<separator orientation="vertical"/>