private void btnLoginActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnLoginActionPerformed
        String fullName = jFullName.getText();
        String orgnName = (String) jOrgnCombo.getSelectedItem();
        int orgnId = orgnMap.get(orgnName);
        String readSecretKeyPath = jReadSecretKey.getText();
        String writeSecretKeyPath = jWriteSecretKey.getText();

        if (fullName.isEmpty() || orgnName.isEmpty() || readSecretKeyPath.isEmpty() || writeSecretKeyPath.isEmpty()) {
            JOptionPane.showMessageDialog(null, "Please fill up all fields.", "Error", JOptionPane.ERROR_MESSAGE);
            return;
        }

        String readSecretKeyChecksum = CryptoUtil.getFileChecksum(readSecretKeyPath, "SHA1");
        String writeSecretKeyChecksum = CryptoUtil.getFileChecksum(writeSecretKeyPath, "SHA1");

        boolean isValidUser = DatabaseClient.getInstance().validateUserLogin(fullName, orgnId, readSecretKeyChecksum, writeSecretKeyChecksum);
        if (isValidUser) {
            JOptionPane.showMessageDialog(null, "Login successful", "Login Successful", JOptionPane.INFORMATION_MESSAGE);

            //set session
            Session.getInstance().setUserName(fullName);
            Session.getInstance().setOrgnId(orgnId);
            Session.getInstance().setOrgnName(orgnName);

            // set the key file in key config
            KeyConfig.getInstance().setUserSecretReadKeyPath(readSecretKeyPath);
            KeyConfig.getInstance().setUserWriteSecretKeyPath(writeSecretKeyPath);

            parent.userHomePanel.update();
            parent.nextPanel(Main.USER_HOME);
        } else {
            JOptionPane.showMessageDialog(null, "Check name, organization, and/or secret keys, and try again", "Login Failure", JOptionPane.ERROR_MESSAGE);
        }

    }//GEN-LAST:event_btnLoginActionPerformed