example-restclient-myworkapp-nodejs icon indicating copy to clipboard operation
example-restclient-myworkapp-nodejs copied to clipboard

Back button on task details is broken if page is reloaded

Open stuswope opened this issue 9 years ago • 0 comments

Navigate to the task detail page and then reload the page. The back button no longer goes back to the task list because the referrer is the same as the current path.

Modify to not set referrer if the path doesn't change or possibly hard code the link in the view to go back to the task list.

public/js/app.js

 // Store the current page for back navigation
 myTasks.run(function($rootScope, $location) {
     $rootScope.$on("$locationChangeStart", function(event, next, current) {
         $rootScope.referrer = current;
     });
 });

stuswope avatar Sep 08 '16 22:09 stuswope