[ckan-changes] [okfn/ckan] ec1243: [xs][scripts] bug fix: prepend CKAN.SITE_URL to re...
GitHub
noreply at github.com
Tue Apr 17 13:21:32 UTC 2012
Branch: refs/heads/release-v1.6.1
Home: https://github.com/okfn/ckan
Commit: ec1243a0b8c25ba04d6b308ce8a5d16a5ebd0f30
https://github.com/okfn/ckan/commit/ec1243a0b8c25ba04d6b308ce8a5d16a5ebd0f30
Author: John Glover <j at johnglover.net>
Date: 2012-04-17 (Tue, 17 Apr 2012)
Changed paths:
M ckan/public/scripts/application.js
Log Message:
-----------
[xs][scripts] bug fix: prepend CKAN.SITE_URL to resource edit format icon call
diff --git a/ckan/public/scripts/application.js b/ckan/public/scripts/application.js
index ba31c59..49a3ae2 100644
--- a/ckan/public/scripts/application.js
+++ b/ckan/public/scripts/application.js
@@ -522,7 +522,7 @@ CKAN.View.Resource = Backbone.View.extend({
}
self.updateIconTimer = setTimeout(function() {
// AJAX to server API
- $.getJSON('/api/2/util/resource/format_icon?format='+encodeURIComponent(self.formatBox.val()), function(data) {
+ $.getJSON(CKAN.SITE_URL + '/api/2/util/resource/format_icon?format='+encodeURIComponent(self.formatBox.val()), function(data) {
if (data && data.icon && data.format==self.formatBox.val()) {
self.li.find('.js-resource-icon').attr('src',data.icon);
self.table.find('.js-resource-icon').attr('src',data.icon);
================================================================
More information about the ckan-changes
mailing list