예제 #1
0
파일: content.py 프로젝트: qyqx/tracim
 def set_status(self, content: Content, new_status: str):
     if new_status in ContentStatus.allowed_values():
         content.status = new_status
         content.revision_type = ActionDescription.STATUS_UPDATE
     else:
         raise ValueError(
             'The given value {} is not allowed'.format(new_status))
예제 #2
0
def AllStatus(type=''):
    return ContentStatus.all(type)
예제 #3
0
def AllStatus(type=''):
    return ContentStatus.all(type)
예제 #4
0
파일: content.py 프로젝트: buxx/tracim
 def set_status(self, content: Content, new_status: str):
     if new_status in ContentStatus.allowed_values():
         content.status = new_status
         content.revision_type = ActionDescription.STATUS_UPDATE
     else:
         raise ValueError('The given value {} is not allowed'.format(new_status))