|
@@ -91,7 +91,7 @@
|
|
:data="documents.mould"
|
|
:data="documents.mould"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -107,10 +107,10 @@
|
|
<el-table-column label="操作" width="200" sortable>
|
|
<el-table-column label="操作" width="200" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <a :href="scope.row.fileUrl">
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
<el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
<el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
</a>
|
|
</a>
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -122,7 +122,7 @@
|
|
:data="documents.part"
|
|
:data="documents.part"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -138,9 +138,10 @@
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <el-button size="small">浏览</el-button>
|
|
|
|
- <el-button size="small" @click="download(scope.row.fileUrl)">下载</el-button>
|
|
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
|
|
+ <el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
|
|
+ </a>
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -152,7 +153,7 @@
|
|
:data="documents.check"
|
|
:data="documents.check"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -168,9 +169,10 @@
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <el-button size="small">浏览</el-button>
|
|
|
|
- <el-button size="small" @click="download(scope.row.fileUrl)">下载</el-button>
|
|
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
|
|
+ <el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
|
|
+ </a>
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -182,7 +184,7 @@
|
|
:data="documents.maintain"
|
|
:data="documents.maintain"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -198,9 +200,10 @@
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <el-button size="small">浏览</el-button>
|
|
|
|
- <el-button size="small" @click="download(scope.row.fileUrl)">下载</el-button>
|
|
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
|
|
+ <el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
|
|
+ </a>
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -212,7 +215,7 @@
|
|
:data="documents.update"
|
|
:data="documents.update"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -228,9 +231,10 @@
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <el-button size="small">浏览</el-button>
|
|
|
|
- <el-button size="small" @click="download(scope.row.fileUrl)">下载</el-button>
|
|
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
|
|
+ <el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
|
|
+ </a>
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -242,7 +246,7 @@
|
|
:data="documents.abandon"
|
|
:data="documents.abandon"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
<el-table-column prop="fileName" label="名称" sortable></el-table-column>
|
|
@@ -258,9 +262,10 @@
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<el-table-column label="操作" width="300" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
<el-button size="small" @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button>
|
|
- <el-button size="small">浏览</el-button>
|
|
|
|
- <el-button size="small" @click="download(scope.row.fileUrl)">下载</el-button>
|
|
|
|
- <el-button size="small" type="danger">删除</el-button>
|
|
|
|
|
|
+ <a :href="scope.row.fileUrl" :download="scope.row.fileName">
|
|
|
|
+ <el-button size="small" @click="download(scope.row.id)">下载</el-button>
|
|
|
|
+ </a>
|
|
|
|
+ <el-button size="small" @click="deleteFile(scope.row.id)" type="danger">删除</el-button>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -274,7 +279,7 @@
|
|
:data="operations"
|
|
:data="operations"
|
|
highlight-current-row
|
|
highlight-current-row
|
|
v-loading="listLoading"
|
|
v-loading="listLoading"
|
|
- style="width: 100%;height:300px;"
|
|
|
|
|
|
+ style="width: 100%;"
|
|
>
|
|
>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column type="index" width="40"></el-table-column>
|
|
<el-table-column prop="name" label="姓名" width="400" sortable></el-table-column>
|
|
<el-table-column prop="name" label="姓名" width="400" sortable></el-table-column>
|
|
@@ -410,7 +415,7 @@ export default {
|
|
this.activeFileName = name;
|
|
this.activeFileName = name;
|
|
this.centerDialogVisible = true;
|
|
this.centerDialogVisible = true;
|
|
},
|
|
},
|
|
- //审批
|
|
|
|
|
|
+ //审批文件
|
|
check(adoption) {
|
|
check(adoption) {
|
|
this.http.post(
|
|
this.http.post(
|
|
this.port.mold.moldFileCheck,
|
|
this.port.mold.moldFileCheck,
|
|
@@ -424,6 +429,7 @@ export default {
|
|
message: "审批成功",
|
|
message: "审批成功",
|
|
type: "success"
|
|
type: "success"
|
|
});
|
|
});
|
|
|
|
+ this.getDocument();
|
|
} else {
|
|
} else {
|
|
this.$message({
|
|
this.$message({
|
|
message: res.msg,
|
|
message: res.msg,
|
|
@@ -442,7 +448,7 @@ export default {
|
|
},
|
|
},
|
|
//下载文件
|
|
//下载文件
|
|
download(id) {
|
|
download(id) {
|
|
- console.log(id + "被下载啦");
|
|
|
|
|
|
+ console.log(id + "被下载啦"); //这里应该有下载记录
|
|
},
|
|
},
|
|
//文件上传
|
|
//文件上传
|
|
uploadFile(params) {
|
|
uploadFile(params) {
|
|
@@ -450,6 +456,7 @@ export default {
|
|
var form = new FormData();
|
|
var form = new FormData();
|
|
form.append("file", fileObj);
|
|
form.append("file", fileObj);
|
|
form.append("blongType", this.activeTab);
|
|
form.append("blongType", this.activeTab);
|
|
|
|
+ form.append("mouldId", this.detailId);
|
|
this.http.uploadFile(
|
|
this.http.uploadFile(
|
|
this.port.mold.moldFileUpload,
|
|
this.port.mold.moldFileUpload,
|
|
form,
|
|
form,
|
|
@@ -474,6 +481,35 @@ export default {
|
|
});
|
|
});
|
|
}
|
|
}
|
|
);
|
|
);
|
|
|
|
+ },
|
|
|
|
+ //文件删除
|
|
|
|
+ deleteFile(fileId) {
|
|
|
|
+ this.http.post(
|
|
|
|
+ this.port.mold.moldFileDelete,
|
|
|
|
+ {
|
|
|
|
+ id: fileId
|
|
|
|
+ },
|
|
|
|
+ res => {
|
|
|
|
+ if (res.code == "ok") {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: "删除成功",
|
|
|
|
+ type: "success"
|
|
|
|
+ });
|
|
|
|
+ this.getDocument();
|
|
|
|
+ } else {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: res.msg,
|
|
|
|
+ type: "error"
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ error => {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: error,
|
|
|
|
+ type: "error"
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ );
|
|
}
|
|
}
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|