0001-misc-add-possibility-to-mark-popup-links-with-data-p.patch
wcs/qommon/static/js/popup.js | ||
---|---|---|
44 | 44 |
} |
45 | 45 | |
46 | 46 |
$(function() { |
47 |
$('a[rel=popup]').click(displayPopup); |
|
47 |
$('a[rel=popup], a[data-popup]').click(displayPopup);
|
|
48 | 48 |
$(document).on('wcs:dialog-loaded', function(e, dialog) { |
49 | 49 |
if ($(dialog).find('input[name$=add_element]').length) { |
50 | 50 |
prepare_widget_list_elements(); |
wcs/qommon/template.py | ||
---|---|---|
263 | 263 |
if 'lang' not in kwargs and hasattr(get_request(), 'language'): |
264 | 264 |
response.filter['lang'] = get_request().language |
265 | 265 | |
266 |
if 'rel="popup"' in body or 'rel="popup"' in kwargs.get('sidebar', ''): |
|
266 |
if ('rel="popup"' in body or 'rel="popup"' in kwargs.get('sidebar', '')) or ( |
|
267 |
'data-popup' in body or 'data-popup' in kwargs.get('sidebar', '')): |
|
267 | 268 |
response.add_javascript(['jquery.js', 'jquery-ui.js', 'popup.js', 'widget_list.js']) |
268 | 269 | |
269 | 270 |
onload = kwargs.get('onload') |
270 |
- |