Commit 608ad89b authored by Jean-Paul Smets's avatar Jean-Paul Smets

New class inheritance.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@15830 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent aabd4633
......@@ -30,12 +30,22 @@ from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, Constraint, Interface
from Products.ERP5.Document.Movement import Movement
from Products.ERP5.Document.Project import Project
class Ticket(Movement):
class Ticket(Movement, Project):
"""
A Ticket allows to track a sales process involving
multilple Person and Organisations. It is a placeholder for
documents, events, etc.
Tickets behave both a movements and as projects:
- as movements because they relate to an amount
of resource exchanged between multiple parties
- as a project because it acts as a reporting
node for other movements (ex. accounting,
task reports)
"""
meta_type = 'ERP5 Ticket'
......@@ -57,14 +67,15 @@ class Ticket(Movement):
, PropertySheet.Arrow
, PropertySheet.Price
, PropertySheet.Movement
, PropertySheet.Amount
, PropertySheet.Ticket
)
security.declareProtected(Permissions.AccessContentsInformation,
'isAccountable')
security.declareProtected(Permissions.AccessContentsInformation, 'isAccountable')
def isAccountable(self):
"""
Returns 1 if this needs to be accounted
Only account movements which are not associated to a delivery
Whenever delivery is there, delivery has priority
"""
return 1
return 1
\ No newline at end of file
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