Skip to content

Commit

Permalink
[Fixes #7033] fix header tab classes (#7049)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattiagiupponi authored Mar 10, 2021
1 parent 2192cb0 commit 30d7bab
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions geonode/templates/metadata_form_js.html
Original file line number Diff line number Diff line change
Expand Up @@ -93,21 +93,21 @@
}

{% if UI_REQUIRED_FIELDS %}
var advancedMissing = $('#ownership').find('.input-empty').length > 0;
if (advancedMissing) {
var metadataMissing = $('#ownership').find('.input-empty').length > 0;
if (metadataMissing) {
var inputs = $('#ownership').find('.input-empty');
var empty = inputs.length;
for (var i=0; i<inputs.length; i++) {
if (typeof inputs[i].value !== undefined && inputs[i].value !== '') {
empty--;
}
}
advancedMissing = empty > 0;
metadataMissing = empty > 0;
}
$('#completeness-hints .metadata-hint')
.toggleClass('progress-bar-danger', mandatoryMissing)
.toggleClass('progress-bar-success', !mandatoryMissing)
.attr('title', mandatoryMissing ? gettext("some schema mandatory fields are missing") : gettext("Metadata Schema mandatory fields completed") )
.toggleClass('progress-bar-danger', metadataMissing)
.toggleClass('progress-bar-success', !metadataMissing)
.attr('title', metadataMissing ? gettext("some schema mandatory fields are missing") : gettext("Metadata Schema mandatory fields completed") )
.tooltip('fixTitle');
{% endif %}

Expand Down

0 comments on commit 30d7bab

Please sign in to comment.