update 标准法规入库/变更流程-流程详情

This commit is contained in:
赵霄
2023-10-10 17:25:51 +08:00
parent eb62f256db
commit dc8046589a
12 changed files with 139 additions and 21 deletions
+3 -1
View File
@@ -29,6 +29,8 @@ import { downloadFile, getFileAccessHttpUrl } from '../api/manage.js'
import { previewPdf } from '../utils/previewPdf.js'
import { Base64 } from 'js-base64'
// 支持预览的文件后缀
const CAN_PREVIEW_FILE_SUFFIX = ['jpg', 'jpeg', 'png', 'raw', 'pdf', 'docx', 'doc']
const FILE_TYPE_IMGS = ['jpg', 'jpeg', 'png', 'raw']
const FILE_TYPE_PDF = 'pdf'
@@ -80,7 +82,7 @@ export default {
}
// 截取文件后缀名
const fileSuffix = file.fileName ? file.fileName.split('.')[file.fileName.split('.').length - 1] : ''
const canPreview = FILE_TYPE_IMGS.some(tt => fileSuffix.toLowerCase() === tt) || fileSuffix.toLowerCase() === FILE_TYPE_PDF
const canPreview = CAN_PREVIEW_FILE_SUFFIX.some(tt => fileSuffix.toLowerCase() === tt)
// 判断是否为可预览格式的文件
if (!canPreview) {
this.$message.loading('该文件类型不支持预览,正在为您准备下载...').then(() => {
+1 -1
View File
@@ -67,7 +67,7 @@ const Base64 = require('js-base64').Base64
// 支持预览的文件类型
const CAN_PREVIEW_FILE_TYPE = ['pdf', 'image']
// 支持预览的文件后缀
const CAN_PREVIEW_FILE_SUFFIX = ['jpg', 'jpeg', 'png', 'raw', 'pdf']
const CAN_PREVIEW_FILE_SUFFIX = ['jpg', 'jpeg', 'png', 'raw', 'pdf', 'docx', 'doc']
const uidGenerator = () => {
return '-' + parseInt(Math.random() * 10000 + 1, 10)
}
+8
View File
@@ -705,6 +705,14 @@ body {
display: block;
margin-bottom: 24px;
white-space: nowrap;
.ant-btn {
margin-left: 8px;
}
.ant-btn:first-child {
margin-left: 0;
}
}
}