feat: 先做一个简单下载
This commit is contained in:
@ -111,7 +111,10 @@
|
|||||||
|
|
||||||
<h2>2.总结分析</h2>
|
<h2>2.总结分析</h2>
|
||||||
<p style="min-height: 100px;" v-loading="loading">{{ textContent }} </p>
|
<p style="min-height: 100px;" v-loading="loading">{{ textContent }} </p>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<el-button style="position: fixed;bottom: 0;left: 45%;" type="primary" size="default"
|
||||||
|
@click="downloadWithStyles">下载</el-button>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<AddForm ref="addForm" :dict="{ D_GS_XS_LX }" />
|
<AddForm ref="addForm" :dict="{ D_GS_XS_LX }" />
|
||||||
@ -125,6 +128,8 @@ import { getItem, setItem } from '@/utils/storage'
|
|||||||
import { fxbgDywdtj, getDictItem, fxbgJqlxtj, fxbgJqlytj, fxbgYdfx, fxbgXsfx, fxgbCljgf, fxgbCzlfx, fxbgTj } from '@/api/semanticAnalysis'
|
import { fxbgDywdtj, getDictItem, fxbgJqlxtj, fxbgJqlytj, fxbgYdfx, fxbgXsfx, fxgbCljgf, fxgbCzlfx, fxbgTj } from '@/api/semanticAnalysis'
|
||||||
import { completions } from '@/api/semanticAnalysis'
|
import { completions } from '@/api/semanticAnalysis'
|
||||||
import { reactive, ref, onMounted, getCurrentInstance, nextTick, computed, watch } from "vue";
|
import { reactive, ref, onMounted, getCurrentInstance, nextTick, computed, watch } from "vue";
|
||||||
|
import { downloadDocWithStyle } from '@/utils/export.js';
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
// 数据
|
// 数据
|
||||||
search: {
|
search: {
|
||||||
@ -158,10 +163,15 @@ const tabHeight = ref(0)
|
|||||||
// 表格高度计算
|
// 表格高度计算
|
||||||
const tabHeightFn = () => {
|
const tabHeightFn = () => {
|
||||||
tabHeight.value = window.innerHeight - 300
|
tabHeight.value = window.innerHeight - 300
|
||||||
window.onresize = function () {
|
window.onresize = function() {
|
||||||
tabHeightFn();
|
tabHeightFn();
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
const downloadDocWithStyle = () => {
|
||||||
|
if (!tableBox.value?.innerHTML) return;
|
||||||
|
downloadDocWithStyle(tableBox.value?.innerHTML)
|
||||||
|
}
|
||||||
|
|
||||||
const pageData = reactive({
|
const pageData = reactive({
|
||||||
parameter: {},
|
parameter: {},
|
||||||
total: 0,
|
total: 0,
|
||||||
|
|||||||
Reference in New Issue
Block a user