Resetting url input on new part if datasheet is empty

This commit is contained in:
2018-11-13 22:07:02 +01:00
parent 40186ad08e
commit b44d05aabd
+3 -1
View File
@@ -182,8 +182,10 @@ function show_part_info(partID) {
$('tr#datasheet-head').html($('<td>DATASHEET: <a href="' + data.datasheet + '" target="_blank"><i class="fa fa-file-text" aria-hidden="true"></i></a></td>'));
$('input[name=datasheet-url-input]').val(data.datasheet);
}
else
else {
$('tr#datasheet-head td').text('DATASHEET: ');
$('input[name=datasheet-url-input]').val('');
}
$('#edit-button').click(function() {
init_edit(partID);
});