Пример #1
0
def getNumberOfPostsPerDay():
    return PostHandler().getNumberOfPostsPerDay()
Пример #2
0
def getPostByGroupId(gID):
    if request.method == 'GET':
        return PostHandler().getPostByGroupId(gID)
    elif request.method == 'POST':
        return PostHandler().addPost(gID, request)
Пример #3
0
def getNumberOfRepliesForGivenPost(pID):
    return PostHandler().getNumberOfRepliesForGivenPost(pID)
Пример #4
0
def getNumberOfPostsPerDayByUser(uID):
    return PostHandler().getNumberOfPostsPerDayByUser(uID)
Пример #5
0
def getNumberOfDislikesPerDay():
    return PostHandler().getNumberOfDislikesPerDay()
Пример #6
0
def getNumberOfDislikesForGivenPost(pID):
    return PostHandler().getNumberOfDislikesForGivenPost(pID)
Пример #7
0
def getListOfUsersWhoDislikedPost(pID):
    if request.method == 'GET':
        return PostHandler().getListOfUsersWhoDislikedPost(pID)
    if request.method == 'POST':
        return PostHandler().reactToPost(pID, request.json, 'dislike')
Пример #8
0
def getNumberOfRepliesPerDay():
    return PostHandler().getNumberOfRepliesPerDay()
Пример #9
0
def getAllPost():
    if request.method == 'GET':
        return PostHandler().getAllPost()
Пример #10
0
def getRepliesByPostID(pID):
    if request.method == 'POST':
        return PostHandler().replyToPostID(pID, request.json)
    if request.method == 'GET':
        return PostHandler().getRepliesByPostID(pID)
Пример #11
0
def getPostByGroupIdDETAILED(gID):
    if request.method == 'GET':
        return PostHandler().getPostByGroupIdDETAILED(gID)
Пример #12
0
def reactToaPost(gID):
    if request.method == 'GET':
        return PostHandler().getReaction(request.json)
    elif request.method == 'POST':
        return PostHandler().react(gID, request.json)
Пример #13
0
def getPostsPerDayByUser(uID):
    return PostHandler().getPostsPerDayByUser(uID)
Пример #14
0
def getPostsByUserID(uID):
    return PostHandler().getPostsByUserID(uID)
Пример #15
0
def getPostByID(pID):
    return PostHandler().getPostByID(pID)