From d6b727f99d4fc1dd6eb762367769373981666725 Mon Sep 17 00:00:00 2001 From: abhisgithub Date: Mon, 10 Sep 2018 17:12:42 +0530 Subject: [PATCH] get etherpad id for and article --- etherpad/views.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/etherpad/views.py b/etherpad/views.py index 4e6fdc7e..dcd2ea72 100644 --- a/etherpad/views.py +++ b/etherpad/views.py @@ -90,4 +90,9 @@ def create_session_group(request, group_id): ether_user = str(ether_user.user_ether_id) validUntil = int(time())+28800 result = epclient.createSession(ether_group, ether_user, validUntil) - return result['sessionID'] \ No newline at end of file + return result['sessionID'] + + +def get_pad_id(article_id): + article = EtherArticle.objects.get(article=article_id) + return article.article_ether_id \ No newline at end of file