source: main/ikobacustom.pcn/trunk/src/ikobacustom/pcn/customers/export.py @ 16250

Last change on this file since 16250 was 12803, checked in by Henrik Bettermann, 10 years ago

Prepare products and contracts for annual payments.

  • Property svn:keywords set to Id
File size: 4.3 KB
Line 
1## $Id: export.py 12803 2015-03-20 18:51:29Z henrik $
2##
3## Copyright (C) 2014 Uli Fouquet & Henrik Bettermann
4## This program is free software; you can redistribute it and/or modify
5## it under the terms of the GNU General Public License as published by
6## the Free Software Foundation; either version 2 of the License, or
7## (at your option) any later version.
8##
9## This program is distributed in the hope that it will be useful,
10## but WITHOUT ANY WARRANTY; without even the implied warranty of
11## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12## GNU General Public License for more details.
13##
14## You should have received a copy of the GNU General Public License
15## along with this program; if not, write to the Free Software
16## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17##
18"""Exporters for pcn customer objects and subobjects.
19"""
20import grok
21from waeup.ikoba.customers.export import (
22    CustomerExporter, CustomerDocumentExporterBase, ContractExporterBase)
23from ikobacustom.pcn.customers.interfaces import (
24    IPCNCustomer, IPCNCustomerJPGDocument,
25    IPCNCustomerPDFDocument,
26    IRONContractProcess,
27    IROPContractProcess,
28    IRPRContractProcess,
29    IRPCContractProcess,
30    IIPPMVLContractProcess,
31    IRPPMVLContractProcess,
32    IAPPITContractProcess,
33    IRPTContractProcess,
34    IAPPTContractProcess)
35from ikobacustom.pcn.interfaces import MessageFactory as _
36
37
38class PCNCustomerExporter(CustomerExporter):
39    """Exporter for Customers.
40    """
41    iface = IPCNCustomer
42    title = _(u'PCN Customers')
43
44
45class PCNCustomerJPGDocumentExporter(CustomerDocumentExporterBase):
46    """Exporter for documents.
47    """
48    grok.name('pcncustomerjpgdocuments')
49    iface = IPCNCustomerJPGDocument
50    title = _(u'PCN Customer JPG Documents')
51    class_name = 'PCNCustomerJPGDocument'
52
53
54class PCNCustomerPDFDocumentExporter(CustomerDocumentExporterBase):
55    """Exporter for documents.
56    """
57    grok.name('pcncustomerpdfdocuments')
58    iface = IPCNCustomerPDFDocument
59    title = _(u'PCN Customer PDF Documents')
60    class_name = 'PCNCustomerPDFDocument'
61
62
63class RONContractExporter(ContractExporterBase):
64    """Exporter for Contract instances.
65    """
66    grok.name('roncontracts')
67    iface = IRONContractProcess
68    title = _(u'Licenses: Retention of Name')
69    class_name = 'RONContract'
70
71
72class ROPContractExporter(ContractExporterBase):
73    """Exporter for Contract instances.
74    """
75    grok.name('ropcontracts')
76    iface = IROPContractProcess
77    title = _(u'Licenses: Registration of Premises')
78    class_name = 'ROPContract'
79
80
81class RPRContractExporter(ContractExporterBase):
82    """Exporter for Contract instances.
83    """
84    grok.name('rprcontracts')
85    iface = IRPRContractProcess
86    title = _(u'Licenses: Registration in the Provisional Register')
87    class_name = 'RPRContract'
88
89
90class RPCContractExporter(ContractExporterBase):
91    """Exporter for Contract instances.
92    """
93    grok.name('rpccontracts')
94    iface = IRPCContractProcess
95    title = _(u'Licenses: Registration as Pharmaceutical Chemist')
96    class_name = 'RPCContract'
97
98
99class IPPMVLContractExporter(ContractExporterBase):
100    """Exporter for Contract instances.
101    """
102    grok.name('ippmvlcontracts')
103    iface = IIPPMVLContractProcess
104    title = _(u'Licenses: Issuance of Patent and Proprietary Medicines Vendors')
105    class_name = 'IPPMVLContract'
106
107
108class RPPMVLContractExporter(ContractExporterBase):
109    """Exporter for Contract instances.
110    """
111    grok.name('rppmvlcontracts')
112    iface = IRPPMVLContractProcess
113    title = _(u'Licenses: Renewal of Patent and Proprietary Medicines Vendors')
114    class_name = 'RPPMVLContract'
115
116
117class APPITContractExporter(ContractExporterBase):
118    """Exporter for Contract instances.
119    """
120    grok.name('appitcontracts')
121    iface = IAPPITContractProcess
122    title = _(u'Licenses: Accepting Pupil Pharmacist for Internship Training')
123    class_name = 'APPITContract'
124
125
126class RPTContractExporter(ContractExporterBase):
127    """Exporter for Contract instances.
128    """
129    grok.name('rptcontracts')
130    iface = IRPTContractProcess
131    title = _(u'Licenses: Registration as a Pharmacy Technician')
132    class_name = 'RPTContract'
133
134
135class APPTContractExporter(ContractExporterBase):
136    """Exporter for Contract instances.
137    """
138    grok.name('apptcontracts')
139    iface = IAPPTContractProcess
140    title = _(u'Licenses: Annual Permit for Pharmacy Technician')
141    class_name = 'APPTContract'
Note: See TracBrowser for help on using the repository browser.