You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

160 lines
7.3 KiB

<?xml version="1.0"?>
<openerp>
<data>
<!-- Configurator -->
<record model="ir.ui.view" id="super_calendar_configurator_tree">
<field name="name">super_calendar_configurator_tree</field>
<field name="model">super.calendar.configurator</field>
<field name="arch" type="xml">
<tree string="Configurators">
<field name="name"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="super_calendar_configurator_form">
<field name="name">super_calendar_configurator_form</field>
<field name="model">super.calendar.configurator</field>
<field name="arch" type="xml">
<form string="Configurator">
<field name="name" select="1" colspan="2"/>
<newline/>
<field name="line_ids" nolabel="1" colspan="4">
<tree string="Lines">
<field name="name"/>
<field name="domain"/>
</tree>
<form string="Line">
<group>
<group>
<field name="name"/>
<field name="domain"/>
<field name="user_field_id"/>
</group>
<group>
<field name="date_start_field_id"/>
<field name="duration_field_id"/>
<field name="date_stop_field_id"
attrs="{'readonly':[('duration_field_id','!=',False)], 'visible': [('duration_field_id','!=',False)]}"/>
</group>
</group>
<group string="Description">
<field name="description_type"/>
<newline/>
<field name="description_field_id"
attrs="{'required':[('description_type','!=','code')], 'invisible':[('description_type','==','code')]}"/>
<group colspan="4" col="1" attrs="{'invisible':[('description_type','!=','code')]}">
<label string="Use '${o}' to refer to the involved object. E.g.: '${o.project_id.name}'" />
<field name="description_code" nolabel="1"
attrs="{'required':[('description_type','==','code')]}"/>
</group>
</group>
</form>
</field>
<newline/>
<button name="generate_calendar_records"
string="Generate Calendar" type="object" icon="gtk-go-forward" colspan="2"/>
</form>
</field>
</record>
<record model="ir.actions.act_window" id="super_calendar_configurator">
<field name="name">Calendar Configurators</field>
<field name="res_model">super.calendar.configurator</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="super_calendar_configurator_tree"/>
</record>
<!-- Calendar -->
<record model="ir.ui.view" id="super_calendar_tree">
<field name="name">super_calendar_tree</field>
<field name="model">super.calendar</field>
<field name="arch" type="xml">
<tree string="Calendar">
<field name="name"/>
<field name="date_start"/>
<field name="duration"/>
<field name="user_id"/>
<field name="configurator_id"/>
<field name="model_id"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="super_calendar_form">
<field name="name">super_calendar_form</field>
<field name="model">super.calendar</field>
<field name="arch" type="xml">
<form string="Calendar">
<sheet>
<group>
<field name="name"/>
<field name="date_start"/>
<field name="duration"/>
<field name="user_id"/>
<field name="configurator_id"/>
<field name="model_id"/>
<field name="res_id"/>
</group>
</sheet>
</form>
</field>
</record>
<record model="ir.ui.view" id="super_calendar">
<field name="name">super_calendar</field>
<field name="model">super.calendar</field>
<field name="arch" type="xml">
<calendar string="Calendar" color="model_id"
date_start="date_start" date_delay="duration"
quick_add="false">
<field name="name"/>
</calendar>
</field>
</record>
<record model="ir.ui.view" id="super_calendar_search">
<field name="name">super_calendar_search</field>
<field name="model">super.calendar</field>
<field name="arch" type="xml">
<search string="Search Calendar" >
<field name="name"/>
<field name="configurator_id" select="1"/>
<field name="model_id" select="1"/>
<field name="user_id" widget="selection" >
<filter domain="[('user_id','=',uid)]" help="My Items" icon="terp-personal"/>
</field>
<newline/>
<group expand="0" string="Extended Filters..." colspan="4" col="8">
<field name="date_start" />
<field name="duration" />
</group>
</search>
</field>
</record>
<record model="ir.actions.act_window" id="super_calendar_action">
<field name="name">Super Calendar</field>
<field name="res_model">super.calendar</field>
<field name="view_type">form</field>
<field name="view_mode">calendar,tree,form</field>
<field name="view_id" ref="super_calendar"/>
</record>
<menuitem id="super_calendar_menu" name="Super Calendar"
action="super_calendar_action"/>
<menuitem id="super_calendar_calendar" name="Calendar"
parent="super_calendar_menu" />
<menuitem id="super_calendar_calendar_calendar" name="Calendar"
parent="super_calendar_calendar" action="super_calendar_action"/>
<menuitem id="super_calendar_configuration" name="Configuration"
parent="super_calendar_menu" />
<menuitem id="super_calendar_configurators" name="Configurators"
parent="super_calendar_configuration" action="super_calendar_configurator"/>
</data>
</openerp>