Exemple #1
0
	def OK(self):
		usuario = str(self.usserLogin.text()).replace(' ','')
		password = str(self.passLogin.text()).replace(' ','')
		log = fichero(usuario,password)
		if log.login():
			#abrir otra interfaz
			self.c = VentanaCalculadora()
			self.c.show()
			self.hide()
		else:
			self.w = Error()
			self.w.show()
Exemple #2
0
class Ventana(QMainWindow,main_class):
	def __init__(self, parent=None):
		QMainWindow.__init__(self, parent)
		self.setupUi(self)
		self.botonLogin.clicked.connect(self.OK)
		self.w = None
		self.c = None
		
		
 
	def OK(self):
		usuario = str(self.usserLogin.text()).replace(' ','')
		password = str(self.passLogin.text()).replace(' ','')
		log = fichero(usuario,password)
		if log.login():
			#abrir otra interfaz
			self.c = VentanaCalculadora()
			self.c.show()
			self.hide()
		else:
			self.w = Error()
			self.w.show()