|  | @@ -10,7 +10,7 @@
 | 
											
												
													
														|  |                <search>
 |  |                <search>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |                    <separator/>
 |  |                    <separator/>
 | 
											
												
													
														|  | -                  <filter string="Este año" name="year" domain="[('date_order','<=', time.strftime('%%Y-12-31')),('date_order','>=',time.strftime('%%Y-01-01'))]"/>
 |  | 
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Este año" name="year" domain="[('create_date','<=', time.strftime('%%Y-12-31')),('date_order','>=',time.strftime('%%Y-01-01'))]"/>
 | 
											
												
													
														|  |                    <filter string="Año pasado " domain="[('date_order','>=',(context_today()-relativedelta(years=1)).strftime('%%Y-01-01')),('date_order','<=', time.strftime('%%Y-01-01'))]"/>
 |  |                    <filter string="Año pasado " domain="[('date_order','>=',(context_today()-relativedelta(years=1)).strftime('%%Y-01-01')),('date_order','<=', time.strftime('%%Y-01-01'))]"/>
 | 
											
												
													
														|  |                    <filter string="Mes actual" domain="[('date_order','<',(context_today()+relativedelta(months=1)).strftime('%%Y-%%m-01')), ('date_order','>=',time.strftime('%%Y-%%m-01'))]"/>
 |  |                    <filter string="Mes actual" domain="[('date_order','<',(context_today()+relativedelta(months=1)).strftime('%%Y-%%m-01')), ('date_order','>=',time.strftime('%%Y-%%m-01'))]"/>
 | 
											
												
													
														|  |                    <filter string="Mes pasado" domain="[('date_order','>=',(context_today()-relativedelta(months=1)).strftime('%%Y-%%m-01')),('date_order','<',time.strftime('%%Y-%%m-01'))]"/>
 |  |                    <filter string="Mes pasado" domain="[('date_order','>=',(context_today()-relativedelta(months=1)).strftime('%%Y-%%m-01')),('date_order','<',time.strftime('%%Y-%%m-01'))]"/>
 | 
											
										
											
												
													
														|  | @@ -23,6 +23,7 @@
 | 
											
												
													
														|  |                    <separator/>
 |  |                    <separator/>
 | 
											
												
													
														|  |                    <group string="">
 |  |                    <group string="">
 | 
											
												
													
														|  |                        <filter string="Por dia" context="{'group_by':'date_order:day'}"/>
 |  |                        <filter string="Por dia" context="{'group_by':'date_order:day'}"/>
 | 
											
												
													
														|  | 
 |  | +                      <filter string="Por mes" context="{'group_by':'date_order:month'}"/>
 | 
											
												
													
														|  |                        <filter string="Creado por" context="{'group_by':'create_uid'}"/>
 |  |                        <filter string="Creado por" context="{'group_by':'create_uid'}"/>
 | 
											
												
													
														|  |                        <filter string="Por sucursal" context="{'group_by':'warehouse_id'}"/>
 |  |                        <filter string="Por sucursal" context="{'group_by':'warehouse_id'}"/>
 | 
											
												
													
														|  |                    </group>
 |  |                    </group>
 | 
											
										
											
												
													
														|  | @@ -30,5 +31,33 @@
 | 
											
												
													
														|  |              </field>
 |  |              </field>
 | 
											
												
													
														|  |          </record>
 |  |          </record>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | 
 |  | +        <record id="view_sale_orderline_filter_search1" model="ir.ui.view">
 | 
											
												
													
														|  | 
 |  | +            <field name="name">sale.order.line.filter.search1</field>
 | 
											
												
													
														|  | 
 |  | +            <field name="model">sale.order.line</field>
 | 
											
												
													
														|  | 
 |  | +            <field name="inherit_id" ref="sale.view_sales_order_line_filter" />
 | 
											
												
													
														|  | 
 |  | +            <field name="arch" type="xml">
 | 
											
												
													
														|  | 
 |  | +              <search>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +                  <separator/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Este año" name="year" domain="[('create_date','<=', time.strftime('%%Y-12-31')),('create_date','>=',time.strftime('%%Y-01-01'))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Año pasado " domain="[('create_date','>=',(context_today()-relativedelta(years=1)).strftime('%%Y-01-01')),('create_date','<=', time.strftime('%%Y-01-01'))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Mes actual" domain="[('create_date','<',(context_today()+relativedelta(months=1)).strftime('%%Y-%%m-01')), ('create_date','>=',time.strftime('%%Y-%%m-01'))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Mes pasado" domain="[('create_date','>=',(context_today()-relativedelta(months=1)).strftime('%%Y-%%m-01')),('create_date','<',time.strftime('%%Y-%%m-01'))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Semana anterior" domain="[('create_date', '>=', ((context_today()+relativedelta(weeks=-2, days=1, weekday=0)).strftime('%%Y-%%m-%%d'))),('create_date', '<=', ((context_today()+relativedelta(weeks=-1, weekday=6)).strftime('%%Y-%%m-%%d')))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Esta semana" domain="[('create_date', '>=', ((context_today()+relativedelta(weeks=-1, days=1, weekday=0)).strftime('%%Y-%%m-%%d'))),('create_date', '<=', ((context_today()+relativedelta(weeks=0, weekday=6)).strftime('%%Y-%%m-%%d')))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Hoy" domain="[('create_date', '>=', datetime.datetime.now().strftime('%Y-%m-%d 00:00:00')),('create_date', '<=',datetime.datetime.now().strftime('%Y-%m-%d 23:23:59'))]"/>
 | 
											
												
													
														|  | 
 |  | +                  <filter string="Ayer" domain="[('create_date','<=', (datetime.date.today()-relativedelta(days=1)).strftime('%%Y-%%m-%%d')),('create_date','>=',(datetime.date.today()-relativedelta(days=1)).strftime('%%Y-%%m-%%d'))]"/>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +                  <separator/>
 | 
											
												
													
														|  | 
 |  | +                  <group string="">
 | 
											
												
													
														|  | 
 |  | +                      <filter string="Por dia" context="{'group_by':'create_date:day'}"/>
 | 
											
												
													
														|  | 
 |  | +                      <filter string="Por mes" context="{'group_by':'create_date:month'}"/>
 | 
											
												
													
														|  | 
 |  | +                      <filter string="Creado por" context="{'group_by':'create_uid'}"/>
 | 
											
												
													
														|  | 
 |  | +                      <!-- <filter string="Por sucursal" context="{'group_by':'warehouse_id'}"/> -->
 | 
											
												
													
														|  | 
 |  | +                  </group>
 | 
											
												
													
														|  | 
 |  | +               </search>
 | 
											
												
													
														|  | 
 |  | +            </field>
 | 
											
												
													
														|  | 
 |  | +        </record>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |      </data>
 |  |      </data>
 | 
											
												
													
														|  |  </openerp>
 |  |  </openerp>
 |