~magentoerpconnect-core-editors/magentoerpconnect/openerp6-module-with-sale-line-uom-patch

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
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
<?xml version="1.0" encoding="utf-8"?>
<openerp>
	<data>
		<!--Magento Product Category Tree/Form view  -->

		<record model="ir.ui.view" id="product_category_form_view_magerp2">
			<field name="name">product.category.form_view_magerp2</field>
			<field name="model">product.category</field>
			<field name="inherit_id" ref="product.product_category_form_view" />
			<field name="type">form</field>
			<field name="arch" type="xml">
				<xpath expr="/form/field[@name='sequence']" position="after">
					<group colspan="4" col="4" attrs="{'invisible':[('magento_exportable','!=',1)],'readonly':[('level','=',0)]}">
						<separator string="Magento Information" colspan="4" />
						<notebook attrs="{'invisible':[('magento_exportable','!=',1)]}" colspan="4">
							<page string="General Information">
								<group cols="2" colspan="4">
									<group col="2" colspan="1">
										<separator string="Meta Information" colspan="2" />
										<field name="meta_title" colspan="2" />
										<field name="meta_keywords" colspan="2" />
										<field name="meta_description" colspan="2" />
										<field name="url_key" colspan="2" />
										<field name="level" colspan="2" />
									</group>
									<group col="1" colspan="1">
										<separator string="Category Image" />
										<field name="image" nolabel="1" widget="image" />
										<field name="image_name" colspan="1" nolabel="1" />
										<separator string="Description" />
										<field name="description" colspan="1" nolabel="1" />
										<group col="4" colspan="1">
											<field name="is_active" colspan="1" />
											<field name="magento_parent_id" />
										</group>
									</group>
								</group>

							</page>
							<page string="Display Settings">
								<group col="4" colspan="4">
									<separator string="Display Mode" colspan="4" />
									<field name="display_mode" colspan="1" nolabel="1" />
									<label string="Products only means that the products associated to the category will display, but not any static blocks.Static block only means that the selected static block will display, but none of the products.Static block and products means that the static block will display with the products listed directly beneath it." colspan="3" />
								</group>
								<separator string="Use Anchor" colspan="4" />
								<group col="4" colspan="4">
									<field name="is_anchor" colspan="1" />
									<label string="Anchored categories will display all products associated to all child categories (and child of child, and child of child of child,etc.) on that category's page, along with the products associated directly to the parent category." colspan="3" />
								</group>
								<separator string="Sorting method" colspan="4" />
								<field name="available_sort_by" />
								<field name="default_sort_by" />
							</page>
						</notebook>
					</group>
				</xpath>
			</field>
		</record>

		<record model="ir.ui.view" id="product_category_form_view_magerp">
			<field name="name">product.category.form_view_magerp</field>
			<field name="model">product.category</field>
			<field name="inherit_id" ref="product.product_category_form_view" />
			<field name="type">form</field>
			<field name="arch" type="xml">
				<field name="sequence" position="after">
					<field name="magento_exportable" />
				</field>
			</field>
		</record>

		<!--Magento product_attribute_set Tree/Form view  -->
		<record model="ir.ui.view" id="magerp_product_attribute_set_form">
			<field name="name">magerp.product_attribute_set.form</field>
			<field name="model">magerp.product_attribute_set</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Magento Product Attribute Sets">
					<group col="4" colspan="4">
						<field name="sort_order" readonly="1" />
						<field name="attribute_set_name" readonly="1" />
					</group>
					<separator string="Attributes in Set" colspan="4" />
					<field name="attributes" nolabel="1" readonly="1" />
				</form>
			</field>
		</record>
		<record model="ir.ui.view" id="magerp_product_attribute_set_tree">
			<field name="name">magerp.product_attribute_set.tree</field>
			<field name="model">magerp.product_attribute_set</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Magento Product Attribute Set">
					<field name="sort_order" select="2" />
					<field name="attribute_set_name" select="1" />
				</tree>
			</field>
		</record>
		<record id="act_magerp_product_attribute_set_form" model="ir.actions.act_window">
			<field name="name">Magento Product Attribute Sets</field>
			<field name="res_model">magerp.product_attribute_set</field>
			<field name="src_model">magerp.product_attribute_set</field>
			<field name="type">ir.actions.act_window</field>
			<field name="view_type">form</field>
			<field name="view_mode">tree,form</field>
			<field name="view_id" ref="magerp_product_attribute_set_tree" />
		</record>

		<!--Magento product_attributes Tree/Form view  -->
		<record model="ir.ui.view" id="magerp_product_attributes_form">
			<field name="name">magerp.product_attributes.form</field>
			<field name="model">magerp.product_attributes</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Magento Product Attributes">
					<group col="4" colspan="4">
						<field name="attribute_code" />
						<field name="frontend_input" select="2" />
						<field name="frontend_class" />
						<field name="backend_model" />
						<field name="backend_type" select="2" />
						<field name="frontend_label"/>

						<field name="is_visible_in_advanced_search" select="2" />
						<field name="is_global" />
						<field name="is_filterable" />
						<field name="is_comparable" />
						<field name="is_visible" />
						<field name="is_searchable" />
						<field name="is_user_defined" />
						<field name="is_configurable" />

						<field name="is_visible_on_front" />
						<field name="is_used_for_price_rules" />
						<field name="is_unique" />
						<field name="is_required" />
						<field name="position" />

						<field name="group" />
						<field name="apply_to" select="2" />
						<field name="default_value" />
						<field name="note" />
						<field name="entity_type_id" />
						<field name="options" readonly="1" />
					</group>
				</form>
			</field>
		</record>
		<record model="ir.ui.view" id="magerp_product_attributes_tree">
			<field name="name">magerp.product_attributes.tree</field>
			<field name="model">magerp.product_attributes</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Magento Product Attributes">
					<field name="attribute_code" select="1" />
					<field name="frontend_label" select="1"/>
					<field name="is_visible" select="1"/>
					<field name="is_required" select="1"/>
					<field name="is_searchable" select="1" />
					<field name="is_comparable" select="1" />
					<field name="entity_type_id" select="1" />
					<field name="group" select="1" />
				</tree>
			</field>
		</record>
		<record id="act_magerp_product_attributes_form" model="ir.actions.act_window">
			<field name="name">Magento Product Attributes</field>
			<field name="res_model">magerp.product_attributes</field>
			<field name="src_model">magerp.product_attributes</field>
			<field name="type">ir.actions.act_window</field>
			<field name="view_type">form</field>
			<field name="view_mode">tree,form</field>
			<field name="view_id" ref="magerp_product_attributes_tree" />
		</record>

		<!--Magento product_attribute groups Tree/Form view  -->
		<record model="ir.ui.view" id="magerp_product_attribute_groups_form">
			<field name="name">magerp.product_attribute_groups.form</field>
			<field name="model">magerp.product_attribute_groups</field>
			<field name="type">form</field>
			<field name="arch" type="xml">
				<form string="Magento Product Attributes Groups">
					<group col="4" colspan="4">
						<field name="attribute_group_name" />
						<field name="attribute_set" />
						<field name="default_id" />
						<field name="sort_order" />
					</group>
				</form>
			</field>
		</record>
		<record model="ir.ui.view" id="magerp_product_attribute_groups_tree">
			<field name="name">magerp.product_attribute_groups.tree</field>
			<field name="model">magerp.product_attribute_groups</field>
			<field name="type">tree</field>
			<field name="arch" type="xml">
				<tree string="Magento Product Attribute groups">
					<field name="attribute_group_name" select="1" />
					<field name="attribute_set" select="2" />
					<field name="default_id" select="2" />
					<field name="sort_order" select="2" />
				</tree>
			</field>
		</record>
		<record id="act_magerp_product_attribute_groups_form" model="ir.actions.act_window">
			<field name="name">Magento Product Attribute Groups</field>
			<field name="res_model">magerp.product_attribute_groups</field>
			<field name="src_model">magerp.product_attribute_groups</field>
			<field name="type">ir.actions.act_window</field>
			<field name="view_type">form</field>
			<field name="view_mode">tree,form</field>
			<field name="view_id" ref="magerp_product_attribute_groups_tree" />
		</record>

		<!-- This is a product inherited form that will be dynamically populated-->
		<record model="ir.ui.view" id="product_product_form_view_magerp">
			<field name="name">product.normal.form_magerp</field>
			<field name="model">product.product</field>
			<field name="inherit_id" ref="product.product_normal_form_view" />
			<field name="type">form</field>
			<field name="arch" type="xml">
				<data>
					<xpath expr="/form/group/group/field[@name='ean13']" position="after">
						<field name="magento_sku" select="2" attrs="{'required':[('magento_exportable','==',True)]}"/>
					</xpath>
					<xpath expr="/form/group/group/field[@name='variants']" position="after">
						<field name="set" select="2" attrs="{'required':[('magento_exportable','==',True)]}"/>
					</xpath>
					<xpath expr="/form/notebook" position="before">
						<field name="magento_exportable" select="2"/>
					</xpath>
				</data>
			</field>
		</record>
		<record model="ir.ui.view" id="product_product_form_view_magerpdynamic">
			<field name="name">product.normal.form_magerp_dynamic</field>
			<field name="model">product.product</field>
			<field name="inherit_id" ref="product.product_normal_form_view" />
			<field name="type">form</field>
			<field name="arch" type="xml">
				<xpath expr="/form/notebook" position="inside">
					<page string="attributes_placeholder"/>
				</xpath>
			</field>
		</record>

		<!--Magento Product Type Tree/Form view  -->
	    <record model="ir.ui.view" id="magerp_product_type_form">
		    <field name="name">magerp.product_product_type.form</field>
		    <field name="model">magerp.product_product_type</field>
		    <field name="type">form</field>
		    <field name="priority" eval="5"/>
		    <field name="arch" type="xml">
		    <form string="Product Type">
				    <field name="product_type"/>
				    <field name="name"/>
		    </form>
		    </field>
	    </record>
	
	    <record model="ir.ui.view" id="magerp_product_type_tree">
		    <field name="name">magerp.product_product_type.tree</field>
		    <field name="model">magerp.product_product_type</field>
		    <field name="type">tree</field>
		    <field name="priority" eval="5"/>
		    <field name="arch" type="xml">
			    <tree string="Product Type">
				    <field name="name" select="1"/>
				    <field name="product_type" select="1"/>			
			    </tree>
		    </field>
	    </record>

        <record model="ir.actions.act_window" id="act_magerp_product_type_form">
            <field name="name">Product Types</field>
            <field name="res_model">magerp.product_product_type</field>
            <field name="view_mode">tree,form</field>
        </record>
	</data>
</openerp>