本文整理汇总了Python中MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase._process方法的典型用法代码示例。如果您正苦于以下问题:Python RHSubmitMaterialBase._process方法的具体用法?Python RHSubmitMaterialBase._process怎么用?Python RHSubmitMaterialBase._process使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase
的用法示例。
在下文中一共展示了RHSubmitMaterialBase._process方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: RHSubmitMaterial
# 需要导入模块: from MaKaC.webinterface.rh.conferenceBase import RHSubmitMaterialBase [as 别名]
# 或者: from MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase import _process [as 别名]
class RHSubmitMaterial(RHContributionMaterialSubmissionRightsBase):
def _checkProtection(self):
RHContributionMaterialSubmissionRightsBase._checkProtection(self)
if self._target.getReviewManager().getLastReview().isAuthorSubmitted():
raise MaKaCError("You have already marked your materials as submitted")
def _checkParams(self,params):
RHContributionDisplay._checkParams(self,params)
if not hasattr(self, "_rhSubmitMaterial"):
self._rhSubmitMaterial=RHSubmitMaterialBase(self._target, self)
self._rhSubmitMaterial._checkParams(params)
def _process(self):
wf=self.getWebFactory()
if wf is None:
url=urlHandlers.UHContributionDisplay.getURL(self._target)
p=contributions.WPSubmitMaterial
else:
url=urlHandlers.UHConferenceDisplay.getURL(self._target.getConference())
p=wf.getContribSubmitMaterial
r=self._rhSubmitMaterial._process(self, self._getRequestParams()) #, p)
if r is None:
self._redirect(url)
else:
return r
示例2: _process
# 需要导入模块: from MaKaC.webinterface.rh.conferenceBase import RHSubmitMaterialBase [as 别名]
# 或者: from MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase import _process [as 别名]
def _process(self):
result = RHSubmitMaterialBase._process(self)
# if a Paper Reviewer uploads a paper, when the status is 'To be corrected', we must change the status to 'Submitted' again.
if (
self._target.getReviewing()
and self._target.getReviewing().getReviewingState() == 2
and RCContributionPaperReviewingStaff.hasRights(self, includingContentReviewer=False)
):
self._target.getReviewManager().getLastReview().setAuthorSubmitted(True)
return result
示例3: RHAddMaterial
# 需要导入模块: from MaKaC.webinterface.rh.conferenceBase import RHSubmitMaterialBase [as 别名]
# 或者: from MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase import _process [as 别名]
class RHAddMaterial( RHCategModifBase ):
_uh = urlHandlers.UHCategoryAddMaterial
def _checkParams( self, params ):
RHCategModifBase._checkParams(self, params)
if not hasattr(self, "_rhSubmitMaterial"):
self._rhSubmitMaterial=RHSubmitMaterialBase(self._target, self)
self._rhSubmitMaterial._checkParams(params)
def _process( self ):
r=self._rhSubmitMaterial._process(self, self._getRequestParams())
if r is None:
self._redirect(self._uh.getURL(self._target))
return r
示例4: RHMaterialsAdd
# 需要导入模块: from MaKaC.webinterface.rh.conferenceBase import RHSubmitMaterialBase [as 别名]
# 或者: from MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase import _process [as 别名]
class RHMaterialsAdd(RHSubContribModifBase):
_uh = urlHandlers.UHSubContribModifAddMaterials
def _checkProtection(self):
material = self._rhSubmitMaterial._getMaterial()
if self._target.canUserSubmit(self._aw.getUser()) and material.getReviewingState() < 3:
return
RHSubContribModifBase._checkProtection(self)
def _checkParams(self, params):
RHSubContribModifBase._checkParams(self, params)
if not hasattr(self, "_rhSubmitMaterial"):
self._rhSubmitMaterial = RHSubmitMaterialBase(self._target, self)
self._rhSubmitMaterial._checkParams(params)
def _process(self):
if self._target.getConference().isClosed():
p = WPConferenceModificationClosed(self, self._target)
return p.display()
r = self._rhSubmitMaterial._process(self, self._getRequestParams())
if r is None:
self._redirect(self._uh.getURL(self._target))
return r
示例5: RHSubmitMaterial
# 需要导入模块: from MaKaC.webinterface.rh.conferenceBase import RHSubmitMaterialBase [as 别名]
# 或者: from MaKaC.webinterface.rh.conferenceBase.RHSubmitMaterialBase import _process [as 别名]
class RHSubmitMaterial(RHSubContributionDisplayBase):
def _checkProtection(self):
if not self._target.canModify( self.getAW() ) and not self._target.canUserSubmit( self.getAW().getUser() ):
if self._target.getModifKey() != "":
raise ModificationError()
if self._getUser() == None:
self._checkSessionUser()
else:
raise ModificationError()
#def _checkProtection(self):
# if self.getAW().getUser() is None:
# self._checkSessionUser()
# elif not self._target.canModify(self.getAW()):
# raise MaKaCError("you are not authorised to submit material for this subcontribution")
def _checkParams(self,params):
RHSubContributionDisplayBase._checkParams(self,params)
if not hasattr(self, "_rhSubmitMaterial"):
self._rhSubmitMaterial=RHSubmitMaterialBase(self._target, self)
self._rhSubmitMaterial._checkParams(params)
def _process(self):
wf=self.getWebFactory()
if wf is None:
url=urlHandlers.UHSubContributionDisplay.getURL(self._target)
p=subContributions.WPSubmitMaterial
else:
url=urlHandlers.UHConferenceDisplay.getURL(self._target.getConference())
p=wf.getSubContribSubmitMaterial
r=self._rhSubmitMaterial._process(self, self._getRequestParams(), p)
if r is None:
self._redirect(url)
else:
return r