公章管理页面

This commit is contained in:
fz
2023-10-27 15:18:15 +08:00
parent 181a27e7cb
commit c7944211fa
10 changed files with 432 additions and 122 deletions
+1 -1
View File
@@ -132,7 +132,7 @@
<el-button size="mini" type="text" icon="el-icon-unlock"
v-if="checkPermi(['caseManagement:list:lock']) && scope.row.lockStatus == 1"
@click="ulockClick(scope.row)">解锁</el-button>
<el-button size="mini" type="text" icon="el-icon-upload" @click="uploadCase(scope.row)">上传证据目录</el-button>
<el-button v-if="checkPermi(['caseManagement:list:listEvidence']) && scope.row.caseStatus <= 1" size="mini" type="text" icon="el-icon-upload" @click="uploadCase(scope.row)">上传证据目录</el-button>
<!-- <el-button
size="mini"
type="text"
@@ -78,6 +78,7 @@ export default {
// },
// 文件上传之前处理
beforeAvatarUpload(file) {
this.uploadFiles = [];
this.uploadFiles.push(file)
},
// 用户点击上传调用
@@ -4,8 +4,9 @@
<el-dialog
title="组庭审核"
:visible="showformateCourt"
v-if="showformateCourt"
@close="cancel"
:destroy-on-close="true"
destroy-on-close
center
>
<el-form label-width="150px" v-if="!noArbitrator">
@@ -36,7 +37,7 @@
{{ formateCourtData.arbitratorName }}
</el-tag>
</div>
<div v-if="isAgreePendTral !== 1">
<div v-if="noArbitrator || isAgreePendTral == 0">
<el-table
:data="dataList"
style="width: 100%"
@@ -46,7 +47,7 @@
<el-table-column
type="selection"
width="55"
v-if="isAgreePendTral == 0"
v-if="noArbitrator || isAgreePendTral == 0"
>
</el-table-column>
<el-table-column
@@ -122,6 +123,11 @@ export default {
this.getarbitrAtor();
},
watch: {
showformateCourt(val){
if(val){
this.isAgreePendTral = 1;
}
},
formateCourtData: {
handler(val) {
if (val.arbitratorName == null) {
@@ -1,10 +1,13 @@
<template>
<div>
<el-dialog title="上传证据目录" :visible="uploadCaseVisable" @close="cancel" center :distroy-on-close="true">
<el-upload class="upload-demo" ref="upload" action="https://jsonplaceholder.typicode.com/posts/"
:on-preview="handlePreview" :on-remove="handleRemove" :file-list="fileList" :auto-upload="false">
<el-button slot="trigger" size="small" type="primary">选取文件</el-button>
<el-button style="margin-left: 10px;" size="small" type="success" @click="submitUpload">上传到服务器</el-button>
<el-upload class="upload-demo" :before-upload="beforeUpload" ref="upload" accept=".zip"
action="https://jsonplaceholder.typicode.com/posts/" :action="UploadUrl()" :headers="headers"
:data="filedata" :on-preview="handlePreview" :on-remove="handleRemove" :on-success="handleSuccess" :file-list="fileList"
:auto-upload="false">
<el-button slot="trigger" size="small" type="primary" :disabled="flagBtn">选取文件</el-button>
<el-button style="margin-left: 10px;" size="small" type="success" @click="submitUpload" :disabled="flagBtn">上传压缩包</el-button>
<div slot="tip" class="el-upload__tip">只能上传zip文件,并且格式为一级目录上传申请书证据材料,二级目录为申请书和证据材料</div>
</el-upload>
<div class="title">证据目录结构</div>
<el-tree :data="data" @node-click="handleNodeClick"></el-tree>
@@ -13,71 +16,42 @@
</template>
<!-- hearDate -->
<script>
// import { updateHeardate } from '@/api/caseManagement/caseManagement'
import { evidenceTree } from '@/api/caseAccess/caseEntry.js'
import { getToken } from "@/utils/auth";
export default {
props: ["uploadCaseVisable", "uploadCaseData"],
data() {
return {
fileList: [],
data: [{
label: '寓件编号_中请人名称 / 中请人',
children: [
{
label: '1_货款申调表pdf',
},
{
label: '2_款白同pdf',
},
{
label: '3_抵押证明材林pdt',
},
{
label: '5.贷款利期罚息计算表pdf',
},
{
label: '6.数字签名验证报告.pdl',
},
{
label: '7_律师费明妞报售.pdt',
},
]
data: [],
headers: {
Authorization: "Bearer " + getToken(),
},
{
label: '寓件编号_中请人名称 / 中请人',
children: [
{
label: '1_货款申调表pdf',
},
{
label: '2_款白同pdf',
},
{
label: '3_抵押证明材林pdt',
},
{
label: '5.贷款利期罚息计算表pdf',
},
{
label: '6.数字签名验证报告.pdl',
},
{
label: '7_律师费明妞报售.pdt',
},
]
}],
filedata: {
id:this.uploadCaseData.id
},
flagBtn:false
};
},
watch: {
uploadCaseVisable(val) {
if (val) {
this.evidenceTreeFn({ caseId: this.uploadCaseData.id })
}
}
},
created() {
},
methods: {
UploadUrl() {
return window.location.origin + "/API/caseApplication/uploadZipFile";
},
cancel() {
this.$emit("uploadCaseCancel");
},
submitUpload() {
this.filedata.id = this.uploadCaseData.id
this.$refs.upload.submit();
},
handleRemove(file, fileList) {
@@ -88,6 +62,36 @@ export default {
},
handleNodeClick(data) {
console.log(data);
},
// 递归替换key
setData(data) {
data.forEach((val, i) => {
val.label = val.evidenceName
this.setData(val.children)
})
},
// 获取证据目录
evidenceTreeFn(data) {
evidenceTree(data).then(res => {
this.setData(res.data);
this.data = res.data;
if(this.data.length > 0){
this.flagBtn = true;
}else{
this.flagBtn = false;
}
})
},
handleSuccess(){
this.evidenceTreeFn({ caseId: this.uploadCaseData.id })
},
beforeUpload(file) {
console.log(file.type);
const isZip = file.type === 'application/x-zip-compressed'
if (!isZip) {
this.$message.error('只能上传zip格式的文件')
}
return isZip
}
},
};
@@ -100,4 +104,8 @@ export default {
font-size: 18px;
font-weight: 600;
}
.el-upload__tip {
color: red;
}
</style>