Beispiel #1
0
 def recvMessage(self, clientMsg):
     try:
         msg = {'msg': clientMsg}
         rply = {'rply': ''}
         chatData = readChat.insertMessage(self.userName, msg, rply)
         readChat.updateJson(chatData)
         self.conversation()
     except BaseException as ex:
         print(ex)
Beispiel #2
0
 def sendMessage(self):
     try:
         msg = {'msg': ''}
         rply = {'rply': self.textEdit_2.toPlainText()}
         self.textEdit_2.setText("")
         chatData = readChat.insertMessage(self.userName, msg, rply)
         readChat.updateJson(chatData)
         # print(self.chatData)
         self.conversation()
     except BaseException as ex:
         print(ex)