Fix JS warnings when $ is not available

The construction ($ || addHorizonLoadEvent) complains when $ is not
defined. Using (window.$ || window.addHorizonLoadEvent) instead solves
this problem.

Change-Id: Ied5db7398f6ca1d25906c84d5e40a4bae6c01f39
This commit is contained in:
Radomir Dopieralski 2013-10-21 12:43:19 +02:00
parent 8dfbe9cf47
commit be56f53588

View File

@ -27,7 +27,7 @@
{{ block.super }}
<script type="text/javascript">
($ || addHorizonLoadEvent)(function () {
(window.$ || window.addHorizonLoadEvent)(function () {
// prepare the js-enabled parts of the formset data table
var prefix = '{{ table.name|escapejs }}';
var empty_row_html = '{% filter escapejs %}{% include "formset_table/_row.html" with row=table.get_empty_row %}{% endfilter %}';