Merge lp:~openbig/bigconsulting/functional_field_add_in_product_tab into lp:bigconsulting
- functional_field_add_in_product_tab
- Merge into addons
Proposed by
Atik Agewan(OpenERP)
Status: | Merged |
---|---|
Merged at revision: | 28 |
Proposed branch: | lp:~openbig/bigconsulting/functional_field_add_in_product_tab |
Merge into: | lp:bigconsulting |
Diff against target: |
409 lines (+219/-59) 3 files modified
product_price_information/product_price_info.py (+136/-13) product_price_information/product_price_info_view.xml (+48/-11) product_price_information/wizard/sale_prize_information_view.xml (+35/-35) |
To merge this branch: | bzr merge lp:~openbig/bigconsulting/functional_field_add_in_product_tab |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
openbig | Pending | ||
Review via email: mp+28188@code.launchpad.net |
Commit message
Description of the change
Functional field are added in product tab.....
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'product_price_information/product_price_info.py' | |||
2 | --- product_price_information/product_price_info.py 2010-05-26 14:22:22 +0000 | |||
3 | +++ product_price_information/product_price_info.py 2010-06-22 14:09:30 +0000 | |||
4 | @@ -1,7 +1,7 @@ | |||
5 | 1 | # -*- encoding: utf-8 -*- | 1 | # -*- encoding: utf-8 -*- |
6 | 2 | ############################################################################## | 2 | ############################################################################## |
7 | 3 | # | 3 | # |
9 | 4 | # OpenERP, Open Source Management Solution | 4 | # OpenERP, Open Source Management Solution |
10 | 5 | # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). All Rights Reserved | 5 | # Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>). All Rights Reserved |
11 | 6 | # $Id$ | 6 | # $Id$ |
12 | 7 | # | 7 | # |
13 | @@ -21,20 +21,20 @@ | |||
14 | 21 | ############################################################################## | 21 | ############################################################################## |
15 | 22 | from osv import fields, osv | 22 | from osv import fields, osv |
16 | 23 | from tools import config | 23 | from tools import config |
18 | 24 | 24 | ||
19 | 25 | class sale_order_line(osv.osv): | 25 | class sale_order_line(osv.osv): |
20 | 26 | _inherit = "sale.order.line" | 26 | _inherit = "sale.order.line" |
21 | 27 | 27 | ||
22 | 28 | _columns = { | 28 | _columns = { |
23 | 29 | 'sale_price_unit_tax': fields.float('Sale price W/O taxes'), | 29 | 'sale_price_unit_tax': fields.float('Sale price W/O taxes'), |
24 | 30 | } | 30 | } |
26 | 31 | 31 | ||
27 | 32 | def product_id_change(self, cr, uid, ids, pricelist, product, qty=0, | 32 | def product_id_change(self, cr, uid, ids, pricelist, product, qty=0, |
28 | 33 | uom=False, qty_uos=0, uos=False, name='', partner_id=False, | 33 | uom=False, qty_uos=0, uos=False, name='', partner_id=False, |
29 | 34 | lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False): | 34 | lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False): |
31 | 35 | 35 | ||
32 | 36 | tax_obj = self.pool.get('account.tax') | 36 | tax_obj = self.pool.get('account.tax') |
34 | 37 | 37 | ||
35 | 38 | result = super(sale_order_line, self).product_id_change(cr, uid, ids, pricelist, product, qty, | 38 | result = super(sale_order_line, self).product_id_change(cr, uid, ids, pricelist, product, qty, |
36 | 39 | uom, qty_uos, uos, name, partner_id, lang, update_tax, date_order, packaging, fiscal_position, flag) | 39 | uom, qty_uos, uos, name, partner_id, lang, update_tax, date_order, packaging, fiscal_position, flag) |
37 | 40 | if product: | 40 | if product: |
38 | @@ -43,19 +43,19 @@ | |||
39 | 43 | result['value']['sale_price_unit_tax'] = product_obj.product_tmpl_id.price_unit_tax | 43 | result['value']['sale_price_unit_tax'] = product_obj.product_tmpl_id.price_unit_tax |
40 | 44 | 44 | ||
41 | 45 | return result | 45 | return result |
43 | 46 | 46 | ||
44 | 47 | sale_order_line() | 47 | sale_order_line() |
45 | 48 | 48 | ||
46 | 49 | class sale_order(osv.osv): | 49 | class sale_order(osv.osv): |
47 | 50 | _name = "sale.order" | 50 | _name = "sale.order" |
48 | 51 | _inherit = "sale.order" | 51 | _inherit = "sale.order" |
50 | 52 | 52 | ||
51 | 53 | def onchange_shop_id(self, cr, uid, ids, shop_id): | 53 | def onchange_shop_id(self, cr, uid, ids, shop_id): |
52 | 54 | res = super(sale_order, self).onchange_shop_id(cr, uid, id, shop_id) | 54 | res = super(sale_order, self).onchange_shop_id(cr, uid, id, shop_id) |
53 | 55 | if 'value' in res and shop_id: | 55 | if 'value' in res and shop_id: |
54 | 56 | res['value']['price_type'] = self.pool.get('sale.shop').browse(cr, uid , shop_id).price_type | 56 | res['value']['price_type'] = self.pool.get('sale.shop').browse(cr, uid , shop_id).price_type |
55 | 57 | return res | 57 | return res |
57 | 58 | 58 | ||
58 | 59 | sale_order() | 59 | sale_order() |
59 | 60 | 60 | ||
60 | 61 | 61 | ||
61 | @@ -86,7 +86,7 @@ | |||
62 | 86 | _defaults = { | 86 | _defaults = { |
63 | 87 | 'price_type': lambda *a: 'tax_included', | 87 | 'price_type': lambda *a: 'tax_included', |
64 | 88 | } | 88 | } |
66 | 89 | 89 | ||
67 | 90 | def set_default(self, cr, uid, ids, context=None): | 90 | def set_default(self, cr, uid, ids, context=None): |
68 | 91 | for o in self.browse(cr, uid, ids, context=context): | 91 | for o in self.browse(cr, uid, ids, context=context): |
69 | 92 | ir_values_obj = self.pool.get('ir.values') | 92 | ir_values_obj = self.pool.get('ir.values') |
70 | @@ -97,8 +97,8 @@ | |||
71 | 97 | 'res_model': 'ir.actions.configuration.wizard', | 97 | 'res_model': 'ir.actions.configuration.wizard', |
72 | 98 | 'type': 'ir.actions.act_window', | 98 | 'type': 'ir.actions.act_window', |
73 | 99 | 'target': 'new', | 99 | 'target': 'new', |
76 | 100 | } | 100 | } |
77 | 101 | 101 | ||
78 | 102 | def action_cancel(self,cr,uid,ids,conect=None): | 102 | def action_cancel(self,cr,uid,ids,conect=None): |
79 | 103 | return { | 103 | return { |
80 | 104 | 'view_type': 'form', | 104 | 'view_type': 'form', |
81 | @@ -107,5 +107,128 @@ | |||
82 | 107 | 'type': 'ir.actions.act_window', | 107 | 'type': 'ir.actions.act_window', |
83 | 108 | 'target':'new', | 108 | 'target':'new', |
84 | 109 | } | 109 | } |
85 | 110 | |||
86 | 111 | sale_shop_price_method_policy() | ||
87 | 112 | \ No newline at end of file | 110 | \ No newline at end of file |
88 | 111 | |||
89 | 112 | sale_shop_price_method_policy() | ||
90 | 113 | |||
91 | 114 | |||
92 | 115 | class product_product(osv.osv): | ||
93 | 116 | _name = "product.product" | ||
94 | 117 | _inherit = "product.product" | ||
95 | 118 | _description = "Product" | ||
96 | 119 | |||
97 | 120 | def _get_all_values(self, cr, uid, ids, name, arg, context={}): | ||
98 | 121 | res = {} | ||
99 | 122 | product = ids | ||
100 | 123 | product_obj = self.pool.get('product.product') | ||
101 | 124 | obj2 = self.pool.get('product.pricelist.item') | ||
102 | 125 | obj = self.pool.get('product.pricelist') | ||
103 | 126 | obj3 = self.pool.get('sale.order.line') | ||
104 | 127 | for line in product_obj.browse(cr, uid, product, context=context): | ||
105 | 128 | partner = line.pi_partner_id.id | ||
106 | 129 | pricelist = line.pi_pricelist_id.id | ||
107 | 130 | qty1 = line.pi_quantity1 | ||
108 | 131 | qty2 = line.pi_quantity2 | ||
109 | 132 | if pricelist != False: | ||
110 | 133 | val1 = obj.price_get(cr, uid, [pricelist], line.id, qty1, partner) | ||
111 | 134 | for key,values in val1.items(): | ||
112 | 135 | c_price1 = values | ||
113 | 136 | val2 = obj.price_get(cr, uid, [pricelist], line.id, qty2, partner) | ||
114 | 137 | for key,values in val2.items(): | ||
115 | 138 | c_price2 = values | ||
116 | 139 | item_line = obj2.search(cr,uid,[]) | ||
117 | 140 | list = [] | ||
118 | 141 | for line2 in obj2.browse(cr, uid, item_line, context=context): | ||
119 | 142 | if line.id == line2.product_id.id: | ||
120 | 143 | list.append(line.min_quantity) | ||
121 | 144 | if list == []: | ||
122 | 145 | m_qty = 1.0 | ||
123 | 146 | else: | ||
124 | 147 | m_qty = max(list) | ||
125 | 148 | val3 = obj.price_get(cr, uid, [pricelist], line.id, m_qty, partner) | ||
126 | 149 | for key,values in val3.items(): | ||
127 | 150 | c_price3 = values | ||
128 | 151 | list_price = product_obj.browse(cr, uid, line.id).standard_price | ||
129 | 152 | list_price1 = list_price * qty1 | ||
130 | 153 | list_price2 = list_price * qty2 | ||
131 | 154 | read_id = obj3.search(cr,uid,[('product_id','=',line.id)]) | ||
132 | 155 | if read_id == []: | ||
133 | 156 | last_price = 0.0 | ||
134 | 157 | qty_last = 0.0 | ||
135 | 158 | last_list_price = 0.0 | ||
136 | 159 | else: | ||
137 | 160 | last_id = max(read_id) | ||
138 | 161 | last_brw = obj3.browse(cr,uid,[last_id],context=context) | ||
139 | 162 | for rec in last_brw: | ||
140 | 163 | product2 = rec.product_id.id | ||
141 | 164 | if line.id == product2: | ||
142 | 165 | last_price = rec.price_unit | ||
143 | 166 | qty_last = rec.product_uom_qty | ||
144 | 167 | val_last = obj.price_get(cr, uid,[pricelist], line.id, qty_last) | ||
145 | 168 | for key,values in val_last.items(): | ||
146 | 169 | last_list_price = values | ||
147 | 170 | |||
148 | 171 | for id in ids: | ||
149 | 172 | res[id] = {} | ||
150 | 173 | if 'pi_customer_prices1' in name: | ||
151 | 174 | res[id]['pi_customer_prices1'] = c_price1 | ||
152 | 175 | if 'pi_customer_prices2' in name: | ||
153 | 176 | res[id]['pi_customer_prices2'] = c_price2 | ||
154 | 177 | if 'pi_list_prices1' in name: | ||
155 | 178 | res[id]['pi_list_prices1'] = list_price1 | ||
156 | 179 | if 'pi_list_prices2'in name: | ||
157 | 180 | res[id]['pi_list_prices2']= list_price2 | ||
158 | 181 | if 'pi_next_better_price_qty'in name: | ||
159 | 182 | res[id]['pi_next_better_price_qty']= m_qty | ||
160 | 183 | if 'pi_best_price_on_qty'in name: | ||
161 | 184 | res[id]['pi_best_price_on_qty']= c_price3 | ||
162 | 185 | if 'pi_last_customer_prices'in name: | ||
163 | 186 | res[id]['pi_last_customer_prices']= last_price | ||
164 | 187 | if 'pi_last_list_prices'in name: | ||
165 | 188 | res[id]['pi_last_list_prices']= last_list_price | ||
166 | 189 | if 'pi_qty_buyed'in name: | ||
167 | 190 | res[id]['pi_qty_buyed']= qty_last | ||
168 | 191 | |||
169 | 192 | else: | ||
170 | 193 | for id in ids: | ||
171 | 194 | res[id] = {} | ||
172 | 195 | if 'pi_customer_prices1' in name: | ||
173 | 196 | res[id]['pi_customer_prices1'] = 0.0 | ||
174 | 197 | if 'pi_customer_prices2' in name: | ||
175 | 198 | res[id]['pi_customer_prices2'] = 0.0 | ||
176 | 199 | if 'pi_list_prices1' in name: | ||
177 | 200 | res[id]['pi_list_prices1'] = 0.0 | ||
178 | 201 | if 'pi_list_prices2'in name: | ||
179 | 202 | res[id]['pi_list_prices2']= 0.0 | ||
180 | 203 | if 'pi_next_better_price_qty'in name: | ||
181 | 204 | res[id]['pi_next_better_price_qty']= 0.0 | ||
182 | 205 | if 'pi_best_price_on_qty'in name: | ||
183 | 206 | res[id]['pi_best_price_on_qty']= 0.0 | ||
184 | 207 | if 'pi_last_customer_prices'in name: | ||
185 | 208 | res[id]['pi_last_customer_prices']= 0.0 | ||
186 | 209 | if 'pi_last_list_prices'in name: | ||
187 | 210 | res[id]['pi_last_list_prices']= 0.0 | ||
188 | 211 | if 'pi_qty_buyed'in name: | ||
189 | 212 | res[id]['pi_qty_buyed']= 0.0 | ||
190 | 213 | return res | ||
191 | 214 | |||
192 | 215 | _columns = { | ||
193 | 216 | 'pi_quantity1': fields.float('Quantity1'), | ||
194 | 217 | 'pi_quantity2': fields.float('Quantity2'), | ||
195 | 218 | 'pi_pricelist_id': fields.many2one('product.pricelist', 'Pricelist'), | ||
196 | 219 | 'pi_partner_id': fields.many2one('res.partner', 'Customer'), | ||
197 | 220 | 'pi_customer_prices1': fields.function(_get_all_values, method=True, type='float', string='Costomer Prices',multi='pi_customer_prices1'), | ||
198 | 221 | 'pi_customer_prices2': fields.function(_get_all_values, method=True, type='float', string='Costomer Prices',multi='pi_customer_prices2'), | ||
199 | 222 | 'pi_list_prices1': fields.function(_get_all_values, method=True, type='float', string='List Prices',multi='pi_list_prices1'), | ||
200 | 223 | 'pi_list_prices2': fields.function(_get_all_values, method=True, type='float', string='List Prices',multi='pi_list_prices2'), | ||
201 | 224 | 'pi_next_better_price_qty': fields.function(_get_all_values, method=True, type='float', string='Next Better Price Qty',multi='pi_next_better_price_qty'), | ||
202 | 225 | 'pi_best_price_on_qty': fields.function(_get_all_values, method=True, type='float', string='Best Price On Quantity',multi='pi_best_price_on_qty'), | ||
203 | 226 | 'pi_last_customer_prices': fields.function(_get_all_values, method=True, type='float', string='Last Costomer Prices',multi='pi_last_customer_prices'), | ||
204 | 227 | 'pi_last_list_prices': fields.function(_get_all_values, method=True, type='float', string='Last List Prices',multi='pi_last_list_prices'), | ||
205 | 228 | 'pi_qty_buyed': fields.function(_get_all_values, method=True, type='float', string='Quantity Buyed',multi='pi_qty_buyed'), | ||
206 | 229 | } | ||
207 | 230 | _defaults = { | ||
208 | 231 | 'pi_quantity1': lambda *a: 1.0, | ||
209 | 232 | 'pi_quantity2': lambda *a: 5.0, | ||
210 | 233 | } | ||
211 | 234 | product_product() | ||
212 | 235 | |||
213 | 113 | 236 | ||
214 | === modified file 'product_price_information/product_price_info_view.xml' | |||
215 | --- product_price_information/product_price_info_view.xml 2010-05-20 14:03:55 +0000 | |||
216 | +++ product_price_information/product_price_info_view.xml 2010-06-22 14:09:30 +0000 | |||
217 | @@ -1,9 +1,7 @@ | |||
218 | 1 | <?xml version="1.0" ?> | 1 | <?xml version="1.0" ?> |
219 | 2 | <openerp> | 2 | <openerp> |
224 | 3 | <data> | 3 | <data> |
225 | 4 | 4 | <!-- Adding shop price field on sale order line form below Unit Price --> | |
222 | 5 | <!-- Adding shop price field on sale order line form below Unit Price --> | ||
223 | 6 | |||
226 | 7 | <record model="ir.ui.view" id="view_sale_order_line_tree_direct_delivery"> | 5 | <record model="ir.ui.view" id="view_sale_order_line_tree_direct_delivery"> |
227 | 8 | <field name="name">sale.order.form2</field> | 6 | <field name="name">sale.order.form2</field> |
228 | 9 | <field name="model">sale.order</field> | 7 | <field name="model">sale.order</field> |
229 | @@ -15,7 +13,7 @@ | |||
230 | 15 | </xpath> | 13 | </xpath> |
231 | 16 | </field> | 14 | </field> |
232 | 17 | </record> | 15 | </record> |
234 | 18 | 16 | ||
235 | 19 | <record model="ir.ui.view" id="product_tax_include_tree"> | 17 | <record model="ir.ui.view" id="product_tax_include_tree"> |
236 | 20 | <field name="name">product.tax.include.tree</field> | 18 | <field name="name">product.tax.include.tree</field> |
237 | 21 | <field name="model">product.product</field> | 19 | <field name="model">product.product</field> |
238 | @@ -27,19 +25,58 @@ | |||
239 | 27 | </field> | 25 | </field> |
240 | 28 | </field> | 26 | </field> |
241 | 29 | </record> | 27 | </record> |
243 | 30 | 28 | ||
244 | 31 | <record id="view_partner_property_form" model="ir.ui.view"> | 29 | <record id="view_partner_property_form" model="ir.ui.view"> |
245 | 32 | <field name="name">sale.shop.property.form.inherit</field> | 30 | <field name="name">sale.shop.property.form.inherit</field> |
246 | 33 | <field name="model">sale.shop</field> | 31 | <field name="model">sale.shop</field> |
247 | 34 | <field name="type">form</field> | 32 | <field name="type">form</field> |
248 | 35 | <field name="inherit_id" ref="sale.view_shop_form"/> | 33 | <field name="inherit_id" ref="sale.view_shop_form"/> |
249 | 36 | <field name="arch" type="xml"> | 34 | <field name="arch" type="xml"> |
251 | 37 | <field name="project_id" position="after"> | 35 | <field name="project_id" position="after"> |
252 | 38 | <field name="price_type"/> | 36 | <field name="price_type"/> |
253 | 39 | </field> | 37 | </field> |
254 | 40 | </field> | 38 | </field> |
255 | 41 | </record> | 39 | </record> |
257 | 42 | 40 | ||
258 | 41 | <!--product.product inherit view --> | ||
259 | 42 | <record id="product_product_price_information_inherit" model="ir.ui.view"> | ||
260 | 43 | <field name="name">product.product.price.information.inherit</field> | ||
261 | 44 | <field name="model">product.product</field> | ||
262 | 45 | <field name="type">form</field> | ||
263 | 46 | <field name="inherit_id" ref="product.product_normal_form_view"/> | ||
264 | 47 | <field name="arch" type="xml"> | ||
265 | 48 | <notebook colspan="4" position="inside"> | ||
266 | 49 | <page string='Price Information'> | ||
267 | 50 | <field name="pi_partner_id"/> | ||
268 | 51 | <field name="pi_pricelist_id"/> | ||
269 | 52 | <field name="pi_quantity1"/> | ||
270 | 53 | <field name="pi_quantity2"/> | ||
271 | 54 | <newline/> | ||
272 | 55 | <group col="6" colspan="4"> | ||
273 | 56 | <group col="4" colspan="3"> | ||
274 | 57 | <separator string="Prices of Product" colspan="2"/> | ||
275 | 58 | <newline/> | ||
276 | 59 | <field name="pi_customer_prices1"/> | ||
277 | 60 | <field name="pi_customer_prices2" nolabel="1"/> | ||
278 | 61 | <field name="pi_list_prices1"/> | ||
279 | 62 | <field name="pi_list_prices2" nolabel="1"/> | ||
280 | 63 | <field name="pi_next_better_price_qty"/> | ||
281 | 64 | <newline/> | ||
282 | 65 | <field name="pi_best_price_on_qty"/> | ||
283 | 66 | </group> | ||
284 | 67 | <group col="3" colspan="3"> | ||
285 | 68 | <separator string="Price on Last Sale" colspan="2"/> | ||
286 | 69 | <newline/> | ||
287 | 70 | <field name="pi_last_customer_prices"/> | ||
288 | 71 | <field name="pi_last_list_prices"/> | ||
289 | 72 | <field name="pi_qty_buyed"/> | ||
290 | 73 | </group> | ||
291 | 74 | </group> | ||
292 | 75 | </page> | ||
293 | 76 | </notebook> | ||
294 | 77 | </field> | ||
295 | 78 | </record> | ||
296 | 79 | |||
297 | 43 | <record id="view_config_price_policy" model="ir.ui.view"> | 80 | <record id="view_config_price_policy" model="ir.ui.view"> |
298 | 44 | <field name="name">Price Method for Sale Order Shop</field> | 81 | <field name="name">Price Method for Sale Order Shop</field> |
299 | 45 | <field name="model">sale.shop.price.method</field> | 82 | <field name="model">sale.shop.price.method</field> |
300 | @@ -55,7 +92,7 @@ | |||
301 | 55 | </form> | 92 | </form> |
302 | 56 | </field> | 93 | </field> |
303 | 57 | </record> | 94 | </record> |
305 | 58 | 95 | ||
306 | 59 | <record id="action_config_price_policy" model="ir.actions.act_window"> | 96 | <record id="action_config_price_policy" model="ir.actions.act_window"> |
307 | 60 | <field name="name">Price Method for Sale Order Shop</field> | 97 | <field name="name">Price Method for Sale Order Shop</field> |
308 | 61 | <field name="type">ir.actions.act_window</field> | 98 | <field name="type">ir.actions.act_window</field> |
309 | @@ -64,12 +101,12 @@ | |||
310 | 64 | <field name="view_mode">form</field> | 101 | <field name="view_mode">form</field> |
311 | 65 | <field name="target">new</field> | 102 | <field name="target">new</field> |
312 | 66 | </record> | 103 | </record> |
314 | 67 | 104 | ||
315 | 68 | <record id="config_wizard_step_shop_price_policy" model="ir.actions.todo"> | 105 | <record id="config_wizard_step_shop_price_policy" model="ir.actions.todo"> |
316 | 69 | <field name="name">Shop Price</field> | 106 | <field name="name">Shop Price</field> |
317 | 70 | <field name="note">This Configuration step use to set default price type for shop.</field> | 107 | <field name="note">This Configuration step use to set default price type for shop.</field> |
318 | 71 | <field name="action_id" ref="action_config_price_policy"/> | 108 | <field name="action_id" ref="action_config_price_policy"/> |
319 | 72 | </record> | 109 | </record> |
321 | 73 | 110 | ||
322 | 74 | </data> | 111 | </data> |
323 | 75 | </openerp> | 112 | </openerp> |
324 | 76 | 113 | ||
325 | === modified file 'product_price_information/wizard/sale_prize_information_view.xml' | |||
326 | --- product_price_information/wizard/sale_prize_information_view.xml 2010-06-09 10:37:58 +0000 | |||
327 | +++ product_price_information/wizard/sale_prize_information_view.xml 2010-06-22 14:09:30 +0000 | |||
328 | @@ -6,46 +6,46 @@ | |||
329 | 6 | <field name="model">sale.prize.information</field> | 6 | <field name="model">sale.prize.information</field> |
330 | 7 | <field name="type">form</field> | 7 | <field name="type">form</field> |
331 | 8 | <field name="arch" type="xml"> | 8 | <field name="arch" type="xml"> |
344 | 9 | <form string="Sale Prize Information"> | 9 | <form string="Sale Prize Information"> |
345 | 10 | <group col="6" colspan="4"> | 10 | <group col="6" colspan="4"> |
346 | 11 | <group col="2" colspan="3"> | 11 | <group col="2" colspan="3"> |
347 | 12 | <field name="partner_id"/> | 12 | <field name="partner_id"/> |
348 | 13 | <field name="product_id"/> | 13 | <field name="product_id"/> |
349 | 14 | <separator string="Prices of Product"/> | 14 | <separator string="Prices of Product"/> |
350 | 15 | <newline/> | 15 | <newline/> |
351 | 16 | <group col="4" colspan="2"> | 16 | <group col="4" colspan="2"> |
352 | 17 | <field name="customer_prices1"/> | 17 | <field name="customer_prices1"/> |
353 | 18 | <field name="customer_prices2" string=""/> | 18 | <field name="customer_prices2" nolabel="1"/> |
354 | 19 | <field name="list_prices1"/> | 19 | <field name="list_prices1"/> |
355 | 20 | <field name="list_prices2" string=""/> | 20 | <field name="list_prices2" nolabel="1"/> |
356 | 21 | </group> | ||
357 | 22 | <field name="next_better_price_qty"/> | ||
358 | 23 | <field name="best_price_on_qty"/> | ||
359 | 24 | <newline/> | ||
360 | 25 | </group> | ||
361 | 26 | <group col="2" colspan="3"> | ||
362 | 27 | <field name="pricelist_id"/> | ||
363 | 28 | <group col="4" colspan="2"> | ||
364 | 29 | <field name="quantity1"/> | ||
365 | 30 | <field name="quantity2"/> | ||
366 | 31 | </group> | ||
367 | 32 | <separator string="Price on Last Sale"/> | ||
368 | 33 | <newline/> | ||
369 | 34 | <field name="last_customer_prices"/> | ||
370 | 35 | <field name="last_list_prices"/> | ||
371 | 36 | <field name="qty_buyed"/> | ||
372 | 21 | </group> | 37 | </group> |
395 | 22 | <field name="next_better_price_qty"/> | 38 | </group> |
396 | 23 | <field name="best_price_on_qty"/> | 39 | <group col="2" colspan="4"> |
397 | 24 | <newline/> | 40 | <button icon="gtk-cancel" special="cancel" string="Cancel" /> |
398 | 25 | </group> | 41 | <button icon="gtk-ok" string="Calculate" name="set_default" type="object"/> |
399 | 26 | <group col="2" colspan="3"> | 42 | </group> |
400 | 27 | <field name="pricelist_id"/> | 43 | </form> |
379 | 28 | <group col="4" colspan="2"> | ||
380 | 29 | <field name="quantity1"/> | ||
381 | 30 | <field name="quantity2"/> | ||
382 | 31 | </group> | ||
383 | 32 | <separator string="Price on Last Sale"/> | ||
384 | 33 | <newline/> | ||
385 | 34 | <field name="last_customer_prices"/> | ||
386 | 35 | <field name="last_list_prices"/> | ||
387 | 36 | <field name="qty_buyed"/> | ||
388 | 37 | </group> | ||
389 | 38 | </group> | ||
390 | 39 | <group col="2" colspan="4"> | ||
391 | 40 | <button icon='gtk-cancel' special="cancel" string="Cancel" /> | ||
392 | 41 | <button icon="gtk-ok" string="Calculate" name="set_default" type="object" /> | ||
393 | 42 | </group> | ||
394 | 43 | </form> | ||
401 | 44 | </field> | 44 | </field> |
402 | 45 | </record> | 45 | </record> |
403 | 46 | 46 | ||
404 | 47 | <record id="action_sale_prize_information" model="ir.actions.act_window"> | 47 | <record id="action_sale_prize_information" model="ir.actions.act_window"> |
406 | 48 | <field name="name">Sale Prize Information</field> | 48 | <field name="name">Sale Price Information</field> |
407 | 49 | <field name="type">ir.actions.act_window</field> | 49 | <field name="type">ir.actions.act_window</field> |
408 | 50 | <field name="res_model">sale.prize.information</field> | 50 | <field name="res_model">sale.prize.information</field> |
409 | 51 | <field name="view_type">form</field> | 51 | <field name="view_type">form</field> |