insertToDB() dodane do AlbumFieldPattern

This commit is contained in:
Agnieszka Janicka 2016-06-07 12:48:23 +02:00
parent 3f474500ab
commit 258b2be5bc
3 changed files with 2 additions and 1 deletions

View File

@ -160,7 +160,8 @@ public class AlbumFieldPattern extends javax.swing.JFrame {
private void SaveChangesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_SaveChangesActionPerformed private void SaveChangesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_SaveChangesActionPerformed
if (this.add) { if (this.add) {
JOptionPane.showMessageDialog(null, "DODAJ"); Album a = new Album(0, albumTitle.getText(), musican.getText(), Integer.parseInt(year.getText()), Category.getSelectedItem().toString());
a.insertToDB();
} else if (this.edit) { } else if (this.edit) {
JOptionPane.showMessageDialog(null, "EDYTUJ"); JOptionPane.showMessageDialog(null, "EDYTUJ");
} else if (this.delete) { } else if (this.delete) {