Commit 569644dfea31d471bc53993615bcae9c55953b5f

Authored by fengwotao
1 parent 00f15d50

feat(src/packages): 重写信息里的视频组件,支持自定义上传

@@ -3,7 +3,12 @@ @@ -3,7 +3,12 @@
3 <template> 3 <template>
4 <collapse-item name="视频" expanded> 4 <collapse-item name="视频" expanded>
5 <setting-item-box name="源" alone> 5 <setting-item-box name="源" alone>
6 - <FileUpload :max="1" :threeSupportFileFormat="supportVideoType" @fileStaticUri="handleFileStaticUri" /> 6 + <FileUpload
  7 + :fileSizeConst="fileSizeConst"
  8 + :max="1"
  9 + :threeSupportFileFormat="supportVideoType"
  10 + @fileStaticUri="handleFileStaticUri"
  11 + />
7 </setting-item-box> 12 </setting-item-box>
8 <setting-item-box name="控制"> 13 <setting-item-box name="控制">
9 <setting-item> 14 <setting-item>
@@ -23,7 +28,7 @@ @@ -23,7 +28,7 @@
23 </template> 28 </template>
24 29
25 <script setup lang="ts"> 30 <script setup lang="ts">
26 -import { PropType } from 'vue' 31 +import { PropType, ref } from 'vue'
27 import { option } from './config' 32 import { option } from './config'
28 import { CollapseItem, SettingItemBox, SettingItem } from '@/components/Pages/ChartItemSetting' 33 import { CollapseItem, SettingItemBox, SettingItem } from '@/components/Pages/ChartItemSetting'
29 import FileUpload from '../../../Composes/Mores/ThreeDimensional/components/FileUpload.vue' 34 import FileUpload from '../../../Composes/Mores/ThreeDimensional/components/FileUpload.vue'
@@ -32,6 +37,8 @@ import type { UploadFileInfo } from 'naive-ui' @@ -32,6 +37,8 @@ import type { UploadFileInfo } from 'naive-ui'
32 //视频类型 37 //视频类型
33 const supportVideoType = ['mp4'] 38 const supportVideoType = ['mp4']
34 39
  40 +const fileSizeConst = ref(100)
  41 +
35 // 适应类型 42 // 适应类型
36 const fitList = [ 43 const fitList = [
37 { 44 {