This commit is contained in:
parent
4bf259e803
commit
1375ad9845
|
|
@ -9,19 +9,30 @@ export function getTransferReceiceListApi(params) {
|
|||
})
|
||||
}
|
||||
|
||||
// 接收查看、进度
|
||||
export function getTransferRecordFilesApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferReceice/getTransferRecordFiles',
|
||||
method: 'GET',
|
||||
params: params,
|
||||
})
|
||||
}
|
||||
|
||||
export function getTransferReceiceDetailByAcceptApi(params) {
|
||||
// 详情
|
||||
export function getTransferReceiceDetailApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferReceice/getTransferReceiceDetail',
|
||||
method: 'GET',
|
||||
params: params,
|
||||
})
|
||||
}
|
||||
|
||||
// 详情列表
|
||||
export function getTransferReceiceFilesApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferReceice/getTransferReceiceFiles',
|
||||
method: 'GET',
|
||||
params: params,
|
||||
})
|
||||
}
|
||||
|
||||
// 确认接收
|
||||
export function transferReceiveApi(data) {
|
||||
return request({
|
||||
url: '/smartArchives/transferReceice/transferReceive',
|
||||
method: 'POST',
|
||||
data,
|
||||
})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,3 +17,21 @@ export function auditTransferApplyApi(data) {
|
|||
data: data,
|
||||
})
|
||||
}
|
||||
|
||||
// 档案移交审核详情
|
||||
export function getTransferAuditApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferApply/getTransferAudit',
|
||||
method: 'GET',
|
||||
params: params
|
||||
})
|
||||
}
|
||||
|
||||
// 档案移交审核-列表详情
|
||||
export function getTransferAudieFilesByApplyIdApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferApply/getTransferAudieFilesByApplyId',
|
||||
method: 'GET',
|
||||
params: params
|
||||
})
|
||||
}
|
||||
|
|
@ -35,3 +35,12 @@ export function updateTransferRecordFilesStatusApi(data) {
|
|||
data,
|
||||
})
|
||||
}
|
||||
|
||||
// 详情
|
||||
export function getTransferRecordDetailApi(params) {
|
||||
return request({
|
||||
url: '/smartArchives/transferRecord/getTransferRecordDetail',
|
||||
method: 'GET',
|
||||
params: params,
|
||||
})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -104,7 +104,7 @@ export default {
|
|||
}).then(() => {
|
||||
this.$store.dispatch('LogOut').then(() => {
|
||||
location.href = process.env.VUE_APP_ENV === 'production'? '/smart-archiving/index': '/index'
|
||||
getSystemConfigApi();
|
||||
// getSystemConfigApi();
|
||||
})
|
||||
}).catch(() => {})
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,7 +9,8 @@ import { saveAs } from 'file-saver'
|
|||
import { decryptWithSM4, encryptWithSM4, hashWithSM3AndSalt } from '@/utils/sm'
|
||||
import { generateRequestSignature } from '@/utils/crypto-js'
|
||||
|
||||
const encryptRequestFlag = getConfig('encryptRequest')
|
||||
|
||||
const encryptRequestFlag = getConfig('encryptRequest',1)
|
||||
const encryptResponseFlag = getConfig('encryptResponse')
|
||||
const checkIntegrityFlag = getConfig('checkIntegrity')
|
||||
const replayAttackFlag = getConfig('replayAttack')
|
||||
|
|
@ -26,7 +27,8 @@ const systemConfig = {
|
|||
},
|
||||
}
|
||||
|
||||
function getConfig(value) {
|
||||
function getConfig(value,type) {
|
||||
|
||||
let config = sessionStorage.getItem('systemConfig');
|
||||
if(config){
|
||||
const decryptArr = JSON.parse(decryptWithSM4(config));
|
||||
|
|
@ -38,6 +40,7 @@ function getConfig(value) {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
let downloadLoadingInstance
|
||||
export let isRelogin = { show: false }
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
import { getNoAuthConfig } from '@/api/system/setting';
|
||||
import {encryptWithSM4} from '@/utils/sm';
|
||||
|
||||
export function getSystemConfigApi() {
|
||||
getNoAuthConfig().then(res => {
|
||||
export async function getSystemConfigApi() {
|
||||
await getNoAuthConfig().then(res => {
|
||||
console.log(res.data);
|
||||
sessionStorage.setItem('systemConfig', encryptWithSM4(JSON.stringify(res.data)));
|
||||
}).catch(error => {
|
||||
console.error('Failed to fetch config:', error);
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@
|
|||
<script>
|
||||
import _ from 'lodash'
|
||||
import {
|
||||
getTransferRecordFilesApi,
|
||||
getTransferReceiceFilesApi,
|
||||
} from '@/api/filesTransfer/accept'
|
||||
export default {
|
||||
name: "AcceptRecordList",
|
||||
|
|
@ -67,7 +67,7 @@ export default {
|
|||
}
|
||||
|
||||
const transferApplyId = this.rowData.id;
|
||||
const res = await getTransferRecordFilesApi({ transferApplyId });
|
||||
const res = await getTransferReceiceFilesApi({ transferApplyId });
|
||||
console.log(res);
|
||||
|
||||
if (Array.isArray(res.data) && res.data.length > 0) {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@
|
|||
|
||||
<template slot="handle" slot-scope="{ data }">
|
||||
<el-button plain size="mini" type="success" icon="el-icon-warning-outline"
|
||||
v-hasPermi="['transfer:apply:query']" @click="handleDetail(data)">
|
||||
v-hasPermi="['transfer:Receice:query']" @click="handleDetail(data)">
|
||||
详情
|
||||
</el-button>
|
||||
</template>
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ import {
|
|||
getTransferApplyFilesByApplyIdApi,
|
||||
getTransferApplyApi,
|
||||
} from '@/api/filesTransfer/apply'
|
||||
import {auditTransferApplyApi} from '@/api/filesTransfer/audit'
|
||||
import {auditTransferApplyApi,getTransferAuditApi,getTransferAudieFilesByApplyIdApi} from '@/api/filesTransfer/audit'
|
||||
import ViewFile from '@/views/viewFile/viewFile.vue'
|
||||
|
||||
export default {
|
||||
|
|
@ -199,12 +199,10 @@ export default {
|
|||
},
|
||||
async initData() {
|
||||
this.fileList = [];
|
||||
console.error(this.id);
|
||||
|
||||
const res = await getTransferApplyFilesByApplyIdApi({ id: this.id });
|
||||
console.log(res);
|
||||
const res = this.viewStatus === 'audit' ? await getTransferAudieFilesByApplyIdApi({ id: this.id }) : await getTransferApplyFilesByApplyIdApi({ id: this.id });
|
||||
|
||||
const res2 = await getTransferApplyApi({ id: this.id });
|
||||
const res2 = this.viewStatus === 'audit' ? await getTransferAuditApi({ id: this.id }) : await getTransferApplyApi({ id: this.id });
|
||||
this.projectName = res2?.data?.proName || '/';
|
||||
this.receivingOrg = res2?.data?.deptName || '/';
|
||||
// 审批信息
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="proName" label="项目名称" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.proName || '--'}}
|
||||
{{ scope.row.proName || '--' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="singleProName" label="单项工程名称" min-width="150">
|
||||
|
|
@ -48,7 +48,8 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="archiveName" label="档案名称" min-width="300">
|
||||
<template slot-scope="scope">
|
||||
<div class="archive-name-cell file-name-link" @click="viewFile(scope.row)">{{ scope.row.archiveName }}</div>
|
||||
<div class="archive-name-cell file-name-link" @click="viewFile(scope.row)">{{
|
||||
scope.row.archiveName }}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
|
@ -61,26 +62,29 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="proName" label="移交时间" min-width="150">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.proName || '--'}}
|
||||
{{ scope.row.transferDate || '--' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
|
||||
<el-table-column prop="archiveName" label="档案名称" min-width="300">
|
||||
<template slot-scope="scope">
|
||||
<div class="archive-name-cell file-name-link" @click="viewFile(scope.row)">{{ scope.row.archiveName }}</div>
|
||||
<div class="archive-name-cell file-name-link" @click="viewFile(scope.row)">{{
|
||||
scope.row.archiveName }}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="createTime" label="接收状态" min-width="120">
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.integrityStatus === '1'" :type="scope.row.integrityStatus === '1' ? 'success' : 'danger'">
|
||||
{{ scope.row.integrityStatus === '1' ? '已接收' : '未接收' }}
|
||||
<el-tag v-if="scope.row.receiveStatus === '1'"
|
||||
:type="scope.row.receiveStatus === '1' ? 'success' : 'warning'">
|
||||
{{ scope.row.receiveStatus === '1' ? '已接收' : '未接收' }}
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="archiveName" label="操作" min-width="100" v-if="viewStatus === 'accept'">
|
||||
<template slot-scope="scope">
|
||||
<el-button plain icon="el-icon-check" type="primary" size="mini" @click="handleAccept(scope.row)">确认接收</el-button>
|
||||
<el-button plain icon="el-icon-check" type="primary" size="mini" v-if="scope.row.receiveStatus === '0'" hasPermi="['transfer:Receice:accept']"
|
||||
@click="handleAccept(scope.row)">确认接收</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
|
@ -107,23 +111,23 @@
|
|||
</span>
|
||||
</el-dialog>
|
||||
<!-- 预览文件 -->
|
||||
<ViewFile v-if="isViewflag" :rowData="row" :title="title" @closeDialog="closeDialog" @showColose="showColose" :width="600" />
|
||||
<ViewFile v-if="isViewflag" :rowData="row" :title="title" @closeDialog="closeDialog" @showColose="showColose"
|
||||
:width="600" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { decryptWithSM4 } from '@/utils/sm'
|
||||
import { getTransferRecordDetailApi, getTransferRecordFilesApi } from '@/api/filesTransfer/record'
|
||||
import {
|
||||
getTransferApplyFilesByApplyIdApi,
|
||||
getTransferApplyApi
|
||||
} from '@/api/filesTransfer/apply'
|
||||
import {
|
||||
getTransferReceiceDetailByAcceptApi,
|
||||
getTransferReceiceDetailApi,
|
||||
getTransferReceiceFilesApi,
|
||||
transferReceiveApi
|
||||
} from '@/api/filesTransfer/accept'
|
||||
import ViewFile from '@/views/viewFile/viewFile.vue'
|
||||
export default {
|
||||
name: 'RecordDetail',
|
||||
components:{ViewFile},
|
||||
components: { ViewFile },
|
||||
data() {
|
||||
return {
|
||||
id: decryptWithSM4(this.$route.query.id),
|
||||
|
|
@ -135,6 +139,7 @@ export default {
|
|||
isViewflag: false,
|
||||
row: {},
|
||||
title: "",
|
||||
form: {},
|
||||
}
|
||||
},
|
||||
|
||||
|
|
@ -146,14 +151,12 @@ export default {
|
|||
// 恢复页面滚动
|
||||
document.body.style.overflow = 'auto';
|
||||
},
|
||||
created(){
|
||||
created() {
|
||||
this.initData();
|
||||
},
|
||||
methods: {
|
||||
// 预览文件
|
||||
viewFile(row) {
|
||||
console.error(row);
|
||||
|
||||
this.title = "预览";
|
||||
this.row = row;
|
||||
this.isViewflag = true;
|
||||
|
|
@ -166,68 +169,82 @@ export default {
|
|||
},
|
||||
handleClose() {
|
||||
let obj = null;
|
||||
if(this.viewStatus === 'record'){
|
||||
if (this.viewStatus === 'record') {
|
||||
obj = { path: "/archivesManagement/filesTransfer/record" }
|
||||
}else{
|
||||
} else {
|
||||
obj = { path: "/archivesManagement/filesTransfer/accept" }
|
||||
}
|
||||
this.$tab.closeOpenPage(obj)
|
||||
},
|
||||
async initData() {
|
||||
this.fileList = [];
|
||||
const res = await getTransferApplyFilesByApplyIdApi({ id: this.id });
|
||||
console.log(res);
|
||||
const res = this.viewStatus === 'accept' ? await getTransferReceiceFilesApi({ transferApplyId: this.id }) : await getTransferRecordFilesApi({ transferApplyId: this.id });
|
||||
|
||||
const res2 = await getTransferApplyApi({ id: this.id });
|
||||
const res2 = this.viewStatus === 'accept' ? await getTransferReceiceDetailApi({ id: this.id }) : await getTransferRecordDetailApi({ id: this.id });
|
||||
this.projectName = res2?.data?.proName || '/';
|
||||
this.receivingOrg = res2?.data?.deptName || '/';
|
||||
|
||||
if (Array.isArray(res.data) && res.data.length > 0) {
|
||||
res.data.map(item => {
|
||||
const newFile = {
|
||||
id: item.id,
|
||||
proName: item.proName,
|
||||
singleProName: item.singleProName,
|
||||
createUserName: item.createUserName,
|
||||
createTime: item.createTime,
|
||||
archiveName: item?.parParentName + '/' + item?.parentName + '/' + item?.fileName,
|
||||
receiveStatus: item.receiveStatus || '0',
|
||||
transferDate: item.transferDate,
|
||||
fileId: item?.fileId || '',
|
||||
}
|
||||
this.fileList.push(newFile);
|
||||
})
|
||||
}
|
||||
|
||||
},
|
||||
// 确认接收
|
||||
handleAccept(row) {
|
||||
console.log(row);
|
||||
this.form = row;
|
||||
this.confirmDialogVisible = true;
|
||||
|
||||
},
|
||||
// 确认完整性状态
|
||||
confirmTransferStatus() {
|
||||
this.closeConfirmDialog();
|
||||
// 调用移交确认接口
|
||||
/* updateIntegrityStatusApi({ proId: this.projectId })
|
||||
.then(res => {
|
||||
transferReceiveApi({ id: this.form.id }).then(res => {
|
||||
if (res.code === 200) {
|
||||
this.$message.success('完整性确认成功');
|
||||
this.closeConfirmDialog();
|
||||
// 可以在这里添加其他逻辑,比如刷新页面或更新状态
|
||||
this.$message.success(res.msg || '确认接收成功');
|
||||
this.refreshData();
|
||||
} else {
|
||||
this.$message.error(res.msg || '完整性确认失败');
|
||||
this.$message.error(res.msg || '确认接收失败');
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
this.$message.error('完整性确认失败,请重试');
|
||||
console.error('完整性确认失败:', error);
|
||||
}); */
|
||||
},
|
||||
// 关闭确认弹框
|
||||
closeConfirmDialog() {
|
||||
this.confirmDialogVisible = false;
|
||||
/* setTimeout(() => {
|
||||
const obj = { path: "/archivesManagement/fileManager" }
|
||||
this.$tab.closeOpenPage(obj)
|
||||
}, 200); */
|
||||
},
|
||||
|
||||
// 刷新数据
|
||||
async refreshData() {
|
||||
this.fileList = [];
|
||||
const res = await getTransferReceiceFilesApi({ transferApplyId: this.id })
|
||||
if (Array.isArray(res.data) && res.data.length > 0) {
|
||||
res.data.map(item => {
|
||||
const newFile = {
|
||||
id: item.id,
|
||||
proName: item.proName,
|
||||
singleProName: item.singleProName,
|
||||
createUserName: item.createUserName,
|
||||
createTime: item.createTime,
|
||||
archiveName: item?.parParentName + '/' + item?.parentName + '/' + item?.fileName,
|
||||
receiveStatus: item.receiveStatus || '0',
|
||||
transferDate: item.transferDate,
|
||||
fileId: item?.fileId || '',
|
||||
}
|
||||
this.fileList.push(newFile);
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
@ -236,7 +253,8 @@ export default {
|
|||
.detail-container {
|
||||
padding: 20px;
|
||||
background: #fff;
|
||||
height: calc(100vh - 120px); /* 减去头部导航栏的高度 */
|
||||
height: calc(100vh - 120px);
|
||||
/* 减去头部导航栏的高度 */
|
||||
overflow-y: auto;
|
||||
box-sizing: border-box;
|
||||
|
||||
|
|
@ -333,9 +351,10 @@ export default {
|
|||
}
|
||||
}
|
||||
|
||||
.back-btn{
|
||||
.back-btn {
|
||||
height: 50px;
|
||||
}
|
||||
|
||||
/* 确认弹框样式 */
|
||||
.confirm-content {
|
||||
display: flex;
|
||||
|
|
@ -367,10 +386,12 @@ export default {
|
|||
color: #909399;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
.file-name-link {
|
||||
color: #409EFF;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.file-name-link:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue