Skip to content

Commit

Permalink
Merge pull request #1296 from kishankoushal/main
Browse files Browse the repository at this point in the history
Notifications
  • Loading branch information
ChaudharyRaman authored Mar 10, 2024
2 parents 162b13b + 702c197 commit 7bbb10c
Show file tree
Hide file tree
Showing 9 changed files with 456 additions and 12 deletions.
4 changes: 2 additions & 2 deletions FusionIIIT/applications/department/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def faculty_view(request):
upload_announcement=upload_announcement,
department = department,
ann_date=ann_date)
# department_notif(usrnm, recipients , message)
department_notif(usrnm, recipients , message)

context = browse_announcements()
return render(request, 'department/dep_request.html', {"user_designation":user_info.user_type,
Expand Down Expand Up @@ -223,7 +223,7 @@ def staff_view(request):
upload_announcement=upload_announcement,
department = department,
ann_date=ann_date)
# department_notif(usrnm, recipients , message)
department_notif(usrnm, recipients , message)

context = browse_announcements()
return render(request, 'department/dep_request.html', {"user_designation":user_info.user_type,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
from rest_framework import serializers
from notifications.models import Notification
class NotificationSerializer(serializers.ModelSerializer):
class Meta:
model = Notification
fields = '__all__'
51 changes: 51 additions & 0 deletions FusionIIIT/applications/notifications_extension/api/urls.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# urls.py
from django.urls import path
from .views import (
LeaveModuleNotificationAPIView,
PlacementCellNotificationAPIView,
AcademicsModuleNotificationAPIView,
OfficeModuleNotificationAPIView,
CentralMessNotificationAPIView,
VisitorsHostelNotificationAPIView,
HealthcareCenterNotificationAPIView,
FileTrackingNotificationAPIView,
ScholarshipPortalNotificationAPIView,
ComplaintSystemNotificationAPIView,
OfficeDeanPnDNotificationAPIView,
OfficeDeanSNotificationAPIView,
GymkhanaVotingNotificationAPIView,
GymkhanaSessionNotificationAPIView,
GymkhanaEventNotificationAPIView,
AssistantshipClaimNotificationAPIView,
DepartmentNotificationAPIView,
OfficeDeanRSPCNotificationAPIView,
ResearchProceduresNotificationAPIView,
MarkAsRead,
Delete,
NotificationsList,
)

urlpatterns = [
path('notifications/', NotificationsList.as_view(), name='notifications' ),
path('delete/', Delete.as_view(),name='delete'),
path('mark_as_read/', MarkAsRead.as_view(),name='mark_as_read'),
path('leave_module_notification/', LeaveModuleNotificationAPIView.as_view(), name='leave_module_notification'),
path('placement_cell_notification/', PlacementCellNotificationAPIView.as_view(), name='placement_cell_notification'),
path('academics_module_notification/', AcademicsModuleNotificationAPIView.as_view(), name='academics_module_notification'),
path('office_module_notification/', OfficeModuleNotificationAPIView.as_view(), name='office_module_notification'),
path('central_mess_notification/', CentralMessNotificationAPIView.as_view(), name='central_mess_notification'),
path('visitors_hostel_notification/', VisitorsHostelNotificationAPIView.as_view(), name='visitors_hostel_notification'),
path('healthcare_center_notification/', HealthcareCenterNotificationAPIView.as_view(), name='healthcare_center_notification'),
path('file_tracking_notification/', FileTrackingNotificationAPIView.as_view(), name='file_tracking_notification'),
path('scholarship_portal_notification/', ScholarshipPortalNotificationAPIView.as_view(), name='scholarship_portal_notification'),
path('complaint_system_notification/', ComplaintSystemNotificationAPIView.as_view(), name='complaint_system_notification'),
path('office_dean_PnD_notification/', OfficeDeanPnDNotificationAPIView.as_view(), name='office_dean_PnD_notification'),
path('office_dean_S_notification/', OfficeDeanSNotificationAPIView.as_view(), name='office_dean_S_notification'),
path('gymkhana_voting/', GymkhanaVotingNotificationAPIView.as_view(), name='gymkhana_voting'),
path('gymkhana_session/', GymkhanaSessionNotificationAPIView.as_view(), name='gymkhana_session'),
path('gymkhana_event/', GymkhanaEventNotificationAPIView.as_view(), name='gymkhana_event'),
path('assistantship_claim/', AssistantshipClaimNotificationAPIView.as_view(), name='assistantship_claim'),
path('department_notification/', DepartmentNotificationAPIView.as_view(), name='department_notification'),
path('office_dean_RSPC_notification/', OfficeDeanRSPCNotificationAPIView.as_view(), name='office_dean_RSPC_notification'),
path('research_procedures_notification/', ResearchProceduresNotificationAPIView.as_view(), name='research_procedures_notification'),
]
Loading

0 comments on commit 7bbb10c

Please sign in to comment.