Lines 1201-1206
$(document).ready(function() {
Link Here
|
1201 |
[% q_add_f = Koha.Preference('PatronQuickAddFields').split('\|') %] |
1201 |
[% q_add_f = Koha.Preference('PatronQuickAddFields').split('\|') %] |
1202 |
var qaddfields = [[% FOREACH field IN q_add_f.unique %]"[% field %]",[% END %]]; |
1202 |
var qaddfields = [[% FOREACH field IN q_add_f.unique %]"[% field %]",[% END %]]; |
1203 |
var skipped_fields = ["contactname","contactfirstname","relationship"]; //Guarantor form is pulled as a whole, ignore individual fields |
1203 |
var skipped_fields = ["contactname","contactfirstname","relationship"]; //Guarantor form is pulled as a whole, ignore individual fields |
|
|
1204 |
var passwd_mandatory = [% IF mandatorypassword %]0[% ELSE %]1[% END %]; |
1204 |
$("#entryform label").each(function () { |
1205 |
$("#entryform label").each(function () { |
1205 |
var input_label = $(this).attr('for'); |
1206 |
var input_label = $(this).attr('for'); |
1206 |
if ( input_label == 'sex-female' ) { |
1207 |
if ( input_label == 'sex-female' ) { |
Lines 1212-1218
$(document).ready(function() {
Link Here
|
1212 |
if ( skipped_fields.indexOf( input_label ) != -1 ) { input_label=""; } |
1213 |
if ( skipped_fields.indexOf( input_label ) != -1 ) { input_label=""; } |
1213 |
if( qaddfields.indexOf( input_label ) != -1 || $(this).attr('class') == 'required' ){ |
1214 |
if( qaddfields.indexOf( input_label ) != -1 || $(this).attr('class') == 'required' ){ |
1214 |
$(this).parent().clone().appendTo("#quick_add_list"); |
1215 |
$(this).parent().clone().appendTo("#quick_add_list"); |
1215 |
if( input_label == 'password') $("#entryform label[for='password2']").parent().clone().appendTo("#quick_add_list"); |
1216 |
if( input_label == 'password' && passwd_mandatory ) $("#entryform label[for='password2']").parent().clone().appendTo("#quick_add_list"); |
1216 |
} |
1217 |
} |
1217 |
}); |
1218 |
}); |
1218 |
if( $("#memberentry_guarantor").length ) { |
1219 |
if( $("#memberentry_guarantor").length ) { |
1219 |
- |
|
|