kontrola formulare v dialog probe
parent
69317372ab
commit
91ab4d662e
|
|
@ -99,7 +99,6 @@ public class DialogProbe extends JFrame {
|
|||
templateComboBox.setEnabled(false);
|
||||
templateComboBox.setBounds(150, getNextY(checkBoxTemplate), 200, 25);
|
||||
for (SnmpTemplate template : Client.snmpTemplate) {
|
||||
System.err.println(node.getDeviceType() + " - " + template.getDeviceType());
|
||||
if (node.getDeviceType() == template.getDeviceType()) {
|
||||
TemplateItem item = new TemplateItem(template.getId(), template.getName(), template);
|
||||
templateComboBox.addItem(item);
|
||||
|
|
@ -233,7 +232,14 @@ public class DialogProbe extends JFrame {
|
|||
save.addActionListener(new ActionListener() {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
// kontrola chyb
|
||||
|
||||
String nazev = nameField.getName();
|
||||
if (nazev == null) {
|
||||
return;
|
||||
}
|
||||
String oid = oidField.getText();
|
||||
if (oid == null) {
|
||||
return;
|
||||
}
|
||||
// sestaveni probe
|
||||
probe.setNodeId(node.getId());
|
||||
probe.setName(nameField.getText());
|
||||
|
|
|
|||
Loading…
Reference in New Issue