Commit 65a30295 by haojie

删除没有用到的方法

parent 526de358
...@@ -50,7 +50,6 @@ import { useStore } from 'vuex'; ...@@ -50,7 +50,6 @@ import { useStore } from 'vuex';
import Loading from '@/components/Loading/FirstCircle.vue'; import Loading from '@/components/Loading/FirstCircle.vue';
import { onBeforeRouteLeave } from 'vue-router'; import { onBeforeRouteLeave } from 'vue-router';
import { injectWindow } from '@/utils/pyqt'; import { injectWindow } from '@/utils/pyqt';
import { show_message } from '@/utils/tool';
import { scriptTypePhonetics } from '@/service/CreateLive'; import { scriptTypePhonetics } from '@/service/CreateLive';
const props = withDefaults( const props = withDefaults(
...@@ -78,16 +77,12 @@ const liveVideoStatus = computed(() => store.getters['live/getLiveVideoStatus']) ...@@ -78,16 +77,12 @@ const liveVideoStatus = computed(() => store.getters['live/getLiveVideoStatus'])
// 视频类型 // 视频类型
const liveInfo = ref({}); const liveInfo = ref({});
const loop = ref(false); const loop = ref(false);
const footerStatus = ref(false);
const showFirstVideo = ref(true); const showFirstVideo = ref(true);
// 第二个视频是否播放 // 第二个视频是否播放
const videoSecondPlay = ref(false); const videoSecondPlay = ref(false);
const confirmVisible = ref(true); const confirmVisible = ref(true);
// 第一个视频是否首次播放
const videoFirstPlay = ref(true);
// 第二个视频是否首次播放 // 第二个视频是否首次播放
const videoSecondFirstPlay = ref(true); const videoSecondFirstPlay = ref(true);
...@@ -99,8 +94,7 @@ const currentPlayMainIndex = ref(props.playMainIndex); ...@@ -99,8 +94,7 @@ const currentPlayMainIndex = ref(props.playMainIndex);
*/ */
// 主视频 // 主视频
const videoFirst = ref<HTMLVideoElement>(); const videoFirst = ref<HTMLVideoElement>();
// 下一个主视频,加载完成才显示--两个主视频标签相互替换
const videoFirstAckup = ref<HTMLVideoElement>();
// 互动视频 // 互动视频
const videoSecond = ref<HTMLVideoElement>(); const videoSecond = ref<HTMLVideoElement>();
...@@ -113,8 +107,6 @@ const secondVideoVolume = ref(initVolume); ...@@ -113,8 +107,6 @@ const secondVideoVolume = ref(initVolume);
let interval = null; let interval = null;
const total = ref(0);
// 离开前先关闭弹窗 // 离开前先关闭弹窗
onBeforeRouteLeave((to, from, next) => { onBeforeRouteLeave((to, from, next) => {
confirmVisible.value = false; confirmVisible.value = false;
......
...@@ -24,7 +24,7 @@ export default function () { ...@@ -24,7 +24,7 @@ export default function () {
.then(() => { .then(() => {
show_message('复制成功', 'success'); show_message('复制成功', 'success');
}) })
.catch((error) => { .catch(() => {
show_message('复制失败', 'error'); show_message('复制失败', 'error');
}); });
} }
......
...@@ -51,19 +51,19 @@ watch( ...@@ -51,19 +51,19 @@ watch(
}, },
); );
const getKey = () => { // const getKey = () => {
return route.name; // return route.name;
}; // };
// 当前路由是否缓存 // 当前路由是否缓存
const routeCache = () => { // const routeCache = () => {
let path = route.path; // let path = route.path;
let index = keepAliveList.value.findIndex((item: any) => item.path == path); // let index = keepAliveList.value.findIndex((item: any) => item.path == path);
if (index !== -1 && keepAliveList.value[index].cache) { // if (index !== -1 && keepAliveList.value[index].cache) {
return true; // return true;
} // }
return false; // return false;
}; // };
</script> </script>
<style lang="less"> <style lang="less">
......
...@@ -54,13 +54,10 @@ import Button from '@/components/Button.vue'; ...@@ -54,13 +54,10 @@ import Button from '@/components/Button.vue';
import Loading from '@/components/loading.vue'; import Loading from '@/components/loading.vue';
import CardOne from '@/components/cardOne.vue'; import CardOne from '@/components/cardOne.vue';
import { onMounted, reactive, ref } from 'vue'; import { onMounted, reactive, ref } from 'vue';
import { useRouter } from 'vue-router';
import routerConfig from '@/router/tool';
import { getDigitalPeopleList } from '@/service/Common'; import { getDigitalPeopleList } from '@/service/Common';
import { LIVE_AUDIT_STATUS } from '@/service/Live'; import { LIVE_AUDIT_STATUS } from '@/service/Live';
import { jumpToCreateLivePage } from '@/router/jump'; import { jumpToCreateLivePage } from '@/router/jump';
const router = useRouter();
const personList = reactive({ const personList = reactive({
list: [], list: [],
}); });
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import { computed, onBeforeUnmount, onMounted, ref, watch } from 'vue'; import { onBeforeUnmount, onMounted, ref, watch } from 'vue';
import AddVideoPlay from '@/components/AddVideoPlay.vue'; import AddVideoPlay from '@/components/AddVideoPlay.vue';
import { getLiveDetail, closeLiveTask } from '@/utils/api/userApi'; import { getLiveDetail, closeLiveTask } from '@/utils/api/userApi';
import { useRoute, useRouter } from 'vue-router'; import { useRoute, useRouter } from 'vue-router';
......
...@@ -164,13 +164,6 @@ ...@@ -164,13 +164,6 @@
label="选择音频" label="选择音频"
@change="createUploadFile" @change="createUploadFile"
></MultipleUpload> ></MultipleUpload>
<!-- <CustomUpload
v-model="mp3Url"
:showOldName="true"
:uploadInfo="uploadInfo"
:config="ossConfig"
@change="createUploadFile"
></CustomUpload> -->
</div> </div>
</ScriptTemplate> </ScriptTemplate>
</div> </div>
...@@ -189,22 +182,19 @@ ...@@ -189,22 +182,19 @@
</template> </template>
<script lang="tsx" setup> <script lang="tsx" setup>
import { computed, onActivated, onBeforeMount, onMounted, reactive, ref, watch } from 'vue'; import { computed, onMounted, reactive, ref, watch } from 'vue';
import Button from '@/components/Button.vue'; import Button from '@/components/Button.vue';
import MultipleUpload from '@/components/MultipleUpload'; import MultipleUpload from '@/components/MultipleUpload';
import CheckBox from '@/components/CheckBox.vue'; import CheckBox from '@/components/CheckBox.vue';
import ConfirmDialog from '@/components/ConfirmDialog.vue'; import ConfirmDialog from '@/components/ConfirmDialog.vue';
import TextScriptDialog from './TextScriptDialog.vue'; import TextScriptDialog from './TextScriptDialog.vue';
import ScriptTemplate from '@/components/ScriptTemplate.vue'; import ScriptTemplate from '@/components/ScriptTemplate.vue';
import CustomUpload from '@/components/upload';
import Select from '@/components/Select.vue'; import Select from '@/components/Select.vue';
import SelectionPopup from '@/components/SelectionPopup.vue'; import SelectionPopup from '@/components/SelectionPopup.vue';
import { show_message, isDev } from '@/utils/tool'; import { show_message, isDev } from '@/utils/tool';
import { createLiveKeys, scriptTypeList, scriptTypeText, scriptTypePhonetics } from '@/service/CreateLive'; import { createLiveKeys, scriptTypeList, scriptTypeText, scriptTypePhonetics } from '@/service/CreateLive';
import { useLiveInfoSubmit } from '@/hooks/useStoreCommit'; import { useLiveInfoSubmit } from '@/hooks/useStoreCommit';
import Textarea from '@/components/textarea.vue';
import { getUploadConfig, getTonesList } from '@/service/Common'; import { getUploadConfig, getTonesList } from '@/service/Common';
import { v4 } from 'uuid';
import { useStore } from 'vuex'; import { useStore } from 'vuex';
import { useRoute } from 'vue-router'; import { useRoute } from 'vue-router';
import useCopy from '@/hooks/useCopy'; import useCopy from '@/hooks/useCopy';
...@@ -279,13 +269,6 @@ const ossConfig = ref({}); ...@@ -279,13 +269,6 @@ const ossConfig = ref({});
const mp3Url = ref(''); const mp3Url = ref('');
// 多选文件列表 // 多选文件列表
const mp3UrlList = ref([]); const mp3UrlList = ref([]);
const uploadInfo = {
label1: '选择音频',
label2: '或拖音频到此处上传',
buttonLabel: '选择音频',
successIcon: imgs.success,
successButtonLabel: '替换音频',
};
// 音频 我的音色 // 音频 我的音色
const phoneticsVisible = ref(false); const phoneticsVisible = ref(false);
...@@ -596,13 +579,6 @@ const phoneticsItemChange = (item: any) => { ...@@ -596,13 +579,6 @@ const phoneticsItemChange = (item: any) => {
}); });
}; };
// 文本提交
const textareaChange = () => {
commitInfo({
[createLiveKeys.textScriptValue]: textareaValue.value,
});
};
// 脚本类型提交 // 脚本类型提交
const scriptTypeChange = (id: string | number) => { const scriptTypeChange = (id: string | number) => {
commitInfo({ commitInfo({
......
...@@ -50,8 +50,6 @@ import CardOne from '@/components/cardOne.vue'; ...@@ -50,8 +50,6 @@ import CardOne from '@/components/cardOne.vue';
import Button from '@/components/Button.vue'; import Button from '@/components/Button.vue';
import Dialog from '@/components/Dialog.vue'; import Dialog from '@/components/Dialog.vue';
import { ref, watch } from 'vue'; import { ref, watch } from 'vue';
import { useRouter } from 'vue-router';
import routerConfig from '@/router/tool';
import { jumpToCreateLivePage } from '@/router/jump'; import { jumpToCreateLivePage } from '@/router/jump';
const props = withDefaults( const props = withDefaults(
...@@ -65,7 +63,6 @@ const props = withDefaults( ...@@ -65,7 +63,6 @@ const props = withDefaults(
const emit = defineEmits(['update:modelValue']); const emit = defineEmits(['update:modelValue']);
const visible = ref(props.modelValue); const visible = ref(props.modelValue);
const router = useRouter();
// 当前选择的数字人 // 当前选择的数字人
const currentCard = ref(''); const currentCard = ref('');
......
...@@ -34,13 +34,9 @@ import CustomLoading from '@/components/loading.vue'; ...@@ -34,13 +34,9 @@ import CustomLoading from '@/components/loading.vue';
import Button from '@/components/Button.vue'; import Button from '@/components/Button.vue';
import { getDraftsList, deleteDrafts } from '@/utils/api/userApi'; import { getDraftsList, deleteDrafts } from '@/utils/api/userApi';
import { onUpdateDrafts } from '@/service/Common'; import { onUpdateDrafts } from '@/service/Common';
import { useRouter } from 'vue-router';
import routerConfig from '@/router/tool';
import { show_message } from '@/utils/tool'; import { show_message } from '@/utils/tool';
import { jumpToCreateLivePage } from '@/router/jump'; import { jumpToCreateLivePage } from '@/router/jump';
const router = useRouter();
const myDigtalList = reactive({ const myDigtalList = reactive({
list: [], list: [],
loading: false, loading: false,
......
...@@ -25,7 +25,6 @@ const props = withDefaults( ...@@ -25,7 +25,6 @@ const props = withDefaults(
playId: 0, playId: 0,
}, },
); );
const videoRef1 = ref<HTMLVideoElement>();
let interval1 = null; let interval1 = null;
const progress = ref(0); const progress = ref(0);
......
import { downloadBlobFile, show_message } from './tool'; import { show_message } from './tool';
import { v4 } from 'uuid'; import { v4 } from 'uuid';
export const createAudioContext = () => { export const createAudioContext = () => {
return new (window.AudioContext || window.webkitAudioContext)(); return new (window.AudioContext || window.webkitAudioContext)();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment