123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104 |
- <?xml version="1.0" encoding="utf-8"?>
- <openerp>
- <data>
- <record id="stock_warehouse_transfer_view_tree" model="ir.ui.view">
- <field name="name">stock.warehouse.transfer.view.tree</field>
- <field name="model">stock.warehouse.transfer</field>
- <field name="arch" type="xml">
- <tree string="Transfers">
- <field name="name"/>
- <field name="date"/>
- <field name="source_warehouse"/>
- <field name="dest_warehouse"/>
- <field name="pickings"/>
- <field name="state"/>
- </tree>
- </field>
- </record>
- <record id="stock_warehouse_transfer_view_form" model="ir.ui.view">
- <field name="name">stock.warehouse.transfer.view.form</field>
- <field name="model">stock.warehouse.transfer</field>
- <field name="arch" type="xml">
- <form string="Transfer">
- <header>
- <button name="action_create_picking" type="object" states="draft" class="oe_highlight" string="Crear Transferencia"/>
- <field name="state" widget="statusbar" translate="1"/>
- </header>
- <sheet>
- <h1>
- <field name="name" required="1" placeholder="Reference" attrs="{'readonly':[('state','!=','draft')]}"/>
- </h1>
- <group>
- <field name="date" required="1" attrs="{'readonly':[('state','!=','draft')]}"/>
- </group>
- <group col="4">
- <field name="source_warehouse" required="1" attrs="{'readonly':[('state','!=','draft')]}"/>
- <field name="dest_warehouse" required="1" attrs="{'readonly':[('state','!=','draft')]}"/>
- </group>
- <separator colspan="4" string="Transferencia" attrs="{'invisible':[('state','in','draft')]}"/>
- <field colspan="4" name="pickings" readonly="1" nolabel="1" attrs="{'readonly':[('state','!=','draft')],'invisible':[('state','=','draft')]}"/>
- <separator colspan="4" string="Productos"/>
- <field colspan="4" name="lines" nolabel="1" attrs="{'readonly':[('state','!=','draft')]}">
- <tree editable="bottom">
- <field name="product_id" domain="[('type','!=','service')]" required="1" options="{'no_create':True,'no_open':True}"/>
- <field name="ean13"/>
- <field name="product_qty" required="1" sum="qty"/>
- <field name="product_uom_id" required="1" invisible="1"/>
- <field name="source_location" invisible="1"/>
- <field name="dest_location" invisible="1"/>
- <field name="note" invisible="1"/>
- </tree>
- </field>
- </sheet>
- </form>
- </field>
- </record>
- <record id="stock_warehouse_transfer_search1" model="ir.ui.view">
- <field name="name">stock.warehouse.transfer.search1</field>
- <field name="model">stock.warehouse.transfer</field>
- <field name="arch" type="xml">
- <search string="Transferencia">
- <field name="name" string="Referencia" filter_domain="['|',('name','ilike',self)]"/>
- <field name="source_warehouse" string="Depósito Origen"/>
- <field name="dest_warehouse" string="Depósito Destino"/>
- <separator/>
- <filter string="Este año" name="year" domain="[('date','<=', time.strftime('%%Y-12-31')),('date','>=',time.strftime('%%Y-01-01'))]"/>
- <filter string="Año pasado " domain="[('date','>=',(context_today()-relativedelta(years=1)).strftime('%%Y-01-01')),('date','<=', time.strftime('%%Y-01-01'))]"/>
- <filter string="Mes actual" domain="[('date','<',(context_today()+relativedelta(months=1)).strftime('%%Y-%%m-01')), ('date','>=',time.strftime('%%Y-%%m-01'))]"/>
- <filter string="Mes pasado" domain="[('date','>=',(context_today()-relativedelta(months=1)).strftime('%%Y-%%m-01')),('date','<',time.strftime('%%Y-%%m-01'))]"/>
- <filter string="Hoy" domain="[('date', '>=', datetime.datetime.now().strftime('%Y-%m-%d 00:00:00')),('date', '<=',datetime.datetime.now().strftime('%Y-%m-%d 23:23:59'))]"/>
- <filter string="Ayer" domain="[('date','<=', (datetime.date.today()-relativedelta(days=1)).strftime('%%Y-%%m-%%d')),('date','>=',(datetime.date.today()-relativedelta(days=1)).strftime('%%Y-%%m-%%d'))]"/>
- <filter string="Semana anterior" domain="[('date', '>=', ((context_today()+relativedelta(weeks=-2, days=1, weekday=0)).strftime('%%Y-%%m-%%d'))),('date', '<=', ((context_today()+relativedelta(weeks=-1, weekday=6)).strftime('%%Y-%%m-%%d')))]"/>
- <filter string="Esta semana" domain="[('date', '>=', ((context_today()+relativedelta(weeks=-1, days=1, weekday=0)).strftime('%%Y-%%m-%%d'))),('date', '<=', ((context_today()+relativedelta(weeks=0, weekday=6)).strftime('%%Y-%%m-%%d')))]"/>
- <separator/>
- <group string="Agrupar por">
- <filter string="Depósito Origen" context="{'group_by':'source_warehouse'}"/>
- <filter string="Depósito Destino" context="{'group_by':'dest_warehouse'}"/>
- </group>
- </search>
- </field>
- </record>
- <record id="stock_warehouse_transfer_action" model="ir.actions.act_window">
- <field name="name">Transferir Productos</field>
- <field name="res_model">stock.warehouse.transfer</field>
- <field name="type">ir.actions.act_window</field>
- <field name="view_type">form</field>
- <field name="view_mode">tree,form</field>
- </record>
- <menuitem action="stock_warehouse_transfer_action"
- id="stock_warehouse_transfer_menu"
- parent="stock.menu_stock_warehouse_mgmt"
- sequence="50"/>
- </data>
- </openerp>
|