Skip to content

Commit

Permalink
Revert "Adding a routes javascript proxy. Fixes spree#1666"
Browse files Browse the repository at this point in the history
This reverts commit af32582.
  • Loading branch information
radar committed Jun 26, 2012
1 parent 75dfe6c commit c53accc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/app/assets/javascripts/admin/admin.js.erb
Expand Up @@ -123,7 +123,7 @@ $.fn.product_autocomplete = function(){
return this.each(function() {
$(this).autocomplete({
source: function(request, response) {
$.get(Spree.routes.admin_products_path({format: 'json'}) + "?q=" + $('#add_product_name').val() + "&authenticity_token=" + encodeURIComponent($('meta[name=csrf-token]').attr("content")), function(data) {
$.get(ajax_root_prefix() + "admin/products.json?q=" + $('#add_product_name').val() + "&authenticity_token=" + encodeURIComponent($('meta[name=csrf-token]').attr("content")), function(data) {
result = prep_product_autocomplete_data(data)
response(result);
});
Expand Down
2 changes: 1 addition & 1 deletion core/app/assets/javascripts/admin/checkouts/edit.js
Expand Up @@ -46,7 +46,7 @@ $(document).ready(function(){
minChars: 5,
delay: 1500,
source: function(request, response) {
$.get(Spree.routes.admin_users_path({format: 'json'}) + "?q=" + $("#customer_search").val() + "&authenticity_token=" + encodeURIComponent($('meta[name=csrf-token]').attr("content")), function(data) {
$.get(ajax_root_prefix() + "admin/users.json?q=" + $("#customer_search").val() + "&authenticity_token=" + encodeURIComponent($('meta[name=csrf-token]').attr("content")), function(data) {
result = prep_user_autocomplete_data(data)
response(result);
});
Expand Down

0 comments on commit c53accc

Please sign in to comment.