PHRAS-941 - fix old jquery selector for selected and checked, fix jquery migrate url call

This commit is contained in:
Florian BLOUET
2016-02-10 19:26:01 +01:00
committed by Benoît Burnichon
parent 27e35ae1b8
commit a1c5148700
4 changed files with 8 additions and 8 deletions

View File

@@ -164,8 +164,8 @@
$('input[name="name"]', $FeedBackForm).val($('input[name="name"]', $dialog.getDomElement()).val());
$('input[name="duration"]', $FeedBackForm).val($('select[name="duration"]', $dialog.getDomElement()).val());
$('textarea[name="message"]', $FeedBackForm).val($('textarea[name="message"]', $dialog.getDomElement()).val());
$('input[name="recept"]', $FeedBackForm).attr('checked', $('input[name="recept"]', $dialog.getDomElement()).attr('checked'));
$('input[name="force_authentication"]', $FeedBackForm).attr('checked', $('input[name="force_authentication"]', $dialog.getDomElement()).attr('checked'));
$('input[name="recept"]', $FeedBackForm).prop('checked', $('input[name="recept"]', $dialog.getDomElement()).prop('checked'));
$('input[name="force_authentication"]', $FeedBackForm).prop('checked', $('input[name="force_authentication"]', $dialog.getDomElement()).prop('checked'));
$FeedBackForm.trigger('submit');
};

View File

@@ -162,9 +162,9 @@ function checkBases(bool) {
var sbas_id = $(this).find('input[name=reference]:first').val();
if (bool)
$(this).find(':checkbox').attr('checked', 'checked');
$(this).find(':checkbox').prop('checked', true);
else
$(this).find(':checkbox').removeAttr('checked');
$(this).find(':checkbox').prop('checked', false);
});
checkFilters(true);
@@ -402,8 +402,8 @@ function reset_adv_search() {
$("option.default-selection", fieldsSort).prop("selected", true);
$("option.default-selection", fieldsSortOrd).prop("selected", true);
$('#ADVSRCH_FIELDS_ZONE option').removeAttr("selected");
$('#ADVSRCH_OPTIONS_ZONE input:checkbox.field_switch').removeAttr('checked');
$('#ADVSRCH_FIELDS_ZONE option').prop("selected", false);
$('#ADVSRCH_OPTIONS_ZONE input:checkbox.field_switch').prop("checked", false);
$("option:eq(0)", dateFilterSelect).prop("selected", true);
$('#ADVSRCH_OPTIONS_ZONE .datepicker').val('');

View File

@@ -315,7 +315,7 @@ function showOption(domInput) {
}
function removeChecked(domInput) {
domInput.closest("form").find('input:radio:visible:checked').removeAttr("checked");
domInput.closest("form").find('input:radio:visible:checked').prop("checked", false);
}
function tableLinkAction(domLink) {
var cl = domLink.attr("id");

View File

@@ -19,7 +19,7 @@
<script type="text/javascript" src="/assets/vendors/modernizr/modernizr{% if not app.debug %}.min{% endif %}.js"></script>
<script type="text/javascript" src="/assets/vendors/jquery/jquery{% if not app.debug %}.min{% endif %}.js"></script>
<script src="http://code.jquery.com/jquery-migrate-1.2.1.js"></script>
<script src="//code.jquery.com/jquery-migrate-1.2.1.js"></script>
<script type="text/javascript" src="/assets/vendors/jquery-ui/jquery-ui{% if not app.debug %}.min{% endif %}.js"></script>
<script type="text/javascript">
$.widget.bridge('uitooltip', $.ui.tooltip);