Lines 189-199
Link Here
|
189 |
return confirm(_("Are you sure you want to delete this field?")); |
189 |
return confirm(_("Are you sure you want to delete this field?")); |
190 |
}); |
190 |
}); |
191 |
|
191 |
|
192 |
$("#add_field").on('submit', function(){ |
192 |
$("#add_field").on('submit', function() { |
193 |
if ( $("#marcfield").val().length > 0 |
193 |
if ( $("#marcfield").length && $("select[name='authorised_value_category']").length ) { |
194 |
&& $("select[name='authorised_value_category']" ).val().length > 0 ) { |
194 |
if ( $("#marcfield").val().length > 0 |
195 |
alert("You cannot select an authorised value category and a marcfield"); |
195 |
&& $("select[name='authorised_value_category']" ).val().length > 0 ) { |
196 |
return false; |
196 |
alert("You cannot select an authorised value category and a marcfield"); |
|
|
197 |
return false; |
198 |
} |
197 |
} |
199 |
} |
198 |
return true; |
200 |
return true; |
199 |
}); |
201 |
}); |
200 |
- |
|
|