diff --git a/ckanext/spatial/public/js/spatial_query.js b/ckanext/spatial/public/js/spatial_query.js index 78fe286f..7ee92d5b 100644 --- a/ckanext/spatial/public/js/spatial_query.js +++ b/ckanext/spatial/public/js/spatial_query.js @@ -17,12 +17,14 @@ this.ckan.module('spatial-query', function ($, _) { default_extent: [[90, 180], [-90, -180]] }, template: { - buttons: [ - '
', - 'Cancel ', - 'Apply', - '
' - ].join('') + buttons: function(c,a) { + return [ + '
', + ''+c+' ', + ''+a+'', + '
' + ].join('') + } }, initialize: function () { @@ -121,7 +123,7 @@ this.ckan.module('spatial-query', function ($, _) { }); // Setup the expanded buttons - buttons = $(module.template.buttons).insertBefore('#dataset-map-attribution'); + buttons = $(module.template.buttons(this._('Cancel'), this._('Confirm'))).insertBefore('#dataset-map-attribution'); // Handle the cancel expanded action $('.cancel', buttons).on('click', function() {