Skip to content

Commit

Permalink
test commit with hradmin
Browse files Browse the repository at this point in the history
  • Loading branch information
Beakbreak committed Feb 19, 2024
1 parent 5056c26 commit 1c87004
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions FusionIIIT/applications/hr2/form_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def post(self, request):
serializer = self.serializer_class(data = request.data[1])
if serializer.is_valid():
serializer.save()
file_id = create_file(uploader = user_info['uploader_name'], uploader_designation = user_info['uploader_designation'], receiver = "21BCS151", receiver_designation="student", src_module="HR", src_object_id= str(serializer.data['id']), file_extra_JSON= {"type": "LTC"}, attached_file= None)
file_id = create_file(uploader = user_info['uploader_name'], uploader_designation = user_info['uploader_designation'], receiver = "21BCS140", receiver_designation="hradmin", src_module="HR", src_object_id= str(serializer.data['id']), file_extra_JSON= {"type": "LTC"}, attached_file= None)
return Response(serializer.data, status= status.HTTP_200_OK)
else:
return Response(serializer.errors, status= status.HTTP_400_BAD_REQUEST)
Expand Down Expand Up @@ -206,4 +206,9 @@ def put(self, request, *args, **kwargs):
serializer.save()
return Response(serializer.data, status = status.HTTP_200_OK)
else:
return Response(serializer.errors, status = status.HTTP_400_BAD_REQUEST)
return Response(serializer.errors, status = status.HTTP_400_BAD_REQUEST)

class AssignerReviewer(APIView):
def post(self, request, *args, **kwargs):
forward_file(file_id = request.data['file_id'], receiver = "21BCS140", receiver_designation = 'hradmin', remarks = request.data['remarks'], file_extra_JSON = request.data['file_extra_JSON'])
return Response(status = status.HTTP_200_OK)

0 comments on commit 1c87004

Please sign in to comment.