Commit 3b7782ac authored by “yiyousong”'s avatar “yiyousong”

pref:修改应用文档下载

parent d3328e22
......@@ -38,7 +38,6 @@
"@vue/cli-service": "~5.0.0",
"browserslist": "^4.21.4",
"caniuse-lite": "^1.0.30001442",
"filemanager-webpack-plugin": "^8.0.0",
"less": "^4.0.0",
"less-loader": "^8.0.0",
"postcss": "^8.4.12",
......
......@@ -45,6 +45,7 @@
<div
class="list flex aic jcb"
v-for="(i, j) in listArr[active].curInfo"
:key="j"
>
<div class="app-name">{{ i.appName }}</div>
<img
......
......@@ -2,11 +2,7 @@
<div class="PoliticsShow-Container">
<div class="header_box">
<div>
<a-button
type="primary"
class="addclass"
@click="openDetails()"
>
<a-button type="primary" class="addclass" @click="openDetails()">
<span>新增</span>
</a-button>
</div>
......@@ -30,10 +26,7 @@
</a-select-option>
</a-select>
<a-button
type="primary"
class="addclass"
@click="getList()"
<a-button type="primary" class="addclass" @click="getList()"
>搜索</a-button
>
</span>
......@@ -50,7 +43,7 @@
:columns="tableHeaders"
:dataSource="tableSourceData"
>
<template slot="operation" slot-scope="text, record, index">
<template slot="operation" slot-scope="text, record">
<a-button
type="link"
v-if="record.appFileUrl"
......@@ -197,7 +190,7 @@ export default {
handleDowload(url) {
let arr = url.split("/");
const a = document.createElement("a");
a.href = process.env.VUE_APP_API_BASE_URL + "/" + url;
a.href = url;
a.download = arr[arr.length - 1];
a.click();
},
......
......@@ -31,7 +31,7 @@
:columns="tableHeaders"
:dataSource="tableSourceData"
>
<template slot="operation" slot-scope="text, record, index">
<template slot="operation" slot-scope="text, record">
<a-button
type="link"
v-if="record.docFileUrl"
......@@ -161,8 +161,9 @@ export default {
},
handleDowload(url) {
let arr = url.split("/");
console.log(process.env.VUE_APP_API_BASE_URL + "/" + url);
const a = document.createElement("a");
a.href = process.env.VUE_APP_API_BASE_URL + "/" + url;
a.href = url;
a.download = arr[arr.length - 1];
a.click();
},
......
const { defineConfig } = require("@vue/cli-service");
const FileManagerPlugin = require("filemanager-webpack-plugin"); // 压缩文件夹
const isDev = process.env.NODE_ENV === "development";
let plugins = [];
// 避免打本地启项目时自动打zip包
if (!isDev) {
plugins.push(
new FileManagerPlugin({
events: {
onEnd: {
// mkdir: ["./dist"],
delete: ["./zip/"],
copy: [{ source: "./dist", destination: "./zip/dist" }],
archive: [{ source: "./zip", destination: "./zip/门户系统.zip" }],
},
},
})
);
}
module.exports = defineConfig({
transpileDependencies: true,
lintOnSave: false,
// 打包目录
outputDir: "dist",
configureWebpack: {
plugins: [...plugins],
plugins: [],
},
devServer: {
proxy: {
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment