# HG changeset patch # User David Douard # Date 1374500291 -7200 # Node ID 8139f82c8bbe7d09dc42b9921be920f61bd0897f # Parent a7412e884d7bc065e0e498cc2117c1c63f1f564f [facets,js] fix bogus checkbox icon appearing after the first interaction (closes #2790332) This is because of the hardcoding of the data/ url. diff -r a7412e884d7b -r 8139f82c8bbe web/data/cubicweb.facets.js --- a/web/data/cubicweb.facets.js Mon Jul 22 14:57:37 2013 +0200 +++ b/web/data/cubicweb.facets.js Mon Jul 22 15:38:11 2013 +0200 @@ -1,14 +1,13 @@ /** filter form, aka facets, javascript functions * * :organization: Logilab - * :copyright: 2003-2011 LOGILAB S.A. (Paris, FRANCE), all rights reserved. + * :copyright: 2003-2013 LOGILAB S.A. (Paris, FRANCE), all rights reserved. * :contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr */ -var SELECTED_IMG = baseuri() + "data/black-check.png"; -var UNSELECTED_IMG = baseuri() + "data/no-check-no-border.png"; -var UNSELECTED_BORDER_IMG = baseuri() + "data/black-uncheck.png"; - +var SELECTED_IMG = DATA_URL + 'black-check.png'; +var UNSELECTED_IMG = DATA_URL + 'no-check-no-border.png'; +var UNSELECTED_BORDER_IMG = DATA_URL + 'black-uncheck.png'; function copyParam(origparams, newparams, param) { var index = $.inArray(param, origparams[0]); diff -r a7412e884d7b -r 8139f82c8bbe web/views/basetemplates.py --- a/web/views/basetemplates.py Mon Jul 22 14:57:37 2013 +0200 +++ b/web/views/basetemplates.py Mon Jul 22 15:38:11 2013 +0200 @@ -162,6 +162,7 @@ self.write_doctype() # explictly close the tag to avoid IE 6 bugs while browsing DOM self._cw.html_headers.define_var('BASE_URL', self._cw.base_url()) + self._cw.html_headers.define_var('DATA_URL', self._cw.datadir_url) w(u'\n' % (content_type, self._cw.encoding)) w(u'\n'.join(additional_headers) + u'\n')