manjulatern / GymProject

A basic django based application.
2 stars 4 forks source link

Issue: Profile page not loading new updated image and other user values #7

Closed sanjaygyawali1 closed 4 years ago

sanjaygyawali1 commented 4 years ago

Steps to replicate:

  1. After login, go to the profile page.
  2. Select a new profile image
  3. Click on "Update Profile Image"

Current Behavior: The profile page is wrongly loaded, as the updated profile image is not seen. The values on User Profile is not loaded as well. After again clicking on the profile link, all the information is loaded along with the updated image.

Expected Behavior: The profile page should be loaded with the updated image and all the values when the profile update is done.

manjulatern commented 4 years ago

profile_image method in gymadmin.views is loading profile.html page as template = loader.get_template('profile.html') context = {'uploaded_file_url': uploaded_file_url} return HttpResponse(template.render(context,request))

can be changed to return redirect('/profile')

manjulatern commented 4 years ago

closed #8