Merge branch 'lhq20250717' into 'dev'
添加附件上传显示提示以及配置项 See merge request itc-framework/ma/2024/front!97
This commit is contained in:
@ -37,6 +37,9 @@
|
|||||||
</a-popover>
|
</a-popover>
|
||||||
</a-input-group>
|
</a-input-group>
|
||||||
</a-upload>
|
</a-upload>
|
||||||
|
<div v-if="VITE_GLOB_UPLOAD_ALERT_TIP?.trim()" style="color: red; margin-top: 8px;">
|
||||||
|
{{VITE_GLOB_UPLOAD_ALERT_TIP}}
|
||||||
|
</div>
|
||||||
<a-modal
|
<a-modal
|
||||||
:bodyStyle="bodyStyle"
|
:bodyStyle="bodyStyle"
|
||||||
:width="800"
|
:width="800"
|
||||||
@ -60,7 +63,7 @@
|
|||||||
import { Icon } from '/@/components/Icon';
|
import { Icon } from '/@/components/Icon';
|
||||||
import { Base64 } from 'js-base64';
|
import { Base64 } from 'js-base64';
|
||||||
import { getAppEnvConfig } from '/@/utils/env';
|
import { getAppEnvConfig } from '/@/utils/env';
|
||||||
|
const { VITE_GLOB_UPLOAD_ALERT_TIP } = getAppEnvConfig();
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
value: String,
|
value: String,
|
||||||
showTip: { type: Boolean, default: true },
|
showTip: { type: Boolean, default: true },
|
||||||
|
|||||||
@ -9,6 +9,9 @@
|
|||||||
>
|
>
|
||||||
上传
|
上传
|
||||||
</a-button>
|
</a-button>
|
||||||
|
<div v-if="VITE_GLOB_UPLOAD_ALERT_TIP?.trim()" style="color: red; margin-top: 8px;">
|
||||||
|
{{VITE_GLOB_UPLOAD_ALERT_TIP}}
|
||||||
|
</div>
|
||||||
<Tooltip placement="bottom" v-if="showPreview">
|
<Tooltip placement="bottom" v-if="showPreview">
|
||||||
<template #title>
|
<template #title>
|
||||||
{{ t('component.upload.uploaded') }}
|
{{ t('component.upload.uploaded') }}
|
||||||
@ -53,7 +56,8 @@
|
|||||||
import UploadModal from './UploadModal.vue';
|
import UploadModal from './UploadModal.vue';
|
||||||
import UploadPreviewModal from './UploadPreviewModal.vue';
|
import UploadPreviewModal from './UploadPreviewModal.vue';
|
||||||
import { getFileList } from '/@/api/system/file';
|
import { getFileList } from '/@/api/system/file';
|
||||||
|
import { getAppEnvConfig } from '/@/utils/env';
|
||||||
|
const { VITE_GLOB_UPLOAD_ALERT_TIP } = getAppEnvConfig();
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
name: 'BasicUpload',
|
name: 'BasicUpload',
|
||||||
components: { UploadModal, Space, UploadPreviewModal, Icon, Tooltip },
|
components: { UploadModal, Space, UploadPreviewModal, Icon, Tooltip },
|
||||||
|
|||||||
@ -15,6 +15,9 @@
|
|||||||
>
|
>
|
||||||
<template #bodyCell="{ column, record }">
|
<template #bodyCell="{ column, record }">
|
||||||
<template v-if="column.dataIndex === 'components'"> {{ t('上传') }} </template>
|
<template v-if="column.dataIndex === 'components'"> {{ t('上传') }} </template>
|
||||||
|
<div v-if="VITE_GLOB_UPLOAD_ALERT_TIP?.trim()" style="color: red; margin-top: 8px;">
|
||||||
|
{{VITE_GLOB_UPLOAD_ALERT_TIP}}
|
||||||
|
</div>
|
||||||
<template v-if="column.dataIndex === 'operation'">
|
<template v-if="column.dataIndex === 'operation'">
|
||||||
<div class="flex">
|
<div class="flex">
|
||||||
<a-button size="small" type="primary" class="mr-2" @click="preview(record.fileUrl)">{{
|
<a-button size="small" type="primary" class="mr-2" @click="preview(record.fileUrl)">{{
|
||||||
@ -52,6 +55,7 @@
|
|||||||
import { useI18n } from '/@/hooks/web/useI18n';
|
import { useI18n } from '/@/hooks/web/useI18n';
|
||||||
import { getAppEnvConfig } from '/@/utils/env';
|
import { getAppEnvConfig } from '/@/utils/env';
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
|
const { VITE_GLOB_UPLOAD_ALERT_TIP } = getAppEnvConfig();
|
||||||
const props = withDefaults(defineProps<{ processId: string }>(), {
|
const props = withDefaults(defineProps<{ processId: string }>(), {
|
||||||
processId: '',
|
processId: '',
|
||||||
});
|
});
|
||||||
|
|||||||
@ -96,6 +96,9 @@
|
|||||||
>
|
>
|
||||||
<img v-if="data.photoUrl" :src="data.photoUrl" />
|
<img v-if="data.photoUrl" :src="data.photoUrl" />
|
||||||
<div v-else>{{ t('点击上传照片') }}</div>
|
<div v-else>{{ t('点击上传照片') }}</div>
|
||||||
|
<div v-if="VITE_GLOB_UPLOAD_ALERT_TIP?.trim()" style="color: red; margin-top: 8px;">
|
||||||
|
{{VITE_GLOB_UPLOAD_ALERT_TIP}}
|
||||||
|
</div>
|
||||||
</a-upload>
|
</a-upload>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
<a-form-item
|
<a-form-item
|
||||||
@ -141,6 +144,7 @@
|
|||||||
import { StampType, StampFileTypeAttributes } from '/@/enums/workflowEnum';
|
import { StampType, StampFileTypeAttributes } from '/@/enums/workflowEnum';
|
||||||
import { dataURLtoBlob } from '/@/utils/file/base64Conver';
|
import { dataURLtoBlob } from '/@/utils/file/base64Conver';
|
||||||
import { useI18n } from '/@/hooks/web/useI18n';
|
import { useI18n } from '/@/hooks/web/useI18n';
|
||||||
|
const { VITE_GLOB_UPLOAD_ALERT_TIP } = getAppEnvConfig();
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
let props = defineProps(['id', 'type', 'info']);
|
let props = defineProps(['id', 'type', 'info']);
|
||||||
const formRef = ref();
|
const formRef = ref();
|
||||||
|
|||||||
Reference in New Issue
Block a user