Browse Source

Redirect correctly after creating a bike

denney-fix-saving-dates
Jason Denney 10 years ago
parent
commit
b1ddcfb867
  1. 2
      app/assets/javascripts/bikes.js

2
app/assets/javascripts/bikes.js

@ -21,7 +21,7 @@ $("#add_bike_submit").click(function(){
contentType: 'application/json',
dataType: "json",
success: function(data, status, xhr){
window.location = data.bikes[0].href;
window.location = data.bikes[0].id;
},
error: function(data, status ){
displayFormErrors(data.responseJSON);

Loading…
Cancel
Save