~openerp-commiter/openobject-addons/trunk-extra-addons

« back to all changes in this revision

Viewing changes to product_variant_configurator/sale.py

  • Committer: Xavier Fernandez
  • Date: 2009-03-03 10:57:09 UTC
  • mto: (3583.1.12 addons-extra)
  • mto: This revision was merged to the branch mainline in revision 3584.
  • Revision ID: xafer@apophis-20090303105709-gz5hcqja7z4wym6w
Initial import
Work in progress

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# -*- encoding: utf-8 -*-
 
2
##############################################################################
 
3
#
 
4
#    OpenERP, Open Source Management Solution    
 
5
#    Copyright (C) 2009 Smile.fr. All Rights Reserved
 
6
#    authors: Raphaël Valyi, Xavier Fernandez
 
7
#
 
8
#    This program is free software: you can redistribute it and/or modify
 
9
#    it under the terms of the GNU General Public License as published by
 
10
#    the Free Software Foundation, either version 3 of the License, or
 
11
#    (at your option) any later version.
 
12
#
 
13
#    This program is distributed in the hope that it will be useful,
 
14
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
15
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
16
#    GNU General Public License for more details.
 
17
#
 
18
#    You should have received a copy of the GNU General Public License
 
19
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
20
#
 
21
##############################################################################
 
22
from osv import fields, osv
 
23
 
 
24
 
 
25
class sale_order_line_dimension_custom_values(osv.osv):
 
26
    _name = "sale.order.line.dimension_custom_values"
 
27
    
 
28
    _columns = {
 
29
                "dimension_type_id": fields.many2one("product.variant.dimension.type", "Dimension Type"),
 
30
                "custom_value": fields.char('Custom Value', size=64),
 
31
                "sale_order_line_id": fields.many2one("sale.order.line", "Sale Order Line"),
 
32
                }
 
33
    
 
34
sale_order_line_dimension_custom_values()
 
35
 
 
36
 
 
37
class sale_order_line(osv.osv):
 
38
    _inherit = "sale.order.line"
 
39
    
 
40
    _columns = {
 
41
                "dimension_custom_value_ids": fields.one2many('sale.order.line.dimension_custom_values', 'sale_order_line_id', 'Dimension Custom Values'),
 
42
                }
 
43
    
 
44
sale_order_line()
 
 
b'\\ No newline at end of file'