Example #1
0
 def getOwned(self,
              blogId: Blog,
              creatorId: auth(User),
              typeId: PostType = None,
              offset: int = None,
              limit: int = None,
              q: QBlogPost = None) -> Iter(BlogPost):
     '''
Example #2
0
class MetaData(Entity):
    '''
    Provides the meta data that is extracted based on the content.
    '''
    Name = str
    Type = str
    Content = Reference
    Thumbnail = Reference
    SizeInBytes = int
    Creator = User
    Creator = auth(Creator)  # This is redundant, is just to keep IDE hinting.
    CreatedOn = datetime
Example #3
0
class Blog(Entity):
    '''
    Provides the blog model.
    '''
    Type = BlogType
    Language = LanguageEntity
    Creator = User; Creator = auth(Creator) # This is redundant, is just to keep IDE hinting.
    Title = str
    Description = str
    OutputLink = str
    CreatedOn = datetime
    LiveOn = datetime
    LastUpdatedOn = datetime
    ClosedOn = datetime
    UpdatedOn = datetime
Example #4
0
class Post(Entity):
    '''
    Provides the post message model.
    '''
    Type = PostType
    Creator = auth(User)
    Author = Collaborator
    IsModified = bool
    Meta = str
    ContentPlain = str
    Content = str
    CreatedOn = datetime
    PublishedOn = datetime
    UpdatedOn = datetime
    DeletedOn = datetime
    AuthorName = str
Example #5
0
 def delete(self, adminId:auth(User.Id), user:User) -> bool:
     '''
Example #6
0
 def insert(self, adminId:auth(User.Id), user:User) -> User.Id:
     '''
Example #7
0
 def getAll(self, adminId:auth(User.Id), offset:int=None, limit:int=LIMIT_DEFAULT, detailed:bool=True, q:QUser=None) -> Iter(User):
     '''
Example #8
0
 def getById(self, adminId:auth(User.Id), id:User.Id) -> User:
     '''
Example #9
0
 def insert(self, userId: auth(User.Id), content: Content) -> MetaData.Id:
     '''
Example #10
0
 def getLiveWhereAdmin(self, adminId:auth(User), languageId:LanguageEntity=None, q:QBlog=None) -> Iter(Blog):
     '''
Example #11
0
 def getAll(self, languageId:LanguageEntity=None, adminId:auth(User)=None, offset:int=None, limit:int=None,
            detailed:bool=True, q:QBlog=None) -> Iter(Blog):
     '''
Example #12
0
 def getOwned(self, blogId:Blog, creatorId:auth(User), typeId:PostType=None, offset:int=None, limit:int=None,
              q:QBlogPost=None) -> Iter(BlogPost):
     '''
Example #13
0
 def putLive(self, adminId:auth(User.Id), blogId:Blog.Id):
     '''
Example #14
0
 def getLiveWhereAdmin(self, adminId:auth(User), languageId:LanguageEntity=None, q:QBlog=None) -> Iter(Blog):
     '''
Example #15
0
 def getAll(self, languageId:LanguageEntity=None, userId:auth(User)=None, offset:int=None, limit:int=None,
            detailed:bool=True, q:QBlog=None) -> Iter(Blog):
     '''
Example #16
0
 def update(self, adminId:auth(User.Id), user:User) -> bool:
     '''
Example #17
0
 def changePassword(self, adminId:auth(User.Id), user:UserPassword):
     '''
Example #18
0
 def insert(self, userId:auth(User.Id), content:Content) -> MetaData.Id:
     '''