0911
This commit is contained in:
@ -35,7 +35,9 @@
|
||||
<el-button type="warning" plain icon="Upload" @click="handleImport" v-hasPermi="['supplierInput:supplierInput:import']">导入</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button type="warning" plain icon="Download" @click="handleExport" v-hasPermi="['supplierInput:supplierInput:export']">导出模板</el-button>
|
||||
<el-button type="warning" plain icon="Download" @click="handleExport" v-hasPermi="['supplierInput:supplierInput:export']"
|
||||
>导出模板</el-button
|
||||
>
|
||||
</el-col>
|
||||
<right-toolbar v-model:showSearch="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
@ -703,7 +705,7 @@ const handleExport = () => {
|
||||
try {
|
||||
// 创建a标签并直接下载public目录下的静态文件
|
||||
const link = document.createElement('a');
|
||||
link.href = '/assets/files/供应商导入模板.xlsx'; // 使用public目录下现有的Excel文件作为模板
|
||||
link.href = '/xx.xlsx';
|
||||
link.download = '供应商导入模板.xlsx';
|
||||
document.body.appendChild(link);
|
||||
link.click();
|
||||
@ -746,7 +748,7 @@ const handleImport = () => {
|
||||
loading.value = true;
|
||||
// 调用导入接口
|
||||
const res = await leadingIn(formData, queryParams.value.projectId);
|
||||
console.log("111111111111",queryParams.value.projectId);
|
||||
console.log('111111111111', queryParams.value.projectId);
|
||||
|
||||
if (res.code === 200) {
|
||||
proxy?.$modal.msgSuccess('导入成功');
|
||||
|
||||
Reference in New Issue
Block a user