summaryrefslogtreecommitdiff
path: root/gnowsys-ndf/gnowsys_ndf
diff options
context:
space:
mode:
authorkatkamrachana <katkam.rachana@gmail.com>2015-05-05 13:33:24 +0530
committerkatkamrachana <katkam.rachana@gmail.com>2015-05-05 13:33:24 +0530
commit5e973a41271c245a4836daaa1049675c1cbd7fff (patch)
tree26c76b36b0c589b7927e63dbfb6266d07d5c8f0e /gnowsys-ndf/gnowsys_ndf
parentb4600f42d03622c3e5ab5855ca183df1017af05e (diff)
downloadgnowsys-5e973a41271c245a4836daaa1049675c1cbd7fff.tar.gz
Show only draft published activities in user dashboard
Diffstat (limited to 'gnowsys-ndf/gnowsys_ndf')
-rw-r--r--gnowsys-ndf/gnowsys_ndf/ndf/views/userDashboard.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/gnowsys-ndf/gnowsys_ndf/ndf/views/userDashboard.py b/gnowsys-ndf/gnowsys_ndf/ndf/views/userDashboard.py
index 87d33c7e..925f936d 100644
--- a/gnowsys-ndf/gnowsys_ndf/ndf/views/userDashboard.py
+++ b/gnowsys-ndf/gnowsys_ndf/ndf/views/userDashboard.py
@@ -182,9 +182,10 @@ def uDashboard(request, group_id):
activity = ""
activity_user = node_collection.find(
- {'$and':[{'$or':[{'_type':'GSystem'},{'_type':'group'},{'_type':'File'}]},
- {"access_policy":{"$in":Access_policy}},{'member_of':{'$nin': [exclued_from_public]}},
- {'$or':[{'created_by':int(ID)}, {'modified_by':int(ID)}]}]
+ {'$and': [{'$or': [{'_type': 'GSystem'}, {'_type': 'group'}, {'_type': 'File'}]},
+ {"access_policy": {"$in": Access_policy}},{'status':{'$in':[u"DRAFT",u"PUBLISHED"]}},
+ {'member_of': {'$nin': [exclued_from_public]}},
+ {'$or': [{'created_by': int(ID)}, {'modified_by': int(ID)}]}]
}).sort('last_update', -1).limit(10)
a_user = []
@@ -210,7 +211,7 @@ def uDashboard(request, group_id):
else:
member_of = node_collection.find_one({"_id": each.member_of[0]})
user_activity.append(each)
-
+
'''
notification_list=[]
notification_object = notification.NoticeSetting.objects.filter(user_id=int(ID))