2023年5月7日 修改错误

This commit is contained in:
bai 2023-05-07 11:37:41 +08:00
parent c7b4c50b88
commit d90c460eca
8 changed files with 22 additions and 67 deletions

View File

@ -23,15 +23,15 @@ const site: AppRouteModule = {
title: '信息中心',
},
},
{
path: 'index2',
name: 'siteIndex2',
component: () => import('/@/views/site/index2.vue'),
meta: {
// affix: true,
title: '测试页',
},
},
// {
// path: 'index2',
// name: 'siteIndex2',
// component: () => import('/@/views/site/index2.vue'),
// meta: {
// // affix: true,
// title: '测试页',
// },
// },
{
path: 'tingKeZuJiMore',
name: 'tingKeZuJiMore',

View File

@ -17,7 +17,7 @@
</video>
</template>
<script lang="ts" setup>
import { ref, onMounted, onBeforeUnmount} from 'vue';
import { ref, onMounted } from 'vue';
import { propTypes } from '/@/utils/propTypes';
import { getDefOptions } from '/@/views/site/common/video/videojs/util';
@ -46,7 +46,7 @@ function init(){
sources: [ { type: props.type, src: props.src, } ]
};
}
let playerMain = <any> videojs(props.videoId, getDefOptions(Object.assign(option, props.videoOption)),() => {
let playerMain = videojs(props.videoId, getDefOptions(Object.assign(option, props.videoOption)),() => {
console.log("加载完成!",playerMain,props.videoOption);
emit('loadEnd',playerMain);
// playerMain.on('pause', function(...d) {

View File

@ -30,7 +30,7 @@
</a-col>
<a-col :span="5">
<a-row>
<a-col :span="24" v-for="(item,index) of tableData" style="text-align: center;">
<a-col :span="24" v-for="(item,index) of tableData" style="text-align: center;" :key="'col-'+index">
<a-card>
<div>
<div style="margin-bottom: .5rem;">
@ -78,18 +78,16 @@ import { nextTick } from 'vue';
import { useRoute } from 'vue-router'
import { getUserId } from '/@/views/site/utils/index';
const mainVideo = <any>ref();
const bVideoRefs = <any>ref([]);
const mainVideo = ref<any>();
const bVideoRefs = ref<any>([]);
const tingKeZuJiAddModal = <any>ref({});
const curentPlayerVideo = <any>ref({});
const kcCardBoxTitle = <any>ref('');
const mainVideoCardBoxTitle = <any>ref('');
const tingKeZuJiAddModal = ref<any>({});
const curentPlayerVideo = ref<any>({});
const kcCardBoxTitle = ref<any>('');
const mainVideoCardBoxTitle = ref<any>('');
const tableData = ref<Recordable>([])
const isError = ref(false);
//{
const model = reactive<Record<string, any>>({ notes:'' });
const route = useRoute();
@ -115,7 +113,7 @@ const getKtangInfo = (params) => defHttp.get({ url: Api.getKtangInfo, params });
onMounted(() => {
if(route.query.id){
model.notes = '';
//ID
//,
list({ pageSize: -1, sfyx: '0', jsbh: route.query.id }).then(res => {
let list = (res?.records) ?? [];
tableData.value = list;
@ -149,15 +147,12 @@ onMounted(() => {
function initVideo(key){
nextTick(() => {
let ref = bVideoRefs.value[key];
console.log(`🚀 --------------------------------------------------🚀`);
console.log(`🚀 ~ file: viewPage.vue:158 ~ nextTick ~ ref:`, key,bVideoRefs,ref);
console.log(`🚀 --------------------------------------------------🚀`);
ref.init();
})
}
function changeLive(item:any){
let mainVideo = <any> document.querySelector('#mainVideo');
let mainVideo = document.querySelector<any>('#mainVideo');
mainVideo?.player?.src([{ type:'application/x-mpegURL',src: item.pullUrl }])
mainVideoCardBoxTitle.value = item.jsmc+item.xm;

View File

@ -60,7 +60,7 @@
</template>
<script lang="ts" setup>
import { ref, reactive, computed, onMounted } from 'vue';
import { ref } from 'vue';
import headerPage from '/@/views/site/common/header.vue';
import footerPage from '/@/views/site/common/footer.vue';
@ -91,26 +91,6 @@
const rkbModeal = ref();
const yykcModeal = ref();
// reactive
let list = reactive({ list: [] });
//
const state = ref({ count: 0 });
let i = ref(1);
//
const stateCount = computed(() => {
return state.value.count;
});
onMounted(() => {
console.log('页面加载完了!');
});
//
function changeClick() {
i.value++;
// list.list.push({ key: i.value });
}
/**
* 刷新预约课程列表数据
*/

View File

@ -1,16 +0,0 @@
<template>
<div>
{{ state }}
<a-button type="error" @click="() => state.count++">点击+1</a-button>
{{ i }}
<a-button type="error" @click="() => i++">点击+1</a-button>
<RouterLink to="/site/index">跳回到主页</RouterLink>
</div>
</template>
<script lang="ts" setup>
import { ref } from 'vue';
const state = ref({ count: 0 });
const i = ref(1);
</script>

View File

@ -78,12 +78,10 @@ function init() {
console.log('init');
listApi({ userid: getUserId(), tingketime: getSysConfig().bxqkssj, ...props.queryParam }).then(res => {
list.value = res ?? [];
console.log(`🚀 ~ file: list.vue:81 ~ listApi ~ list:`, list)
});
}
function onSearch() {
console.log('onSearch');
init();
}

View File

@ -50,7 +50,7 @@
</div>
</template>
<script lang="ts" setup>
import { ref, reactive, watch,onMounted } from 'vue';
import { ref, reactive, watch, onMounted } from 'vue';
import headerPage from '/@/views/site/common/header.vue';
import footerPage from '/@/views/site/common/footer.vue';
import listPage from '/@/views/site/tingKeZuJi/list.vue';
@ -69,7 +69,6 @@ onMounted(() => {
const listRef = ref();
function onSearch(){
console.log('onSearch -A',listRef);
listRef.value.onSearch();
}

View File

@ -231,7 +231,6 @@ function save() {
createMessage.warning(errorMsg);
return;
}
console.log('formData =>',formData);
//
defHttp.post({ url: Api.save, params: formData }, { isTransformResponse: false })
.then((res) => {