Merge branch 'support/2.7' into support/3.0

# Conflicts:
#	js/wizardhelper.js
This commit is contained in:
Stephen Abello
2023-02-22 15:46:13 +01:00

View File

@@ -176,7 +176,7 @@ function WizardHelper(sClass, sFormPrefix, sState, sInitialState, sStimulus) {
var sString = "$('#"+aRefreshed[i]+"').trigger('change').trigger('update');";
window.setTimeout(sString, 1); // Synchronous 'trigger' does nothing, call it asynchronously
}
if($('.blockUI').length == 0) {
if($('[data-field-status="blocked"]').length === 0) {
$('.disabledDuringFieldLoading').prop("disabled", false).removeClass('disabledDuringFieldLoading');
}
};
@@ -203,9 +203,11 @@ function WizardHelper(sClass, sFormPrefix, sState, sInitialState, sStimulus) {
{operation: 'wizard_helper', json_obj: this.ToJSON()},
function (html) {
$('#ajax_content').html(html);
$('.blockUI').parent().unblock();
$('[data-field-status="blocked"]')
.attr('data-field-status', 'ready')
.unblock();
if($('.blockUI').length == 0) {
if($('[data-field-status="blocked"]').length === 0) {
$('.disabledDuringFieldLoading').prop("disabled", false).removeClass('disabledDuringFieldLoading');
}
}
@@ -247,21 +249,22 @@ function WizardHelper(sClass, sFormPrefix, sState, sInitialState, sStimulus) {
{
sAttCode = aFieldNames[index];
sFieldId = this.GetFieldId(sAttCode);
if (sFieldId !== undefined)
{
if (sFieldId !== undefined) {
nbOfFieldsToUpdate++;
$('#fstatus_'+sFieldId).html('<img src="../images/indicator.gif" />');
$('#field_'+sFieldId).find('div').block({
message: '',
overlayCSS: {backgroundColor: '#f1f1f1', opacity: 0.3}
$('#fstatus_' + sFieldId).html('<img src="../images/indicator.gif" />');
$('#field_' + sFieldId).find('div')
.attr('data-field-status', 'blocked')
.block({
message: '',
overlayCSS: {backgroundColor: '#f1f1f1', opacity: 0.3}
});
fieldForm = $('#field_' + sFieldId).closest('form');
this.RequestAllowedValues(sAttCode);
}
index++;
}
if ((fieldForm !== null) && ($('.blockUI').length > 0)) {
if ((fieldForm !== null) && ($('[data-field-status="blocked"]').length > 0)) {
fieldForm.find('button[type=submit]:not(:disabled)').prop("disabled", true).addClass('disabledDuringFieldLoading');
}