<?xml version="1.0" ?>
<terp>
	<data>
		<record model="ir.ui.view" id="view_employee_quote_form">
			<field name="name">hr_evaluation.quote.form</field>
			<field name="model">hr_evaluation.quote</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Evalution Quote">
					<field name="name" select="1" colspan="3"/>
					<field name="type_id" select="1"/>
					<field name="value_id" select="1"/>
				</form>
			</field>
		</record>
		<record model="ir.ui.view" id="view_employee_quote_tree">
			<field name="name">hr_evaluation.quote.tree</field>
			<field name="model">hr_evaluation.quote</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Evalution Quote">
					<field name="name"/>
					<field name="type_id"/>
					<field name="value_id"/>
				</tree>
			</field>
		</record>


		<record model="ir.ui.view" id="view_employee_evaluation_form">
			<field name="name">hr_evaluation.evaluation.form</field>
			<field name="model">hr_evaluation.evaluation</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Employee Evaluation">
					<notebook>
					<page string="Informal Data">
						<field name="name" select="1"/>
						<field name="employee_id" select="1"/>
						<field name="user_id" select="1"/>
						<field name="date" select="1"/>
						<separator string="Good Points" colspan="2"/>
						<separator string="Bad Points" colspan="2"/>
						<field name="info_good" colspan="2" nolabel="1"/>
						<field name="info_bad" colspan="2" nolabel="1"/>
						<separator string="To Improve" colspan="2"/>
						<separator string="Employee Response" colspan="2"/>
						<field name="info_improve" colspan="2" nolabel="1"/>
						<field name="info_employee" colspan="2" nolabel="1"/>
						<separator string="Status" colspan="4"/>
						<field name="state" search="1"/>
						<button string="Done" states="draft"/>
						<button string="Schedule next evaluation" states="draft,done"/>
					</page><page string="Quotations">
						<field name="quote_ids" colspan="4" nolabel="1"/>
					</page>
					</notebook>
				</form>
			</field>
		</record>
		<record model="ir.ui.view" id="view_employee_evaluation_tree">
			<field name="name">hr_evaluation.evaluation.tree</field>
			<field name="model">hr_evaluation.evaluation</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Employee Evaluation">
					<field name="date"/>
					<field name="employee_id"/>
					<field name="name"/>
				</tree>
			</field>
		</record>

		<record model="ir.actions.act_window" id="open_view_employee_evaluation_form">
			<field name="name">hr_evaluation.evaluation</field>
			<field name="res_model">hr_evaluation.evaluation</field>
			<field name="view_type">form</field>
			<field name="view_mode">form,tree</field>
		</record>
		<menuitem
			name="Human Resources/Evaluations/HR Responsible/Evaluations"
			id="menu_open_view_employee_evaluation_form"
			action="open_view_employee_evaluation_form"/>

		<record model="ir.actions.act_window" id="open_view_employee_evaluation_next_list">
			<field name="name">hr_evaluation.evaluation.next.list</field>
			<field name="res_model">hr_evaluation.evaluation</field>
			<field name="domain">[('date','&lt;=',time.strftime('%Y-%m-%d'))]</field>
			<field name="view_type">form</field>
			<field name="view_mode">tree,form</field>
		</record>
		<menuitem
			name="Human Resources/Evaluations/HR Responsible/Next Evaluations"
			id="menu_open_view_employee_evaluation_next_list"
			action="open_view_employee_evaluation_next_list"/>

		<record model="ir.actions.act_window" id="open_view_employee_evaluation_next_my_list">
			<field name="name">hr_evaluation.evaluation.next.list</field>
			<field name="res_model">hr_evaluation.evaluation</field>
			<field name="domain">[('date','&lt;=',time.strftime('%Y-%m-%d')),('user_id','=',uid)]</field>
			<field name="view_type">form</field>
			<field name="view_mode">tree,form</field>
		</record>
		<menuitem
			name="Human Resources/Evaluations/HR Responsible/My Next Evaluations"
			id="menu_open_view_employee_evaluation_next_my_list"
			action="open_view_employee_evaluation_next_my_list"
			groups="admin"/>

		<!--
		  Menu for the employee to view his own preceeding evaluations.
	 	  Todo Filter to this employee only. Use Wizard ?
		-->
		<record model="ir.ui.view" id="view_employee_evaluation_form_ro">
			<field name="name">hr_evaluation.evaluation.form.ro</field>
			<field name="model">hr_evaluation.evaluation</field>
			<field name="type">form</field>
			<field name="priority" eval="32"/>
			<field name="arch" type="xml">
				<form string="Employee Evaluation">
					<notebook>
					<page string="Informal Data">
						<field name="name" select="1" readonly="1"/>
						<field name="employee_id" readonly="1"/>
						<field name="user_id" select="1" readonly="1"/>
						<field name="date" select="1" readonly="1"/>
						<separator string="Good Points" colspan="2"/>
						<separator string="Bad Points" colspan="2"/>
						<field name="info_good" colspan="2" nolabel="1" readonly="1"/>
						<field name="info_bad" colspan="2" nolabel="1" readonly="1"/>
						<separator string="To Improve" colspan="2"/>
						<separator string="Employee Response" colspan="2"/>
						<field name="info_improve" colspan="2" nolabel="1" readonly="1"/>
						<field name="info_employee" colspan="3" nolabel="1" readonly="1"/>
						<separator string="Status" colspan="4"/>
						<field name="state" search="1"/>
						<button string="Done" states="draft"/>
						<button string="Schedule next evaluation" states="draft,done"/>
					</page><page string="Quotations">
						<field name="quote_ids" colspan="4" nolabel="1" readonly="1"/>
					</page>
					</notebook>
				</form>
			</field>
		</record>
		<record model="ir.actions.act_window" id="open_view_employee_evaluation_my_old_list">
			<field name="name">hr_evaluation.evaluation.next.list</field>
			<field name="res_model">hr_evaluation.evaluation</field>
			<field name="view_type">form</field>
			<field name="view_mode">form,tree</field>
			<field name="view_id" ref="view_employee_evaluation_form_ro"/>
		</record>
		<menuitem
			name="Human Resources/Evaluations/My Preceeding Evaluations"
			id="menu_open_view_employee_my_old_evaluation_list"
			action="open_view_employee_evaluation_my_old_list"/>

		#
		# Evaluation Criterions
		#
		<record model="ir.ui.view" id="view_evaluation_type_tree">
			<field name="name">hr_evaluation.type.tree</field>
			<field name="model">hr_evaluation.type</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Evaluation Criterion">
						<field name="name" select="1"/>
						<field name="score" select="1"/>
				</tree>
			</field>
		</record>
		<record model="ir.ui.view" id="view_evaluation_type_form">
			<field name="name">hr_evaluation.type.form</field>
			<field name="model">hr_evaluation.type</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Evaluation Criterion">
					<notebook>
					<page string="Information">
						<field name="name" select="1"/>
						<field name="active" select="1"/>
						<field name="score" select="1"/>
						<separator string="Choices Results" colspan="4"/>
						<field name="value_ids" colspan="4" nolabel="1"/>
						<separator string="Apply to categories" colspan="4"/>
						<field name="category_ids" colspan="4" nolabel="1">
							<form>
								<field name="name" select="1"/>
							</form>
						</field>
					</page><page string="Notes">
						<field name="info" nolabel="1" colspan="4"/>
					</page>
					</notebook>
				</form>
			</field>
		</record>
		<record model="ir.actions.act_window" id="open_view_evaluation_type_form">
			<field name="name">hr_evaluation.type.form</field>
			<field name="res_model">hr_evaluation.type</field>
			<field name="view_type">form</field>
			<field name="view_mode">form,tree</field>
		</record>
		<menuitem
			name="Human Resources/Evaluations/Configuration/Evaluation Criterions"
			id="menu_open_view_evaluation_type_form"
			action="open_view_evaluation_type_form"/>

	</data>
</terp>
