This commit is contained in:
@@ -64,7 +64,7 @@ const videoUpload = multer({
|
||||
storage: storage,
|
||||
fileFilter: mixedFileFilter, // 使用混合文件过滤器
|
||||
limits: {
|
||||
fileSize: 100 * 1024 * 1024 // 100MB 限制
|
||||
fileSize: 350 * 1024 * 1024 // 100MB 限制
|
||||
}
|
||||
});
|
||||
|
||||
|
@@ -63,7 +63,7 @@ export const videoApi = {
|
||||
* @returns {Object} 验证结果
|
||||
*/
|
||||
validateVideoFile(file) {
|
||||
const maxSize = apiConfig.upload.video?.maxFileSize || 100 * 1024 * 1024 // 100MB
|
||||
const maxSize = apiConfig.upload.video?.maxFileSize || 350 * 1024 * 1024 // 350MB
|
||||
const allowedTypes = apiConfig.upload.video?.allowedTypes || [
|
||||
'video/mp4',
|
||||
'video/avi',
|
||||
|
@@ -90,7 +90,7 @@ const props = defineProps({
|
||||
},
|
||||
maxSize: {
|
||||
type: Number,
|
||||
default: 100 * 1024 * 1024 // 100MB
|
||||
default: 350 * 1024 * 1024 // 350MB
|
||||
}
|
||||
})
|
||||
|
||||
|
@@ -33,7 +33,7 @@ export const apiConfig = {
|
||||
},
|
||||
// 视频上传配置
|
||||
video: {
|
||||
maxFileSize: 100 * 1024 * 1024, // 100MB
|
||||
maxFileSize: 350 * 1024 * 1024, // 350MB
|
||||
allowedTypes: ['video/mp4', 'video/avi', 'video/mov', 'video/wmv', 'video/flv', 'video/webm'],
|
||||
maxCount: 1 // 最多上传1个视频
|
||||
}
|
||||
|
Reference in New Issue
Block a user