setting.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <template>
  2. <div class="bs-setting-wrap">
  3. <el-form
  4. ref="form"
  5. :model="config"
  6. label-width="90px"
  7. label-position="left"
  8. class="setting-body"
  9. >
  10. <slot name="top" />
  11. <el-form
  12. :model="config.customize"
  13. label-position="left"
  14. class="setting-body"
  15. label-width="90px"
  16. >
  17. <SettingTitle>标题</SettingTitle>
  18. <el-form-item label="播放器名称" class="lc-field-body">
  19. <el-input
  20. v-model="config.title"
  21. clearable
  22. />
  23. </el-form-item>
  24. <SettingTitle>位置</SettingTitle>
  25. <div class="lc-field-body">
  26. <PosWhSetting :config="config" />
  27. </div>
  28. <SettingTitle>基础</SettingTitle>
  29. <div class="lc-field-body">
  30. <el-form-item label="视频链接">
  31. <el-input
  32. v-model="config.customize.videoUrl"
  33. clearable
  34. />
  35. </el-form-item>
  36. <el-form-item label="视频封面">
  37. <el-input
  38. v-model="config.customize.posterUrl"
  39. clearable
  40. />
  41. </el-form-item>
  42. <el-form-item label="视频格式">
  43. <el-select
  44. v-model="config.customize.videoType"
  45. popper-class="bs-el-select"
  46. class="bs-el-select"
  47. >
  48. <el-option
  49. v-for="item in videoTypeList"
  50. :key="item.value"
  51. :label="item.label"
  52. :value="item.value"
  53. />
  54. </el-select>
  55. </el-form-item>
  56. </div>
  57. </el-form>
  58. </el-form>
  59. </div>
  60. </template>
  61. <script>
  62. import SettingTitle from 'packages/SettingTitle/index.vue'
  63. import PosWhSetting from 'packages/BigScreenDesign/RightSetting/PosWhSetting.vue'
  64. export default {
  65. name: 'Border14Setting',
  66. components: {
  67. PosWhSetting,
  68. SettingTitle
  69. },
  70. props: {
  71. config: {
  72. type: Object,
  73. required: true
  74. },
  75. predefineThemeColors: {
  76. type: Array,
  77. default: () => {
  78. return [
  79. '#007aff',
  80. '#1aa97b',
  81. '#ff4d53',
  82. '#1890FF',
  83. '#DF0E1B',
  84. '#0086CC',
  85. '#2B74CF',
  86. '#00BC9D',
  87. '#ED7D32'
  88. ]
  89. }
  90. }
  91. },
  92. data () {
  93. return {
  94. videoTypeList: [
  95. {
  96. label: 'mp4',
  97. value: 'video/mp4'
  98. },
  99. {
  100. label: 'm3u8',
  101. value: 'application/x-mpegURL'
  102. },
  103. {
  104. label: 'flv',
  105. value: 'video/x-flv'
  106. },
  107. {
  108. label: 'mov',
  109. value: 'rtmp/mp4'
  110. }
  111. ]
  112. }
  113. },
  114. watch: {},
  115. mounted () {},
  116. methods: {}
  117. }
  118. </script>
  119. <style lang="scss" scoped>
  120. .lc-field-body {
  121. padding: 12px 16px;
  122. }
  123. </style>