def acceptdlg(self): ''' On user clicking the login button ''' if self.validateInput(): member = Membership() newPwd = self.txtConfirmPass.text() try: #Set new password member.setPassword(stdm.data.app_dbconn.User.UserName,newPwd) QMessageBox.information(self, QApplication.translate("ChangePasswordDialog","Change Password"), QApplication.translate("ChangePasswordDialog","Your password has successfully been changed")) self.accept() except SecurityException as se: QMessageBox.critical(self, QApplication.translate("ChangePasswordDialog","Password Error"), str(se)) self.txtNewPass.selectAll()
def acceptdlg(self): ''' On user clicking the login button ''' if self.validateInput(): member = Membership() newPwd = self.txtConfirmPass.text() try: #Set new password member.setPassword(stdm.data.app_dbconn.User.UserName, newPwd) QMessageBox.information( self, QApplication.translate("ChangePasswordDialog", "Change Password"), QApplication.translate( "ChangePasswordDialog", "Your password has successfully been changed")) self.accept() except SecurityException as se: QMessageBox.critical( self, QApplication.translate("ChangePasswordDialog", "Password Error"), str(se)) self.txtNewPass.selectAll()