[13972] | 1 | ## $Id: applicant.py 13968 2016-06-22 04:39:50Z henrik $ |
---|
| 2 | ## |
---|
| 3 | ## Copyright (C) 2016 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 | import os |
---|
| 19 | import grok |
---|
| 20 | from zope.component import getUtility, createObject, getAdapter |
---|
| 21 | from zope.component.interfaces import IFactory |
---|
| 22 | from zope.event import notify |
---|
| 23 | from zope.securitypolicy.interfaces import IPrincipalRoleManager |
---|
| 24 | from zope.interface import implementedBy |
---|
| 25 | from zope.schema.interfaces import RequiredMissing, ConstraintNotSatisfied |
---|
| 26 | from hurry.workflow.interfaces import IWorkflowInfo, IWorkflowState |
---|
| 27 | from waeup.kofa.interfaces import IKofaUtils |
---|
| 28 | from waeup.kofa.interfaces import MessageFactory as _ |
---|
| 29 | from waeup.kofa.utils.helpers import attrs_to_fields |
---|
| 30 | from waeup.kofa.applicants.interfaces import IApplicantRefereeReport |
---|
| 31 | |
---|
| 32 | |
---|
| 33 | class ApplicantRefereeReport(grok.Model): |
---|
| 34 | """This is referee report. |
---|
| 35 | """ |
---|
| 36 | grok.implements(IApplicantRefereeReport) |
---|
| 37 | grok.provides(IApplicantRefereeReport) |
---|
| 38 | |
---|
| 39 | def __init__(self): |
---|
| 40 | super(ApplicantRefereeReport, self).__init__() |
---|
| 41 | self.r_id = None |
---|
| 42 | return |
---|
| 43 | |
---|
| 44 | ApplicantRefereeReport = attrs_to_fields(ApplicantRefereeReport) |
---|
| 45 | |
---|
| 46 | |
---|
| 47 | class ApplicantRefereeReportFactory(grok.GlobalUtility): |
---|
| 48 | """A factory for applicant online payments. |
---|
| 49 | """ |
---|
| 50 | grok.implements(IFactory) |
---|
| 51 | grok.name(u'waeup.ApplicantRefereeReport') |
---|
| 52 | title = u"Create a new referee report.", |
---|
| 53 | description = u"This factory instantiates new referee report instances." |
---|
| 54 | |
---|
| 55 | def __call__(self, *args, **kw): |
---|
| 56 | return ApplicantRefereeReport() |
---|
| 57 | |
---|
| 58 | def getInterfaces(self): |
---|
| 59 | return implementedBy(ApplicantRefereeReport) |
---|