-
Notifications
You must be signed in to change notification settings - Fork 40
Notification framework #191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
| #no relationship specified | ||
|
|
||
| class share_graph_event(Base): | ||
| __tablename__ = 'share_graph_event' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need some docs on the schema. What does the table store? Why do you need each attribute?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Class names should have camel case.
graphs/views.py
Outdated
| context['footer'] = True | ||
|
|
||
| return render(request, 'graphs/graphs.html', context) | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add python documentation for this method. https://www.python.org/dev/peps/pep-0257/
|
@MridulS, I have updated the master branch with new installation process. I would like you to fetch your master branch from main repository and update your master branch. |
| db_session = data_connection.new_session() | ||
|
|
||
| # Get the current time | ||
| cur_time = datetime.now() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we dont need this variable. you directly assign the value while creating the share event object.
|
I added some comments. The priority is to get a working demo by Monday meeting though. |
graphs/exception.py
Outdated
| @@ -0,0 +1,4 @@ | |||
| from django.core.exceptions import ObjectDoesNotExist | |||
|
|
|||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not to be used anymore.
|
@tmmurali @adbharadwaj Updates to the front end.
Click on Click on Click on Click on |
graphs/util/db.py
Outdated
| db_session = data_connection.new_session() | ||
| try: | ||
|
|
||
| events = db_session.query(models.ShareGraphEvent).filter(models.ShareGraphEvent.member_id == member_id).filter(models.ShareGraphEvent.group_id == group_id).all() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you use the update api here ?
4.1 Notification system4.1.1 View all notifications flow.
4.1.2 View all notifications for a group.
4.1.3 Mark one or more notifications as read.
|
|
I have made two different User Interfaces right now, one which greys out the notifications as the tick mark button is clicked (you need to refresh to remove those notifications from the screen) and the other one removes the notification from the list of notification on click. The grey one is closer to github but I personally like the second one. @tmmurali @adbharadwaj Thoughts? |
graphs/util/db.py
Outdated
| return {'Error': 'No share graph event found.'} | ||
|
|
||
|
|
||
| def get_share_graph_event_by_member_id_and_group_id(member_id, group_id): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Docstring required
|
@adbharadwaj The left group column uses groups from grouped_notifications.keys() to fetch the groups, if all the notifications are read then it will not be possible to fetch groups for the user so I have added a new controller method |
|
|
||
| $('[data-toggle="tooltip"]').tooltip(); | ||
| // grey out notification row and remove the tick mark for notification row | ||
| var manipulate_dom = function(notification_ids){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename method name to "grey_out_notifications"








Screen after logging in


Click on notifications in the nav bar.
@adbharadwaj @tmmurali