NIHVIVO-646 Move custom form utilities to a separate js file and add utility mixin methods to mix them in to specific custom forms. Make paths to css and js files in formPrefix.jsp and formSuffix.jsp absolute instead of relative.
This commit is contained in:
parent
c11d40a0f9
commit
cc480a3961
5 changed files with 22 additions and 15 deletions
|
@ -34,6 +34,9 @@ var addAuthorForm = {
|
|||
|
||||
initForm: function() {
|
||||
|
||||
// Mix in the custom form utility methods
|
||||
vitro.utils.borrowMethods(vitro.customFormUtils, this);
|
||||
|
||||
this.showFormButton.click(function() {
|
||||
addAuthorForm.showFormDiv.hide();
|
||||
addAuthorForm.form.show();
|
||||
|
@ -41,7 +44,7 @@ var addAuthorForm = {
|
|||
});
|
||||
|
||||
this.cancel.click(function() {
|
||||
addAuthorForm.form.hide();
|
||||
addAuthorForm.hideFields(addAuthorForm.form);
|
||||
addAuthorForm.showFormDiv.show();
|
||||
return false;
|
||||
});
|
||||
|
@ -51,6 +54,7 @@ var addAuthorForm = {
|
|||
// when clicking remove: remove the author, and change link text to "undo"
|
||||
// when clicking undo: add the author back, and change link text to "remove"
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$(document).ready(function() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue