Hide production tab on services
issue9232 review299441002
This commit is contained in:
+7
-7
@@ -16,6 +16,13 @@ class Template(metaclass=PoolMeta):
|
||||
},
|
||||
depends=['type'])
|
||||
|
||||
@classmethod
|
||||
def view_attributes(cls):
|
||||
return super().view_attributes() + [
|
||||
('//page[@id="production"]', 'states', {
|
||||
'invisible': ~Eval('producible'),
|
||||
})]
|
||||
|
||||
|
||||
class Product(metaclass=PoolMeta):
|
||||
__name__ = 'product.product'
|
||||
@@ -63,13 +70,6 @@ class Product(metaclass=PoolMeta):
|
||||
default.setdefault('boms', None)
|
||||
return super(Product, cls).copy(products, default=default)
|
||||
|
||||
@classmethod
|
||||
def view_attributes(cls):
|
||||
return super(Product, cls).view_attributes() + [
|
||||
('//page[@id="production"]', 'states', {
|
||||
'invisible': ~Eval('producible'),
|
||||
})]
|
||||
|
||||
|
||||
class ProductBom(sequence_ordered(), ModelSQL, ModelView):
|
||||
'Product - BOM'
|
||||
|
||||
Reference in New Issue
Block a user