Move cost price to product level instead of template
issue6515 review41321002
This commit is contained in:
1 parent
68a55912b4
commit
20498ba816
3 files changed
+6
-15
No files matched your search
@@ -83,19 +83,16 @@ Create product::
|
||||
|
||||
>>> ProductUom = Model.get('product.uom')
|
||||
>>> hour, = ProductUom.find([('name', '=', 'Hour')])
|
||||
>>> Product = Model.get('product.product')
|
||||
>>> ProductTemplate = Model.get('product.template')
|
||||
>>> product = Product()
|
||||
|
||||
>>> template = ProductTemplate()
|
||||
>>> template.name = 'Service'
|
||||
>>> template.default_uom = hour
|
||||
>>> template.type = 'service'
|
||||
>>> template.list_price = Decimal('20')
|
||||
>>> template.cost_price = Decimal('5')
|
||||
>>> template.account_revenue = revenue
|
||||
>>> template.save()
|
||||
>>> product.template = template
|
||||
>>> product.save()
|
||||
>>> product, = template.products
|
||||
|
||||
Create a Project::
|
||||
|
||||
|
||||
@@ -83,19 +83,16 @@ Create product::
|
||||
|
||||
>>> ProductUom = Model.get('product.uom')
|
||||
>>> hour, = ProductUom.find([('name', '=', 'Hour')])
|
||||
>>> Product = Model.get('product.product')
|
||||
>>> ProductTemplate = Model.get('product.template')
|
||||
>>> product = Product()
|
||||
|
||||
>>> template = ProductTemplate()
|
||||
>>> template.name = 'Service'
|
||||
>>> template.default_uom = hour
|
||||
>>> template.type = 'service'
|
||||
>>> template.list_price = Decimal('20')
|
||||
>>> template.cost_price = Decimal('5')
|
||||
>>> template.account_revenue = revenue
|
||||
>>> template.save()
|
||||
>>> product.template = template
|
||||
>>> product.save()
|
||||
>>> product, = template.products
|
||||
|
||||
Create a Project::
|
||||
|
||||
|
||||
@@ -83,19 +83,16 @@ Create product::
|
||||
|
||||
>>> ProductUom = Model.get('product.uom')
|
||||
>>> hour, = ProductUom.find([('name', '=', 'Hour')])
|
||||
>>> Product = Model.get('product.product')
|
||||
>>> ProductTemplate = Model.get('product.template')
|
||||
>>> product = Product()
|
||||
|
||||
>>> template = ProductTemplate()
|
||||
>>> template.name = 'Service'
|
||||
>>> template.default_uom = hour
|
||||
>>> template.type = 'service'
|
||||
>>> template.list_price = Decimal('20')
|
||||
>>> template.cost_price = Decimal('5')
|
||||
>>> template.account_revenue = revenue
|
||||
>>> template.save()
|
||||
>>> product.template = template
|
||||
>>> product.save()
|
||||
>>> product, = template.products
|
||||
|
||||
Create a Project::
|
||||
|
||||
|
||||
Reference in new issue
Block a user