diff --git a/laundary_mgt/data/ir_sequence_data.xml b/laundary_mgt/data/ir_sequence_data.xml
index 451160e..18b7a66 100644
--- a/laundary_mgt/data/ir_sequence_data.xml
+++ b/laundary_mgt/data/ir_sequence_data.xml
@@ -6,7 +6,7 @@
Sales Order Line
sale.order.line
- Trac
+
3
diff --git a/laundary_mgt/models/__pycache__/sale.cpython-36.pyc b/laundary_mgt/models/__pycache__/sale.cpython-36.pyc
index a461ce3..fbcb6f0 100644
Binary files a/laundary_mgt/models/__pycache__/sale.cpython-36.pyc and b/laundary_mgt/models/__pycache__/sale.cpython-36.pyc differ
diff --git a/laundary_mgt/models/sale.py b/laundary_mgt/models/sale.py
index 304d3c8..35125c2 100644
--- a/laundary_mgt/models/sale.py
+++ b/laundary_mgt/models/sale.py
@@ -26,7 +26,8 @@ class SaleOrder(models.Model):
company_id = default=lambda self: self.env.company
seq_date = fields.Datetime.now()
for line in order.order_line:
- line.tracking_code = self.env['ir.sequence'].next_by_code('sale.order.line', sequence_date=seq_date) or _('New')
+ tracking_code = self.env['ir.sequence'].next_by_code('sale.order.line', sequence_date=seq_date) or _('New')
+ line.tracking_code = self.name + tracking_code
class SaleOrderLine(models.Model):
@@ -34,8 +35,9 @@ class SaleOrderLine(models.Model):
_description = 'Sales Order Line'
wash_type = fields.Many2one('wash.type', string='Wash Type')
- cloth_name = fields.Char(string='Cloth Name',copy=False)
- tracking_code = fields.Char(string='Tracking Code',copy=False,readonly="1")
+ color = fields.Many2one('color.type', string='Color')
+ cloth_name = fields.Many2one('cloth.type',string='Cloth Name',copy=False)
+ tracking_code = fields.Char(string='Tracking Code',)
remark = fields.Text('Remark',copy=False)
upload_image = fields.Image("Upload Image")
@@ -46,4 +48,16 @@ class WashType(models.Model):
_name = 'wash.type'
_description = 'Wash Type'
+ name = fields.Char(string='Name')
+
+class ColorType(models.Model):
+ _name = 'color.type'
+ _description = 'Color Type'
+
+ name = fields.Char(string='Name')
+
+class ClothType(models.Model):
+ _name = 'cloth.type'
+ _description = 'Cloth Type'
+
name = fields.Char(string='Name')
\ No newline at end of file
diff --git a/laundary_mgt/security/ir.model.access.csv b/laundary_mgt/security/ir.model.access.csv
index 643a646..57480db 100644
--- a/laundary_mgt/security/ir.model.access.csv
+++ b/laundary_mgt/security/ir.model.access.csv
@@ -1,2 +1,4 @@
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_wash_type,wash.type,model_wash_type,sales_team.group_sale_salesman,1,1,1,1
+access_color_type,color.type,model_color_type,sales_team.group_sale_salesman,1,1,1,1
+access_cloth_type,cloth.type,model_cloth_type,sales_team.group_sale_salesman,1,1,1,1
diff --git a/laundary_mgt/views/sale_views.xml b/laundary_mgt/views/sale_views.xml
index 239402a..ef74960 100644
--- a/laundary_mgt/views/sale_views.xml
+++ b/laundary_mgt/views/sale_views.xml
@@ -12,11 +12,98 @@
+
+
+
+
+
+ cloth.type.tree
+ cloth.type
+
+
+
+
+
+
+
+
+ Cloth Type
+ cloth.type
+ tree,kanban,form
+ []
+
+ Cloth type
+
+
+
+
+
+
+
+ wash.type.tree
+ wash.type
+
+
+
+
+
+
+
+
+ Wash Type
+ wash.type
+ tree,kanban,form
+ []
+
+ Wash type
+
+
+
+
+
+
+
+
+ color.type.tree
+ color.type
+
+
+
+
+
+
+
+
+ Color Type
+ color.type
+ tree,form
+ []
+
+ Create new Color
+
+
+
+
+
+
+