File tree Expand file tree Collapse file tree 2 files changed +16
-16
lines changed Expand file tree Collapse file tree 2 files changed +16
-16
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ export default {
4949 <el-button
5050 type =" danger"
5151 :disabled =" !streamLoading"
52- @click =" cancelStream "
52+ @click =" stopStream "
5353 >
5454 中断请求
5555 </el-button >
@@ -82,9 +82,9 @@ export default {
8282 };
8383 },
8484 methods: {
85- cancelStream () {
85+ stopStream () {
8686 if (typeof window !== ' undefined' ) {
87- this .stopStream ();
87+ this .cancelStream ();
8888 }
8989 },
9090 async startSSE () {
@@ -98,7 +98,7 @@ export default {
9898 } catch (err) {
9999 console .error (' Fetch error:' , err);
100100 }
101- }
101+ },
102102 },
103103 watch: {
104104 // 监听流数据变化,更新内容
@@ -177,7 +177,7 @@ export default {
177177
178178 <el-button
179179 :disabled =" !streamLoading"
180- @click =" cancelStream "
180+ @click =" stopStream "
181181 type =" danger"
182182 >
183183 中断请求
@@ -211,9 +211,9 @@ export default {
211211 };
212212 },
213213 methods: {
214- cancelStream () {
214+ stopStream () {
215215 if (typeof window !== ' undefined' ) {
216- this .stopStream ();
216+ this .cancelStream ();
217217 }
218218 },
219219 async startSIPStream () {
@@ -239,7 +239,7 @@ export default {
239239 } catch (err) {
240240 console .error (' Fetch error:' , err);
241241 }
242- }
242+ },
243243 },
244244 watch: {
245245 // 监听流数据变化,更新内容
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ Demonstrates how to handle SSE stream data and display Markdown content in the B
4949 <el-button
5050 type =" danger"
5151 :disabled =" !streamLoading"
52- @click =" cancelStream "
52+ @click =" stopStream "
5353 >
5454 Cancel Request
5555 </el-button >
@@ -83,9 +83,9 @@ Demonstrates how to handle SSE stream data and display Markdown content in the B
8383 };
8484 },
8585 methods: {
86- cancelStream () {
86+ stopStream () {
8787 if (typeof window !== ' undefined' ) {
88- this .stopStream ();
88+ this .cancelStream ();
8989 }
9090 },
9191 async startSSE () {
@@ -99,7 +99,7 @@ Demonstrates how to handle SSE stream data and display Markdown content in the B
9999 } catch (err) {
100100 console .error (' Fetch error:' , err);
101101 }
102- }
102+ },
103103 },
104104 watch: {
105105 // Watch for changes in stream data and update content
@@ -178,7 +178,7 @@ Demonstrates how to handle SIP protocol stream data and use a custom transform s
178178
179179 <el-button
180180 :disabled =" !streamLoading"
181- @click =" cancelStream "
181+ @click =" stopStream "
182182 type =" danger"
183183 >
184184 Cancel Request
@@ -212,9 +212,9 @@ Demonstrates how to handle SIP protocol stream data and use a custom transform s
212212 };
213213 },
214214 methods: {
215- cancelStream () {
215+ stopStream () {
216216 if (typeof window !== ' undefined' ) {
217- this .stopStream ();
217+ this .cancelStream ();
218218 }
219219 },
220220 async startSIPStream () {
@@ -240,7 +240,7 @@ Demonstrates how to handle SIP protocol stream data and use a custom transform s
240240 } catch (err) {
241241 console .error (' Fetch error:' , err);
242242 }
243- }
243+ },
244244 },
245245 watch: {
246246 // Watch for changes in stream data and update content
You can’t perform that action at this time.
0 commit comments