调整
This commit is contained in:
		| @@ -28,7 +28,7 @@ | ||||
|         trigger="click" | ||||
|       > | ||||
|         <div class="avatar-wrapper"> | ||||
|           <img :src="avatar" class="user-avatar" alt="avatar" /> | ||||
|           <img :src="avatar" class="user-avatar" /> | ||||
|           <em class="el-icon-caret-bottom" /> | ||||
|         </div> | ||||
|         <el-dropdown-menu slot="dropdown"> | ||||
|   | ||||
| @@ -39,6 +39,7 @@ function connect() { | ||||
|  | ||||
|     ws.onerror = event => { | ||||
|       // console.log({ event }); | ||||
|       ws.close(); | ||||
|       ws = undefined; | ||||
|       window.removeEventListener("message", handleOnMessageReceive); | ||||
|  | ||||
| @@ -56,6 +57,7 @@ function connect() { | ||||
|   } catch (error) { | ||||
|     // console.log(error); | ||||
|     // console.log("浏览器不支持websocket"); | ||||
|     ws.close(); | ||||
|     ws = undefined; | ||||
|     websocketInit(); | ||||
|   } | ||||
|   | ||||
| @@ -91,9 +91,9 @@ export default { | ||||
|   data() { | ||||
|     return { | ||||
|       topicTypeDict: { | ||||
|         0: "建议", | ||||
|         1: "食谱", | ||||
|         2: "咨询", | ||||
|         0: "食材", | ||||
|         1: "身体", | ||||
|         2: "环境", | ||||
|       }, | ||||
|       replyTarget: "", | ||||
|       replyContent: "", | ||||
|   | ||||
		Reference in New Issue
	
	Block a user