Commit 7c610b49 authored by Jérome Perrin's avatar Jérome Perrin

if parent class implement an interface, classes inheriting from this parent

class does not have to declare implementing the same interface again. 



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@27547 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 46bb812a
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet
......@@ -61,8 +60,6 @@ class AccountingTransactionLine(DeliveryLine):
, PropertySheet.AccountingTransactionLine
)
# Declarative interfaces
zope.interface.implements( )
security.declareProtected(Permissions.AccessContentsInformation,
'getInventoriatedQuantity')
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from DateTime import DateTime
from copy import deepcopy
......@@ -58,9 +57,6 @@ class AmortisationRule(Rule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -62,7 +62,8 @@ class Amount(Base, Variated):
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements(interfaces.IVariated,)
zope.interface.implements(interfaces.IVariated,
interfaces.IAmount)
property_sheets = ( PropertySheet.Base
, PropertySheet.SimpleItem
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Amount import Amount
......@@ -64,9 +63,6 @@ class AmountFilter(MappedValue, Amount):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -53,9 +52,6 @@ class AnnotationLine(PaySheetLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -131,9 +130,6 @@ class AssortedResource(TransformedResource):
, PropertySheet.TransformedResource
)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Local property sheet
_properties = (
{ 'id' : 'variation_base_category',
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -68,9 +67,6 @@ class BankAccount(Folder, Coordinate, MetaNode):
, PropertySheet.BankAccount
)
# Declarative interfaces
zope.interface.implements( interfaces.ICoordinate, )
security.declareProtected(Permissions.AccessContentsInformation, 'getReference')
def getReference(self, *args, **kw):
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -63,9 +62,6 @@ class Container(Movement, XMLObject):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -51,9 +50,6 @@ class ContainerCell(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -27,8 +27,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -55,9 +53,6 @@ class ContainerLine(DeliveryLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -25,7 +25,7 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
##############################################################################
import zope.interface
from Acquisition import aq_base
from AccessControl import ClassSecurityInfo
from Products.ERP5.Document.Predicate import Predicate
......@@ -49,8 +49,6 @@ class ContributionPredicate(Predicate, XMLObject):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements(interfaces.IPredicate,)
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -49,9 +48,6 @@ class Currency(Resource):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base
......@@ -57,9 +56,6 @@ class DeliveryCell(MappedValue, Movement, ImmobilisationMovement):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -56,9 +55,6 @@ class DeliveryLine(Movement, XMLObject, XMLMatrix, Variated,
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -49,9 +48,6 @@ class DeliveryRule(Rule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
import re, socket, sys
from DateTime import DateTime
from operator import add
......@@ -652,9 +651,6 @@ class Document(PermanentURLMixIn, XMLObject, UrlMixIn, ConversionCacheMixin, Sna
, PropertySheet.Snapshot
)
# Declarative interfaces
zope.interface.implements()
searchable_property_list = ('asText', 'title', 'description', 'id', 'reference',
'version', 'short_title',
'subject', 'source_reference', 'source_project_title',)
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -82,9 +81,6 @@ class Domain(Predicate, MetaNode, MetaResource):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IPredicate, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.Predicate
......
......@@ -27,8 +27,6 @@
#
##############################################################################
import zope.interface
import re, types
from DateTime import DateTime
from Globals import get_request
......@@ -136,9 +134,6 @@ class EmailDocument(File, TextDocument):
, PropertySheet.Reference
)
# Declarative interfaces
zope.interface.implements()
# Searchable Text - at least search the body message
# - later: search attachments too
searchable_property_list = TextDocument.searchable_property_list
......
......@@ -26,8 +26,6 @@
#
##############################################################################
import zope.interface
import mimetypes
import re
......@@ -107,8 +105,6 @@ class File(Document, CMFFile, ConversionCacheMixin):
'version', 'short_title',
'subject', 'source_reference', 'source_project_title',)
# Declarative interfaces
#zope.interface.implements( , )
### Special edit method
security.declarePrivate( '_edit' )
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -65,8 +64,6 @@ class GeographicAddress(Coordinate, Base):
, PropertySheet.GeographicAddress
)
# Declarative interfaces
zope.interface.implements( interfaces.ICoordinate, )
security.declareProtected(Permissions.AccessContentsInformation, 'asText')
def asText(self):
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -56,9 +55,6 @@ class ImmobilisationCell(Movement, XMLObject, ImmobilisationMovement):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -57,9 +56,6 @@ class ImmobilisationLine(Movement, XMLObject, ImmobilisationMovement, DeliveryLi
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -84,9 +83,6 @@ class ImmobilisationMovement(Movement, XMLObject):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -59,8 +58,6 @@ class InternetProtocolAddress(Base, Coordinate):
, PropertySheet.InternetProtocolAddress
)
# Declarative interfaces
zope.interface.implements( interfaces.ICoordinate, )
def asText(self):
"""
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Acquisition import aq_base
from AccessControl import ClassSecurityInfo
......@@ -53,9 +52,6 @@ class InventoryCell(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,8 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base
......@@ -53,9 +51,6 @@ class InventoryLine(DeliveryLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -53,9 +52,6 @@ class InvoiceCell(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -56,9 +55,6 @@ class InvoiceLine(DeliveryLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -48,9 +47,6 @@ class InvoiceRule(DeliveryRule):
isPortalContent = 1
isRADContent = 1
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Declarative security
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -53,9 +52,6 @@ class InvoiceTransactionRule(Rule, PredicateMatrix):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -28,7 +28,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -50,9 +49,6 @@ class InvoicingRule(Rule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,8 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -67,9 +65,6 @@ class MappedValue(Predicate, Amount):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IPredicate, interfaces.IVariated,)
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.SimpleItem
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -47,9 +46,6 @@ class OpenOrderCell(SupplyCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.SupplyLine import SupplyLine
......@@ -49,10 +48,6 @@ class OpenOrderLine(SupplyLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated,
interfaces.IPredicate )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -25,7 +25,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -48,8 +47,6 @@ class OpenOrderRule(DeliveryRule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
......
......@@ -27,8 +27,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base
......@@ -54,9 +52,6 @@ class OrderCell(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -62,8 +61,6 @@ class OrderLine(DeliveryLine):
, PropertySheet.ItemAggregation
)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
def applyToOrderLineRelatedMovement(self, portal_type='Simulation Movement',
method_id = 'expand'):
......
......@@ -27,8 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -50,9 +48,6 @@ class OrderRule(DeliveryRule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
......@@ -58,9 +57,6 @@ class Path(MappedValue):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IPredicate, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces
from Products.ERP5.Document.InvoiceCell import InvoiceCell
......@@ -49,9 +48,6 @@ class PaySheetCell(InvoiceCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -49,9 +49,6 @@ class PaySheetLine(InvoiceLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
__implements__ = ( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces
from Products.ERP5.Document.TradeModelLine import TradeModelLine
......@@ -51,9 +50,6 @@ class PaySheetModelLine(TradeModelLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces
from Products.ERP5.Document.DeliveryCell import DeliveryCell
......@@ -46,9 +45,6 @@ class PaySheetModelSlice(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet
......@@ -64,8 +63,6 @@ class PaySheetTransaction(Invoice):
, PropertySheet.DefaultAnnotationLine
)
# Declarative Interface
zope.interface.implements( )
security.declareProtected(Permissions.AccessContentsInformation,
'getRatioQuantityFromReference')
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet
from Products.ERP5.Document.AccountingTransactionLine import AccountingTransactionLine
......@@ -56,6 +55,4 @@ class PaySheetTransactionLine(AccountingTransactionLine):
, PropertySheet.Arrow
)
# Declarative interfaces
zope.interface.implements( )
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base, aq_parent, aq_inner, aq_acquire
from Products.CMFCore.utils import getToolByName
......@@ -52,9 +51,6 @@ class PaymentRule(Rule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -48,9 +48,6 @@ class ProductionOrderRule(TransformationRuleMixin, OrderRule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
__implements = ( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -48,9 +47,6 @@ class ProductionReportCell(DeliveryCell):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -58,9 +57,6 @@ class ProductionReportLine(DeliveryLine):
, PropertySheet.ItemAggregation
)
# Declarative interfaces
zope.interface.implements( )
security.declareProtected( Permissions.ModifyPortalContent, 'newCellContent')
def newCellContent(self, id, portal_type='Production Report Cell', **kw):
"""
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -66,6 +65,3 @@ class ProjectReport(Delivery):
PropertySheet.Task,
)
# Declarative Interface
zope.interface.implements( )
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass
from AccessControl import ClassSecurityInfo
from Products.CMFCore.utils import getToolByName
......@@ -101,9 +100,6 @@ class SimulationMovement(Movement):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.SimpleItem
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from Globals import InitializeClass, PersistentMapping
from AccessControl import ClassSecurityInfo
......@@ -54,9 +53,6 @@ class SupplyCell(Predicate, DeliveryCell, Path):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.CategoryCore
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5Type.XMLMatrix import XMLMatrix
......@@ -52,10 +51,6 @@ class SupplyLine(DeliveryLine, Path):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated,
interfaces.IPredicate )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
......@@ -44,9 +43,6 @@ class TaxLine(DeliveryLine):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated, )
# Declarative properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.Rule import Rule
......@@ -44,9 +43,6 @@ class TaxRule(DeliveryRule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -26,7 +26,6 @@
#
##############################################################################
import zope.interface
from AccessControl.ZopeGuards import guarded_getattr
from AccessControl import ClassSecurityInfo
from zLOG import LOG, WARNING
......@@ -92,9 +91,6 @@ class TextDocument(Document, TextContent):
, PropertySheet.TextDocument
)
# Declarative interfaces
zope.interface.implements()
# Explicit inheritance
security.declareProtected(Permissions.ModifyPortalContent, 'PUT')
PUT = TextContent.PUT # We have a security issue here with Zope < 2.8
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, interfaces
from Products.ERP5.Document.TransformationRule import TransformationRule
......@@ -49,9 +48,6 @@ class TradeModelRule(TransformationRule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -42,7 +42,6 @@ from Products.ERP5.Document.Predicate import Predicate
from Products.CMFCategory.Renderer import Renderer
from Products.ERP5.AggregatedAmountList import AggregatedAmountList
import zope.interface
from zLOG import LOG, WARNING
......
......@@ -28,7 +28,6 @@
#
##############################################################################
import zope.interface
from ExtensionClass import Base
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base, aq_parent, aq_inner, aq_acquire
......@@ -213,8 +212,6 @@ class TransformationRule(TransformationRuleMixin, Rule):
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -27,7 +27,6 @@
#
##############################################################################
import zope.interface
from AccessControl import ClassSecurityInfo
from Acquisition import aq_base, aq_parent, aq_inner, aq_acquire
from Products.CMFCore.utils import getToolByName
......@@ -61,8 +60,7 @@ class TransformationSourcingRule(TransformationRuleMixin, Rule):
# Declarative security
security = ClassSecurityInfo()
security.declareObjectProtected(Permissions.AccessContentsInformation)
zope.interface.implements( interfaces.IPredicate,
interfaces.IRule )
# Default Properties
property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject
......
......@@ -78,10 +78,7 @@ class TransformedResource(Predicate, XMLObject, XMLMatrix, Amount):
)
# Declarative interfaces
zope.interface.implements( interfaces.IVariated
, interfaces.ITransformation
)
zope.interface.implements( interfaces.ITransformation )
### Variation matrix definition
#
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment