瀏覽代碼

auto commit

master
jfinn 3 年之前
父節點
當前提交
aa88d08d77
共有 1 個檔案被更改,包括 6 行新增1 行删除
  1. 6
    1
      wsps/consumers.py

+ 6
- 1
wsps/consumers.py 查看文件

41
 	):
41
 	):
42
 	# def connect(self):
42
 	# def connect(self):
43
 	async def ws_conn0(self):
43
 	async def ws_conn0(self):
44
-		
44
+
45
 		print("ChatConsumer:ws_conn0")
45
 		print("ChatConsumer:ws_conn0")
46
 		# p("!!!!!!!!!!!!!!!!!!!!?")
46
 		# p("!!!!!!!!!!!!!!!!!!!!?")
47
 		print("",end="",flush=True)
47
 		print("",end="",flush=True)
48
 		# time.sleep(1.5)
48
 		# time.sleep(1.5)
49
 
49
 
50
 		# p("!!!!!!!!!!!!!!!!!!!!")
50
 		# p("!!!!!!!!!!!!!!!!!!!!")
51
+
52
+		await self.send(text_data=json.dumps({
53
+			'wsconn': {"abc.":12}
54
+		}))
55
+
51
 		# print("",end="",flush=True)
56
 		# print("",end="",flush=True)
52
 		self.accept()
57
 		self.accept()
53
 
58
 

Loading…
取消
儲存