updates for autocomplete

This commit is contained in:
hjkhjk54 2011-12-07 15:32:16 +00:00
parent eb73a306cb
commit 1982bda0ee
2 changed files with 12 additions and 7 deletions

View file

@ -107,7 +107,7 @@ var customForm = {
}
else if (this.findValidationErrors()) {
this.initFormWithValidationErrors();
} else if(this.supportEdit && this.editMode == 'edit') {
} else if(this.supportEdit) {
this.initFormWithSupportEdit();
}
// If type is already selected when the page loads (Firefox retains value
@ -176,11 +176,15 @@ var customForm = {
},
initFormWithSupportEdit: function() {
this.initFormWithValidationErrors();
//Hide verify match when edit mode
this.verifyMatch.hide();
if(this.editMode == 'edit') {
this.initFormWithValidationErrors();
//Hide verify match when edit mode
this.verifyMatch.hide();
} else {
this.initFormFullView();
}
//Disable submit button until selection made
this.button.attr('disabled', true);
this.button.attr('disabled', 'disabled');
},
// Bind event listeners that persist over the life of the page. Event listeners
@ -407,7 +411,7 @@ var customForm = {
//Resetting so disable submit button again for object property autocomplete
if(this.supportEdit) {
this.button.attr('disabled', true);
//this.button.attr('disabled', 'disabled');
}
}

View file

@ -58,7 +58,8 @@
<p>
<input type="submit" id="submit" value="${editConfiguration.submitLabel}" role="button "/>
<input type="submit" id="submit" value="${editConfiguration.submitLabel}" role="button" disabled="disabled"/>
<span class="or"> or </span>
<a title="Cancel" class="cancel" href="${cancelUrl}">Cancel</a>
</p>