-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhr_contract_view.xml
127 lines (117 loc) · 5.61 KB
/
hr_contract_view.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record id="view_contract_init_tree" model="ir.ui.view">
<field name="name">hr.contract.init.tree</field>
<field name="model">hr.contract.init</field>
<field name="arch" type="xml">
<tree string="Contract Initial Values">
<field name="name"/>
<field name="date"/>
<field name="trial_period"/>
<field name="struct_id"/>
<field name="state"/>
</tree>
</field>
</record>
<record id="view_contract_init_form" model="ir.ui.view">
<field name="name">hr.contract.init.form</field>
<field name="model">hr.contract.init</field>
<field name="arch" type="xml">
<form string="Contract Initial Values" version="7.0">
<header>
<button name="signal_approve" type="workflow" states="draft" string="Approve" class="oe_highlight" />
<button name="signal_decline" type="workflow" states="draft,approve" string="Decline" class="oe_highlight" />
<button string="Reset to New" name="set_to_draft" states="decline" type="object" groups="hr_security.group_hr_director"/>
<field name="state" widget="statusbar" statusbar_visible="draft,approve" />
</header>
<label for="name" class="oe_edit_only"/>
<h1>
<field name="name"/>
</h1>
<group>
<group>
<field name="date"/>
<field name="trial_period"/>
</group>
<group>
<field name="struct_id"/>
</group>
</group>
<group string="Initial Wages">
<field name="wage_ids" nolabel="1">
<tree string="Initial Wages" editable="bottom">
<field name="category_ids" widget="many2many_tags"/>
<field name="job_id"/>
<field name="starting_wage"/>
<field name="is_default"/>
</tree>
</field>
</group>
</form>
</field>
</record>
<record id="open_contract_init" model="ir.actions.act_window">
<field name="name">Contract Starting Values</field>
<field name="res_model">hr.contract.init</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
</record>
<menuitem action="open_contract_init"
id="menu_hr_contract_init"
parent="hr_contract.next_id_56"
sequence="10"/>
<!-- Initial Wages -->
<record id="view_init_wage_tree" model="ir.ui.view">
<field name="name">hr.contract.init.wage.tree</field>
<field name="model">hr.contract.init.wage</field>
<field name="arch" type="xml">
<tree string="Initial Wages">
<field name="category_ids" widget="many2many_tags"/>
<field name="job_id"/>
<field name="starting_wage"/>
<field name="is_default"/>
</tree>
</field>
</record>
<record id="view_init_wage_form" model="ir.ui.view">
<field name="name">hr.contract.init.wage.form</field>
<field name="model">hr.contract.init.wage</field>
<field name="arch" type="xml">
<form string="Initial Wages" version="7.0">
<group>
<group>
<field name="job_id"/>
<field name="starting_wage"/>
<field name="is_default"/>
</group>
<group>
<field name="category_ids" widget="many2many_tags"/>
</group>
</group>
</form>
</field>
</record>
<!-- Contract -->
<record id="hr_contract_view_form" model="ir.ui.view">
<field name="name">hr.contract.view.form.contract_init</field>
<field name="model">hr.contract</field>
<field name="inherit_id" ref="hr_contract.hr_contract_view_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='trial_date_start']" position="replace">
<field name="trial_date_start" class="oe_inline" on_change="onchange_trial(trial_date_start)"/> -
</xpath>
</field>
</record>
<record id="hr_contract_view_form" model="ir.ui.view">
<field name="name">hr.contract.view.form.contract_init</field>
<field name="model">hr.contract</field>
<field name="inherit_id" ref="hr_simplify.view_contract_form"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='job_id']" position="replace">
<field name="job_id" required="1" domain="[('department_id', '=', employee_dept_id)]" on_change="onchange_job(job_id)"/>
</xpath>
</field>
</record>
</data>
</openerp>