Auto Commit

上级 c4a2c4f7
......@@ -107,13 +107,6 @@ export default {
onmessage: (msg) => {
if (msg.data === '[DONE]') {
this.loading = false;
axios({
method: "post",
url: "https://flask-wujiaping.inscode.cc/addhistory",
data: dialog.text,
}).then((res) => {
console.log(res.data)
});
return;
};
const data = JSON.parse(msg.data);
......@@ -128,6 +121,15 @@ export default {
dialog.text += text;
}
},
onclose() {
axios({
method: "post",
url: "https://flask-wujiaping.inscode.cc/addhistory",
data: dialog.text,
}).then((res) => {
console.log(res.data)
});
},
onerror: (err) => {
console.log("error", err);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册