| | |
| | | /> |
| | | </template> |
| | | <template #content> |
| | | <a-spin :loading="onFileSelectedLoading" dot> |
| | | <a-spin :loading="loading" dot style="width: 100%"> |
| | | <a-textarea |
| | | readonly |
| | | auto-size |
| | |
| | | id: agentObj.id, |
| | | }), |
| | | }); |
| | | refreshScroll(); |
| | | |
| | | const reader = response?.body |
| | | ?.pipeThrough(new TextDecoderStream()) |
| | |
| | | const d = val?.data; |
| | | if (typeof d !== 'boolean') { |
| | | console.info('data:', d); |
| | | streamStr.value = d.content; |
| | | if (d?.content) { |
| | | streamStr.value = d.content; |
| | | } else { |
| | | streamStr.value = d.code + d.sql; |
| | | } |
| | | startDisplayStr(); |
| | | } |
| | | } catch (e) { |
| | |
| | | |
| | | if (typeof d !== 'boolean') { |
| | | console.info('data:', d); |
| | | streamStr.value = d.content; |
| | | |
| | | if (d?.content) { |
| | | streamStr.value = d.content; |
| | | } else { |
| | | streamStr.value = d.code; |
| | | } |
| | | |
| | | startDisplayStr(); |
| | | } |
| | | } catch (e) { |
| | |
| | | if (timer) { |
| | | clearTimeout(timer!); |
| | | } |
| | | |
| | | const res = streamStr.value; |
| | | // 将数组中的字符串拼接起来 |
| | | |