feat: change user_update api response, and add the basic and session auth to rest framework config file
This commit is contained in:
@@ -183,8 +183,8 @@ class MeView(BaseViewSetMixin, GenericViewSet, UserService):
|
||||
def user_update(self, request):
|
||||
ser = self.get_serializer(instance=request.user, data=request.data, partial=True)
|
||||
ser.is_valid(raise_exception=True)
|
||||
ser.save()
|
||||
return Response({"detail": _("Malumotlar yangilandi")})
|
||||
data = ser.save()
|
||||
return Response(UserSerializer(data).data)
|
||||
|
||||
|
||||
@extend_schema(tags=["change-password"], description="Parolni o'zgartirish uchun")
|
||||
|
||||
Reference in New Issue
Block a user