@Override
	public void actionPerformed(ActionEvent ae) {
		
		if(ae.getSource() == btnSubmit){
			CustomerDataSource cusDS = new CustomerDataSource();
			
			if(!tfFName.getText().isEmpty() && !tfLName.getText().isEmpty() && !tfPhone.getText().isEmpty() && !cusDS.checkCustomerByPhone(tfPhone.getText()))
			{
				Customer c = new Customer();
			
				c.setFirstName(tfFName.getText());
				c.setLastName(tfLName.getText());
				c.setAddress_one(tfAddress1.getText());
				c.setAddress_two(tfAddress2.getText());
				c.setCity(tfCity.getText());
				c.setState(tfState.getText());
				c.setZipCode(tfZipCode.getText());
				c.setPhoneNumber(tfPhone.getText());
				
				cusDS.createCustomer(c);
				
			
				if(c.getId()!=0)
					JOptionPane.showMessageDialog(this,
							"Adding " + c.getFirstName() + " " + c.getLastName() + " successful!");
				else
					JOptionPane.showMessageDialog(this,
		                   "Adding " + c.getFirstName() + " " + c.getLastName() + " failed!");
				tfFName.setText("");
				tfLName.setText("");
				tfAddress1.setText("");
				tfAddress2.setText("");
				tfCity.setText("");
				tfState.setText("");
				tfZipCode.setText("");
				tfPhone.setText("");
			}else if(  !tfFName.getText().isEmpty() && !tfLName.getText().isEmpty() && cusDS.checkCustomerByPhone(tfPhone.getText())){
				JOptionPane.showMessageDialog(this,
		                   "Phone \""+ tfPhone.getText() +"\" is already existed ");
				tfFName.setText("");
				tfLName.setText("");
				tfAddress1.setText("");
				tfAddress2.setText("");
				tfCity.setText("");
				tfState.setText("");
				tfZipCode.setText("");
				tfPhone.setText("");
			}else
				JOptionPane.showMessageDialog(this,
		                   "\"First Name\" or \"Last Name\" or \"Phone\" cannot be empty ");
			cusDS.close();
		}
		
	}