clinic/netforce_clinic/models/shop_line.py

20 lines
668 B
Python
Raw Normal View History

2015-01-21 01:35:55 +00:00
from netforce.model import Model, fields
2015-01-23 10:28:08 +00:00
class ShopLine(Model):
_name="clinic.shop.line"
_string="Shop Line"
2015-01-21 01:35:55 +00:00
_fields={
2015-01-23 10:28:08 +00:00
'shop_id': fields.Many2One('clinic.shop','Shop',required=True,on_delete="cascade"),
2015-02-02 01:41:43 +00:00
'categ_id': fields.Many2One("product.categ","Category"),
2015-01-21 01:35:55 +00:00
'product_id': fields.Many2One('product','Product'),
'description': fields.Char("Description"),
'uom_id': fields.Many2One("uom","UOM"),
'qty': fields.Integer("Qty"),
'price': fields.Float("Price"),
'amount': fields.Float("Amount"),
'account_id': fields.Many2One("account.account","Account"),
}
2015-01-23 10:28:08 +00:00
ShopLine.register()