{'html': "\n\n\n\n
\n
\n
\n
\n

\n Collection privacy

\n
\n \n
\n
\n \n
\n
\n
\n\n\n
\n

Privacy settings determine who is able to view documents in this collection.

\n
\n \n \n \n \n
\n\n
\n",'onload': function(modal) { $('form', modal.body).on('submit', function() { modal.postForm(this.action, $(this).serialize()); return false; }); var restrictionTypePasswordField = $("input[name='restriction_type'][value='password']", modal.body); var restrictionTypeGroupsField = $("input[name='restriction_type'][value='groups']", modal.body); var passwordField = $(".password-field", modal.body); var groupsFields = $('#groups-fields', modal.body); function refreshFormFields() { if (restrictionTypePasswordField.is(':checked')) { passwordField.show(); groupsFields.hide(); } else if (restrictionTypeGroupsField.is(':checked')){ passwordField.hide(); groupsFields.show(); } else { passwordField.hide(); groupsFields.hide(); } } refreshFormFields(); $("input[name='restriction_type']", modal.body).on('change', refreshFormFields); } }