123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255 |
- <openerp>
- <data>
- <record id="ir_cron_scheduler_demo_action" model="ir.cron">
- <field name="name">Demo scheduler</field>
- <field name="user_id" ref="base.user_root"/>
- <field name="interval_number">1</field>
- <field name="interval_type">minutes</field>
- <field name="numbercall">-1</field>
- <field eval="False" name="doall"/>
- <field eval="'car.workshop'" name="model"/>
- <field eval="'process_demo_scheduler_queue'" name="function"/>
- </record>
- <record model="ir.ui.view" id="worksheet_form_view">
- <field name="name">worksheet.form.view</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <form string="Worksheet">
- <header>
- <button name="workshop_create_invoices" string="Crear Factura" type="object"
- class="btn-primary" states="waiting"/>
- <button class="btn-primary" name="cancel" string="Cancelar" type="object" states="waiting"/>
- <field name="stage_id" widget="statusbar" clickable="True"/>
- <field name="state" widget="statusbar" invisible="1"/>
- </header>
- <sheet string="Hoja de Tarea">
- <field name="kanban_state" widget="kanban_state_selection" invisible="1"/>
- <div class="oe_title">
- <h1 class="o_row">
- <field name="name" placeholder="Titulo de la tarea"/>
- </h1>
- </div>
- <group>
- <group>
- <field name="vehicle_id" string="Vehiculo" required="1" attrs="{'readonly': [('state','!=','waiting')]}"/>
- <field name="user_id" string="Responsable" required="1"/>
- </group>
- <group>
- <field name="date_deadline" string="Fecha limite entrega"/>
- <field name="tag_ids" widget="many2many_tags" string="Etiquetas"/>
- <field name="progress" widget="progressbar" />
- </group>
- </group>
- <notebook>
- <page name="description_page" string="Descripción">
- <field name="description" type="html"/>
- <div class="oe_clear"/>
- </page>
- <page name="timesheet_page" string="Hoja de trabajo">
- <group string ="Trabajo Planeado">
- <field name="planned_works" nolabel="1">
- <tree string="Planned Work" editable="bottom">
- <field name="planned_work" string="Trabajo"/>
- <field name="time_spent" sum= "Estimated Time" widget="float_time" string="Tiempo Estimado"/>
- <field name="work_date" string="Fecha de trabajo"/>
- <field name="responsible" string="Responsable"/>
- <field name="work_cost" string="Precio"/>
- <field name="completed" string="¿El trabajo esta terminado?"/>
- </tree>
- </field>
- </group>
- <group string = "Trabajos terminados">
- <field name="works_done" nolabel="1">
- <tree string="Planned Work" editable="bottom">
- <field name="planned_work" string="Trabajo"/>
- <field name="duration" sum= "Estimated Time" widget="float_time" string="Duracion"/>
- <field name="work_date2" string="Fecha de trabajo"/>
- <field name="responsible" string="Responsable"/>
- <field name="work_cost" string="Precio"/>
- </tree>
- </field>
- </group>
- <group string = "Materiales Utilizados">
- <field name="materials_used" nolabel="1"/>
- </group>
- <group>
- <field name="amount_total" string="Monto Total"/>
- </group>
- <group class="oe_subtotal_footer oe_right" name="project_hours">
- <field name="effective_hour" widget="float_time" string="Horas Gastadas"/>
- <field name ="remaining_hour" class="oe_subtotal_footer_separator" widget="float_time" string="Horas Restantes"/>
- </group>
- </page>
- <page string="Informacion Extra">
- <group col="4">
- <group col="2">
- <field name="partner_id" string="Cliente" required="1"/>
- <field name="company_id" string="Empresa" required="1"/>
- </group>
- <group col="2">
- <field name="date_assign" string="Fecha de creación"/>
- <field name="date_last_stage_update" string="Fecha de cambio de etapa"/>
- </group>
- </group>
- </page>
- </notebook>
- </sheet>
- </form>
- </field>
- </record>
- <record model="ir.ui.view" id="worksheet_tree_view">
- <field name="name">worksheet.tree.view</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <tree string="Hoja de Trabajo">
- <field name="name"/>
- <field name="vehicle_id" invisible="context.get('user_invisible', False)"/>
- <field name="user_id" invisible="context.get('user_invisible', False)"/>
- <field name="date_deadline" invisible="context.get('deadline_visible',True)"/>
- <field name="amount_total"/>
- <field name="stage_id" invisible="context.get('set_visible',False)"/>
- </tree>
- </field>
- </record>
- <record model="ir.ui.view" id="car_workshop_view_kanban">
- <field name="name">car.workshop.kanban</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <kanban default_group_by="stage_id" class="o_kanban_small_column">
- <field name="color"/>
- <field name="priority"/>
- <field name="stage_id" options='{"group_by_tooltip": {"description": "Stage Description", "legend_priority": "Use of stars"}}'/>
- <field name="user_id"/>
- <field name="description"/>
- <field name="sequence"/>
- <field name="date_deadline"/>
- <field name="tag_ids"/>
- <field name="attachment_ids"/>
- <field name="active"/>
- <templates>
- <t t-name="kanban-box">
- <div t-attf-class="oe_kanban_color_#{kanban_getcolor(record.color.raw_value)} oe_kanban_card oe_kanban_global_click">
- <div class="oe_dropdown_toggle oe_dropdown_kanban" groups="base.group_user">
- <span class="oe_e">í</span>
- <ul class="oe_dropdown_menu">
- <t t-if="widget.view.is_action_enabled('edit')"><li><a type="edit">Edit...</a></li></t>
- <t t-if="widget.view.is_action_enabled('delete')"><li><a type="delete">Delete</a></li></t>
- <li>
- <ul class="oe_kanban_project_times" groups="project.group_time_work_estimation_tasks">
- <li><a name="set_remaining_time_1" type="object" class="oe_kanban_button">1</a></li>
- <li><a name="set_remaining_time_2" type="object" class="oe_kanban_button">2</a></li>
- <li><a name="set_remaining_time_5" type="object" class="oe_kanban_button">5</a></li>
- <li><a name="set_remaining_time_10" type="object" class="oe_kanban_button">10</a></li>
- </ul>
- </li>
- <br/>
- <li><ul class="oe_kanban_colorpicker" data-field="color"/></li>
- </ul>
- </div>
- <div class="oe_kanban_content">
- <div><b><field name="name"/></b></div>
- <div>
- <field name="vehicle_id"/><br/>
- <t t-if="record.date_deadline.raw_value and record.date_deadline.raw_value lt (new Date())" t-set="red">oe_kanban_text_red</t>
- <span t-attf-class="#{red || ''}"><i><field name="date_deadline"/></i></span>
- </div>
- <div class="oe_kanban_bottom_right">
- <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar pull-right"/>
- </div>
- </div>
- <div class="oe_clear"></div>
- </div>
- </t>
- </templates>
- </kanban>
- </field>
- </record>
- <record id="worksheet_calender_view" model="ir.ui.view">
- <field name="name">worksheet.calender.view</field>
- <field name="model">car.workshop</field>
- <field eval="2" name="priority"/>
- <field name="arch" type="xml">
- <calendar color="user_id" date_start="date_deadline" string="Tasks">
- <field name="name"/>
- <field name="vehicle_id"/>
- </calendar>
- </field>
- </record>
- <record id="view_car_workshop_pivot" model="ir.ui.view">
- <field name="name">car.workshop.pivot</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <graph string="Vehicles" type="pivot">
- <field name="vehicle_id" type="row"/>
- <field name="stage_id" type="col"/>
- </graph>
- </field>
- </record>
- <record id="view_car_workshop_graph" model="ir.ui.view">
- <field name="name">car.workshop.graph</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <graph string="Project Tasks">
- <field name="vehicle_id"/>
- <field name="stage_id"/>
- </graph>
- </field>
- </record>
- <record model="ir.actions.act_window" id="worksheet_action_super_button">
- <field name="name">Hoja de Trabajo</field>
- <field name="res_model">car.workshop</field>
- <field name="context">{'search_default_vehicle_id': active_id}</field>
- <field name="view_mode">kanban,tree,form,calendar,graph</field>
- </record>
- <record id="view_vehicle_search_form" model="ir.ui.view">
- <field name="name">car.workshop.search.form</field>
- <field name="model">car.workshop</field>
- <field name="arch" type="xml">
- <search string="Worksheet">
- <field name="name" string="Tasks"/>
- <field name="tag_ids"/>
- <field name="partner_id"/>
- <field name="vehicle_id"/>
- <field name="user_id"/>
- <field name="stage_id"/>
- <filter string="Mi hoja de trabajo" domain="[('user_id','=',uid)]"/>
- <separator/>
- <filter string="Nuevo" name="draft" domain="[('stage_id.sequence', '<=', 1)]"/>
- <separator/>
- <filter string="Archivados" name="inactive" domain="[('active','=',False)]"/>
- <group expand="0" string="Agrupar por ">
- <filter string="Vehiculo" name="vehicle" context="{'group_by':'vehicle_id'}"/>
- <filter string="Hoja de trabajo" context="{'group_by':'name'}"/>
- <filter string="Asignado a" name="User" context="{'group_by':'user_id'}"/>
- <filter string="Etapa" name="Stage" context="{'group_by':'stage_id'}"/>
- <separator/>
- </group>
- </search>
- </field>
- </record>
- <record model="ir.actions.act_window" id="action_car_workshop_filtered">
- <field name="name">Hoja de tareas</field>
- <field name="res_model">car.workshop</field>
- <field name="view_mode">kanban,tree,form,calendar</field>
- </record>
- <menuitem id="main_workshop_menu" name="Car Workshop" />
- <menuitem name="Buscar" id="search_worksheet" parent="main_workshop_menu" sequence="2"/>
- <menuitem name="Lista de tareas" id="vehicle_works" parent="search_worksheet" action="action_car_workshop_filtered"/>
- <menuitem id="menu_worksheet_config" name="Configuration" parent="main_workshop_menu" sequence="4"/>
- </data>
- </openerp>
|