コード例 #1
0
 def _checkProtection(self):
     if self._target.getConference().hasEnabledSection("paperReviewing"):
         if not (RCContributionReviewer.hasRights(self)):
             raise MaKaCError("Only the reviewer of this contribution can access this page / perform this request")
             #RHContribModifBase._checkProtection(self);
     else:
         raise MaKaCError(_("Paper Reviewing is not active for this conference"))
コード例 #2
0
 def _checkProtection(self):
     if self._target.getConference().hasEnabledSection("paperReviewing"):
         if not self._target.getConference().getConfPaperReview().getChoice() in [CPR.CONTENT_REVIEWING, CPR.CONTENT_AND_LAYOUT_REVIEWING]:
             raise MaKaCError(_("Content Reviewing is not active for this conference"))
         elif not (RCContributionReviewer.hasRights(self)):
             raise MaKaCError("Only the reviewer of this contribution can access this page / perform this request")
             #RHContribModifBase._checkProtection(self);
     else:
         raise MaKaCError(_("Paper Reviewing is not active for this conference"))
コード例 #3
0
 def _checkProtection(self):
     if self._target.getConference().hasEnabledSection("paperReviewing"):
         if not self._target.getConference().getConfPaperReview().getChoice() in [CPR.CONTENT_REVIEWING, CPR.CONTENT_AND_LAYOUT_REVIEWING]:
             raise MaKaCError(_("Content Reviewing is not active for this conference"))
         elif not (RCContributionReviewer.hasRights(self)):
             raise MaKaCError("Only the reviewer of this contribution can access this page / perform this request")
             #RHContribModifBase._checkProtection(self);
     else:
         raise MaKaCError(_("Paper Reviewing is not active for this conference"))
コード例 #4
0
 def _checkProtection(self):
     if self._target.getConference().hasEnabledSection("paperReviewing"):
         if not (RCContributionReviewer.hasRights(self)):
             raise MaKaCError(
                 "Only the reviewer of this contribution can access this page / perform this request"
             )
             #RHContribModifBase._checkProtection(self);
     else:
         raise MaKaCError(
             _("Paper Reviewing is not active for this conference"))
コード例 #5
0
ファイル: reviewing.py プロジェクト: dbourillot/indico
    def _checkProtection(self):
        if self._target.getConference().hasEnabledSection("paperReviewing"):
            hasRights = False
            if self._current == 'refereeJudgement':
                hasRights =  RCContributionReferee.hasRights(self)
            elif self._current == 'editorJudgement':
                hasRights =  RCContributionEditor.hasRights(self)
            elif self._current == 'reviewerJudgement':
                hasRights = RCContributionReviewer.hasRights(self)

            if not hasRights and not RCPaperReviewManager.hasRights(self):
                ProtectedModificationService._checkProtection(self)
        else:
            raise ServiceError("ERR-REV1b",_("Paper Reviewing is not active for this conference"))
コード例 #6
0
    def _checkProtection(self):
        if self._target.getConference().hasEnabledSection("paperReviewing"):
            hasRights = False
            if self._current == 'refereeJudgement':
                hasRights =  RCContributionReferee.hasRights(self)
            elif self._current == 'editorJudgement':
                hasRights =  RCContributionEditor.hasRights(self)
            elif self._current == 'reviewerJudgement':
                hasRights = RCContributionReviewer.hasRights(self)

            if not hasRights and not RCPaperReviewManager.hasRights(self):
                ProtectedModificationService._checkProtection(self)
        else:
            raise ServiceError("ERR-REV1b",_("Paper Reviewing is not active for this conference"))
コード例 #7
0
    def _checkProtection(self):
        if self._target.event_new.as_legacy.hasEnabledSection("paperReviewing"):
            hasRights = False
            if self._current == 'refereeJudgement':
                hasRights =  RCContributionReferee.hasRights(self)
            elif self._current == 'editorJudgement':
                hasRights =  RCContributionEditor.hasRights(self)
            elif self._current == 'reviewerJudgement':
                hasRights = RCContributionReviewer.hasRights(self)

            if not hasRights and not RCPaperReviewManager.hasRights(self):
                if not self._target.can_manage(session.user):
                    raise ServiceAccessError("You don't have the rights to modify this object")
        else:
            raise ServiceError("ERR-REV1b",_("Paper Reviewing is not active for this conference"))
コード例 #8
0
ファイル: reviewing.py プロジェクト: stomanin/indico
    def _checkProtection(self):
        if self._target.event_new.as_legacy.hasEnabledSection("paperReviewing"):
            hasRights = False
            if self._current == 'refereeJudgement':
                hasRights =  RCContributionReferee.hasRights(self)
            elif self._current == 'editorJudgement':
                hasRights =  RCContributionEditor.hasRights(self)
            elif self._current == 'reviewerJudgement':
                hasRights = RCContributionReviewer.hasRights(self)

            if not hasRights and not RCPaperReviewManager.hasRights(self):
                if not self._target.can_manage(session.user):
                    raise ServiceAccessError("You don't have the rights to modify this object")
        else:
            raise ServiceError("ERR-REV1b",_("Paper Reviewing is not active for this conference"))